On Tue, Jul 14, 2015 at 11:14 AM, Zdravko Balorda <
li...@ruby-forum.com> wrote:
> There are cases where we are required by law to be able to playback
> requests that have changed something in the database.
1. requests that *have* already changed something or that *could*
(potentially) have changed something?
- e.g. if an update request fails (validation, exception, error, etc.)
should it still be recorded?
2. how much of the request environment do you need to capture
to be able to realistically "play back" the request?
- current_user
- session variables
- request headers
- db state (data, schema) # see point #3
- app version and state # see point #3
- system environment (date/time, TZ, libraries) # see point #3
3. how far back does this history need to go?
- is it reasonable or accurate to "play back" an operation:
- if you've e.g. run a migration on the affected table since the
original request?
- if you're using a class or classes modified or added since the
original request?
- if you're using a system library that's been modified/updated
since the original request?
P.S. Please tell me the "playback" operation -- which by definition is
non-idempotent -- would be happening on a backup/mirror database,
regardless :-)
> Is there a module that can navigate through log history and show all
> pages that were submitted?
> Can it be done?
Anything can be done with enough time and money :-)
(If I had to implement something like this, I'd probably start looking
at ElasticSearch and Logstash.)
FWIW,
--
Hassan Schroeder ------------------------
hassan.s...@gmail.com
http://about.me/hassanschroeder
twitter: @hassan
Consulting Availability : Silicon Valley or remote