Merge pull request #287036 from srhb/kafka-versions-cleanup
kafka: versions cleanup and drop older
This commit is contained in:
commit
efdfa300ee
@ -103,13 +103,8 @@ let
|
||||
}) { inherit system; });
|
||||
|
||||
in with pkgs; {
|
||||
kafka_2_8 = makeKafkaTest "kafka_2_8" { kafkaPackage = apacheKafka_2_8; };
|
||||
kafka_3_0 = makeKafkaTest "kafka_3_0" { kafkaPackage = apacheKafka_3_0; };
|
||||
kafka_3_1 = makeKafkaTest "kafka_3_1" { kafkaPackage = apacheKafka_3_1; };
|
||||
kafka_3_2 = makeKafkaTest "kafka_3_2" { kafkaPackage = apacheKafka_3_2; };
|
||||
kafka_3_3 = makeKafkaTest "kafka_3_3" { kafkaPackage = apacheKafka_3_3; };
|
||||
kafka_3_4 = makeKafkaTest "kafka_3_4" { kafkaPackage = apacheKafka_3_4; };
|
||||
kafka_3_5 = makeKafkaTest "kafka_3_5" { kafkaPackage = apacheKafka_3_5; };
|
||||
kafka_3_6 = makeKafkaTest "kafka_3_6" { kafkaPackage = apacheKafka_3_6; };
|
||||
kafka_3_7 = makeKafkaTest "kafka_3_7" { kafkaPackage = apacheKafka_3_7; };
|
||||
kafka = makeKafkaTest "kafka" { kafkaPackage = apacheKafka; };
|
||||
kafka_kraft = makeKafkaTest "kafka_kraft" { kafkaPackage = apacheKafka; mode = "kraft"; };
|
||||
}
|
||||
|
@ -1,102 +1,70 @@
|
||||
{ lib, stdenv, fetchurl, jdk17_headless, jdk11_headless, makeWrapper, bash, coreutils, gnugrep, gnused, ps,
|
||||
majorVersion ? "1.0" }:
|
||||
{ lib, stdenv, fetchurl, jdk17_headless, jdk11_headless, makeWrapper, bash, coreutils, gnugrep, gnused, ps }:
|
||||
|
||||
let
|
||||
versionMap = {
|
||||
"3.5" = {
|
||||
kafkaVersion = "3.5.0";
|
||||
"3_7" = {
|
||||
kafkaVersion = "3.7.0";
|
||||
scalaVersion = "2.13";
|
||||
sha256 = "sha256-KjpGjgab5XDxbWEqgZbC96kge36shlvpNNIM4SUusvg=";
|
||||
sha256 = "sha256-ZfJuWTe7t23+eN+0FnMN+n4zeLJ+E/0eIE8aEJm/r5w=";
|
||||
jre = jdk17_headless;
|
||||
};
|
||||
"3.4" = {
|
||||
kafkaVersion = "3.4.1";
|
||||
"3_6" = {
|
||||
kafkaVersion = "3.6.2";
|
||||
scalaVersion = "2.13";
|
||||
sha256 = "sha256-p28XpSuPLNMd4RVx/zZqcUggtuTgKJOwFZ0J2w7a+Zg=";
|
||||
sha256 = "sha256-wxfkf3cUHTFG6VY9nLodZIbIHmcLIR7OasRqn3Lkqqw=";
|
||||
jre = jdk17_headless;
|
||||
};
|
||||
"3.3" = {
|
||||
kafkaVersion = "3.3.2";
|
||||
scalaVersion = "2.13";
|
||||
sha256 = "sha256-Gv5XrpXnEajH8fSbcfIfURz+QPcqTrJ1oe3SGXYLNRc=";
|
||||
jre = jdk17_headless;
|
||||
};
|
||||
"3.2" = {
|
||||
kafkaVersion = "3.2.3";
|
||||
scalaVersion = "2.13";
|
||||
sha256 = "sha256-tvkbwBP83M1zl31J4g6uu4/LEhqJoIA9Eam48fyT24A=";
|
||||
jre = jdk17_headless;
|
||||
};
|
||||
"3.1" = {
|
||||
kafkaVersion = "3.1.2";
|
||||
scalaVersion = "2.13";
|
||||
sha256 = "sha256-SO1bTQkG3YQSv657QjwBeBCWbDlDqS3E5eUp7ciojnI=";
|
||||
jre = jdk17_headless;
|
||||
};
|
||||
"3.0" = {
|
||||
kafkaVersion = "3.0.2";
|
||||
scalaVersion = "2.13";
|
||||
sha256 = "sha256-G8b6STGlwow+iDqMCeZkF3HTKd94TKccmyfZ7AT/7yE=";
|
||||
jre = jdk17_headless;
|
||||
};
|
||||
"2.8" = {
|
||||
kafkaVersion = "2.8.2";
|
||||
scalaVersion = "2.13";
|
||||
sha256 = "sha256-inZXZJSs8ivtEqF6E/ApoyUHn8vg38wUG3KhowP8mfQ=";
|
||||
jre = jdk11_headless;
|
||||
};
|
||||
|
||||
};
|
||||
in
|
||||
|
||||
with versionMap.${majorVersion};
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "${scalaVersion}-${kafkaVersion}";
|
||||
pname = "apache-kafka";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://apache/kafka/${kafkaVersion}/kafka_${version}.tgz";
|
||||
inherit sha256;
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
buildInputs = [ jre bash gnugrep gnused coreutils ps ];
|
||||
build = versionInfo: with versionInfo; stdenv.mkDerivation rec {
|
||||
version = "${scalaVersion}-${kafkaVersion}";
|
||||
pname = "apache-kafka";
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out
|
||||
cp -R config libs $out
|
||||
src = fetchurl {
|
||||
url = "mirror://apache/kafka/${kafkaVersion}/kafka_${version}.tgz";
|
||||
inherit sha256;
|
||||
};
|
||||
|
||||
mkdir -p $out/bin
|
||||
cp bin/kafka* $out/bin
|
||||
cp bin/connect* $out/bin
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
buildInputs = [ jre bash gnugrep gnused coreutils ps ];
|
||||
|
||||
# allow us the specify logging directory using env
|
||||
substituteInPlace $out/bin/kafka-run-class.sh \
|
||||
--replace 'LOG_DIR="$base_dir/logs"' 'LOG_DIR="$KAFKA_LOG_DIR"'
|
||||
installPhase = ''
|
||||
mkdir -p $out
|
||||
cp -R config libs $out
|
||||
|
||||
substituteInPlace $out/bin/kafka-server-stop.sh \
|
||||
--replace 'ps' '${ps}/bin/ps'
|
||||
mkdir -p $out/bin
|
||||
cp bin/kafka* $out/bin
|
||||
cp bin/connect* $out/bin
|
||||
|
||||
for p in $out/bin\/*.sh; do
|
||||
wrapProgram $p \
|
||||
--set JAVA_HOME "${jre}" \
|
||||
--set KAFKA_LOG_DIR "/tmp/apache-kafka-logs" \
|
||||
--prefix PATH : "${bash}/bin:${coreutils}/bin:${gnugrep}/bin:${gnused}/bin"
|
||||
done
|
||||
chmod +x $out/bin\/*
|
||||
'';
|
||||
# allow us the specify logging directory using env
|
||||
substituteInPlace $out/bin/kafka-run-class.sh \
|
||||
--replace 'LOG_DIR="$base_dir/logs"' 'LOG_DIR="$KAFKA_LOG_DIR"'
|
||||
|
||||
passthru = {
|
||||
inherit jre; # Used by the NixOS module to select the supported jre
|
||||
substituteInPlace $out/bin/kafka-server-stop.sh \
|
||||
--replace 'ps' '${ps}/bin/ps'
|
||||
|
||||
for p in $out/bin\/*.sh; do
|
||||
wrapProgram $p \
|
||||
--set JAVA_HOME "${jre}" \
|
||||
--set KAFKA_LOG_DIR "/tmp/apache-kafka-logs" \
|
||||
--prefix PATH : "${bash}/bin:${coreutils}/bin:${gnugrep}/bin:${gnused}/bin"
|
||||
done
|
||||
chmod +x $out/bin\/*
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
inherit jre; # Used by the NixOS module to select the supported jre
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://kafka.apache.org";
|
||||
description = "High-throughput distributed messaging system";
|
||||
license = licenses.asl20;
|
||||
sourceProvenance = with sourceTypes; [ binaryBytecode ];
|
||||
maintainers = [ maintainers.ragge ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://kafka.apache.org";
|
||||
description = "High-throughput distributed messaging system";
|
||||
license = licenses.asl20;
|
||||
sourceProvenance = with sourceTypes; [ binaryBytecode ];
|
||||
maintainers = [ maintainers.ragge ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
in with lib; mapAttrs'
|
||||
(majorVersion: versionInfo: nameValuePair "apacheKafka_${majorVersion}" (build versionInfo))
|
||||
versionMap
|
||||
|
@ -86,6 +86,13 @@ mapAliases ({
|
||||
ansible_2_13 = throw "Ansible 2.13 goes end of life in 2023/11"; # Added 2023-12-30
|
||||
ansible_2_14 = throw "Ansible 2.14 goes end of life in 2024/05 and can't be supported throughout the 24.05 release cycle"; # Added 2024-04-11
|
||||
apacheAnt_1_9 = throw "Ant 1.9 has been removed since it's not used in nixpkgs anymore"; # Added 2023-11-12
|
||||
apacheKafka_2_8 = throw "apacheKafka_2_8 through _3_5 have been removed from nixpkgs as outdated"; # Added 2024-02-12
|
||||
apacheKafka_3_0 = throw "apacheKafka_2_8 through _3_5 have been removed from nixpkgs as outdated"; # Added 2024-02-12
|
||||
apacheKafka_3_1 = throw "apacheKafka_2_8 through _3_5 have been removed from nixpkgs as outdated"; # Added 2024-02-12
|
||||
apacheKafka_3_2 = throw "apacheKafka_2_8 through _3_5 have been removed from nixpkgs as outdated"; # Added 2024-02-12
|
||||
apacheKafka_3_3 = throw "apacheKafka_2_8 through _3_5 have been removed from nixpkgs as outdated"; # Added 2024-02-12
|
||||
apacheKafka_3_4 = throw "apacheKafka_2_8 through _3_5 have been removed from nixpkgs as outdated"; # Added 2024-02-12
|
||||
apacheKafka_3_5 = throw "apacheKafka_2_8 through _3_5 have been removed from nixpkgs as outdated"; # Added 2024-06-13
|
||||
antimicroX = antimicrox; # Added 2021-10-31
|
||||
appthreat-depscan = dep-scan; # Added 2024-04-10
|
||||
arcanist = throw "arcanist was removed as phabricator is not supported and does not accept fixes"; # Added 2024-06-07
|
||||
|
@ -17861,14 +17861,11 @@ with pkgs;
|
||||
apacheAnt = callPackage ../development/tools/build-managers/apache-ant { };
|
||||
ant = apacheAnt;
|
||||
|
||||
apacheKafka = apacheKafka_3_5;
|
||||
apacheKafka_2_8 = callPackage ../servers/apache-kafka { majorVersion = "2.8"; };
|
||||
apacheKafka_3_0 = callPackage ../servers/apache-kafka { majorVersion = "3.0"; };
|
||||
apacheKafka_3_1 = callPackage ../servers/apache-kafka { majorVersion = "3.1"; };
|
||||
apacheKafka_3_2 = callPackage ../servers/apache-kafka { majorVersion = "3.2"; };
|
||||
apacheKafka_3_3 = callPackage ../servers/apache-kafka { majorVersion = "3.3"; };
|
||||
apacheKafka_3_4 = callPackage ../servers/apache-kafka { majorVersion = "3.4"; };
|
||||
apacheKafka_3_5 = callPackage ../servers/apache-kafka { majorVersion = "3.5"; };
|
||||
inherit (callPackages ../servers/apache-kafka { })
|
||||
apacheKafka_3_6
|
||||
apacheKafka_3_7;
|
||||
|
||||
apacheKafka = apacheKafka_3_7;
|
||||
|
||||
apng2gif = callPackage ../tools/graphics/apng2gif { };
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user