Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

DatumFactory is not an ImageIO SPI class

Tags:

java

geotools

We are migrating our project to java 9 and I am getting this exception while using geotools:

java.lang.IllegalArgumentException: org.opengis.referencing.datum.DatumFactory is not an ImageIO SPI class
    at java.desktop/javax.imageio.spi.ServiceRegistry.checkClassAllowed(ServiceRegistry.java:745)
    at java.desktop/javax.imageio.spi.ServiceRegistry.<init>(ServiceRegistry.java:140)
    at org.geotools.factory.FactoryRegistry.<init>(FactoryRegistry.java:155)
    at org.geotools.factory.FactoryRegistry.<init>(FactoryRegistry.java:146)
    at org.geotools.factory.FactoryCreator.<init>(FactoryCreator.java:82)

My java version:

openjdk 9
OpenJDK Runtime Environment (build 9+181)
OpenJDK 64-Bit Server VM (build 9+181, mixed mode)

I know there are some changes to support java 9 in GeoTools 19.0, but upgrading geotools to version 19.0 (and 20.x too!) doesn't solve this problem.

like image 604
Gent Avatar asked Oct 15 '25 13:10

Gent


1 Answers

Please check the readme.html file. I checked version 20.2 and it says:

Warning: Java 9 is not yet supported

like image 189
mate00 Avatar answered Oct 18 '25 02:10

mate00



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!