@jens thanks for your reply.
I want to limit the number of documents a user can have on a free account. Let’s say that a user can only have 100 documents using the free account. If he wants to have more than 100 documents he will need to pay an extra fee.
In order to do this I need to be able to prevent the user from adding more documents when the limit is reached. Also, knowing how much space a user documents are occupying is an important metric as well.
A user might have very little number of documents but if he has a lot of space being occupied by those documents, that would be a problem.
My application is a sound synthesizer . I have initially developed a preset synchronisation system on my own but it was not robust at all. I need a robust solution to scale the app capabilities and I have found couchbase.
Presets are just JSON files. But in the future, a preset can also have sound files (blobs). Since people get excited with this kind of ability, they start add documents over and over without having any concern about the implications of the database grow. I want to find ways of limiting this and getting extra revenue from the users who want to have more documents and space in order to be able to maintain and scale the complex system this involves.
Does this make sense to you? Can you see other problems arising?