diff --git a/Cargo.lock b/Cargo.lock index 37b6ab1..af81838 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1925,7 +1925,7 @@ dependencies = [ [[package]] name = "gftp" version = "0.4.0" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "actix-rt", "anyhow", @@ -5811,7 +5811,7 @@ dependencies = [ [[package]] name = "ya-agreement-utils" version = "0.6.0" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "chrono", "regex", @@ -5871,7 +5871,7 @@ dependencies = [ [[package]] name = "ya-core-model" version = "0.9.0" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "chrono", "derive_more", @@ -5892,7 +5892,7 @@ dependencies = [ [[package]] name = "ya-counters" version = "0.2.0" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "actix", "actix-rt", @@ -5910,23 +5910,29 @@ dependencies = [ [[package]] name = "ya-gsb-http-proxy" version = "0.1.0" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "actix", "actix-http", + "actix-rt", "actix-web", "async-stream", "chrono", + "env_logger 0.10.2", "futures 0.3.30", "futures-core", + "hex", "http 1.1.0", "log", + "rand 0.8.5", "reqwest", "serde", "serde_derive", "serde_json", "thiserror", "tokio", + "ya-client-model 0.6.0", + "ya-core-model", "ya-counters", "ya-service-bus", ] @@ -5988,7 +5994,7 @@ dependencies = [ [[package]] name = "ya-runtime-api" version = "0.7.1" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "anyhow", "bytes 1.6.0", @@ -6059,7 +6065,7 @@ dependencies = [ [[package]] name = "ya-transfer" version = "0.3.0" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "actix", "actix-http", @@ -6101,7 +6107,7 @@ dependencies = [ [[package]] name = "ya-utils-futures" version = "0.3.0" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "futures 0.3.30", "tokio", @@ -6110,7 +6116,7 @@ dependencies = [ [[package]] name = "ya-utils-path" version = "0.1.0" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "anyhow", "directories", @@ -6120,7 +6126,7 @@ dependencies = [ [[package]] name = "ya-utils-process" version = "0.3.0" -source = "git+https://github.com/golemfactory/yagna.git?rev=c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b#c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" +source = "git+https://github.com/golemfactory/yagna.git?rev=891f319668add90938183d7f266790329bcb5f08#891f319668add90938183d7f266790329bcb5f08" dependencies = [ "actix", "anyhow", diff --git a/Cargo.toml b/Cargo.toml index 4a8c8b4..596068f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -12,14 +12,14 @@ members = [ ] [dependencies] -ya-core-model = { git = "https://github.com/golemfactory/yagna.git", rev = "c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b", features = ["activity", "appkey"] } -ya-runtime-api = { git = "https://github.com/golemfactory/yagna.git", rev = "c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" } +ya-core-model = { git = "https://github.com/golemfactory/yagna.git", rev = "891f319668add90938183d7f266790329bcb5f08", features = ["activity", "appkey"] } +ya-runtime-api = { git = "https://github.com/golemfactory/yagna.git", rev = "891f319668add90938183d7f266790329bcb5f08" } +ya-utils-process = { git = "https://github.com/golemfactory/yagna.git", rev = "891f319668add90938183d7f266790329bcb5f08" } ya-service-bus = "0.7.1" ya-client-model = "0.6.0" ya-agreement-utils = "0.5" -ya-utils-process = { git = "https://github.com/golemfactory/yagna.git", rev = "c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" } -ya-transfer = { git = "https://github.com/golemfactory/yagna.git", rev = "c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" } -ya-counters = { git = "https://github.com/golemfactory/yagna.git", rev = "c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" } +ya-transfer = { git = "https://github.com/golemfactory/yagna.git", rev = "891f319668add90938183d7f266790329bcb5f08" } +ya-counters = { git = "https://github.com/golemfactory/yagna.git", rev = "891f319668add90938183d7f266790329bcb5f08" } gpu-detection = { path = "gpu-detection" } actix = "0.13" @@ -41,7 +41,7 @@ flexi_logger = { version = "0.28", features = ["colors"] } regex = "1" reqwest = { version = "0.11", features = ["blocking", "json"] } async-stream = "0.3" -ya-gsb-http-proxy = { git = "https://github.com/golemfactory/yagna.git", rev = "c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" } +ya-gsb-http-proxy = { git = "https://github.com/golemfactory/yagna.git", rev = "891f319668add90938183d7f266790329bcb5f08" } http = "1.1" bytes = "1.5" humantime = "2.1" @@ -53,7 +53,7 @@ assert_cmd = "2.0" predicates = "3.1" [patch.crates-io] -ya-core-model = { git = "https://github.com/golemfactory/yagna.git", rev = "c16a6baa45f523ecf4dd8f190d5d0db5cd44c14b" } +ya-core-model = { git = "https://github.com/golemfactory/yagna.git", rev = "891f319668add90938183d7f266790329bcb5f08" } [build-dependencies] static_vcruntime = "2.0" diff --git a/src/main.rs b/src/main.rs index 7916a9b..405cfc6 100644 --- a/src/main.rs +++ b/src/main.rs @@ -25,7 +25,6 @@ use ya_counters::message::GetCounters; use ya_counters::service::{CountersService, CountersServiceBuilder}; use ya_counters::TimeCounter; use ya_gsb_http_proxy::gsb_to_http::GsbToHttpProxy; -use ya_gsb_http_proxy::message::GsbHttpCallMessage; use ya_service_bus::typed::{self as gsb, Endpoint}; use ya_transfer::transfer::{DeployImage, Shutdown, TransferService, TransferServiceContext}; @@ -466,10 +465,7 @@ async fn run( } }); - gsb::bind_stream(&exe_unit_url, move |message: GsbHttpCallMessage| { - let stream = gsb_proxy.pass(message); - Box::pin(stream.map(Ok)) - }); + gsb_proxy.bind(&exe_unit_url); }; send_state( &ctx,