• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Compressing PDF - Internal Server Error

New Here ,
Aug 04, 2022 Aug 04, 2022

Copy link to clipboard

Copied

Hi there,

 

I hope this is the right place to post. We just began using the adobe sdk for node and are running into a problem.

We are attempting to compress a PDF that is about 80 MB.

 

I tried making a proof of concept to see if this would work. I followed the exact code that the intro docs have and put it into a simple express app.

app.get('/', (req, res, next) => {
    const credentials = PDFServicesSdk.Credentials
        .serviceAccountCredentialsBuilder()
        .fromFile("pdfservices-api-credentials.json")
        .build();

    const executionContext = PDFServicesSdk.ExecutionContext.create(credentials),
        compressPDF = PDFServicesSdk.CompressPDF,
        compressPDFOperation = compressPDF.Operation.createNew();

    const input = PDFServicesSdk.FileRef.createFromLocalFile('test-2.pdf');
    compressPDFOperation.setInput(input);
    compressPDFOperation.execute(executionContext)
        .then(result => result.saveAsFile('compressPDFOutput.pdf'))
        .catch(err => {
            if (err instanceof PDFServicesSdk.Error.ServiceApiError
                || err instanceof PDFServicesSdk.Error.ServiceUsageError) {
                console.log('Exception encountered while executing operation', err);
            } else {
                console.log('Exception encountered while executing operation', err);
            }
        });
});

 

When I hit the endpoint I get a log saying that all validations were successful, but after about 5 minutes I get an error that says: Exception encountered while executing operation ServiceApiError: Error occurred while processing the request; transactionId=zfGcEYqzqSadns5DR4U4QwcppboEdBSu

 

And then in the error stack that is logged I also have the requestTrackingId:
requestTrackingId: 'oxZiI0zgGyLO6F4BQuIcuevoIhk8zfyS'

 

I can't imagine Adobe wouldn't be able to handle files of 80 MB. We plan on using this commercially and paying for this service, but I can't even get the intro docs to work correctly which worries me.

 

Any help/suggestions would be greatly appreciated!

Views

167

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jun 06, 2023 Jun 06, 2023

Copy link to clipboard

Copied

Hi, I am facing the same issue. Did you find the solution

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 11, 2023 Jun 11, 2023

Copy link to clipboard

Copied

LATEST

Hi, I am facing the same issue. Did anyone have solution

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources