Sampler function error when calling the photoshop api | Community
Skip to main content
Level 4
December 12, 2024
Solved

Sampler function error when calling the photoshop api

  • December 12, 2024
  • 1 reply
  • 467 views

Hi,

 

We are trying to implement the adobe photoshop action api with the aio app builder to capture the png and psd files with Layered PSD non-destructive and transparent background. 

 

When deployed the app builder code and triggering the action code via post processing profile, we are getting a rendition created with the no background of the image(white background) in aem.  But this is not the complete output we want. By checking the app builder logs, i could able to see the below error. Also i am getting 202 response code from the photoshop api. We checked the .atn file via the postman, it is giving the correct output image as expected.

 

stderr: Sampler function failed with error Error reading file /sys/fs/cgroup/memory/memory.stat, Message: ENOENT: no such file or directory, open '/sys/fs/cgroup/memory/memory.stat'.

 

If anyone have any idea about why i am not getting the complete expected output in aem. please let me know.. Thanks in advance!

 

 

 

 

Regards,

Bhavani Bharanidharan

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by TarunKumar

Hi @bhavanibharani ,

Few things that you can check is making sure you run npm install after updating the package.json file, so that all the npm modules are installed.

Then update your action code in actions/<worker-name>/index.js to use the Photoshop API SDK. 

In below link you will find that cutout service has been used to remove the background image.


https://developer.adobe.com/app-builder/docs/resources/asset-compute-worker-ps-api/lesson3/

 

 

-Tarun

 

 

1 reply

TarunKumar
Community Advisor
TarunKumarCommunity AdvisorAccepted solution
Community Advisor
January 8, 2025

Hi @bhavanibharani ,

Few things that you can check is making sure you run npm install after updating the package.json file, so that all the npm modules are installed.

Then update your action code in actions/<worker-name>/index.js to use the Photoshop API SDK. 

In below link you will find that cutout service has been used to remove the background image.


https://developer.adobe.com/app-builder/docs/resources/asset-compute-worker-ps-api/lesson3/

 

 

-Tarun