Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
from durabletask.aio import client as aioclient
from grpc.aio import AioRpcError

from dapr.aio.clients.grpc.interceptors import DaprClientTimeoutInterceptorAsync
from dapr.clients import DaprInternalError
from dapr.clients.http.client import DAPR_API_TOKEN_HEADER
from dapr.conf import settings
Expand Down Expand Up @@ -68,6 +69,7 @@ def __init__(
secure_channel=uri.tls,
log_handler=options.log_handler,
log_formatter=options.log_formatter,
interceptors=[DaprClientTimeoutInterceptorAsync()],
)

async def schedule_new_workflow(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
from grpc import RpcError

from dapr.clients import DaprInternalError
from dapr.clients.grpc.interceptors import DaprClientTimeoutInterceptor
from dapr.clients.http.client import DAPR_API_TOKEN_HEADER
from dapr.conf import settings
from dapr.conf.helpers import GrpcEndpoint
Expand Down Expand Up @@ -71,6 +72,7 @@ def __init__(
secure_channel=uri.tls,
log_handler=options.log_handler,
log_formatter=options.log_formatter,
interceptors=[DaprClientTimeoutInterceptor()],
)

def schedule_new_workflow(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
from durabletask import task, worker

from dapr.clients import DaprInternalError
from dapr.clients.grpc.interceptors import DaprClientTimeoutInterceptor
from dapr.clients.http.client import DAPR_API_TOKEN_HEADER
from dapr.conf import settings
from dapr.conf.helpers import GrpcEndpoint
Expand Down Expand Up @@ -71,13 +72,17 @@
raise DaprInternalError(f'{error}') from error

options = self._logger.get_options()
all_interceptors = []
if interceptors:
all_interceptors.extend(interceptors)
all_interceptors.append(DaprClientTimeoutInterceptor())
self.__worker = worker.TaskHubGrpcWorker(
host_address=uri.endpoint,
metadata=metadata,
secure_channel=uri.tls,
log_handler=options.log_handler,
log_formatter=options.log_formatter,
interceptors=interceptors,
interceptors=all_interceptors,
concurrency_options=worker.ConcurrencyOptions(
maximum_concurrent_activity_work_items=maximum_concurrent_activity_work_items,
maximum_concurrent_orchestration_work_items=maximum_concurrent_orchestration_work_items,
Expand Down Expand Up @@ -249,7 +254,7 @@
try:
is_ready = self.wait_for_worker_ready(timeout=self._worker_ready_timeout)
if not is_ready:
raise RuntimeError('WorkflowRuntime worker and its stream are not ready')

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.13)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.11)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.10)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.14)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready

Check failure on line 257 in ext/dapr-ext-workflow/dapr/ext/workflow/workflow_runtime.py

View workflow job for this annotation

GitHub Actions / build (3.12)

WorkflowRuntime worker and its stream are not ready
else:
self._logger.debug(
'WorkflowRuntime worker is ready and its stream can receive work items'
Expand Down
Loading