diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 350a267..4ea6524 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -19,7 +19,7 @@ jobs: show-progress: false - name: Setup java - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: 'adopt' java-version: '11' diff --git a/akka/src/main/scala/akka.stream.io.compression.brotli/BrotliCompressor.scala b/akka/src/main/scala/akka.stream.io.compression.brotli/BrotliCompressor.scala index b8d10cc..1c4ee23 100644 --- a/akka/src/main/scala/akka.stream.io.compression.brotli/BrotliCompressor.scala +++ b/akka/src/main/scala/akka.stream.io.compression.brotli/BrotliCompressor.scala @@ -61,52 +61,4 @@ class BrotliCompressor(level: Int = BrotliCompressor.DefaultQuality) extends Com /** Make sure any resources have been released */ override final def close(): Unit = {} -} - - -/* - - - - public BrotliOutputStream(OutputStream destination, Encoder.Parameters params) - - - - - - */ - - - -/* -public BrotliEncoderChannel(WritableByteChannel destination, Encoder.Parameters params) - throws IOException { - -*/ - - -/* - -protected def flushWithBuffer(buffer: Array[Byte]): ByteString = { - val written = deflater.deflate(buffer, 0, buffer.length, Deflater.SYNC_FLUSH) - ByteString.fromArray(buffer, 0, written) - } - - private def newTempBuffer(size: Int = 65536): Array[Byte] = { - // The default size is somewhat arbitrary, we'd like to guess a better value but Deflater/zlib - // is buffering in an unpredictable manner. - // `compress` will only return any data if the buffered compressed data has some size in - // the region of 10000-50000 bytes. - // `flush` and `finish` will return any size depending on the previous input. - // This value will hopefully provide a good compromise between memory churn and - // excessive fragmentation of ByteStrings. - // We also make sure that buffer size stays within a reasonable range, to avoid - // draining deflator with too small buffer. - new Array[Byte](math.max(size, MinBufferSize)) - } -} - -*/ - - - +} \ No newline at end of file diff --git a/build.sbt b/build.sbt index 50ea0e4..67a089d 100644 --- a/build.sbt +++ b/build.sbt @@ -21,7 +21,7 @@ lazy val sharedSettings = Seq( publishConfiguration := publishConfiguration.value.withOverwrite(true) ) -val Brotli4jVersion = "1.12.0" +val Brotli4jVersion = "1.15.0" lazy val common = project .settings( sharedSettings, diff --git a/common/lib/native-linux-aarch64-1.12.0.jar b/common/lib/native-linux-aarch64-1.12.0.jar deleted file mode 100644 index 7302fa2..0000000 Binary files a/common/lib/native-linux-aarch64-1.12.0.jar and /dev/null differ diff --git a/common/lib/native-linux-aarch64-1.15.0.jar b/common/lib/native-linux-aarch64-1.15.0.jar new file mode 100644 index 0000000..0498e72 Binary files /dev/null and b/common/lib/native-linux-aarch64-1.15.0.jar differ diff --git a/common/lib/native-linux-armv7-1.12.0.jar b/common/lib/native-linux-armv7-1.12.0.jar deleted file mode 100644 index e6458b9..0000000 Binary files a/common/lib/native-linux-armv7-1.12.0.jar and /dev/null differ diff --git a/common/lib/native-linux-armv7-1.15.0.jar b/common/lib/native-linux-armv7-1.15.0.jar new file mode 100644 index 0000000..10de59e Binary files /dev/null and b/common/lib/native-linux-armv7-1.15.0.jar differ diff --git a/common/lib/native-linux-ppc64le-1.15.0.jar b/common/lib/native-linux-ppc64le-1.15.0.jar new file mode 100644 index 0000000..d1e2a39 Binary files /dev/null and b/common/lib/native-linux-ppc64le-1.15.0.jar differ diff --git a/common/lib/native-linux-riscv64-1.15.0.jar b/common/lib/native-linux-riscv64-1.15.0.jar new file mode 100644 index 0000000..2f37db6 Binary files /dev/null and b/common/lib/native-linux-riscv64-1.15.0.jar differ diff --git a/common/lib/native-linux-s390x-1.15.0.jar b/common/lib/native-linux-s390x-1.15.0.jar new file mode 100644 index 0000000..634eb9e Binary files /dev/null and b/common/lib/native-linux-s390x-1.15.0.jar differ diff --git a/common/lib/native-linux-x86_64-1.12.0.jar b/common/lib/native-linux-x86_64-1.12.0.jar deleted file mode 100644 index b9c5cef..0000000 Binary files a/common/lib/native-linux-x86_64-1.12.0.jar and /dev/null differ diff --git a/common/lib/native-linux-x86_64-1.15.0.jar b/common/lib/native-linux-x86_64-1.15.0.jar new file mode 100644 index 0000000..d25d6ff Binary files /dev/null and b/common/lib/native-linux-x86_64-1.15.0.jar differ diff --git a/common/lib/native-osx-aarch64-1.12.0.jar b/common/lib/native-osx-aarch64-1.12.0.jar deleted file mode 100644 index 27ed0f2..0000000 Binary files a/common/lib/native-osx-aarch64-1.12.0.jar and /dev/null differ diff --git a/common/lib/native-osx-aarch64-1.15.0.jar b/common/lib/native-osx-aarch64-1.15.0.jar new file mode 100644 index 0000000..f7329e6 Binary files /dev/null and b/common/lib/native-osx-aarch64-1.15.0.jar differ diff --git a/common/lib/native-osx-x86_64-1.12.0.jar b/common/lib/native-osx-x86_64-1.12.0.jar deleted file mode 100644 index 66558dd..0000000 Binary files a/common/lib/native-osx-x86_64-1.12.0.jar and /dev/null differ diff --git a/common/lib/native-osx-x86_64-1.15.0.jar b/common/lib/native-osx-x86_64-1.15.0.jar new file mode 100644 index 0000000..c9e8660 Binary files /dev/null and b/common/lib/native-osx-x86_64-1.15.0.jar differ diff --git a/common/lib/native-windows-aarch64-1.15.0.jar b/common/lib/native-windows-aarch64-1.15.0.jar new file mode 100644 index 0000000..eb07a42 Binary files /dev/null and b/common/lib/native-windows-aarch64-1.15.0.jar differ diff --git a/common/lib/native-windows-x86_64-1.12.0.jar b/common/lib/native-windows-x86_64-1.12.0.jar deleted file mode 100644 index 97487b0..0000000 Binary files a/common/lib/native-windows-x86_64-1.12.0.jar and /dev/null differ diff --git a/common/lib/native-windows-x86_64-1.15.0.jar b/common/lib/native-windows-x86_64-1.15.0.jar new file mode 100644 index 0000000..0350af8 Binary files /dev/null and b/common/lib/native-windows-x86_64-1.15.0.jar differ diff --git a/scripts/update-lib.sh b/scripts/update-lib.sh index 346b346..024451b 100755 --- a/scripts/update-lib.sh +++ b/scripts/update-lib.sh @@ -2,11 +2,18 @@ cd ../common/lib/ -version='1.12.0' +version='1.15.0' -curl -OJ -# "https://repo1.maven.org/maven2/com/aayushatharva/brotli4j/native-osx-aarch64/${version}/native-osx-aarch64-${version}.jar" -curl -OJ -# "https://repo1.maven.org/maven2/com/aayushatharva/brotli4j/native-osx-x86_64/${version}/native-osx-x86_64-${version}.jar" -curl -OJ -# "https://repo1.maven.org/maven2/com/aayushatharva/brotli4j/native-windows-x86_64/${version}/native-windows-x86_64-${version}.jar" -curl -OJ -# "https://repo1.maven.org/maven2/com/aayushatharva/brotli4j/native-linux-x86_64/${version}/native-linux-x86_64-${version}.jar" -curl -OJ -# "https://repo1.maven.org/maven2/com/aayushatharva/brotli4j/native-linux-aarch64/${version}/native-linux-aarch64-${version}.jar" -curl -OJ -# "https://repo1.maven.org/maven2/com/aayushatharva/brotli4j/native-linux-armv7/${version}/native-linux-armv7-${version}.jar" +for platform in 'native-osx-aarch64' \ + 'native-osx-x86_64' \ + 'native-windows-x86_64' \ + 'native-windows-aarch64' \ + 'native-linux-x86_64' \ + 'native-linux-aarch64' \ + 'native-linux-armv7' \ + 'native-linux-s390x' \ + 'native-linux-riscv64' \ + 'native-linux-ppc64le' +do + curl -OJ -# "https://repo1.maven.org/maven2/com/aayushatharva/brotli4j/${platform}/${version}/${platform}-${version}.jar" +done \ No newline at end of file