6

I am looking to add an audit trail to our Rails app. At the moment, I am trying to lock down my requirements and determine the appropriate software architecture.

Our website gets about one hundred million page requests a week, and growing. We currently log a subset of actions into a MySQL table, but that table is much too large and drags down performance of the rest of the app. It's therefore hard to imagine solutions such as audited or paper_trail would work out. We also can't just keep around our log files, even compressed, because they are huge.

So, what sort of software architecture is appropriate here?

  • paper_trail allows you to specify which table audit records are persisted to. As such, you could do a table per object, which might help with performance by reducing the number of records per table. I'm not sure if you missed that or if such a suggestion is even appropriate in regards to your data. – saghaulor Aug 05 '15 at 05:47
  • Thanks for the comment. Separate tables for separate models is helpful, and perhaps we could store the data in an entirely separate SQL server (possibly via a small pull request to paper_trail). That'd help a bit, but not enough for our particular use case. – ChrisInEdmonton Aug 05 '15 at 12:28
  • Hi @ChrisInEdmonton, I am currently solving a similar challenge. Might I as you how did you figure it out? Thanks. – user984621 Feb 28 '16 at 08:11
  • We never did. We currently store our data in MySQL, but with row counts approaching the billions, we are planning on taking a look into various NoSQL stores. – ChrisInEdmonton Feb 28 '16 at 12:53

0 Answers0