chore: increase chat timeout (#768)
This commit is contained in:
parent
54b811125e
commit
773efcd91a
|
|
@ -6,6 +6,7 @@ use shared_entity::dto::ai_dto::{
|
|||
SummarizeRowResponse, TranslateRowParams, TranslateRowResponse,
|
||||
};
|
||||
use shared_entity::response::{AppResponse, AppResponseError};
|
||||
use std::time::Duration;
|
||||
use tracing::instrument;
|
||||
|
||||
impl Client {
|
||||
|
|
@ -46,6 +47,7 @@ impl Client {
|
|||
.http_client_with_auth(Method::POST, &url)
|
||||
.await?
|
||||
.json(¶ms)
|
||||
.timeout(Duration::from_secs(30))
|
||||
.send()
|
||||
.await?;
|
||||
|
||||
|
|
@ -66,6 +68,7 @@ impl Client {
|
|||
.http_client_with_auth(Method::POST, &url)
|
||||
.await?
|
||||
.json(¶ms)
|
||||
.timeout(Duration::from_secs(30))
|
||||
.send()
|
||||
.await?;
|
||||
log_request_id(&resp);
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@ use shared_entity::dto::ai_dto::{
|
|||
use shared_entity::response::{AppResponse, AppResponseError};
|
||||
use std::pin::Pin;
|
||||
use std::task::{Context, Poll};
|
||||
use std::time::Duration;
|
||||
use tracing::error;
|
||||
|
||||
impl Client {
|
||||
|
|
@ -111,6 +112,7 @@ impl Client {
|
|||
let resp = self
|
||||
.http_client_with_auth(Method::GET, &url)
|
||||
.await?
|
||||
.timeout(Duration::from_secs(30))
|
||||
.send()
|
||||
.await?;
|
||||
log_request_id(&resp);
|
||||
|
|
@ -130,6 +132,7 @@ impl Client {
|
|||
let resp = self
|
||||
.http_client_with_auth(Method::GET, &url)
|
||||
.await?
|
||||
.timeout(Duration::from_secs(30))
|
||||
.send()
|
||||
.await?;
|
||||
log_request_id(&resp);
|
||||
|
|
|
|||
Loading…
Reference in New Issue