DEV Community

Hasura for Hasura

Posted on • Originally published at hasura.io on

Case Study: Industrial IoT Platform Machine Metrics Increased Developer Velocity by 10x Using Hasura

Case Study: Industrial IoT Platform Machine Metrics Increased Developer Velocity by 10x Using Hasura

The team at MachineMetrics has shared deeper information about their offering, their usage of Hasura, and the benefits they enjoyed in a recent recording !

MachineMetrics Industrial IoT Platform who just announced their $20M Series B funding round, is a company that transforms manufacturing shop floor data from insights into actions with powerful apps that reduce machine downtime, increase throughput, and maximize profitability driven by their customers’ manufacturing equipment. Their platform automates machine data collection and production analytics to deliver data-driven insights in a matter of minutes.

Collecting metrics on each machine such as load, temperature, speed, and state, this data is uploaded to their cloud service for analysis, presenting dashboards used on the production floor, and even predictive maintenance to reduce machine failures and downtime.

“Hasura has increased our development velocity by 10X.”

Machine Metrics chose TimescaleDB to handle their time series workload. Hasura’s seamless integration with TimescaleDB was a big part of why Machine Metrics started exploring Hasura to build their GraphQL powered data access layer.

The result? Fast, reliable, secure data APIs which also enabled their teams to increase developer productivity by almost 10x, faster feature addition enabled by rapid prototyping of new features, and better customer retention!

Other advantages include:

  • Increased developer productivity and far less middle-tier code
  • Incremental adoption of GraphQL while migrating away from their legacy APIs and REST endpoints
  • Providing a secure data API for their end customers
  • Data integration with their existing systems

Case Study: Industrial IoT Platform Machine Metrics Increased Developer Velocity by 10x Using Hasura

MachineMetrics’ Challenge

MachineMetrics found themselves needing to modernize their architecture to meet their customers’ needs to directly access data, as well as to create new innovative features and reduce time to market for their new offerings. Machine Metrics was already using TimescaleDB to manage their time series data and needed a product that was compatible with it.

Case Study: Industrial IoT Platform Machine Metrics Increased Developer Velocity by 10x Using Hasura

Incremental Adoption

Hasura enabled MachineMetrics to make the transition to a GraphQL-based architecture without requiring an disruptive, all-or-nothing switch. They were making a transition from REST to GraphQL, and from a variety of NoSQL data stores to Postgres, and needed to do this without disrupting operations, and while continuing to provide a consistent user experience on their frontend Machine Metrics gradually added Hasura into their systems while continuing to use their legacy APIs and REST endpoints. Over time they plan to refactor their existing REST services to be served by Hasura as well.

Auto-Generated GraphQL Data Access

MachineMetrics consolidated their data to TimescaleDB, which provides a time-series SQL database. Hasura enabled them to instantly auto-generate all the GraphQL schemas, resolvers, and API endpoints to query the database - hyper accelerating their development and eliminating tedious ongoing maintenance.

Integrating Existing APIs With Remote Schemas and Remote Joins

“Hasura’s remote schemas and joins saves us hours of work to get to that data faster without having to go to different places”

Utilizing Hasura’s support for remote schemas, MachineMetrics was able to integrate systems that were separated and siloed in the past. Now they can derive insights from operational, time-series, and 3rd party data. An example of this is the integration with their IoT Edge Device fleet management platform into their graph to seamlessly query information about the devices and manage upgrades.

Security & Access Control

Data access requests come from many different sources - internally from their web frontend, their reporting and analytics systems, as well as external requests from their customers. Hasura’s integrated, granular access control and authorization capabilities provide peace of mind that sensitive data is only accessible to the right people internally and with their customers. Configurable down to the individual database column and row level, authorization extends to other systems integrated via remote schemas connected via Hasura.

One of the interesting use cases is the combination with Grafana. MachineMetrics have set up Grafana to use their OAuth flow and have the GraphQL Data source forward a JWT token to a proxy endpoint. This exchanges the token for a JWT used for authentication with Hasura. All the benefits of Hasura’s permission system using Grafana!

10X Productivity

Hasura has radically increased the productivity and time to market for the engineering team. Creating a new feature only requires a single frontend developer now; in the past this would have required the assistance of a data engineer and a backend/API engineer.

Using Hasura has reduced their reliance on full-stack and backend engineers - the data engineering team performs more direct work on GraphQL API endpoint creation, and the frontend team is able to create custom APIs without having to wait on another team to build it for them.

“Hasura and GraphQL have created an explosion of new ideas for new product innovation. In a 2-day hackathon, we were able to accomplish with Hasura what would have taken 2 weeks”

The initial PoC with Hasura showed the potential of GraphQL & Hasura to discover and access all of their data. This led to a flurry of ideas and internal projects to leverage the data. Some of the projects are now in production or on our product roadmap.This newfound agility has also let MachineMetrics create Labs - experimental new features that customers can opt into using.

Increased Customer Engagement & Retention with GraphQL Data APIs

Machine Metrics recently started providing direct access to data to their customers so that they can provide direct access to data to their customers via Hasura and can create custom queries for their own analysis. This has helped them earn new customers who appreciate this flexibility, and has increased customer retention and engagement.

Customizable Reporting & Analytics

Hasura’s GraphQL endpoints provide even more value to MachineMetrics’ customers by also enabling them to create custom reports, data visualizations, and analytics with tools like Grafana, providing an easy to use reporting and observability UI layer.

Operational Excellence

MachineMetrics utilizes Datadog for monitoring of their systems; Hasura’s Datadog support enables them to export all the Hasura logs so they can centralize all their app monitoring on one system and quickly diagnose any issues that occur.

What’s Next for MachineMetrics

MachineMetrics plans on utilizing even more Hasura features in the future and using it to support multiple database backends simultaneously, including MySQL. Currently used for data querying, MachineMetrics plans on increasing the role of Hasura for data mutations in the future. Hasura migrations will also enable them to make consistent metadata and data schema changes as they develop new features and put them into production.

Thank you to our friends at MachineMetrics, and Jochen Rau - Lead Data Engineer for sharing their story with us!

Top comments (0)