summary refs log tree commit diff
path: root/pkgs/servers/zookeeper
diff options
context:
space:
mode:
authorDamien Diederen <dd@crosstwine.com>2020-11-23 13:25:45 +0100
committerDamien Diederen <dd@crosstwine.com>2020-12-09 15:46:38 +0100
commitf77d01ffc5916711be911d56b8206c61c022aab5 (patch)
tree320bfd7373fc1ed6ab73f2b28d89284836483950 /pkgs/servers/zookeeper
parentab845500a0fe920f02983efd355a220651225d71 (diff)
downloadnixpkgs-f77d01ffc5916711be911d56b8206c61c022aab5.tar
nixpkgs-f77d01ffc5916711be911d56b8206c61c022aab5.tar.gz
nixpkgs-f77d01ffc5916711be911d56b8206c61c022aab5.tar.bz2
nixpkgs-f77d01ffc5916711be911d56b8206c61c022aab5.tar.lz
nixpkgs-f77d01ffc5916711be911d56b8206c61c022aab5.tar.xz
nixpkgs-f77d01ffc5916711be911d56b8206c61c022aab5.tar.zst
nixpkgs-f77d01ffc5916711be911d56b8206c61c022aab5.zip
zookeeper: 3.4.12 -> 3.6.2
A big jump, but the structure hasn't changed much.

This recipe is still based on a binary release provided by upstream.

(It might be interesting to start doing our own builds at some point,
to split client from server, and/or to create packages for removed
"contribs" such as 'zooInspector'.  Upstream intends to further slim
down its release tarballs as most deployments only need specific assets.)
Diffstat (limited to 'pkgs/servers/zookeeper')
-rw-r--r--pkgs/servers/zookeeper/default.nix34
1 files changed, 11 insertions, 23 deletions
diff --git a/pkgs/servers/zookeeper/default.nix b/pkgs/servers/zookeeper/default.nix
index b0685d7f954..5777532d947 100644
--- a/pkgs/servers/zookeeper/default.nix
+++ b/pkgs/servers/zookeeper/default.nix
@@ -2,11 +2,11 @@
 
 stdenv.mkDerivation rec {
   pname = "zookeeper";
-  version = "3.4.13";
+  version = "3.6.2";
 
   src = fetchurl {
-    url = "mirror://apache/zookeeper/${pname}-${version}/${pname}-${version}.tar.gz";
-    sha256 = "0karf13zks3ba2rdmma2lyabvmasc04cjmgxp227f0nj8677kvbw";
+    url = "mirror://apache/zookeeper/${pname}-${version}/apache-${pname}-${version}-bin.tar.gz";
+    sha512 = "caff5111bb6876b7124760bc006e6fa2523efa54b99321a3c9cd8192ea0d5596abc7d70a054b1aac9b20a411407dae7611c7aba870c23bff28eb1643ba499199";
   };
 
   buildInputs = [ makeWrapper jre ];
@@ -15,40 +15,28 @@ stdenv.mkDerivation rec {
 
   installPhase = ''
     mkdir -p $out
-    cp -R conf docs lib ${pname}-${version}.jar $out
+    cp -R conf docs lib $out
+    # Without this, zkCli.sh tries creating a log file in the Nix store.
+    substituteInPlace $out/conf/log4j.properties \
+        --replace 'INFO, RFAAUDIT' 'INFO, CONSOLE'
     mkdir -p $out/bin
-    cp -R bin/{zkCli,zkCleanup,zkEnv,zkServer}.sh $out/bin
+    cp -R bin/{zkCli,zkCleanup,zkEnv,zkServer,zkSnapShotToolkit,zkTxnLogToolkit}.sh $out/bin
     patchShebangs $out/bin
     substituteInPlace $out/bin/zkServer.sh \
         --replace /bin/echo ${coreutils}/bin/echo
-    for i in $out/bin/{zkCli,zkCleanup,zkServer}.sh; do
+    for i in $out/bin/{zkCli,zkCleanup,zkServer,zkSnapShotToolkit,zkTxnLogToolkit}.sh; do
       wrapProgram $i \
         --set JAVA_HOME "${jre}" \
         --prefix PATH : "${bash}/bin"
     done
     chmod -x $out/bin/zkEnv.sh
-
-    mkdir -p $out/share/zooinspector
-    cp -r contrib/ZooInspector/{${pname}-${version}-ZooInspector.jar,icons,lib,config} $out/share/zooinspector
-
-    classpath="$out/${pname}-${version}.jar:$out/share/zooinspector/${pname}-${version}-ZooInspector.jar"
-    for jar in $out/lib/*.jar $out/share/zooinspector/lib/*.jar; do
-      classpath="$classpath:$jar"
-    done
-
-    cat << EOF > $out/bin/zooInspector.sh
-    #!${runtimeShell}
-    cd $out/share/zooinspector
-    exec ${jre}/bin/java -cp $classpath org.apache.zookeeper.inspector.ZooInspector
-    EOF
-    chmod +x $out/bin/zooInspector.sh
   '';
 
   meta = with stdenv.lib; {
-    homepage = "http://zookeeper.apache.org";
+    homepage = "https://zookeeper.apache.org";
     description = "Apache Zookeeper";
     license = licenses.asl20;
-    maintainers = with maintainers; [ nathan-gs cstrahan pradeepchhetri ];
+    maintainers = with maintainers; [ nathan-gs cstrahan pradeepchhetri ztzg ];
     platforms = platforms.unix;
   };
 }