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

JDK 17. org.apache.ignite.internal.mem.file.MappedFile.map0 is null #10956

Closed
dresblr opened this issue Sep 25, 2023 · 2 comments
Closed

JDK 17. org.apache.ignite.internal.mem.file.MappedFile.map0 is null #10956

dresblr opened this issue Sep 25, 2023 · 2 comments

Comments

@dresblr
Copy link

dresblr commented Sep 25, 2023

Hi Community,

In our setup, utilizing Apache Ignite version 2.15.0 along with JDK 17, we've encountered the following problem:

Cannot invoke "java.lang.reflect.Method.invoke(Object, Object[])" because "o.a.i.i.mem.file.MappedFile.map0" is null
 class org.apache.ignite.IgniteCheckedException: Cannot invoke "java.lang.reflect.Method.invoke(Object, Object[])" because "org.apache.ignite.internal.mem.file.MappedFile.map0" is null
   at org.apache.ignite.internal.util.IgniteUtils.cast(IgniteUtils.java:7929)
   at org.apache.ignite.internal.util.future.GridFutureAdapter.resolve(GridFutureAdapter.java:261)
   at org.apache.ignite.internal.util.future.GridFutureAdapter.get0(GridFutureAdapter.java:210)
   at org.apache.ignite.internal.util.future.GridFutureAdapter.get(GridFutureAdapter.java:161)
   at org.apache.ignite.internal.processors.cache.GridCachePartitionExchangeManager$ExchangeWorker.body0(GridCachePartitionExchangeManager.java:3376)
   at org.apache.ignite.internal.processors.cache.GridCachePartitionExchangeManager$ExchangeWorker.body(GridCachePartitionExchangeManager.java:3182)
   at org.apache.ignite.internal.util.worker.GridWorker.run(GridWorker.java:125)
   at java.base/java.lang.Thread.run(Thread.java:833)
 Caused by: java.lang.NullPointerException: Cannot invoke "java.lang.reflect.Method.invoke(Object, Object[])" because "org.apache.ignite.internal.mem.file.MappedFile.map0" is null
   at org.apache.ignite.internal.mem.file.MappedFile.map(MappedFile.java:126)
   at org.apache.ignite.internal.mem.file.MappedFile.<init>(MappedFile.java:65)
   at org.apache.ignite.internal.mem.file.MappedFileMemoryProvider.nextRegion(MappedFileMemoryProvider.java:134)
   at org.apache.ignite.internal.processors.cache.persistence.IgniteCacheDatabaseSharedManager$3.nextRegion(IgniteCacheDatabaseSharedManager.java:1419)
   at org.apache.ignite.internal.pagemem.impl.PageMemoryNoStoreImpl.addSegment(PageMemoryNoStoreImpl.java:716)
   at org.apache.ignite.internal.pagemem.impl.PageMemoryNoStoreImpl.start(PageMemoryNoStoreImpl.java:279)
   at org.apache.ignite.internal.processors.cache.GridCacheProcessor.startCacheGroup(GridCacheProcessor.java:2471)
   at org.apache.ignite.internal.processors.cache.GridCacheProcessor.getOrCreateCacheGroupContext(GridCacheProcessor.java:2181)
   at org.apache.ignite.internal.processors.cache.GridCacheProcessor.prepareCacheContext(GridCacheProcessor.java:1991)
   at org.apache.ignite.internal.processors.cache.GridCacheProcessor.lambda$null$6a5b31b9$1(GridCacheProcessor.java:1830)
   at org.apache.ignite.internal.processors.cache.GridCacheProcessor.lambda$prepareStartCaches$15(GridCacheProcessor.java:1753)
   at org.apache.ignite.internal.processors.cache.GridCacheProcessor.lambda$prepareStartCaches$926b6886$1(GridCacheProcessor.java:1827)
   at org.apache.ignite.internal.util.IgniteUtils.doInParallel(IgniteUtils.java:11628)
   at org.apache.ignite.internal.util.IgniteUtils.doInParallel(IgniteUtils.java:11530)
   at org.apache.ignite.internal.processors.cache.GridCacheProcessor.prepareStartCaches(GridCacheProcessor.java:1822)
   at org.apache.ignite.internal.processors.cache.GridCacheProcessor.prepareStartCaches(GridCacheProcessor.java:1752)
   at org.apache.ignite.internal.processors.cache.GridCacheProcessor.startCachesOnLocalJoin(GridCacheProcessor.java:1698)
   at org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionsExchangeFuture.initCachesOnLocalJoin(GridDhtPartitionsExchangeFuture.java:1172)
   at org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionsExchangeFuture.init(GridDhtPartitionsExchangeFuture.java:1006)
   at org.apache.ignite.internal.processors.cache.GridCachePartitionExchangeManager$ExchangeWorker.body0(GridCachePartitionExchangeManager.java:3348)

The underlying issue is that the signature of the private method map0 in the sun.nio.ch.FileChannelImpl class has been modified to include an additional boolean parameter. The updated signature now reads as follows: private native long map0(int prot, long position, long length, boolean isSync)

org.apache.ignite.internal.mem.file.MappedFile#map0

Thanks,
Siarhei D.

@ivandasch
Copy link
Contributor

@dresblr Thanks for submitting this issue, a jira ticked was created https://issues.apache.org/jira/browse/IGNITE-20515

@ivandasch
Copy link
Contributor

Fixed in #10961

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

No branches or pull requests

2 participants