Expand my Community achievements bar.

SOLVED

Can I read values stored into aio-lib-state by a aio-runtime-action into AEM java say osgi service?

Avatar

Level 6

My use case follows an idea I posted 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager-ideas/enhance-assetcompute...

 

Basically I am receiving asset creation events from Workfront and am creating assets into AEM using a runtime action. I am able to create successfully using AssetCompute microservice. But after asset creation, I need to update altText and couple custom properties. These values are available with event at Runtime action. Now AssetCompute microservice DOES NOT allow to update metadata. The runtime action dies once it fires createAsset, doesnt wait ( or doesnt know) for asset to complete processing.  

 

So I temporarily need to cache altText metadata somewer; wait for microservice to complete upload process, and then update metadata. One workaround is to use JCR as temp storage. store the metadata properties onto /var somewer and then fetch them after asset processed. Looking for better solutions. Thinking of caching the metadata onto aio-lib-state and ask AEM to pull from aio-lib-state. But looks there is NO Java SDK/library available to reuse aio-lib-state. I have to expose another web-action at aio runtime, and make AEM call a fetchAIOLibState web-action to fetch metadata. 

 

Any other better solution to temp cache metadata, wait for asset completion event and update into asset.

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Employee
Employee

Hi @sarav_prakash 

 

I spoke to the engineering team. 

 

> Thinking of caching the metadata onto aio-lib-state and ask AEM to pull from aio-lib-state. But looks there is NO Java SDK/library available to reuse aio-lib-state. I have to expose another web-action at aio runtime, and make AEM call a fetchAIOLibState web-action to fetch metadata. 

 

This looks like a fine approach.

 

Thanks
Manik

 

View solution in original post

2 Replies

Avatar

Correct answer by
Employee
Employee

Hi @sarav_prakash 

 

I spoke to the engineering team. 

 

> Thinking of caching the metadata onto aio-lib-state and ask AEM to pull from aio-lib-state. But looks there is NO Java SDK/library available to reuse aio-lib-state. I have to expose another web-action at aio runtime, and make AEM call a fetchAIOLibState web-action to fetch metadata. 

 

This looks like a fine approach.

 

Thanks
Manik

 

Avatar

Employee

Another option to explore is to use an Asset Compute custom worker to read the required data from the event or aio-lib-state and create a custom rendition(which will be in JCR). Leverage AEM workflow to update the asset properties as needed.

 

Regards