-
Notifications
You must be signed in to change notification settings - Fork 10
Description
Problem
DurableTaskAzureManagedConnectionString parses connection string property keys case-sensitively. It stores keys as-is during parsing and looks them up by exact case, so a connection string like:
endpoint=https://example.com;authentication=ManagedIdentity;taskhub=myHub
fails with: "The connection string must contain an Authentication property"
This violates the Azure SDK convention that connection string property names are case-insensitive. All other Azure SDKs (.NET, Python, Java) handle connection string keys case-insensitively.
File: packages/durabletask-js-azuremanaged/src/connection-string.ts, lines 89-91 and 105-112.
Root Cause
parseConnectionString() stores keys with their original casing (properties.set(key, value)), and getValue() performs a case-sensitive Map.get() lookup. Since the getRequiredValue() calls use PascalCase names ("Authentication", "Endpoint", "TaskHub"), any connection string with differently-cased keys fails validation.
Proposed Fix
Normalize keys to lowercase during parsing (properties.set(key.toLowerCase(), value)) and use lowercase in lookups (this.properties.get(name.toLowerCase())). This preserves value casing while making key matching case-insensitive.
Impact
Severity: Medium. Users who receive or copy connection strings with non-PascalCase keys (e.g., from environment variables, config files, or other tools) cannot connect to the Azure Durable Task Scheduler. The fix is backward-compatible — existing connection strings with PascalCase keys continue to work.