GraphQL could be the key to controlling the API explosion

Application development has a long history of rapid evolution and transformation, perhaps faster than any other industry. The tools we use to build and host our apps are constantly changing.

The rapid developments in programming tools provide many opportunities to create software for companies of different sizes, industries, and budgets. However, the increased flexibility and diversity of tools, as well as the ever-changing landscape, also present their own set of challenges.

Developers must be able to build their applications in a way that they can adapt to the scale and changes experienced by their organization, customers, and infrastructure. Fortunately, with the shift to graph-based programming, companies will be much better equipped to stay agile as they continually grow and adapt to the needs of their customers.

The challenges of modern app development

Get your tickets for TNW Valencia now!

The heart of technology reaches the heart of the Mediterranean

One of the blessings (and curses) of modern app development is the many options you have.

You can choose to run your application on your own servers, in the cloud, or in a hybrid model. You can use a serverless model, where a cloud provider manages your server in the background and you focus on functionality, or choose a containerized model, where your application is packaged in a docker file. You can choose from different data storage and hosting models, including data warehouses and data lakes. And you can do these and many other options for each component of your application.

The benefit of this powerful variety of computing and storage platforms is that you can tailor your application to the needs of your customers and your organization. However, the downside is the additional complexity involved in communicating with the different service APIs that support your application.

GraphQL helps developers communicate with APIs through flexible and structured data queries.

“Many applications must communicate with dozens, even hundreds of services at run time. In some cases, each app update (mobile, web, etc.) requires hundreds of API calls to different services,” says Peggy Rayzis, Senior Director of Developer Experience at Apollo Graph, Inc. “This requires enormous effort and complicated by developers, who have to make sure that all these different services are compatible and can interoperate.

The added complexity also makes it difficult to iterate, add or modify features, or change the underlying infrastructure. In each case, redundant implementations and inconsistencies between services force developers to make intensive changes to their code to connect all the old and new services.

Graph-based programming to the rescue

One of the trends helping developers address the complexity of the application ecosystem is graph-based programming. Graph-based programming allows developers to add a data schema layer between their application and API services running in the background. This abstraction layer decouples these parts and allows them to evolve without causing major disruptions to each other.

“Basically, the idea is that you add a middle layer that allows your application to interact with your data entities by querying a graph,” says Rayzis. “The graphics layer is consistent and flexible regardless of the type of infrastructure that is running behind the scenes, whether it is an on-premises server, a virtual machine in the cloud, a REST API, a data warehouse, or a serverless function like AWS. Lambda. ”

Graph-based programming was popularized by GraphQL, a data query language introduced by Facebook in 2015. GraphQL helps developers communicate with APIs through flexible, structured data queries. This makes it easier for the developer to focus on the application logic and data schema and also maintain application stability as APIs evolve and change.

We’re seeing 30% of Fortune 500 companies build their applications on the supergraphic.

Companies and applications of different sizes can benefit from graph-based programming. Rayzis says:

Regardless of size and structure, all applications can benefit from graphics-based development. As your application grows or your data infrastructure changes, your graph remains consistent and remains tied to your application logic.

For example, Walmart used GraphQL to create a federated schema of different entities used in its different applications and services offered on the web and mobile. With GraphQL, they could eliminate much of the code that is replicated in their APIs, unify their applications, and become much more agile in deploying features and improving the user experience.

The next generation of graph-based tools

“What we’ve found in our more than six years of working with developers implementing GraphQL at scale is that its flexibility is its greatest strength, but it can also have some negative consequences if it’s not implemented in a principled way,” says Rayzis.

These limitations led to the idea of ​​the supergraph, Apollo’s special implementation of GraphQL. The supergraph goes beyond the basic benefits of GraphQL, which is to replace data retrieval and backend to frontend code (BFF) with schemas and queries. It brings together the data, microservices, and digital capabilities of an enterprise, creating a unified composition layer for the entire organization. The architecture of the supergraph is based on Apollo’s open technology, the Apollo Federation. Apollo also provides GraphOS, a cloud-based tooling platform with an edge runtime and schema delivery pipeline for the supergraph. According to Rayzis:

The supergraph allows you to distribute the graph schema across different teams and different services, but then unify it into a single interface for the client. It’s about solving real customer problems. It is based on our years of experience helping clients implement GraphQL. And really, the fundamental principles are that it’s a unified layer, integrated modules that can evolve over time.

One company that has benefited from the supergraphic is, one of the world’s largest online travel agencies. has been around since 1996 and therefore runs a lot of legacy code and infrastructure. This makes changing the software architecture very challenging, especially since the company employs thousands of engineers and needs to ensure they can collaborate securely.

Thanks to the flexibility and versatility of the super graph, was able to gradually transition to GraphQL without disrupting any of its services. As they gradually rolled out supergraphic throughout the organization, engineers and managers realized its benefits and helped speed the transition. Full adoption of the super graphic has enabled to ship 40% faster, sometimes doubling the speed at which they are launching features. At the same time, they have managed to significantly reduce errors and last-minute changes.

“We are seeing 30% of Fortune 500 companies build their applications on the supergraphic. And I think that number will only increase in the next few years,” says Rayzis.

It will drastically lower the barrier to app development and allow more developers to build apps. It will continue to reduce the time it takes to build those apps. So by making it more accessible and reducing that time, you’ll see even more innovation.

Leave a Reply

Your email address will not be published. Required fields are marked *