Updates from Squidex: January 2018

Sebastian Stehle
Squidex
Published in
3 min readJan 18, 2018

It’s a great start of the year. We have developed a bunch of new features in the last weeks and we would like to talk about them in this blog post.

Stronger Consistency Model

Until January, Squidex used an CQRS architecture with a weak consistency model. This is the model that was used before:

When you make a mutation using our user interface or the API — e.g. creating a new content item — Squidex is writing this information as events to the database, e.g. a ContentCreated event. A background process then fetches these events and populates another database, which is optimized for reading. Lets say if you use Squidex to build a blog, when you create a new post you want to redirect the user to the page for this post, but it might not be ready yet and the page will show a 404 error, because the background process is too slow at the moment. A few seconds later it might show up, not a big deal for a blog but harder to handle in other cases. There is a good article how to deal with it, but it is not an easy task.

Therefore we changed our model. Now when you write content, the change is available immediately. Period. Nothing special and easy to handle. When you update your own Squidex installation, our new migration system will upgrade the database automatically for you. There are still some background processes, e.g. to populate statistics tables and to trigger webhooks, because we want mutations to be fast, but this is nothing that you have to care about usually.

Bulk Edit

With our improved consistency model it was easy to add bulk edit features to the user interface. You can select content items and publish, unpublish, restore, archive or delete them, depending on their status, and we also made the footer and header sticky. Yaay!

GraphQL Part 1: More Queries

We realized that the GraphQL endpoint was not consistent with the REST endpoint, because REST also delivers the total number of content items to make pagination easier. Therefore we introduced new queries, e.g. queryCountriesContentsWithTotal.

Btw, the old query operations are working the same way.

GraphQL Part 2: Mutations

Finally we found the time to implement mutations. Now you can create, update, patch, publish, unpublish, archive, restore and delete content items with GraphQL. We do not support the JSON field type for mutations yet, because there are some limitations with graphql-dotnet, but we will work on that. The GraphQL endpoint supports the same operations now as the REST endpoint. So far there are no plans to support all other operations, e.g. creating schemas and apps, because it is hard to maintain two APIs, but we consider to support other special endpoints, e.g. GRPC for import and backup operations.

Whats Next?

On the feature side, you can check our Roadmap on Trello. You can also add comments if you have an account. We also have to improve the documentation and create samples.

My personal project is to create a new profile page with Squidex and make the code available on Github and also publish a docker image.

On the technical side our migration to Microsoft Orleans for improved scalability is still in-progress, but we have decided to wait for version 2.0 or even 2.1 yet and focus on features now.

--

--