Modern Integration Methods for Supply Chain Autonomy – Part II

essidsolutions

Communication between yard trucks and the cloud requires a fast and flexible server-side API when it comes to automating distribution yards. In part 2 of this series, Kyle Hayes, principal architect at Outrider, explains that despite the several benefits it offers, GraphQL lacks a broad range of support across toolkits and libraries due to its relatively young age. If you missed the first part of this series, click here.

Driven by Specification

Similar to SOAP and gRPC, but unlike REST, GraphQL APIs are implemented in accordance with a well-defined and strongly typed schema that not only enforces the contracts of communication but provides consistently generated documentation. 

Developers familiar with GraphQL APIs can easily read and integrate with other GraphQL APIs because the language is treated the same regardless of where it is being used. Method signatures and data types vary, but they are more easily digested than reading poorly written API documentation due to the consistency of schema generation.

Paving the Way for Real-Time Data

Webhooks provide a nice stop-gap for event-based integration between disparate enterprise systems, but they fall victim to a few of the same drawbacks as REST. For example, there are no defined standards or specifications for how a webhook should be implemented or its response heuristics. Each implementation is unrestricted to define the endpoint, message enveloping, and style of execution, however they choose. 

Great for implementers. Bad for integrators. With the ever-increasing need for real-time data streams, especially when integrating across enterprises, GraphQL supports subscriptions which are just as intuitive to use as queries and mutations. WebSockets is a natural transport protocol for this live data. In fact, thanks to the industry standard Apollo Server for building state-of-the-art implementations of these features, it is easy to communicate with a GraphQL API entirely over WebSockets.

WebSockets were first referenced in 2008 as part of the HTML5 specification—they’ve been around for a while. Many real-time technologies have been enabled because of browser adoption of this technology many years later (think Slack or real-time notifications in Facebook). However, direct usage of this transport protocol can be limited and buggy, especially across browsers. 

Besides, it is up to each developer to define the messaging contracts, thereby causing more fragmentation and potentially fragility when it comes to interoperability between systems. Using a language like GraphQL over WebSockets provides an intuitive, well-defined, and documented query and response language.

Learn More: Digitalization of the Supply Chain During a Pandemic

GraphQL at Outrider

As developers recognize the benefits of GraphQL, the usage across applications everywhere is quickly increasing. However, it lacks a broad range of support across toolkits and libraries due to its relatively young age. Legacy services and applications sometimes don’t adapt well to new ways of working or communication technologies. Companies can benefit from taking bold steps to streamline a crucial piece in the supply chain and, simultaneously, modernize communication channels through the use of a GraphQL API. These integrations allow a live, holistic view into yard operations, in which historically, data has been stale and siloed.

Customers who leverage a GraphQL API get a tailored query and integration experience with their WMS. Supporting this type of API enables a more agile team to quickly turn around features and new types of data. Further, they will quickly realize the benefits of a modern and dynamic query language.

Outrider’s team, for instance, is building a powerful product, enabling enterprises to have a real-time view of their autonomous yard operations. GraphQL subscriptions and secure WebSockets allow us to stream live telemetry from the autonomous yard trucks to the end user’s browser or mobile devices. 

They will see trucks and trailers moving across the map in their distribution yard as it is happening. Dynamic data flows such as these also provide pertinent visibility into their operational needs, such as the health and hardware status of the yard trucks.

Looking Towards the Future

The Connectivity team at Outrider develops and oversees the communications layer between our trucks and the cloud. We also develop SaaS operations software for our customers. We will continue to use GraphQL, as it is proving to be a highly valuable technology, to build more integrations with enterprise systems and within our internal software. The Outrider System will continue to see value-add features with quicker turnaround due to the agility of this architecture.

As more sets of data are made available through GraphQL, it will be advantageous to begin orchestrating our GraphQL APIs. This will allow us to divide our services into multiple modules rather than having everything funneled through a single code base. Successful GraphQL orchestration can be achieved by utilizing technologies such as Apollo FederationOpens a new window , which allow for this type of architecture to exist with much of the same integration qualities we have come to appreciate with GraphQL. Orchestration is key to enterprise architectures as numerous and disparate data sources are often needed for new applications of the data and can be otherwise tedious or incompatible with ambiguous REST APIs.

Companies must support multiple types of enterprise applications integrations over the internet in an agile and dynamic manner—fulfilling dynamic data requirements for different data clients serving different industries. GraphQL’s straightforward implementation, well-defined specifications, and agile approach to server-side data querying make it a more modern and future-proof choice.

Did you enjoy reading this series? Comment below or let us know your thoughts on LinkedInOpens a new window , TwitterOpens a new window , or FacebookOpens a new window . We would love to hear from you!