Skip to content

ARTEMIS-5972: Replace JNI with Panama Foreign Function & Memory (FFM)…#6444

Open
mayankkunwar wants to merge 1 commit into
apache:mainfrom
mayankkunwar:ARTEMIS-5972
Open

ARTEMIS-5972: Replace JNI with Panama Foreign Function & Memory (FFM)…#6444
mayankkunwar wants to merge 1 commit into
apache:mainfrom
mayankkunwar:ARTEMIS-5972

Conversation

@mayankkunwar
Copy link
Copy Markdown

… API for Journal Native Layer

@clebertsuconic
Copy link
Copy Markdown
Contributor

nice one @mayankkunwar

@mayankkunwar mayankkunwar force-pushed the ARTEMIS-5972 branch 2 times, most recently from 17ca830 to 758dfd6 Compare May 14, 2026 00:05
Comment thread pom.xml Outdated
<module>artemis-lockmanager</module>
<module>artemis-image</module>
<module>artemis-image/examples</module>
<module>artemis-ffm</module>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

<module>artemis-ffm</module> Isn't really a useful name for the module, it doesn't really describe what the module is used for or help someone identify what functionality this might include. Probably should indicate is a libaio module "artemis-libaio' or some such as the FFM bits is the implementation part of what its doing, not what it does.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@tabish121 we could add other libraries that are using ffm later. Mayank is doing some experimentation with ioUring... we could add that into this module if it gets any useful.

Not that I foresee many other libraries in the future.. but what if we ever add more?

I didn't want to use the word native as native itself is a reserved name in java, and to not confuse with the current JNI implementation.

@mayankkunwar mayankkunwar force-pushed the ARTEMIS-5972 branch 8 times, most recently from a91e37f to f177963 Compare May 20, 2026 18:01
Comment thread artemis-ffm/etc/checkstyle-suppressions.xml Outdated
Comment thread artemis-ffm/pom.xml
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>

<maven.compiler.source>22</maven.compiler.source>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

these are specified in the parent pom, right? can we remove these?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

In the parent pom the defined version is 17, but the FFM part needs 22 to be defined. So we need this here until parent is defined as 22 or later

@Fork(value = 2)
@Warmup(iterations = 5, time = 200, timeUnit = TimeUnit.MILLISECONDS)
@Measurement(iterations = 10, time = 200, timeUnit = TimeUnit.MILLISECONDS)
public class AioCompareBenchmark {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We can merge this here initially.. but I will move these to the performance-jmh module, after merged.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

okay


try {
// fillHeader(fileId);
// libaioFile.write(0L, BLOCK_SIZE, headerBuffer, callback);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

can we remove commented out code ? I don't think this is needed.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Sure, let me remove them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants