Skip to content

Commit 153b25b

Browse files
committed
rename variable to align with new meaning
1 parent 4a70aea commit 153b25b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

airbyte_cdk/sources/declarative/concurrent_declarative_source.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
class ConcurrentDeclarativeSource(ManifestDeclarativeSource, Generic[TState]):
5959
# By default, we defer to a value of 2. A value lower than than could cause a PartitionEnqueuer to be stuck in a state of deadlock
6060
# because it has hit the limit of futures but not partition reader is consuming them.
61-
SINGLE_THREADED_CONCURRENCY_LEVEL = 2
61+
_LOWEST_SAFE_CONCURRENCY_LEVEL = 2
6262

6363
def __init__(
6464
self,
@@ -108,8 +108,8 @@ def __init__(
108108
concurrency_level // 2, 1
109109
) # Partition_generation iterates using range based on this value. If this is floored to zero we end up in a dead lock during start up
110110
else:
111-
concurrency_level = self.SINGLE_THREADED_CONCURRENCY_LEVEL
112-
initial_number_of_partitions_to_generate = self.SINGLE_THREADED_CONCURRENCY_LEVEL // 2
111+
concurrency_level = self._LOWEST_SAFE_CONCURRENCY_LEVEL
112+
initial_number_of_partitions_to_generate = self._LOWEST_SAFE_CONCURRENCY_LEVEL // 2
113113

114114
self._concurrent_source = ConcurrentSource.create(
115115
num_workers=concurrency_level,

0 commit comments

Comments
 (0)