All Products
Search
Document Center

SchedulerX:SchedulerxWorker parameters

Last Updated:Mar 11, 2026

Configure SchedulerxWorker to control how your application connects to SchedulerX, manages resources, and handles shutdown. This topic lists all available parameters grouped by function, with default values and usage guidance.

Connection parameters

These parameters establish the connection between your application and SchedulerX.

ParameterDescriptionDefault valueRequired
setEndpoint(String endpoint)The endpoint for a specific region.NoneYes
setNamespace(String namespace)The namespace ID.NoneYes
setGroupId(String groupId)The application ID (group ID). Generated when you create the application in the SchedulerX console.NoneYes

Authentication parameters

Authenticate your application with SchedulerX. Use either an AccessKey pair or an appKey, not both.

ParameterDescriptionDefault valueRequired
setAliyunAccessKey(String aliyunAccessKey)The AccessKey ID of your Alibaba Cloud account. Not required if you use appKey for authentication.NoneConditional
setAliyunSecretKey(String aliyunSecretKey)The AccessKey secret of your Alibaba Cloud account. Not required if you use appKey for authentication.NoneConditional

Network parameters

Override auto-detected network settings when your environment requires explicit configuration.

ParameterDescriptionDefault valueRequired
setHost(String host)The IP address of the application. Set this when the auto-detected IP address is incorrect, such as in environments with multiple network interface cards (NICs) or VPNs.NoneNo
setPort(int port)The port on which the application listens.NoneNo

Resource pool parameters

Tune resource allocation for concurrent job execution.

ParameterDescriptionDefault valueRequired
setEnableBatchWork(boolean enableBatchWork)Enables grid computing. See Grid computing guidance for details.trueNo
setShareContainerPool(boolean shareConatinerPool)Allows all jobs in the application to share the same container pool. Enable this when many jobs run concurrently. When enabled, setSharePoolSize controls the pool size.falseNo
setSharePoolSize(int sharePoolSize)The size of the shared container pool. Only applies when setShareContainerPool is set to true.64No

Scheduling frequency parameters

Fine-tune job scheduling frequency and delay behavior.

ParameterDescriptionDefault valueRequired
setMapMasterStatusCheckInterval(int interval)The interval, in milliseconds, at which SchedulerX checks whether all tasks are completed in the Map model. Lower values increase the check frequency. Reduce this value to increase the trigger frequency for second-delay jobs.3000No
setEnableSecondDelayCycleIntervalMs(boolean enable)Changes the delay unit for second-delay jobs from seconds to milliseconds in the console. Set to true to increase the trigger frequency for second-delay jobs.falseNo

Graceful shutdown parameters

Control how the application shuts down. setGraceShutdownMode and setGraceShutdownTimeout work together. Graceful shutdown is disabled by default. To enable it, set both parameters: choose a shutdown mode and set a timeout value greater than 0.

ParameterDescriptionDefault valueRequired
setGraceShutdownMode(String mode)The graceful shutdown mode. Valid values: WAIT_ALL (the application closes only after all received jobs and tasks complete) and WAIT_RUNNING (the application closes after running jobs and tasks that have allocated threads complete).None (disabled)No
setGraceShutdownTimeout(long delay)The shutdown grace period in seconds. If not set or set to a value less than or equal to 0, graceful shutdown does not take effect, even when setGraceShutdownMode is configured.NoneNo

Advanced parameters

ParameterDescriptionDefault valueRequired
setBlockAppStart(boolean block)Blocks the application process from starting if SchedulerX fails to complete initialization.NoneNo
setClassLoader(ClassLoader userClassLoader)A custom class loader. May be required for non-Spring applications that use a third-party framework.NoneNo
setLabel(String label)Labels added to the application at startup. Use labels to designate specific workers for job scheduling. Suitable for canary release and stress testing scenarios.NoneNo
setSlsCollectorEnable(boolean enable)Enables Simple Log Service (SLS) log collection.trueNo

Grid computing guidance

The setEnableBatchWork parameter controls grid computing and defaults to true.

  • If your application does not use grid computing, set setEnableBatchWork to false.

  • If your application uses grid computing, keep the default value of true. Setting it to false causes the first job trigger on each worker to be delayed by at least 20 seconds.

Parameter dependencies

Some parameters depend on each other. Configure them together to avoid unexpected behavior.

ParameterDepends onRelationship
setSharePoolSizesetShareContainerPoolsetSharePoolSize only takes effect when setShareContainerPool is true.
setGraceShutdownTimeoutsetGraceShutdownModeBoth must be set for graceful shutdown to work. The timeout must be greater than 0.
setAliyunAccessKeysetAliyunSecretKeyAlways set both together. Not required if you use appKey for authentication.