cleanup
This commit is contained in:
parent
93bccd3b19
commit
05e30e4420
4 changed files with 1 additions and 10 deletions
1
Cargo.lock
generated
1
Cargo.lock
generated
|
@ -2510,7 +2510,6 @@ dependencies = [
|
||||||
"futures",
|
"futures",
|
||||||
"futures-util",
|
"futures-util",
|
||||||
"lazy_static",
|
"lazy_static",
|
||||||
"redis",
|
|
||||||
"serde",
|
"serde",
|
||||||
"serde-aux",
|
"serde-aux",
|
||||||
"serde_json",
|
"serde_json",
|
||||||
|
|
|
@ -16,7 +16,7 @@ services:
|
||||||
image: ghcr.io/genudine/saerro/api:latest
|
image: ghcr.io/genudine/saerro/api:latest
|
||||||
pull_policy: always
|
pull_policy: always
|
||||||
ports:
|
ports:
|
||||||
- 8000:80
|
- 80:8000
|
||||||
links:
|
links:
|
||||||
- tsdb
|
- tsdb
|
||||||
restart: always
|
restart: always
|
||||||
|
|
|
@ -6,7 +6,6 @@ edition = "2021"
|
||||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
redis = { version = "0.22.1", default_features = false, features = ["r2d2"] }
|
|
||||||
lazy_static = "1.4.0"
|
lazy_static = "1.4.0"
|
||||||
tokio-tungstenite = { version = "0.18.0", features=["native-tls"] }
|
tokio-tungstenite = { version = "0.18.0", features=["native-tls"] }
|
||||||
serde = { version = "1.0.149", features = ["derive"] }
|
serde = { version = "1.0.149", features = ["derive"] }
|
||||||
|
|
|
@ -14,8 +14,6 @@ use tokio_tungstenite::{connect_async, tungstenite::Message};
|
||||||
mod translators;
|
mod translators;
|
||||||
|
|
||||||
lazy_static! {
|
lazy_static! {
|
||||||
// static ref PAIR: String = env::var("PAIR").unwrap_or_default();
|
|
||||||
// static ref ROLE: String = env::var("ROLE").unwrap_or("primary".to_string());
|
|
||||||
static ref WS_ADDR: String = env::var("WS_ADDR").unwrap_or_default();
|
static ref WS_ADDR: String = env::var("WS_ADDR").unwrap_or_default();
|
||||||
static ref PG: AsyncOnce<sqlx::PgPool> = AsyncOnce::new(async {
|
static ref PG: AsyncOnce<sqlx::PgPool> = AsyncOnce::new(async {
|
||||||
let db_url = std::env::var("DATABASE_URL")
|
let db_url = std::env::var("DATABASE_URL")
|
||||||
|
@ -77,11 +75,6 @@ struct AnalyticsEvent {
|
||||||
event_name: String,
|
event_name: String,
|
||||||
}
|
}
|
||||||
|
|
||||||
// async fn track_pop(pop_event: PopEvent) {
|
|
||||||
// track_pop_db(pop_event.clone()).await;
|
|
||||||
// track_pop_redis(pop_event).await;
|
|
||||||
// }
|
|
||||||
|
|
||||||
async fn track_pop(pop_event: PopEvent) {
|
async fn track_pop(pop_event: PopEvent) {
|
||||||
// println!("[ws/track_pop]");
|
// println!("[ws/track_pop]");
|
||||||
let pool = PG.get().await;
|
let pool = PG.get().await;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue