sentry-arroyo 2.19.6__tar.gz → 2.19.7__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {sentry_arroyo-2.19.6/sentry_arroyo.egg-info → sentry_arroyo-2.19.7}/PKG-INFO +1 -1
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/dlq.py +9 -6
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/processor.py +1 -1
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7/sentry_arroyo.egg-info}/PKG-INFO +1 -1
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/setup.py +1 -1
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/LICENSE +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/MANIFEST.in +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/README.md +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/abstract.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/kafka/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/kafka/commit.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/kafka/configuration.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/kafka/consumer.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/local/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/local/backend.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/local/storages/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/local/storages/abstract.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/backends/local/storages/memory.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/commit.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/errors.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/abstract.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/batching.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/buffer.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/commit.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/filter.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/guard.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/healthcheck.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/noop.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/produce.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/reduce.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/run_task.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/run_task_in_threads.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/run_task_with_multiprocessing.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/unfold.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/py.typed +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/types.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/clock.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/codecs.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/concurrent.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/logging.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/metricDefs.json +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/metric_defs.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/metrics.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/profiler.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/utils/retries.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/examples/transform_and_produce/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/examples/transform_and_produce/batched.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/examples/transform_and_produce/script.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/examples/transform_and_produce/simple.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/requirements.txt +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/sentry_arroyo.egg-info/SOURCES.txt +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/sentry_arroyo.egg-info/dependency_links.txt +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/sentry_arroyo.egg-info/not-zip-safe +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/sentry_arroyo.egg-info/requires.txt +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/sentry_arroyo.egg-info/top_level.txt +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/setup.cfg +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/backends/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/backends/mixins.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/backends/test_commit.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/backends/test_kafka.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/backends/test_local.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_all.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_batching.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_buffer.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_commit.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_filter.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_guard.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_noop.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_produce.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_reduce.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_run_task.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_run_task_in_threads.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_run_task_with_multiprocessing.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/strategies/test_unfold.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/processing/test_processor.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/test_commit.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/test_dlq.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/test_types.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/utils/__init__.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/utils/test_concurrent.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/utils/test_metrics.py +0 -0
- {sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/tests/utils/test_retries.py +0 -0
|
@@ -44,11 +44,12 @@ class InvalidMessage(Exception):
|
|
|
44
44
|
"""
|
|
45
45
|
|
|
46
46
|
def __init__(
|
|
47
|
-
self, partition: Partition, offset: int, needs_commit: bool = True
|
|
47
|
+
self, partition: Partition, offset: int, needs_commit: bool = True, reason: Optional[str] = None,
|
|
48
48
|
) -> None:
|
|
49
49
|
self.partition = partition
|
|
50
50
|
self.offset = offset
|
|
51
51
|
self.needs_commit = needs_commit
|
|
52
|
+
self.reason = reason
|
|
52
53
|
|
|
53
54
|
@classmethod
|
|
54
55
|
def from_value(cls, value: BrokerValue[Any]) -> InvalidMessage:
|
|
@@ -177,7 +178,7 @@ class DlqLimitState:
|
|
|
177
178
|
class DlqProducer(ABC, Generic[TStrategyPayload]):
|
|
178
179
|
@abstractmethod
|
|
179
180
|
def produce(
|
|
180
|
-
self, value: BrokerValue[TStrategyPayload]
|
|
181
|
+
self, value: BrokerValue[TStrategyPayload], reason: Optional[str] = None
|
|
181
182
|
) -> Future[BrokerValue[TStrategyPayload]]:
|
|
182
183
|
"""
|
|
183
184
|
Produce a message to DLQ.
|
|
@@ -201,7 +202,7 @@ class NoopDlqProducer(DlqProducer[Any]):
|
|
|
201
202
|
"""
|
|
202
203
|
|
|
203
204
|
def produce(
|
|
204
|
-
self, value: BrokerValue[KafkaPayload]
|
|
205
|
+
self, value: BrokerValue[KafkaPayload], reason: Optional[str] = None,
|
|
205
206
|
) -> Future[BrokerValue[KafkaPayload]]:
|
|
206
207
|
future: Future[BrokerValue[KafkaPayload]] = Future()
|
|
207
208
|
future.set_running_or_notify_cancel()
|
|
@@ -229,7 +230,9 @@ class KafkaDlqProducer(DlqProducer[KafkaPayload]):
|
|
|
229
230
|
self.__topic = topic
|
|
230
231
|
|
|
231
232
|
def produce(
|
|
232
|
-
self,
|
|
233
|
+
self,
|
|
234
|
+
value: BrokerValue[KafkaPayload],
|
|
235
|
+
reason: Optional[str] = None,
|
|
233
236
|
) -> Future[BrokerValue[KafkaPayload]]:
|
|
234
237
|
value.payload.headers.append(
|
|
235
238
|
("original_partition", f"{value.partition.index}".encode("utf-8"))
|
|
@@ -353,7 +356,7 @@ class DlqPolicyWrapper(Generic[TStrategyPayload]):
|
|
|
353
356
|
self.__dlq_policy.limit, assignment
|
|
354
357
|
)
|
|
355
358
|
|
|
356
|
-
def produce(self, message: BrokerValue[TStrategyPayload]) -> None:
|
|
359
|
+
def produce(self, message: BrokerValue[TStrategyPayload], reason: Optional[str] = None) -> None:
|
|
357
360
|
"""
|
|
358
361
|
Removes all completed futures, then appends the given future to the list.
|
|
359
362
|
Blocks if the list is full. If the DLQ limit is exceeded, an exception is raised.
|
|
@@ -371,7 +374,7 @@ class DlqPolicyWrapper(Generic[TStrategyPayload]):
|
|
|
371
374
|
|
|
372
375
|
should_accept = self.__dlq_limit_state.record_invalid_message(message)
|
|
373
376
|
if should_accept:
|
|
374
|
-
future = self.__dlq_policy.producer.produce(message)
|
|
377
|
+
future = self.__dlq_policy.producer.produce(message, reason)
|
|
375
378
|
self.__futures[message.partition].append((message, future))
|
|
376
379
|
else:
|
|
377
380
|
raise RuntimeError("Dlq limit exceeded")
|
|
@@ -376,7 +376,7 @@ class StreamProcessor(Generic[TStrategyPayload]):
|
|
|
376
376
|
) from None
|
|
377
377
|
|
|
378
378
|
# XXX: This blocks if there are more than MAX_PENDING_FUTURES in the queue.
|
|
379
|
-
self.__dlq_policy.produce(invalid_message)
|
|
379
|
+
self.__dlq_policy.produce(invalid_message, exc.reason)
|
|
380
380
|
|
|
381
381
|
self.__metrics_buffer.incr_timing(
|
|
382
382
|
"arroyo.consumer.dlq.time", time.time() - start_dlq
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{sentry_arroyo-2.19.6 → sentry_arroyo-2.19.7}/arroyo/processing/strategies/run_task_in_threads.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|