Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mariadb: 10.2.17 -> 10.3.15 #44343

Merged
merged 4 commits into from Jun 4, 2019
Merged

mariadb: 10.2.17 -> 10.3.15 #44343

merged 4 commits into from Jun 4, 2019

Conversation

Izorkin
Copy link
Contributor

@Izorkin Izorkin commented Aug 2, 2018

Motivation for this change

The goal for the split is to avoid duplicating binary files in client and server packages. Change default codepage to utf8mb4. Additional improvements.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Fits CONTRIBUTING.md.

@Izorkin Izorkin mentioned this pull request Aug 2, 2018
9 tasks
@Izorkin Izorkin changed the title mariadb: fix build client and refactor config mariadb: fix build client and change config Aug 2, 2018

patches = [ ./cmake-includedir.patch ./include-dirs-path.patch ]
++ stdenv.lib.optional stdenv.cc.isClang ./clang-isfinite.patch;

cmakeFlags = [
"-DBUILD_CONFIG=mysql_release"
"-DCMAKE_BUILD_TYPE=Release"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should already be the default. (see cmake setup hook)

@jtojnar
Copy link
Contributor

jtojnar commented Aug 2, 2018

It would be nice if you could split the changeset to multiple commits, it is pretty hard to wrap my head around all those changes. Also why are you removing the comments?

@Izorkin
Copy link
Contributor Author

Izorkin commented Aug 2, 2018

Comments were removed by mistake.I will try to fix and split the PR to separate commits soon.

@Izorkin
Copy link
Contributor Author

Izorkin commented Aug 2, 2018

Changed PR. Please check.

@@ -50,8 +50,8 @@ common = rec { # attributes common to both builds
cmakeFlags = [
"-DBUILD_CONFIG=mysql_release"
"-DMANUFACTURER=NixOS.org"
"-DDEFAULT_CHARSET=utf8"
"-DDEFAULT_COLLATION=utf8_general_ci"
"-DDEFAULT_CHARSET=utf8mb4"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

postInstall = ''
rm -r "$out"/share/mysql
rm -r "$out"/share/doc/mysql/{policy,systemd}
rm "$out"/bin/{galera_new_cluster,galera_recovery,mariadb-service-convert,msql2mysql,my_print_defaults,mysql_convert_table_format,mysqld_safe_helper,mysql_install_db,mysql_plugin,mysql_secure_installation,mysql_setpermission,mysql_upgrade,mytop,perror,replace,resolveip,resolve_stack_dump,wsrep_sst_rsync_wan,mysql_config,mariadb_config}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you wrap or split long lines for readability?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@@ -224,7 +216,7 @@ galera = stdenv.mkDerivation rec {
version = "25.3.23";

src = fetchurl {
url = "https://mirrors.nxthost.com/mariadb/mariadb-10.2.14/galera-${version}/src/galera-${version}.tar.gz";
url = "https://mirrors.nxthost.com/mariadb/mariadb-10.3.8/galera-${version}/src/galera-${version}.tar.gz";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does the old url not work anymore?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Working. Just changed the link to the current version MariaDB

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So it's a version update? If so you also need to update the hash, and mark it as such in the commit message

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, these are identical versions.

"-DSECURITY_HARDENED=ON"

"-DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock"
"-DINSTALL_UNIX_ADDRDIR=/run/mysqld/mysqld.sock"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this correct? mysqld.sock is a socket file, not a directory (as suggested by the name ADDRDIR).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. If not specified "MYSQL_UNIX_ADDR" is used INSTALL_UNIX_ADDRDIR
https://github.com/MariaDB/server/blob/10.3/cmake/install_layout.cmake#L252-L254

@Izorkin
Copy link
Contributor Author

Izorkin commented Aug 13, 2018

MariaDB revert to 10.2.16 - 4c45016
Need reupdate PR?

@@ -98,28 +96,26 @@ common = rec { # attributes common to both builds
client = stdenv.mkDerivation (common // {
name = "mariadb-client-${common.version}";

outputs = [ "bin" "dev" "out" ];
outputs = [ "dev" "out" "man" ];
Copy link
Member

@vcunat vcunat Aug 18, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a non-standard output order; I would expect "out" to be first in this set. https://nixos.org/nixpkgs/manual/#multiple-output-file-binaries-first-convention (same again below)

@Izorkin Izorkin changed the title mariadb: fix build client and change config mariadb: update to 10.3.9 Aug 19, 2018
@Mic92 Mic92 changed the title mariadb: update to 10.3.9 mariadb: 10.2.17 -> 10.3.9 Aug 23, 2018
@Izorkin Izorkin changed the title mariadb: 10.2.17 -> 10.3.9 mariadb: 10.2.17 -> 10.3.10 Oct 5, 2018
@Izorkin
Copy link
Contributor Author

Izorkin commented Apr 14, 2019

@Izorkin
Copy link
Contributor Author

Izorkin commented Apr 15, 2019

@aanderse
Copy link
Member

@Izorkin I think you're having trouble finding 1 person willing to merge each of these changes. Some of these changes individually aren't a big deal to merge, but all together at the same time make it difficult to be certain regressions aren't introduced. If this was broken into several PRs I'm guessing at least a few of the new PRs would be merged much sooner than this individual PR would be. Merging the contents of this PR spread out over several PRs over a period of time would likely also help tracking down any potential regressions that might arise from this much quicker.

Just my 2 cents.

@Izorkin
Copy link
Contributor Author

Izorkin commented May 19, 2019

@aanderse see #44343 (comment)
I can squashed in 1 PR.

@aanderse
Copy link
Member

@Izorkin multiple commits was an improvement... but I wonder if you might need to go as far as multiple commits to get some action on this.

You are doing quite a few things in a single PR and I just wonder if you're making too many changes at once so no one is comfortable enough to merge all the changes at once.

I don't speak for others, I just wonder if they feel that way.

@Izorkin
Copy link
Contributor Author

Izorkin commented May 19, 2019

Simplify PR to, for example, 5 commits?

@aanderse
Copy link
Member

You might consider creating a PR to change the default code page, a PR to bump the version, and a PR to apply some cleanup.

@Izorkin Izorkin changed the title mariadb: 10.2.17 -> 10.3.12 mariadb: 10.2.17 -> 10.3.15 May 19, 2019
@Izorkin
Copy link
Contributor Author

Izorkin commented May 19, 2019

Reconfigured and updated to 10.3.15

@Izorkin
Copy link
Contributor Author

Izorkin commented May 19, 2019

@GrahamcOfBorg build mariadb.server mariadb.client
@GrahamcOfBorg test mysql mysqlBackup mysqlReplication

@Izorkin
Copy link
Contributor Author

Izorkin commented Jun 4, 2019

Updated PR.

@matthewbauer matthewbauer merged commit 75a82b5 into NixOS:master Jun 4, 2019
@Izorkin
Copy link
Contributor Author

Izorkin commented Jun 4, 2019

Thanks!

@Izorkin Izorkin deleted the mariadb-10.3 branch June 4, 2019 16:30
@ajs124 ajs124 mentioned this pull request Jun 9, 2019
10 tasks
ajs124 added a commit to ajs124/nixpkgs that referenced this pull request Jun 14, 2019
The 10.2 → 10.3 upgrade (NixOS#44343) broke it
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet