Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Invalid SYNC_DATABASE_URL" with sqlite and syncstorage-rs #255

Open
BobVul opened this issue Oct 8, 2020 · 2 comments
Open

"Invalid SYNC_DATABASE_URL" with sqlite and syncstorage-rs #255

BobVul opened this issue Oct 8, 2020 · 2 comments

Comments

@BobVul
Copy link

BobVul commented Oct 8, 2020

I'm using the same config I had pre-rs.

Is SQLite no longer supported?

The storage tests also fail on make test with 404 errors.

sqluri = sqlite:////root/syncserver.db

I get the following stacktrace on make serve:

Invalid SYNC_DATABASE_URL: sqlite:////root/syncserver.db, status: 500, metric_label: None }', src/main.rs:51:64
stack backtrace:
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: ApiError { inner:    0: failure::backtrace::internal::InternalBacktrace::new
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/failure-0.1.8/src/backtrace/internal.rs:46
   1: failure::backtrace::Backtrace::new
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/failure-0.1.8/src/backtrace/mod.rs:121
   2: failure::context::Context<D>::new
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/failure-0.1.8/src/context.rs:84
   3: <syncstorage::error::ApiError as core::convert::From<syncstorage::error::ApiErrorKind>>::from
             at src/error.rs:335
   4: <T as core::convert::Into<U>>::into
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/core/src/convert/mod.rs:564
   5: <syncstorage::error::ApiError as core::convert::From<syncstorage::db::error::DbError>>::from
             at src/error.rs:347
   6: syncstorage::server::Server::with_settings::{{closure}}
             at src/server/mod.rs:161
   7: <core::future::from_generator::GenFuture<T> as core::future::future::Future>::poll
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/core/src/future/mod.rs:79
   8: syncstorage::main::{{closure}}
             at src/main.rs:51
   9: <core::future::from_generator::GenFuture<T> as core::future::future::Future>::poll
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/core/src/future/mod.rs:79
  10: <tokio::task::local::RunUntil<T> as core::future::future::Future>::poll::{{closure}}::{{closure}}
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/task/local.rs:528
  11: tokio::coop::with_budget::{{closure}}
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/coop.rs:127
  12: std::thread::local::LocalKey<T>::try_with
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/thread/local.rs:265
  13: std::thread::local::LocalKey<T>::with
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/thread/local.rs:241
  14: tokio::coop::with_budget
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/coop.rs:120
      tokio::coop::budget
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/coop.rs:96
      <tokio::task::local::RunUntil<T> as core::future::future::Future>::poll::{{closure}}
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/task/local.rs:528
  15: tokio::macros::scoped_tls::ScopedKey<T>::set
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/macros/scoped_tls.rs:63
  16: tokio::task::local::LocalSet::with
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/task/local.rs:442
  17: <tokio::task::local::RunUntil<T> as core::future::future::Future>::poll
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/task/local.rs:518
  18: tokio::task::local::LocalSet::run_until::{{closure}}
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/task/local.rs:392
  19: <core::future::from_generator::GenFuture<T> as core::future::future::Future>::poll
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/core/src/future/mod.rs:79
  20: tokio::runtime::basic_scheduler::BasicScheduler<P>::block_on::{{closure}}::{{closure}}
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/runtime/basic_scheduler.rs:131
  21: tokio::coop::with_budget::{{closure}}
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/coop.rs:127
  22: std::thread::local::LocalKey<T>::try_with
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/thread/local.rs:265
  23: std::thread::local::LocalKey<T>::with
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/thread/local.rs:241
  24: tokio::coop::with_budget
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/coop.rs:120
      tokio::coop::budget
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/coop.rs:96
      tokio::runtime::basic_scheduler::BasicScheduler<P>::block_on::{{closure}}
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/runtime/basic_scheduler.rs:131
  25: tokio::runtime::basic_scheduler::enter::{{closure}}
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/runtime/basic_scheduler.rs:213
  26: tokio::macros::scoped_tls::ScopedKey<T>::set
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/macros/scoped_tls.rs:63
  27: tokio::runtime::basic_scheduler::enter
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/runtime/basic_scheduler.rs:213
  28: tokio::runtime::basic_scheduler::BasicScheduler<P>::block_on
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/runtime/basic_scheduler.rs:123
  29: tokio::runtime::Runtime::block_on::{{closure}}
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/runtime/mod.rs:444
  30: tokio::runtime::context::enter
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/runtime/context.rs:72
  31: tokio::runtime::handle::Handle::enter
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/runtime/handle.rs:76
  32: tokio::runtime::Runtime::block_on
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/runtime/mod.rs:441
  33: tokio::task::local::LocalSet::block_on
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-0.2.22/src/task/local.rs:353
  34: actix_rt::runtime::Runtime::block_on
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/actix-rt-1.1.1/src/runtime.rs:89
  35: actix_rt::builder::SystemRunner::block_on
             at /root/.cargo/registry/src/github.com-1ecc6299db9ec823/actix-rt-1.1.1/src/builder.rs:187
  36: syncstorage::main
             at src/main.rs:27
  37: core::ops::function::FnOnce::call_once
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/core/src/ops/function.rs:227
  38: std::sys_common::backtrace::__rust_begin_short_backtrace
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/sys_common/backtrace.rs:137
  39: std::rt::lang_start::{{closure}}
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/rt.rs:66
  40: core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/core/src/ops/function.rs:259
      std::panicking::try::do_call
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/panicking.rs:373
      std::panicking::try
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/panicking.rs:337
      std::panic::catch_unwind
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/panic.rs:379
      std::rt::lang_start_internal
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/rt.rs:51
  41: std::rt::lang_start
             at /rustc/18bf6b4f01a6feaf7259ba7cdae58031af1b7b39/library/std/src/rt.rs:65
  42: main
  43: __libc_start_main
  44: _start
@jrconlin
Copy link
Member

jrconlin commented Oct 9, 2020

First off, we're probably going to roll back the syncstorage-rs PR for now, since there are a few issues that have come up.

The sql library we're using pretty much wants mysql like DSNs, and I think there's some other issues with sqlite support as well. I'm not sure if we'll be able to support it out of the box, but as always, we welcome possible fixes.

@BobVul
Copy link
Author

BobVul commented Oct 10, 2020

That's fair enough, thanks for the clarification. Unfortunately I don't think I know enough Rust to directly contribute anything that isn't terribly hacky.

Mic92 pushed a commit to Mic92/syncserver that referenced this issue Feb 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants