Enhanced capabilities for Azure Monitor metrics for functions

Open
#172 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
azure, java
Domain
observability

Research direction

Start by reviewing how Azure Monitor metrics are currently emitted for Java durable functions and how the WorkflowOrchestrator context is represented. The issue proposes a Labels annotation and propagation of clientId, technicalAccountId, and orgId, but names no files or tests; done requires an agreed design for custom metric tags and its validation.

Written by the indexing model from the issue text.

Description

Enhancement Observability P2

Today, durable framework provides good metrics to see the load on the clusters on Azure Monitor. Eg. how many instances for a specific function are in failed/successful state.
But sometimes we need more than just these counts. Eg, each of these functions are triggered with some context, like this for triggered for which clientId, orgId etc. Now, these can be tags for the uber level failed/successful orchestrator/activity function.

I wanted to check if such an enhancement request could be catered to. I could think of a way like this :

@FunctionName("WorkflowOrchestrator")
@Labels [(clientId = ""), (technicalAccountId = ""), (orgId = "")]
public ObjectNode workflowOrchestrator(@DurableOrchestrationTrigger(name = "runtimeState") TaskOrchestrationContext ctx)

We could have a Labels annotation with a list of custom tags that could be added at the time of calling the function or be as a part of the context. And these could then be propagated as tags on Azure Monitor.

Dominant language
Java
Stars
29
Forks
18
Avg merge
1d 10h
Merged PRs (30d)
2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from microsoft/durabletask-java

All issues in microsoft/durabletask-java

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.