I am sure I have seen a post here or on the github site about implementing a Mongodb driver for entity history functionality. I have searched but can not find anything. My Azure database is growing too fast with the insertions into the three entity history tables. I would like to cut into the code and push all entity history entries into Mongodb. Does anyone have any pointers on how to do this?
7 Answer(s)
-
0
Hi @BobIngham,
AspNet Zero doesn't support MongoDb. So maybe it was something else you remember. I remember a topic about MongoDb but it was about running AspNet Zero with MongoDb.
-
0
I am sure I have seen a post here or on the github site about implementing a Mongodb driver for entity history functionality.
Nope.
I would like to cut into the code and push all entity history entries into Mongodb. Does anyone have any pointers on how to do this?
You can implement and replace IEntityHistoryStore.
-
0
Hi Aaron, Someone mentioned table bloat after running Entity History for a while on Azure. It would be nice to cut into the code somewhere and serialise the EntityChangeSet along with the related EntityChanges and EntitypropertyChanges and then simply throw them into a document database. After all, the data are immutable and, as such, are perfect for this functionality. Of course it would also mean cutting into code to deserialise but I don't think that would be problem. I will come back to this later, where should I start? Cheers, Bob
-
0
<cite>aaron: </cite> You can implement and replace IEntityHistoryStore.
-
0
That's a bit like telling me to replace the wimwam on the universal transmogrifier. Can you point me to the github code where the save command is?
-
0
You don't need to know Module Zero's implementation, but here it is: EntityHistoryStore.cs#L22-L25
You can also read the documentation on Replacing Built-In Services.
-
0
Aaron, Forever in your debt. I will take a look at this later, at least now I can see it can be done. Now it's a matter of finding out how to do it! Thanks for your help again, it really is much appreciated. Cheers, Bob