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

Add release automation workflow #384

Merged
merged 2 commits into from
Jan 28, 2023
Merged

Add release automation workflow #384

merged 2 commits into from
Jan 28, 2023

Conversation

xerial
Copy link
Owner

@xerial xerial commented Jan 28, 2023

No description provided.

@xerial xerial added internal and removed feature labels Jan 28, 2023
@xerial xerial merged commit c515db5 into master Jan 28, 2023
@xerial xerial deleted the release-automation branch January 28, 2023 08:33
- uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '11'

Choose a reason for hiding this comment

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

Hi ~ @xerial, 1.19.0 was compiled and released using Java 11, will Java 8 no longer be supported after 1.19.0? I didn't find relevant information in the release notes.

Choose a reason for hiding this comment

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

Sorry, please ignore my comment temporarily

Copy link
Owner Author

Choose a reason for hiding this comment

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

The build target is 1.8, so it should work with Java 8 https://github.com/xerial/snappy-java/blob/master/build.sbt#L30

Choose a reason for hiding this comment

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

Thanks very much for your reply.

Copy link

@LuciferYang LuciferYang Jan 31, 2023

Choose a reason for hiding this comment

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

@xerial I'm very sorry, but I still need to bother you
I wrote a simple demo to reproduce this issue, the demo is in https://github.com/LuciferYang/snappy-java-test

@Test
 public void testCompress() throws IOException {
        ByteBuffer src = ByteBuffer.allocateDirect(1024);
        src.put("hello world".getBytes());
        src.flip();
        ByteBuffer dest = ByteBuffer.allocateDirect(1024);
        int maxCompressedLen = Snappy.compress(src, dest);
        Assert.assertEquals(maxCompressedLen, 13);
    }

run the above case with zulu 8u352

java -version
openjdk version "1.8.0_352"
OpenJDK Runtime Environment (Zulu 8.66.0.15-CA-macos-aarch64) (build 1.8.0_352-b08)
OpenJDK 64-Bit Server VM (Zulu 8.66.0.15-CA-macos-aarch64) (build 25.352-b08, mixed mode)

with snappy-java 1.1.8.4 the test passed

mvn clean test -Dsnappy-java.version=1.1.8.4

with snappy-java 1.1.9.0

mvn clean test -Dsnappy-java.version=1.1.9.0

the test failed as follows:

-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running org.example.SnappyJavaTest
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.374 sec <<< FAILURE!
testCompress(org.example.SnappyJavaTest)  Time elapsed: 0.345 sec  <<< ERROR!
java.lang.NoSuchMethodError: java.nio.ByteBuffer.limit(I)Ljava/nio/ByteBuffer;
	at org.xerial.snappy.Snappy.compress(Snappy.java:157)
	at org.example.SnappyJavaTest.testCompress(SnappyJavaTest.java:17)

Choose a reason for hiding this comment

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

And if I run the mvn test with zulu 11, there is no above issue

Copy link

@LuciferYang LuciferYang Jan 31, 2023

Choose a reason for hiding this comment

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

I create a issue #389 for this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants