revert prompt_gateway changes

This commit is contained in:
Syed Hashmi 2026-03-16 16:52:35 -07:00
parent 125af57837
commit 95486db92a
2 changed files with 6 additions and 9 deletions

View file

@ -205,8 +205,7 @@ impl HttpContext for StreamContext {
info!("on_http_request_body: sending request to model server");
debug!("request body: {}", json_data);
let timeout_ms = MODEL_SERVER_REQUEST_TIMEOUT_MS;
let timeout_str = timeout_ms.to_string();
let timeout_str = MODEL_SERVER_REQUEST_TIMEOUT_MS.to_string();
let mut headers = vec![
(ARCH_UPSTREAM_HOST_HEADER, MODEL_SERVER_NAME),
@ -231,7 +230,7 @@ impl HttpContext for StreamContext {
headers,
Some(json_data.as_bytes()),
vec![],
Duration::from_millis(timeout_ms),
Duration::from_secs(5),
);
if let Some(content) = self.user_prompt.as_ref().unwrap().content.as_ref() {

View file

@ -171,8 +171,7 @@ impl StreamContext {
callout_context.request_body.messages.clone(),
);
let arch_messages_json = serde_json::to_string(&params).unwrap();
let timeout_ms = DEFAULT_TARGET_REQUEST_TIMEOUT_MS;
let timeout_str = timeout_ms.to_string();
let timeout_str = DEFAULT_TARGET_REQUEST_TIMEOUT_MS.to_string();
let mut headers = vec![
(":method", "POST"),
@ -194,7 +193,7 @@ impl StreamContext {
headers,
Some(arch_messages_json.as_bytes()),
vec![],
Duration::from_millis(timeout_ms),
Duration::from_secs(5),
);
callout_context.response_handler_type = ResponseHandlerType::DefaultTarget;
callout_context.prompt_target_name = Some(default_prompt_target.name.clone());
@ -423,8 +422,7 @@ impl StreamContext {
debug!("on_http_call_response: api call body {:?}", api_call_body);
let timeout_ms = API_REQUEST_TIMEOUT_MS;
let timeout_str = timeout_ms.to_string();
let timeout_str = API_REQUEST_TIMEOUT_MS.to_string();
let http_method_str = http_method.to_string();
let mut headers: HashMap<_, _> = [
@ -459,7 +457,7 @@ impl StreamContext {
headers.into_iter().collect(),
api_call_body.as_deref().map(|s| s.as_bytes()),
vec![],
Duration::from_millis(timeout_ms),
Duration::from_secs(5),
);
info!(