Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: webfactory/slimdump
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 1.13.0
Choose a base ref
...
head repository: webfactory/slimdump
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 1.14.0
Choose a head ref
  • 8 commits
  • 16 files changed
  • 2 contributors

Commits on Jan 21, 2022

  1. Führe GitHub Actions Workflows mit Ubuntu 20.04 aus (#87)

    Der für uns wesentliche Unterschied sollte die Verwendung von MySQL 8 sein. Auf diese Weise können wir testen, ob wir vorwärtskompatibel sind.
    mpdude authored Jan 21, 2022
    Configuration menu
    Copy the full SHA
    92452e3 View commit details
    Browse the repository at this point in the history

Commits on Aug 29, 2022

  1. Bump dependencies, update test matrix (#91)

    Update the test matrix to run also PHP 8.x while dropping compatibility with really old package versions.
    
    Update `composer.lock` (used when building the boxed .phar version) using PHP 7.4.
    mpdude authored Aug 29, 2022
    Configuration menu
    Copy the full SHA
    31320e1 View commit details
    Browse the repository at this point in the history
  2. Remove DumperTest (#90)

    The `DumperTest` class is FUBAR in its design: It mocks the DBAL connection, making assumptions about the order and semantics of the queries the `Dumper` class will issue.
    
    As long as we need to query the database for schema information and/or use the DBAL schema tool that does it, probably the only way to go for code like this is to do real functional/integration tests against a real database.
    
    Since this broken test is getting in our way in #88, let's remove it.
    mpdude authored Aug 29, 2022
    Configuration menu
    Copy the full SHA
    d03589e View commit details
    Browse the repository at this point in the history

Commits on Aug 30, 2022

  1. Refactor output-format related code into a dedicated class + interface (

    #88)
    
    We are looking into adding an option to do CSV exports as well. As a first step in that direction, we need to separate everything related to how we write export SQL from things related to fetching the data and user interface. Currently, that's all mixed up in the `Dumper` class.
    
    This PR takes a first step in that direction by introducing the `OutputFormatDriverInterface`, and moving everything related to exporting SQL from the `Dumper` class to `MysqlOutputFormatDriver`.
    
    Co-authored-by: Matthias Pigulla <mp@webfactory.de>
    FabianSchmick and mpdude authored Aug 30, 2022
    Configuration menu
    Copy the full SHA
    fb2d7af View commit details
    Browse the repository at this point in the history

Commits on Sep 2, 2022

  1. Refactor the SlimdumpCommand, DumpTask and Dumper classes (#93)

    This PR contains a few refactorings that make the `SlimdumpCommand`, `DumpTask` and `Dumper` classes and method signatures more straightforward:
    
    * By creating the `MysqlOutputFormatDriver` in `SlimdumpCommand`, we can pass it the necessary information from command line switches directly. No need to pass-through these flags and settings through other classes/methods.
    * Separate the `OutputInterface` given to `MysqlOutputFormatDriver` (for writing out SQL) from the `OutputInterface` passed to `Dumper` (where it is used to output progress information)
    * Use a `NullOutput` for the progress-related `OutputInterface` instead of passing a `$noProgress` boolean through several methods. Saves us a bunch of `if`-conditionals.
    * "Extract method" refactorings for some meaningful chunks of code
    mpdude authored Sep 2, 2022
    Configuration menu
    Copy the full SHA
    819c4f7 View commit details
    Browse the repository at this point in the history
  2. Remove the Dumper::keepalive() method (#94)

    The `Connection::ping()` method is deprecated in Doctrine DBAL.
    
    According to the deprecation notice, "retry and reconnecting lost connections now happens automatically".
    
    Thus, we can remove the `keepalive()` method.
    mpdude authored Sep 2, 2022
    Configuration menu
    Copy the full SHA
    064c2b0 View commit details
    Browse the repository at this point in the history
  3. Ensure PHP 7.2 compatibility for the composer.lock file (#95)

    Downgrade dependencies to versions compatible with PHP ^7.2, and add a workflow to check if the composer.lock file works for different PHP versions.
    
    We need to declare `symfony/service-contracts` `^2.1.2` to come up with dependency versions compatible with PHP 7.2 – 8.1.
    mpdude authored Sep 2, 2022
    Configuration menu
    Copy the full SHA
    2119d7c View commit details
    Browse the repository at this point in the history

Commits on Sep 16, 2022

  1. Implement CSV output mode (#92)

    This change implements a new output mode for CSV files.
    
    The new command option `--output-csv=...` enables CSV output mode, and must be given the path to a directory. The output mode will create `.csv` files in the given directory, named according to the dumped tables.
    
    This output format does not support output redirection from `stdout` as the default MySQL SQL format does.
    
    CSV files will be created only for tables that contain data. In other words, `schema` type dumps will skip the table in question. Also, dumping views/triggers makes no sense for CSV files, they will be skipped as well.
    
    How to best write binary (BLOB) data and/or NULL values in CSV files is probably highly controversial. For now, we'll just go with the [`0x...` hex literals supported by MySQL](https://dev.mysql.com/doc/refman/8.0/en/hexadecimal-literals.html). Maybe having binary data in CSV files is not a sane idea in the first place.
    
    Co-authored-by: Matthias Pigulla <mp@webfactory.de>
    FabianSchmick and mpdude authored Sep 16, 2022
    Configuration menu
    Copy the full SHA
    6d6bab7 View commit details
    Browse the repository at this point in the history
Loading