0

Azure Event Hub Logging has a policy configuration which defines the information that gets logged downstream. I've set up an IEventProcessor listener which gets a handle to all of the EventData configured in the policy. I could write code in IEventProcessor to log this data through a company-specific logger. I could also write code in my IEventProcessor to skip additional logging if context.LastError.Reason = "OperationNotFound".

Is there a way to configure filters in the policy to handle this type of logic that would prefilter events that I want to log or don't want to log? Also, is there a way to programmatically do this through some type of pre-event handler? By the time my IEventProcessor listener implementation is reached, I'm assuming that the event has already been logged somewhere.

4

1 に答える 1

1

chooseポリシーを使用し、choose 内にポリシーを配置することをお勧めし<logtoeventhub>ます。

于 2016-02-03T16:41:03.947 に答える