Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce variables for GraphQL Application server #752

Open
3 tasks
navarr opened this issue Feb 22, 2024 · 4 comments
Open
3 tasks

Introduce variables for GraphQL Application server #752

navarr opened this issue Feb 22, 2024 · 4 comments
Assignees

Comments

@navarr
Copy link
Member

navarr commented Feb 22, 2024

Starting with Magento 2.4.7, Adobe has introduced a method to run a GraphQL Application server.

As always, when testing local environments it's important to be able to mirror the way production works at some point.

Documentation on enabling and running the application server for on-premises deployments (which includes Warden): https://experienceleague.adobe.com/docs/commerce-operations/performance-best-practices/performance-best-practices/application-server.html?lang=en#enable-application-server-on-on-premises-deployments

Initial ideas for how to best handle this is a WARDEN_MAGENTO2_GRAPHQL_SERVER_ENABLED flag. When 1, this would start up an image that runs the application server and receives traffic through Traefik automatically.

  • Determine if we should use a custom entry script or a special image (likely a custom entry script)
  • Add OpenSwoole from PECL to the PHP images
  • Write entry script
@navarr navarr self-assigned this Feb 22, 2024
@bap14
Copy link
Contributor

bap14 commented Feb 22, 2024

@navarr given that this is an optional item in Adobe Commerce Cloud, and the differences in how the processes are handled, I would lean toward using a separate image entirely for this. According to their documentation it's a separate app that's just routed via the /graphql path.

@navarr
Copy link
Member Author

navarr commented Feb 22, 2024

@bap14 My primary concern with doing it that way is that we're adding a new image variant for every version of PHP with the only difference being pecl's OpenSwoole. Everything else is still within the Magento application

I definitely intend for it to be a second container, but it seems overkill for it to be a new image variant.

@bap14
Copy link
Contributor

bap14 commented Feb 22, 2024

@navarr Ah, I see. I misunderstood your initial thought.

@bap14
Copy link
Contributor

bap14 commented Feb 26, 2024

@navarr I submitted a PR to add Openswoole to the base PHP images ( wardenenv/images#22 ). Once that's added, it will make things easier to play around with. At the moment Openswoole is application dependent (e.g. M2 will use a different entrypoint / start than a Laravel project).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 📋 Backlog
Development

No branches or pull requests

2 participants