It is absolutely possible. I'm actually working on building one right now myself; originally for my own use but now I'm designing it for eventual public use. I'm making use of couchdb as my database. I suggest you look at the source code for the put saver module to get an idea of how you might implement what're you're suggesting.
Regards
So far I am uncertain as to the best approach to take. Because of the size of even an empty tiddlywiki I am leaning toward storing each as a separate file on the server upon save of the wiki. I am thinking this helps ensure each tiddlywiki is "future proof" because each is fully self contained. Newer versions of tiddlywiki will not affect older versions.
However this is all new to me and so I may be mistaken on some basics.
Regards