I'm working with Azure Event Grid to receive incoming events from an external publisher. When files are uploaded to a blob container named "snlf", I want my Service Bus trigger Function App to process them.
Current Setup: I use Event Grid to filter events for files under the "snlf" container:
Event Grid System-Topic Configuration:
Metrics: Mapped to a Service Bus queue
Filters: Event Types: Event Created
Subject Filters: Begins with: /blobService/default/containers/snlf/
Ends with: .json
Delivery Properties: Header Name: SessionID Type: Dynamic Value: subject
Problem: Azure Service Bus is rejecting events from Event Grid when the subject length exceeds 128 characters.
Constraints: I need to compress the subject before it reaches the Service Bus. Using Logic Apps or Function Apps for compression is not ideal due to added technical debt.
Question: How can I truncate or compress the subject within Event Grid before it reaches Service Bus? Are there alternative ways to handle this limitation effectively?
Any suggestions or examples would be greatly appreciated!