Skip to content

Commit

Permalink
Disable async serve handler in Ray Service cluster (ray-project#447)
Browse files Browse the repository at this point in the history
  • Loading branch information
fishbone authored Aug 9, 2022
1 parent c802311 commit eaa6790
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions ray-operator/controllers/ray/common/constant.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ const (
RAY_TIMEOUT_MS_TASK_WAIT_FOR_DEATH_INFO = "RAY_timeout_ms_task_wait_for_death_info"
RAY_GCS_SERVER_REQUEST_TIMEOUT_SECONDS = "RAY_gcs_server_request_timeout_seconds"
RAY_SERVE_KV_TIMEOUT_S = "RAY_SERVE_KV_TIMEOUT_S"
SERVE_DEPLOYMENT_HANDLE_IS_SYNC = "SERVE_DEPLOYMENT_HANDLE_IS_SYNC"

// Ray core default configurations
DefaultRedisPassword = "5241590000000000"
Expand Down
4 changes: 4 additions & 0 deletions ray-operator/controllers/ray/common/pod.go
Original file line number Diff line number Diff line change
Expand Up @@ -568,6 +568,10 @@ func setContainerEnvVars(pod *v1.Pod, rayContainerIndex int, rayNodeType rayiov1
gcsTimeoutEnv := v1.EnvVar{Name: RAY_GCS_SERVER_REQUEST_TIMEOUT_SECONDS, Value: "5"}
container.Env = append(container.Env, gcsTimeoutEnv)
}
if !envVarExists(SERVE_DEPLOYMENT_HANDLE_IS_SYNC, container.Env) {
serveHandleSync := v1.EnvVar{Name: SERVE_DEPLOYMENT_HANDLE_IS_SYNC, Value: "1"}
container.Env = append(container.Env, serveHandleSync)
}
if !envVarExists(RAY_SERVE_KV_TIMEOUT_S, container.Env) {
serveKvTimeoutEnv := v1.EnvVar{Name: RAY_SERVE_KV_TIMEOUT_S, Value: "5"}
container.Env = append(container.Env, serveKvTimeoutEnv)
Expand Down

0 comments on commit eaa6790

Please sign in to comment.