Build Collaborative Apps

6 reasons why TerminusDB is the right toolkit to build collaborative apps

If you are looking to build collaborative applications where users are a primary source of data and content, then this article explains the TerminusDB and TerminusX features that make them well-suited data management toolkits for building collaborative applications.

Collaborative apps use cases

TerminusDB and TerminusX are being used for numerous applications with collaboration at the core. Here are a few examples.

A backend designed for collaboration

TerminusDB/X is a data management platform that was born out of the need to collaborate. Since then, it has evolved from specializing in complex academic data to becoming a toolkit to build collaborative applications. Our goal is to provide a rich developer experience that offers problem solvers an array of tools to push the boundaries of application development.

There are many TerminusDB/X features and we’ve listed the ones that make it perfect for those looking to build collaborative applications.

Build with JSON

Build with JSON

JSON is the medium of data communication. You can store your data in essentially the way you mean to manipulate it in your programming language. This radically reduces the impedance mismatch which has been a constant source of irritation for developers who were forced to use SQL. It’s also re-usable as an abstract syntax tree for building the communication of queries and updates themselves. No longer do you have to build a query with brittle concatenations of strings. 

MongoDB has achieved remarkable success by providing developers with a database to store data as JSON documents and has helped make application development easier and quicker. 

TerminusDB/X also stores data as JSON documents to provide that ease and speed, but we’ve taken the document store a step further. For further reading on this read our blog What if MongoDB and Neo4j had a Baby.

Graph database - business logic in the database

As mentioned, we’ve taken the document store one step further. The underlying storage structure of TerminusDB/X is a labeled, directed, and edge-labeled graph. Each source and target node has a distinct name, and every edge has a name and a direction.

The segments of the graph are JSON documents meaning that the graph is an interconnected series of documents. This ‘document graph’ provides the ease of development that JSON documents provide, but also the insight that graph databases bring. The relationships between data are almost as important as the data itself.

This means that business logic is contained within the database and that provides developers with the ability to use this logic within their applications.

Flexible and extendable schema

If you’re building an application for users to interact with, then a schema will help you get the UI right. MongoDB users might scoff at this thought, but the bigger your application, the more you will need the guidance and stability that schema provides.

The TerminusDB schema language enables documents and their relationships to be specified using simple JSON syntax. This syntax makes it as easy as possible to specify a JSON object to automatically convert to a graph. This approach enables data to be viewed as collections of documents or as knowledge graphs of interconnected objects.

We’ll also discuss the revision control and collaboration features later, but these tools allow you to change the schema as your application and user requirements evolve, but more on this later.

Schema also plays an important role in application development with TerminusDB/X creating document frames from the schema, and with our Document SDK, means that you can build directly from these frames. Which gives us a segway into…

Document UI SDK

Thanks to our wonderful radio DJ style segway, we’ve landed on our Document UI SDK. The software development kit works directly with the document frames generated from your database schema. This makes building intuitive and data-driven user interfaces easier and quicker. Take a look at the critical asset management system we’re working on for an example of what you can do with it.

Use sophisticated queries to build rich applications where users interact with and update the data. Build in JavaScript and style with CSS and JSON. Using the SDK closely bonds your data and application from inception to evolution.

Database revision control and collaboration tools

TerminusDB features collaboration and version control tools that enable you to branch, reset, rebase, and query data. The ability to create database branches means that changes to schema and the data itself can be achieved quickly and efficiently. Workflow pipelines help developers work together to review, discuss, and approve updates and also help to remove silos, and encourage people to work together to use their collective skills and experience to build better.

As an immutable database, TerminusDB stores everything. The commit-graph time stamps all changes and records what data changed and who changed it. You can then travel back in time to see what data looked like, across branches too, at any particular time.

These features are great for collaborative building, but they are also perfect to add as features to your application. Spin-off branches for users to work with to input their particular expertise all safely away from production. We’ve got another article focusing on some of the things you can do with a version-controlled database.

Diff and patch

A fundamental tool in Git’s strategy for distributed management of source code is the concept of the diff and the patch. These foundational operations are what make Git possible. Diff is used to construct a patch that can be applied to an object so that the final state makes sense. This has helped Git become synonymous with software development and incredibly popular. Developers can work together with control.

We have the same principles for structured data in TerminusDB/X. The very nature of collaborative applications means that many users will be working with the data, whether that’s manipulating it, editing it, or adding to it. JSON diff and patch enable users to compare JSON documents to spot differences and apply one of a number of patches.

The diff and patch functionality can be achieved directly via a client, or by a user interface. Automated diff alerts can also be set up to allow users and moderators to view and decide the outcome of conflicts and changes to the database.

Other notable mentions

There are many more TerminusDB/X features, we’ve listed a few others below that are worthy of mention:

  • Multiple interfaces – Create and maintain your databases using programmatic interfaces such as JavaScript and Python APIs.
  • Advanced query language – WOQL is a powerful and sophisticated query language that allows you to concisely express complex patterns over arbitrary data structures. Read more about WOQL.
  • Data validation – Generate forms for viewing and entering data with automatic data validation.
  • Visual model builder – Use a lightweight Graphical User Interface to easily build, maintain and enforce complex data models.

A recap as to why TerminusDB/X is perfect for building collaborative apps

We’ve covered quite a lot of ground in this article, here’s a quick recap to explain why TerminusDB and TerminusX are the right tools to help you build your collaborative applications.

  1. Build with JSON.
  2. Embed business logic into your database with our document graph.
  3. Use flexible and extendable schema to blueprint your design.
  4. Develop direct from document frames with our UI SDK to knit front and backend together.
  5. Use revision control and collaboration features within your application to let many users collaborate and share to build richness into your application.
  6. Advanced diff and patch operations enable a layer of control and moderation to data to help maintain data integrity across many users.

TerminusDB is an immutable graph database that creates a graph from JSON documents. It features collaboration and version control tools that enable you to branch and query data. These tools enable collaborative builds and the creation of applications designed to let many users collaborate asynchronously.

TerminusX is a cloud self-service data platform built on TerminusDB.

If you’re interested in having a play, getting started is easy. Either install TerminusDB or sign up for TerminusX to get started in minutes. Join us on Discord for troubleshooting or to discuss your ideas and seek inspiration.

Latest Stories
Talk to the team
If you've got questions or want to be part of the TerminusDB community, come say hi on Discord.
Community