Consultor Eletrônico



Kbase P16252: What is autoTrimTimeout value?
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   4/21/2009
Status: Verified

GOAL:

What is autoTrimTimeout value?

GOAL:

How is autoTrimTimeout measured?

GOAL:

How does the broker calculate currently numbers of the running Agents and Servers?

GOAL:

Why does WebSpeed Agents / AppServer Servers decrease after while?

GOAL:

After while the number of WebSpeed Agents have decreased.

GOAL:

After while the number of AppServer Servers have decreased.

GOAL:

How does the ubroker.properties autoTrimTimeout feature work?

GOAL:

How does the autoTrimTimeout value for WebSpeed and AppServer work?

GOAL:

How does the WebSpeed Broker spawn and trim Agents?

GOAL:

How does the maxSrvrInstance and the minSrvrInstance work?

GOAL:

How does the Agent/Server Auto-trim value affect the numbers of running Agents/Servers?

GOAL:

How does the Algorithm for the autotrim feature in WebSpeed and AppServer work?

GOAL:

What does message 8051 indicate in the broker log file

GOAL:

Shutdown requested: <threadName> ... (8051)

FACT(s) (Environment):

All Supported Operating Systems
Progress 9.x
OpenEdge 10.x

FIX:

The 'autoTrimTimeout' value is the time the broker attempts to automatically trim remove idle servers/agents for the corresponding broker.

This is a REQUIRED value and must be defined.

By default the value is set to '1800'. This value is measured in seconds and is equivalent to 30 minutes.

When the autoTrimTimeout is reached, the broker will trim available server/agents down to the number defined as the minSrvrInstance. The message " Shutdown requested: <threadName> ...(8051) is written in the broker log file.

BUSY Agents or Servers will never be trimmed.

The lower you set the Agent/Server Auto-trim Interval value, the more quickly the broker reacts to a drop in the workload. Under a reasonably steady work load, the broker should trim the number of running agent/servers to the number needed. However, if the workload fluctuates a great deal and the Agent/Server Auto-trim Interval is set too low, the broker may trim agent/servers that it must then restart.


NOTE Repetitive trimming and restarting causes the system to waste resources on unnecessary process management.

Setting the Auto Trim Timeout to 0 disables it and no trimming will be done.

This information is stored within ubroker.properties file within the $DLC/properties directory.

An Agent/Server Auto-trim Example:
To better understand the use of the Agent/Server Auto-trim feature, consider a scenario involving:
- a broker serving a client/server application running in stateless mode
- following property values are set:
Minimum Agent/Server Instances: 10
Initial Agent/Server Instances to Start: 10
Maximum Agent/Server Instances: 50
Agent/Server Auto-trim Interval: 1800
When the broker starts, it starts 10 agent/servers. This also marks the start of the first Agent/Server Auto-trim Interval. Assume that the broker is idle for 30 minutes (it's just before people arrive for work, for instance). At the end of the 30-minute interval, the highest number of agent/servers that were busy at the same time would be zero (no requests made of any of the agent/servers).
Since zero is less than the Minimum Agent/Servers Instances value of 10, no automatic trimming takes place. This marks the start of the second interval.
Agents 10 10
Time 0----------15----------30---->
Status A A
Trim 0
A = Available
B = Busy

As the second interval starts, employees begin their workday and a sudden need for additional agent/servers occurs. In fact the broker receives so many requests that it must start 20 new agent/servers. Assume this demand on the agent/servers continues through the second interval.
At the interval's end, the maximum number of busy agent/servers would be 30, which is the number the broker scaled up to in response to high demand. 30 agent/servers are running, and the maximum busy level is 30. No trimming occurs.
Agents 10 10 &n.bsp; 30
Time 0----------30----------60---->
Status A A B
Trim 0
A = Available
B = Busy

During the next interval, the request load diminishes and at the end only 20 agent/servers are concurrently busy. The maximum number of busy agent/servers for the interval remains at 30, since 30 were busy at the start of the interval. Thirty agent/servers are running, and the maximum busy level is 30. No trimming occurs.
Agents 10 10 30 30
Time 0----------30----------60----------90---->
Status A A B 20B/10A
Trim 0
A = Available
B = Busy

Assume that all employees have to attend a meeting that begins midway through the interval. The highest number of agent/servers busy at that same time was 20.
At the end of the interval, there would be 30 agent/servers running, with zero agent/servers currently busy. Since the maximum busy level is 20 at the start of the interval) while the number of running agent/servers are 30 (all available since everyone in meeting), the broker will trim back the number of agent/servers to 20 (the highest number of busy agent/servers at that same in the interval).
Agents 10 10 30 30 30 ..20
Time 0----------30----------60----------90----------120---->
Status A A B 20B/10A A
Trim 0 10 -> 20 reminding
A = Available
B = Busy

The company meeting ran for another 30 minutes, and the entire next interval elapsed without any requests. Therefore the maximum busy agent/servers would be zero, with 20 currently running. Since the Minimum Agent/Serv.er Instances property value is set to 10, the broker will trim back to 10 agent/servers.
Agents 10 10 30 30 30 ..20 20 ..10
Time 0----------30----------60----------90----------120----------150---->
Status A A B 20B/10A A A
Trim 0 10 10 -> 10 reminding
A = Available
B = Busy
.