v1.12.10
This commit is contained in:
parent
c16d239b65
commit
b31639e3e9
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "async-graphql"
|
name = "async-graphql"
|
||||||
version = "1.12.9"
|
version = "1.12.10"
|
||||||
authors = ["sunli <scott_s829@163.com>"]
|
authors = ["sunli <scott_s829@163.com>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
description = "The GraphQL server library implemented by rust"
|
description = "The GraphQL server library implemented by rust"
|
||||||
|
@ -17,8 +17,8 @@ readme = "README.md"
|
||||||
default = ["bson", "uuid", "url", "chrono-tz"]
|
default = ["bson", "uuid", "url", "chrono-tz"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
async-graphql-parser = { path = "async-graphql-parser", version = "0.4.0" }
|
async-graphql-parser = { path = "async-graphql-parser", version = "0.5.0" }
|
||||||
async-graphql-derive = { path = "async-graphql-derive", version = "1.12.9" }
|
async-graphql-derive = { path = "async-graphql-derive", version = "1.12.10" }
|
||||||
anyhow = "1.0.26"
|
anyhow = "1.0.26"
|
||||||
thiserror = "1.0.11"
|
thiserror = "1.0.11"
|
||||||
async-trait = "0.1.30"
|
async-trait = "0.1.30"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "async-graphql-actix-web"
|
name = "async-graphql-actix-web"
|
||||||
version = "1.4.8"
|
version = "1.4.10"
|
||||||
authors = ["sunli <scott_s829@163.com>"]
|
authors = ["sunli <scott_s829@163.com>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
description = "async-graphql for actix-web"
|
description = "async-graphql for actix-web"
|
||||||
|
@ -13,7 +13,7 @@ keywords = ["futures", "async", "graphql"]
|
||||||
categories = ["network-programming", "asynchronous"]
|
categories = ["network-programming", "asynchronous"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
async-graphql = { path = "..", version = "1.12.9" }
|
async-graphql = { path = "..", version = "1.12.10" }
|
||||||
actix-web = "2.0.0"
|
actix-web = "2.0.0"
|
||||||
actix-web-actors = "2.0.0"
|
actix-web-actors = "2.0.0"
|
||||||
actix = "0.9.0"
|
actix = "0.9.0"
|
||||||
|
|
|
@ -127,6 +127,8 @@ where
|
||||||
Subscription: SubscriptionType + Send + Sync + 'static,
|
Subscription: SubscriptionType + Send + Sync + 'static,
|
||||||
{
|
{
|
||||||
fn handle(&mut self, data: Bytes, ctx: &mut Self::Context) {
|
fn handle(&mut self, data: Bytes, ctx: &mut Self::Context) {
|
||||||
ctx.text(std::str::from_utf8(&data).ok().unwrap_or_default());
|
if let Ok(text) = std::str::from_utf8(&data) {
|
||||||
|
ctx.text(text);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "async-graphql-derive"
|
name = "async-graphql-derive"
|
||||||
version = "1.12.9"
|
version = "1.12.10"
|
||||||
authors = ["sunli <scott_s829@163.com>"]
|
authors = ["sunli <scott_s829@163.com>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
description = "Macros for async-graphql"
|
description = "Macros for async-graphql"
|
||||||
|
@ -16,7 +16,7 @@ categories = ["network-programming", "asynchronous"]
|
||||||
proc-macro = true
|
proc-macro = true
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
async-graphql-parser = { path = "../async-graphql-parser", version = "0.4.0" }
|
async-graphql-parser = { path = "../async-graphql-parser", version = "0.5.0" }
|
||||||
proc-macro2 = "1.0.6"
|
proc-macro2 = "1.0.6"
|
||||||
syn = { version = "1.0.20", features = ["full", "extra-traits"] }
|
syn = { version = "1.0.20", features = ["full", "extra-traits"] }
|
||||||
quote = "1.0.3"
|
quote = "1.0.3"
|
||||||
|
|
|
@ -13,7 +13,7 @@ keywords = ["futures", "async", "graphql"]
|
||||||
categories = ["network-programming", "asynchronous"]
|
categories = ["network-programming", "asynchronous"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
async-graphql = { path = "..", version = "1.12.9" }
|
async-graphql = { path = "..", version = "1.12.10" }
|
||||||
lambda_http = { git = "https://github.com/awslabs/aws-lambda-rust-runtime" }
|
lambda_http = { git = "https://github.com/awslabs/aws-lambda-rust-runtime" }
|
||||||
futures = "0.3.0"
|
futures = "0.3.0"
|
||||||
async-trait = "0.1.30"
|
async-trait = "0.1.30"
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "async-graphql-parser"
|
name = "async-graphql-parser"
|
||||||
version = "0.4.0"
|
version = "0.5.0"
|
||||||
authors = ["sunli <scott_s829@163.com>"]
|
authors = ["sunli <scott_s829@163.com>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
description = "GraphQL query parser for async-graphql"
|
description = "GraphQL query parser for async-graphql"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "async-graphql-tide"
|
name = "async-graphql-tide"
|
||||||
version = "1.4.9"
|
version = "1.4.10"
|
||||||
authors = ["vkill <vkill.net@gmail.com>"]
|
authors = ["vkill <vkill.net@gmail.com>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
description = "async-graphql for tide"
|
description = "async-graphql for tide"
|
||||||
|
@ -13,7 +13,7 @@ keywords = ["futures", "async", "graphql"]
|
||||||
categories = ["network-programming", "asynchronous"]
|
categories = ["network-programming", "asynchronous"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
async-graphql = { path = "..", version = "1.12.9" }
|
async-graphql = { path = "..", version = "1.12.10" }
|
||||||
tide = "0.8"
|
tide = "0.8"
|
||||||
async-trait = "0.1.30"
|
async-trait = "0.1.30"
|
||||||
serde_json = "1.0.51"
|
serde_json = "1.0.51"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "async-graphql-warp"
|
name = "async-graphql-warp"
|
||||||
version = "1.4.9"
|
version = "1.4.10"
|
||||||
authors = ["sunli <scott_s829@163.com>"]
|
authors = ["sunli <scott_s829@163.com>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
description = "async-graphql for warp"
|
description = "async-graphql for warp"
|
||||||
|
@ -13,7 +13,7 @@ keywords = ["futures", "async", "graphql"]
|
||||||
categories = ["network-programming", "asynchronous"]
|
categories = ["network-programming", "asynchronous"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
async-graphql = { path = "..", version = "1.12.9" }
|
async-graphql = { path = "..", version = "1.12.10" }
|
||||||
warp = "0.2.2"
|
warp = "0.2.2"
|
||||||
futures = "0.3.0"
|
futures = "0.3.0"
|
||||||
bytes = "0.5.4"
|
bytes = "0.5.4"
|
||||||
|
|
|
@ -175,15 +175,12 @@ where
|
||||||
select! {
|
select! {
|
||||||
bytes = srx.next() => {
|
bytes = srx.next() => {
|
||||||
if let Some(bytes) = bytes {
|
if let Some(bytes) = bytes {
|
||||||
if tx
|
if let Ok(text) = String::from_utf8(bytes.to_vec()) {
|
||||||
.send(Message::text(
|
if tx.send(Message::text(text)).await.is_err()
|
||||||
String::from_utf8(bytes.to_vec()).unwrap()
|
|
||||||
))
|
|
||||||
.await
|
|
||||||
.is_err()
|
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -240,15 +237,11 @@ where
|
||||||
select! {
|
select! {
|
||||||
bytes = srx.next() => {
|
bytes = srx.next() => {
|
||||||
if let Some(bytes) = bytes {
|
if let Some(bytes) = bytes {
|
||||||
if tx
|
if let Ok(text) = String::from_utf8(bytes.to_vec()) {
|
||||||
.send(Message::text(
|
if tx.send(Message::text(text)).await.is_err() {
|
||||||
String::from_utf8(bytes.to_vec()).unwrap()
|
|
||||||
))
|
|
||||||
.await
|
|
||||||
.is_err()
|
|
||||||
{
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user