-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Investigate "document model" requirement #1
Comments
From reading the document, I can take:
The goal is to make platform that will be able to give insights into the business processes of the Maker. But is the scope of the MVP (at the moment) is only the database model + API on top, I assume the modelling can happen in the upper layer or later on in the development phase. The only requirement here for us is then to closely follow Domain-driven design pattern.
From this I assume that we will also (in the long-term) need to create some kind of export/import format + the viewer of the document.
This is a bit trickier requirement, it implies we should export operations (ie actual code) + processor (also code) together with the document static state. So we would need to export not only the data, but the model(s) related to that data. This is becoming especially tricky if we expect migrations and model changes (see more points below)
The provided example is too simple, because it displays only one-to-one or one-to-many relations. If we to introduce any other relation, like many-to-many or many-to-one, we would end up with data duplications (eg comments + users, where several comments contains the same user object). Therefore, the proposed format only works as a representation of the data, not as a storage/exchange medium. We might want to use something like
This requirement reminds me of "operational transformation" algorithm used for the complex realtime collaborative systems (eg google docs). From the other side it also matches a description of the blockchain transaction "calldata". Both seems too complex technologies to achieve specified goal. If there is no other hidden problems this requirement tries to solve, I think a history of edits + data about who and when did those edits might be sufficient here. That would produce the same data as in the examples, but without "replay to get into the final state" functionality. I think "replay" also contradicts point about making database exports/read-only replicas accessible and useful for analysts familiar with SQL.
Keeping history of operations to be able to replay them would require us:
This is basically a smart contract on steroids (since usual contracts can't really work with complex data structures such as json objects). See my point above for the overall question about distributing code with data.
I think it's a good idea to implement an auto-generated UI on top of the data structures that will be defined in our system instead of expecting every other system to reimplement the wheel. I would actually push this requirement on top in order to make MVP version usable end-to-end without external tools or curl commands. In the long-term we can maybe even provide a frontend plugin/iframe to easier integrate editing interface into other platforms.
This requirement is doable in the long-term, if we would keep all logic out of the database and resolvers and keep it potentially operational inside the browser. I would even consider using sqlite instead of the postgresql, because it's actually faster and can work in the browser. This way, a private sqlite instance can be created in the browser to keep all the data. This is still a complex requirement, since it introduces immense complexity for the locally run migrations and makes data integrity a complex task.
I generally don't see a problem with this requirement, although I assume it's a long-term one. For simple files with can start with base64 encoding them and later introduce more complex system with file upload as soon as we figure out "export/import" and "local editing" functionalities.
Many data exchange formats (like
Are we talking about the platform that let users write frontend-only code to get insights into the data (without the ability to modify the data?). Like observablehq.com? Then, I think, integrating the data with existing tools and providing integration examples will potentially be more useful than introducing a completely new application that someone have to spend time learning. Or is this UI suppose to be a "playground" to develop new operations/processors and test them over actual data before submitting it as a pull request? I think I'm missing concrete examples of the usage of such application to understand it. Or more generally put, what does this requirement try to solve? OverallThank you for the doc @wkampmann, I think it clarifies a lot of points and gives a lot of insights into the future of the tool. Most of the things are not directly relevant to start working on the project, but useful to keep in mind. Main takeaways: we should aim to have UI already for the MVP, we must preserve history of the records from day 1 and keep in mind potential frontend-only/offline-first functionality of the future. Next, I will do technical research on the existing tools to come up with a framework that will let us accomplish all possible outcomes of this evaluation. |
@wkampmann, would you be able to bring some input on the raised questions? I think it will be most important to outline underlying non-technical requirements here, since it we will allow us to derive technical decisions from it. I.e.: what exactly is the problem that the proposed model is trying to solve? |
Also, please let me know here if I misinterpreted/misunderstood something on the page, while deriving requirements from it |
So the outcome of the investigation and based on the last meeting at 24.03.2023: document model requirement will be split into 4 parts:
Current integration schema: |
Goal
Clarity on the requirement and technical solutions
Context
During the last meeting we were introduced with the requirement of the "document model". In order to properly implement it, we need to figure out:
Notes: let's not discuss something very long-term in this issue to keep scope small, but just clarify things that might influence our initial setup/approach here.
Assets
Tasks
The text was updated successfully, but these errors were encountered: