File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change 1212import temporalio .bridge .worker
1313from temporalio .common import WorkerDeploymentVersion
1414
15- _DEFAULT_RESOURCE_ACTIVITY_MAX = 500
15+ _DEFAULT_RESOURCE_SLOTS_MAX = 500
1616
1717logger = logging .getLogger (__name__ )
1818
@@ -327,7 +327,7 @@ def _to_bridge_slot_supplier(
327327 return temporalio .bridge .worker .FixedSizeSlotSupplier (slot_supplier .num_slots )
328328 elif isinstance (slot_supplier , ResourceBasedSlotSupplier ):
329329 min_slots = 5 if kind == "workflow" else 1
330- max_slots = _DEFAULT_RESOURCE_ACTIVITY_MAX
330+ max_slots = _DEFAULT_RESOURCE_SLOTS_MAX
331331 ramp_throttle = (
332332 timedelta (seconds = 0 ) if kind == "workflow" else timedelta (milliseconds = 50 )
333333 )
@@ -464,8 +464,7 @@ def _get_slot_supplier_max(slot_supplier: SlotSupplier) -> Optional[int]:
464464 return slot_supplier .num_slots
465465 elif isinstance (slot_supplier , ResourceBasedSlotSupplier ):
466466 return (
467- slot_supplier .slot_config .maximum_slots
468- or _DEFAULT_RESOURCE_ACTIVITY_MAX
467+ slot_supplier .slot_config .maximum_slots or _DEFAULT_RESOURCE_SLOTS_MAX
469468 )
470469 return None
471470
You can’t perform that action at this time.
0 commit comments