The Linux Foundation this week announced that Ent, an entity framework for the Go programming language that Facebook made available as an open-source project, is now being governed going forward under the auspices of the consortium.
The Ent framework makes it easier for developers to build and maintain complex backend applications created using a codebase made up of hundreds of different entity types that generally have complex relationships with one another, says Ariel Mashraki, Ent’s creator and lead maintainer. “All logic is in one schema,” adds Mashraki.
A graph provides the foundation for modeling an application schema using the Ent framework. It employs code-generation techniques to create type-safe, efficient code that makes it simpler to work with databases. Schemas are modeled in graph concepts based on nodes and edges that make traversing through datasets and expressing complex queries easier and less error-prone, he says.
The code generated by Ent is completely type-safe, which means that many classes of common bugs are caught earlier in the development process. In addition, code editing software can understand Ent code very well to offer developers useful hints and feedback as they are typing code.
Finally, schemas are defined in actual Go code, which helps streamline integrations with external systems at the data-access layer.
Similar in concept to other object-relational mappers (ORMs), the Ent framework provides a more opinionated approach to improve developer productivity that eliminates the need to rely on a traditional table-oriented method, notes Mashraki. Queries create a graph traversal.ent that comes with a command-line tool to automatically generate code schema and create a visual representation of the schema.
Overall, there are now already more than 100 contributors working at organizations ranging from GitHub, Mail.ru, Scaleway to VirtaHealth, adds Maskraki. The project is also looking to welcome additional contributors.
In general, applications are becoming more complex as they are increasingly deployed across what is becoming a highly distributed computing environment. That shift makes it that much more difficult for developers to manage code bases that, in many cases, are now continuously updated.
It’s not clear to what degree the Ent framework might supplant other approaches to managing codebases, but as the number of Ent, contributors increases it will be difficult for any proprietary framework for managing a Go codebase to keep pace with the rate of innovation that an open-source community can sustain over the long haul.
In the meantime, the Go programming language continues to gain momentum as a simpler way to build more efficient software. In some cases, choosing which programming language to employ is often driven by how rich the frameworks and tooling for that programming language really are. There are clearly a large number of developers that are fans of Go but translating that enthusiasm into building complex backend applications that were once the preserve of, for example, Java, requires a more organized approach to building a larger ecosystem around it.