Are there Async Event Handler for WebPageEvents ?
I want to create an event handler to update a page once it has been created, and also to wipe any image metadata when the image is added to the CMS. I see in the documentation there is a way to do this asynchronously with IInfo providers, but I dont think this is available for Webpages or Content Items.
Am I missing something, or am I going to need to use GetAwaiter().GetResult() again?
Environment
Xperience by Kentico version: [30.3.1]
.NET version: [8]
Execution environment: [local)]
Link to relevant Xperience by Kentico documentation
Answers
The async event handlers for object types are new and our first step in moving away from native .NET event handling for global events. We haven't yet added these for content items, but we plan to in the future as we adopt modern .NET patterns.
So, yes, you will need to use .GetAwaiter().GetResult()
.
You can look at the Kentico Community Portal for examples of how to handle async calls in global event handlers for content items.
Watch the roadmap, docs Changelog, and read the Refresh blog posts to see when we release an update for these APIs.
If it's a priority for you to get true async content item event handling, give us roadmap feedback.
To answer this question, you have to login first.