DEV Community

Discussion on: GraphQL on Azure: Part 1 - Getting Started

Collapse
 
talk2megooseman profile image
Erik Guzman

Nice post! Doing GraphQL on Azure Functions is so simple with Apollo server. I would recommend it to anyone so they can play around with GQL and keep costs down while they learn and grow. I started my own little series covering the journey.

Collapse
 
aaronpowell profile image
Aaron Powell

That is the way that I tend to go for it, but it does have the downside of cold start potentially impacting your GraphQL endpoint, which is why it's worth looking at App Service as well.

Collapse
 
talk2megooseman profile image
Erik Guzman

Personally I did end up migrating to App Services, another reason to do so is "Subscription" types

Thread Thread
 
aaronpowell profile image
Aaron Powell

I haven't played with subscriptions in GraphQL yet, but I've got some ideas on how to tackle it using SignalR

Thread Thread
 
_shirish profile image
Shirish

Can you point to any working sample on how to get subscriptions working on Apollo Server with Azure functions. ?

Thread Thread
 
aaronpowell profile image
Aaron Powell

Conveniently I wrote a blog post about this today - dev.to/azure/graphql-on-azure-part...

The best way to have a server that provides Subscriptions is to implement it on App Service as Azure Functions doesn't provide a way in which you can connect to a WebSocket (given it's event driven, a persistent connection wouldn't fit the model).

Collapse
 
_shirish profile image
Shirish

Building out an basic GraphQL API works flawless on AzureFunctions, However we ran into while trying to use subscriptions. Have you got GraphQL subscriptions working while running Apollo Server on AzureFunctions (node.js) ?