Which cloudflare app executes first?


#1

If a user installs 2 cloudflare apps (both altering site content), which app would execute first? Is there a way for the user to setup which app to execute first?


#2

I’ve not seen that question asked before. I’ve not tried two apps that would simultaneously act on the same code. Which 2 apps are you using?


#3

The apps that I use are not published yet, as we’re still developing it. Both app uses Workers.


#4

Maybe @KentonVarda can give a more definitive answer. Or point you in the right direction.


#5

I’m not actually the best person to answer this as I don’t work on apps specifically. But, my understanding is that by default, we would choose the ordering based on app IDs – so, the order is arbitrary, but consistent for two given apps. There were also plans for apps to be able to specify what “layer” they run at, e.g. security vs. performance vs. content modification, and that would influence ordering, but I don’t know if that got implemented or not.