Release blog post, ActiveRecord models: How to remove data in GDPR compliant way
- Add WipeOut to your application's Gemfile:
gem "wipe_out", "~> 1.0"
Check newest release at here.
Quick example:
Given the following model:
# == Schema Info
#
# Table name: users
#
# id :integer(11) not null, primary key
# name :varchar(11) not null
# orders_count :integer(11) not null
class User < ActiveRecord::Base
end
We can define custom wipe out plan:
UserWipeOutPlan = WipeOut.build_plan do
wipe_out :name
ignore :orders_count
end
and execute it:
User.last.then { |user| UserWipeOutPlan.execute(user) }
It will overwrite data inside name
but leave, orders_count
untouched.
There is also support for relations and making sure that policies are defined for any added columns.
Read more in getting started doc.
See development.md