Expand my Community achievements bar.

AEMaaCS and Asset Compute: Call to custom worker failed with: 401 Unauthorized

Avatar

Level 3

Hi, I created an Asset Compute worker as shown in the tutorials, and it works when I call it from http://localhost:9000/. Now I am trying to call it from AEM by configuring the processing profile and specifying the worker URL from aio app get-url.

When I upload an asset, I see that AEM is trying to call the worker but then I see the following in the logs:

*INFO* [sling-cq-asset-processing-4-adobe-io-assetcompute-events-consuming-job] com.adobe.cq.assetcompute.impl.event.AssetComputeRenditionEventImpl Asset Compute worker failed to generate rendition for asset [...REDACTED...], processingId: '7c09d411-ef92-4a6c-8616-b734f4354bf0', Reason: 'GenericError', Message: 'Call to custom worker https://[...REDACTED...]-stage.adobeioruntime.net/api/v1/web/dx-asset-compute-worker-1/worker failed with : 401 Unauthorized'.

 

In the runtime logs, I see the following:

2023-06-18T06:12:35.014Z stdout: 2023-06-18T06:12:35.013Z [main /adobeio/shared-validators-v1/headless-v2] info: Calling the main action
2023-06-18T06:12:35.501Z stdout: 2023-06-18T06:12:35.501Z [main /adobeio/shared-validators-v1/headless-v2] info: 401: request is invalid, reason: failed authorization. Please verify your token and organization id.

 

Can someone suggest how that can be resolved? The tutorials don't mention configuring any authentication information on the AEM side. Does it have to do with the settings in "Adobe IMS Technical Account Configuration" for Asset Compute?

 

Topics

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

2 Replies

Avatar

Level 3

Update: I don't know whether it is an expected behavior or not, but updating the "Adobe IMS Technical Account Configuration" for Asset Compute helped. There was already a configuration created for the default runtime, and I used another runtime that I created specifically for my investigation, so I had to update the config.

 

I wonder if AEM can work with two different Adobe IO runtimes.

Avatar

Employee

The Asset Compute configuration "Adobe IMS Technical Account Configuration" is where the standard AEM rendition requests go to. The error "401: request is invalid, reason: failed authorization. Please verify your token and organization id." means that the Runtime action deployed at https://[...REDACTED...]-stage.adobeioruntime.net/api/v1/web/dx-asset-compute-worker-1/worker is not in the same Org as that of the configured AEM instance.