PHPackages                             arxy/gdpr-mysqldump - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. arxy/gdpr-mysqldump

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

arxy/gdpr-mysqldump
===================

A drop-in replacement for mysqldump that optionally sanitizes DB fields for better GDPR conformity.

07PHP

Since Sep 24Pushed 6y ago1 watchersCompare

[ Source](https://github.com/Warxcell/gdpr-mysqldump)[ Packagist](https://packagist.org/packages/arxy/gdpr-mysqldump)[ RSS](/packages/arxy-gdpr-mysqldump/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

Install &amp; Configure
=======================

[](#install--configure)

```
services:
    Arxy\GdprDumpBundle\Converter\DoctrineConverter:
        arguments: ["@doctrine.orm.entity_manager"]

    Arxy\GdprDumpBundle\Transformer\FakerTransformer: ~
    Arxy\GdprDumpBundle\Transformer\StaticValueTransformer: ~
    Arxy\GdprDumpBundle\Transformer\SymfonyPasswordTransformer: ~

arxy_gdpr_dump:
    dsn: 'mysql://user:password@host:port/dbName'
    value_converter: 'Arxy\GdprDumpBundle\Converter\DoctrineConverter' // optional
    gdpr:
        table_name:
            column_name:
                transformer: Arxy\GdprDumpBundle\Transformer\FakerTransformer
                options:
                    generator: firstName
                    arguments: { 'gender': 'male' }
                    locale: en_US
```

Converters:
-----------

[](#converters)

Converters are used to convert value from database to PHP and vice-versa. (For example - convert string '2019-08-20 23:50:50' to \\DateTime(''2019-08-20 23:50:50'))

### Available converters:

[](#available-converters)

`Arxy\GdprDumpBundle\Converter\DoctrineConverter` - uses Doctrine metadata to convert values.

Transformers:
-------------

[](#transformers)

Transformers are used to transform value of column to GDPR-compatible.

### Available transformer:

[](#available-transformer)

`Arxy\GdprDumpBundle\Transformer\FakerTransformer` used with option `generator`, `arguments` and/or `locale`See  for all available `generator`/`arguments` values.

`Arxy\GdprDumpBundle\Transformer\JsonTransformer` - decorates another transformer. Simply `json_encode` it's value.

`Arxy\GdprDumpBundle\Transformer\SerializeTransfoemr` - decorates another transformer. Simply `serialize` it's value.

`Arxy\GdprDumpBundle\Transformer\StaticValueTransformer` - sets the value of option `value`

`Arxy\GdprDumpBundle\Transformer\SymfonyPasswordTransformer` used with option `password` and `saltColumn`. Encodes `password` as per `security` section of Symfony Configuration.

You can always add your own Transformer which fits your needs. Just create your own class which implements `Arxy\GdprDumpBundle\Transformer`or extends `Arxy\GdprDumpBundle\AbstractTransformer` and register it as Symfony Service with tag `arxy.gdpr_mysqldump.transformer`. If you are using Symfony with autowire and autoconfigure you probably won't need to do anything else except creating the class - symfony will take care of the other things. Voila!

How it works
------------

[](#how-it-works)

First values are fetched from database. If ValueConverter is available - it converts the value into PHP variable. Then ValueTransformer is called. The returned value is passed to ValueConverter, if available which converts it into Database Value.

Usage
=====

[](#usage)

Use type-hint `Ifsnop\Mysqldump\Mysqldump` and see documentation of library at `https://github.com/ifsnop/mysqldump-php`.

Configuring and installing using pure php.
==========================================

[](#configuring-and-installing-using-pure-php)

```
$valueTransformer = new \Arxy\GdprDumpBundle\ValueTransformer();
$valueTransformer->addTransformer(new \Arxy\GdprDumpBundle\Transformer\FakerTransformer());

$tableCustomers = new \Arxy\GdprDumpBundle\Metadata\TableMetadata("customers");
$tableCustomers->addColumn(new \Arxy\GdprDumpBundle\Metadata\ColumnMetadata("firstName", \Arxy\GdprDumpBundle\Transformer\FakerTransformer::class, [
'generator' => 'firstName']));
$valueTransformer->addTableMetadata($tableCustomers);

$mysqldump = new \Ifsnop\Mysqldump\Mysqldump($dsn, $user, $password, $dumpSettings, $pdoSettings);
$mysqldump->setTransformColumnValueHook($transformValue);
```

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/517cc56dc986696cfbcbfa0678b9b46b106091ff675b9a3cdebffb70e6742368?d=identicon)[Warxcell](/maintainers/Warxcell)

---

Top Contributors

[![Warxcell](https://avatars.githubusercontent.com/u/3340882?v=4)](https://github.com/Warxcell "Warxcell (10 commits)")

---

Tags

gdprgdpr-dumpmysqlmysql-dumpsql-dump

### Embed Badge

![Health badge](/badges/arxy-gdpr-mysqldump/health.svg)

```
[![Health](https://phpackages.com/badges/arxy-gdpr-mysqldump/health.svg)](https://phpackages.com/packages/arxy-gdpr-mysqldump)
```

###  Alternatives

[mainwp/mainwp-child

This is the Child plugin for the MainWP Dashboard

973.4k](/packages/mainwp-mainwp-child)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
