This site was D8 and using the old Cloudinary module with the ancient library and a ton of custom code. After a lot of work I got it upgraded to D9, uninstalled the old Cloudinary and installed the latest 2.1.3. And I deleted most of the custom code.

Everything seemed to be okay then we started losing all the graphics across the site, then they'd come back.

I finally managed to figure out it was because were exceeding the fetches on the Admin API ... consulting Cloudinary support they temporarily increased the quota so we stopped losing graphics but wanted to know why it was using the Admin API?

That's what I'd like to know, so any help would be appreciated.

We're on the Advanced Extra Classic Plan - what am I missing? What do you need to know?

Comments

adaddinsane created an issue.

adaddinsane’s picture

OK, here's some additional data.

As mentioned, every image URL is coming out using the "res" sub-domain instead of "api-eu".

File URI: cloudinary://images/2023-03/background.png

becomes

Image URI: https://res.cloudinary.com/xxx/image/upload/s--krZz8bFO--/c_fill%2Ch_243%2Cw_360/v1/images/2023-03/background.png?itok=IOSup1_k

But the Cloudinary config looks like this:

Cloudinary\Configuration\Configuration Object
(
    [sections:protected] => Array
        (
            [0] => cloud
            [1] => api
            [2] => url
            [3] => tag
            [4] => responsive_breakpoints
            [5] => auth_token
            [6] => logging
        )

    [includeSensitive:protected] => 1
    [cloud] => Cloudinary\Configuration\CloudConfig Object
        (
            [cloudName] => xxx
            [apiKey] => 999999999999999
            [apiSecret] => pppppppppppppppppppp
            [oauthToken] => 
            [signatureAlgorithm:protected] => 
            [explicitlySetKeys:protected] => Array
                (
                    [cloudName] => 1
                    [apiKey] => 1
                    [apiSecret] => 1
                )

        )

    [api] => Cloudinary\Configuration\ApiConfig Object
        (
            [uploadPrefix:protected] => https://api-eu.cloudinary.com
            [apiProxy] => 
            [connectionTimeout] => 
            [timeout:protected] => 
            [uploadTimeout:protected] => 
            [chunkSize:protected] => 
            [callbackUrl] => 
            [explicitlySetKeys:protected] => Array
                (
                    [uploadPrefix] => 1
                )

        )
...the rest is empty.

Nothing I do forces it to use "api-eu" instead of "res" - I have changed everything I can find.

nginex’s picture

Hi,

There are plenty of fixes in #3314722: Create a Cloudinary media source instead of a separate media type
It will be a new major version and there is upgrade path from 2.x

You could try to switch to that fork and recheck or wait for new release

nginex’s picture

Admin API is used for many features in the current implementation, I will check if it makes sense, if it's mandotary and will be back to you later with more information