jts
jts copied to clipboard
Publish ESRi, Oracle modules on Maven
These have non-open source dependencies but, unless they are published, they will not be useable (without inflicting on developers to "go off and build it yourself").
In the case of Oracle the only additional work required (by the Maven releaser) is to install an Oracle JDBC driver jar in their local Maven repo, and then build/release the JTS module (in a suitable place in Maven).
FWIW Vividsolutions managed to publish such modules without apparent problem.
In the case of Oracle the only additional work required (by the Maven releaser) is to install an Oracle JDBC driver jar in their local Maven repo, and then build/release the JTS module (in a suitable place in Maven).
Actually to run (at least some of) the testcases a developer also needs to have an oracle instance running
This is a serious pain. Now that Oracle drivers are in Maven Central is there any reason this can't be done?
@yeroc @andyjefferson Creating a PR that updates https://github.com/locationtech/jts/blob/master/modules/io/ora/pom.xml
and .travis.yml
to build the oracle module could be a start
Actually to run (at least some of) the testcases a developer also needs to have an oracle instance running
Yes, that is a serious impediment to maintaining and publishing these modules, IMO. I am no longer in a position to run the tests for these modules . I suppose the Oracle module could be released in a "compile-only" way, if that is worth anything. The unit tests would have to be disabled in some way for CI, I think?
Other ideas welcome.
FWIW Vividsolutions managed to publish such modules without apparent problem.
At Vivid we had an environment in which to develop and run the tests.
FWIW Oracle JDBC driver(s) are in Maven central.
Change https://github.com/locationtech/jts/blob/master/pom.xml#L116 to be "com.oracle.database.jdbc", "ojdbc8" and version 12.2.0.1
Change https://github.com/locationtech/jts/blob/master/modules/io/ora/pom.xml#L40 to be "com.oracle.database.jdbc", "ojdbc8".
Change https://github.com/locationtech/jts/blob/master/modules/io/ora/README.md to remove the lines about needing an Oracle JDBC driver, since one is in the Maven repo.
That presumably would allow anyone to build it. You'd have to disable tests without a working Oracle instance, clearly.
I tried "mvn clean install -DskipTests" followed by "mvn install -Poracle -DskipTests" but got some Maven whinges on the second command about "Failure to find org.locationtech.jts:jts-io:pom:1.18.0-SNAPSHOT". The parent seems to be set to 1.18.0-SNAPSHOT rather than the current 1.18.2-SNAPSHOT, so perhaps change that.
Oh, and https://github.com/locationtech/jts/blob/master/modules/io/ora/pom.xml will also need the dependency
<dependency>
<groupId>org.locationtech.jts</groupId>
<artifactId>jts-core</artifactId>
<version>${project.version}</version>
<type>test-jar</type>
<scope>test</scope>
</dependency>
adding.
Do all of that and you can finally do "mvn install -Poracle -DskipTests"