Skip to content

Instantly share code, notes, and snippets.

@rippinrobr
Last active June 14, 2018 12:23
Show Gist options
  • Save rippinrobr/d35ed9a24d74189931b1b58b43826e5f to your computer and use it in GitHub Desktop.
Save rippinrobr/d35ed9a24d74189931b1b58b43826e5f to your computer and use it in GitHub Desktop.
Starting the actix system
let sys = actix::System::new("conspiracies-api");
// Start 3 parallel db executors
let addr = SyncArbiter::start(3, || {
DbExecutor(SqliteConnection::establish("database/conspiracies.sqlite3").unwrap())
});
..... Route definitions here .....
let _ = sys.run();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment