stock news thing
This commit is contained in:
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
**/target
|
||||
1904
stock_news_publisher/Cargo.lock
generated
Normal file
1904
stock_news_publisher/Cargo.lock
generated
Normal file
File diff suppressed because it is too large
Load Diff
12
stock_news_publisher/Cargo.toml
Normal file
12
stock_news_publisher/Cargo.toml
Normal file
@@ -0,0 +1,12 @@
|
||||
[package]
|
||||
name = "stock_news_publisher"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
log = "0.4.24"
|
||||
simple_logger = "5.0.0"
|
||||
redis = "0.28.0"
|
||||
reqwest = {version = "0.12.12", features = ["blocking"]}
|
||||
rmp-serde = "1.3.0"
|
||||
serde = "1.0.217"
|
||||
22
stock_news_publisher/src/main.rs
Normal file
22
stock_news_publisher/src/main.rs
Normal file
@@ -0,0 +1,22 @@
|
||||
use log::info;
|
||||
use redis::{Client, Commands};
|
||||
use std::thread;
|
||||
|
||||
pub const NEWS_API_KEY: &str = "QdRyR4ztkKKeBq8btsOW0QVpiHWPQDnCRa6rBUkG";
|
||||
fn main() {
|
||||
println!("Hello, world!");
|
||||
simple_logger::init().unwrap();
|
||||
info!("Logging operational");
|
||||
// program the publpisher here
|
||||
|
||||
let client = Client::open("redis::/192.168.1.23/").unwrap();
|
||||
|
||||
let mut connection = client.get_connection().unwrap();
|
||||
|
||||
|
||||
}
|
||||
|
||||
#[derive(Debug, Copy, Clone)]
|
||||
struct Notification{
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user