Assume for historical reasons the event store is likely 1 table in one
database. What experiences (or ideas) do people have on:
- backup and restore (10 years of events is a lot of events)
- size of event store over time (what's your load)
- keeping inserts performant on an ever-growing database
Also, has anyone ever deleted old events, and if so, what was the outcome?
Of course we can split up event stores by AR, but it just divides up
the same amount of data..
Thanks in advance!
JAmes
Big enough to hold 10 years of data? Not as expensive as backing up
and restoring 10 years of data.
> What is the business value of having that data?
Events? Is it safe to delete old events? I'll lose my ability to
recreate my read-side, unless I intelligently roll-up similar events
to only keep the latest for a particular AR. I'm curious if anyone
has done this.
> Can we archive old data?
How do I know if data is old? "StoreCreatedEvent" may be the first
event in the eventstore, but it's still extremely relevant.
I'm looking for some rules of thumb; I'll definitely summarize once we're done.
JAmes
In my experience, the cost of consumer hard drives is one factor you
can quite safely ignore when trying to get more space for your app.
Getting the IT department to add 2TB to your production DB server's
fibre-channel SAN (and its offsite backup/disaster recovery
environment of course) will still be near impossible.
--
Richard Dingwall
http://richarddingwall.name
Hey Neil,
Thanks muchly for an amazing summary. If you're okay with this, I'd
like to summarize these posts somewhere.
> I suppose as well, I didn't really get the:
> "Assume for historical reasons the event store is likely 1 table in
> one database."
I guess I really only said that to skip the "split AR's into separate
tables" discussion (since I feel that's just delaying the ultimate
concern).
JAmes
To satisfy them and off-load events to a backup server, have a
time-based snapshot minimum along with event-count snapshot maximum.
I'm moving to a 100K per aggregate segregation policy (but could be
anything - even convention-based). Keep the files that keep older
events than the last snapshot is contained within be kept on back up
servers.
What this DOES buy you, is cheaper and faster additions of machines to
load balance your transactional side. You're not moving TBs of data
for a new node if you want complete redundancy everywhere.
Should you need to correct an error and re-read all the events, you
still can without too much additional work.
My $0.02,
Adam
--
Adam
http://adventuresinagile.blogspot.com/
http://twitter.com/adymitruk/
http://www.agilevancouver.net/
http://altnetvancouver.ning.com/