Skip to content

[CosmosDb] Replacing scaling logs to WebJobs extension methods#975

Open
alrod wants to merge 1 commit intodevfrom
alrod/replace-logs-cosmosdb
Open

[CosmosDb] Replacing scaling logs to WebJobs extension methods#975
alrod wants to merge 1 commit intodevfrom
alrod/replace-logs-cosmosdb

Conversation

@alrod
Copy link
Member

@alrod alrod commented Nov 18, 2025

No description provided.

if (!TryHandleCosmosException(e))
{
_logger.LogWarning(Events.OnScaling, "Unable to handle {0}: {1}", e.GetType().ToString(), e.Message);
_logger.LogFunctionScaleWarning("Unable to handle.", _functionId, e);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given the format change here, I suggest to reword to "Unable to handle exception.", or perhaps keep the wording as it was for this?

Thinking the formatted end result "Function 'Foo' warning: Unable to handle." showing up in log summaries is too vague.

}

_logger.LogWarning(Events.OnScaling, errormsg);
_logger.LogFunctionScaleWarning(errormsg, _functionId, e);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: while you're in here, let's fix errormsg -> errorMsg or errorMessage

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants