Skip to: Site menu | Main content

GeoTools

The Open Source Java GIS Toolkit

EPSG-Oracle Plugin Print

Module Maintainer: jgarnett
Status: Construction of a epsg-oracle CRSAuthority that will work in a Java EE environment
Email Help: jgarnett@refractions.net
Plug-in: CRSAuthority
User Docs: EPSG Oracle Plugin

Research

The epsg-oracle plugin is an experiment focused on cleaning up the JDBC Authority abstract classes to ensure the DataSource can be provided.

Development

Actually Using Oracle

To develop this module you will need to follow the optional section in the developers guide for Oracle. This will place an oracle jdbc driver into your local maven repository where it can then be used during the online tests.

C:> cd C:\oracle\product\10.2.0\jdbc\lib
C:\oracle\product\10.2.0\jdbc\lib>mvn install:install-file
-Dfile=ojdbc14.jar 
       -DgroupId=com.oracle -DartifactId=ojdbc14 -Dversion=10.2.0
-Dpackaging=jar
    

The choice of maven profile (to use oracle or to not use oracle) is controlled with a oracle property.

mvn clean install -Doracle=
true
    

Or to set up for testing in eclipse:

mvn eclipse:eclipse -Doracle=
true
    

Using Online Tests

The other thing you will need to do for online tests is place a oracle.properties file describing your database in the magic location below.

C:\Documents and Settings\Jody\.geotools\epsg\oracle.properties
user=jody
password=***
url=jdbc:oracle:thin:@bilbi:1521:orcl
      

You can then run the online tests:

mvn -Doracle.jdbc=
true test -P online
    

Ideas

Some ideas on the use of DataSource in GeoTools (and how we can set up a testing environment are recorded here): J2EE and Connection Pools

In addition the following problems have been noted ...

org.geotools.referencing.factory:

  • AbstractAuthorityFactory - some features are just package-visible ( org.geotools.referencing.factory)
    • They were package-private on purpose. They are usually implementation of public API defined somewhere else. We would need to know why access to those implementation class are wanted, and if there is any way to adress the need without making the implementation class public.
  • BufferedAuthorityFactory had problem with put(Object, Object) not caching
    • Caching should work, at least in 2.4-SNAPSHOT. Need more details about why caching is considered to not work.

org.geotools.referencing.factory.epsg:

  • AuthorityCodes is only package visisble
    • See previous comment about implementation class.
  • BursaWolfInfo is only package visible
    • Should NOT be public. This is a very low level implementation detail.
  • DataSource - this is WRONG we cannot extend DataSource on our own (we need to use one provided by others)
    • Already deprecated in 2.4-SNAPSHOT for many months. The only reason why it still there is to respect the "deprecate first, delete after next release" cycle.
  • DefaultFactory requirements
    • Some kind of DATASOURCE_NAME to work in JBoss (should be configurable)
    • This is already configurable in 2.4-SNAPSHOT through Hints.EPSG_DATASOURCE_NAME.
    • Require DEFAULT_BUFFER_MAX and DEFAULT_PRIORITY_DEC as constructor parameters, either as DefaultFactory(Hints, int, int) to expose the parent constructor, or as new Hints of their own
    • createFactory() needs to wrap the DataSource obtained from JNDI into a class that implements the local DataSource interface.
    • Not needed anymore, since the local DataSource interface is now deprecated.
    • createFactory() cannot bind the DataSource into JNDI (will not always have permission)
    • 2.4-SNAPSHOT already do not bind anymore.
    • createBackingStore() needs to close the JDBC connection obtained from the DataSource (thereby returning it to the pool)
    • We already close the connection (since 2.2 I believe), but after a timeout. The default timeout is 20 minutes. We can change that to a lower level, for example 2 minutes.
    • FactoryUsingAnsiSQL - should not cache the connection (the DataSource will do that)
    • We keep the connection until it is closed by the above-cited timeout. We recreate it from the DataSource after the timeout. 2.4-SNAPSHOT already do that.
    • FactoryUsingOracleSQL - addition to 'AS', the Oracle reserved word 'FILE' is replaced in the query Strings. This necessary because one query uses 'FILE' to rename a column in a SELECT for a column. This factory is used by the AbstractDataSource
    • FactoryUsingSQL - also caches the Connection instead of DataSource
    • TableInfo - not public
    • Again this is a low-level implementation detail that should never be public.

The following bug reports are important:

  • http://jira.codehaus.org/browse/GEOT-909 - EPSG DefaultFactory does not work in an EJB environment
    • Need to supply a DATASOURCE_NAME hint - should be of the form "java:EPSG" to keep JBoss happy
    • Already done in 2.4-SNAPSHOT.
    • FactoryUsingSQL should not remove connection from a pool like FactoryUsingSQL does (need to connect and close on each use). Needed for a multi user environment like Java EE.
    • The connection is already closed after a timeout (20 minutes by default, but we can change that). It was already working like that in 2.2.
    • Need to either use a single factory (may become a bottleneck) or use a pool of factories (will need to fix the FactoryUsingSQL connection cache first)
    • We need a single instance of BufferedAuthorityFactory if we want caching to work. It would be possible to update BufferedAuthorityFactory in order to handle many instances of FactoryUsingSQL, but I would like to see if there is really a bottleneck there before to introduce this complication. I was assuming that in typical cases, a user will work with a small set of CRS (~5) appropriate for the area he is working on, in which case many instances of FactoryUsingSQL will not give us much.
  • http://jira.codehaus.org/browse/GEOT-908 - FactoryUsingSQL uses Oracle reserved word in query
    • fixed?
  • http://jira.codehaus.org/browse/GEOT-907 - Caching in BufferedAuthorityFactory does not work
    • fixed?

Outstanding Issues

This is a research module, and is not currently tracked using Jira. This is however associated with referencing:

Errors were reported by the JIRA trusted connection.

  • Unrecognized application: confluence:8447594
jira.codehaus.org (69 issues)
T Key Summary Assignee Reporter Pr Status Res Created Updated Due
Improvement GEOT-1183 Add support for EPSG:32662 Martin Desruisseaux Andrea Aime Major Open UNRESOLVED Mar 05, 2007 Sep 05, 2007
Bug GEOT-790 CRS Factories can block on loss of network connection. Martin Desruisseaux Jesse Eichar Major Open UNRESOLVED Dec 19, 2005 Dec 19, 2005
Bug GEOT-1179 Bursa-Wolf parameters selection in the EPSG database Martin Desruisseaux Martin Desruisseaux Major Open UNRESOLVED Mar 02, 2007 Mar 03, 2008
Bug GEOT-909 EPSG DefaultFactory does not work in an EJB environment Martin Desruisseaux Felix LJ Mayer Major Open UNRESOLVED Aug 02, 2006 Jun 01, 2007
Improvement GEOT-352 Need transformation from a geoidal to an ellipsoidal height Unassigned Martin Desruisseaux Major Open UNRESOLVED Dec 11, 2004 Jun 21, 2006
Bug GEOT-923 Need a few standard, global projections Martin Desruisseaux Adrian Custer Major Open UNRESOLVED Aug 15, 2006 Aug 15, 2006
Bug GEOT-671 Some coordinate transformation codes are not supported. Simone Giannecchini Alex Petkov Major In Progress UNRESOLVED Aug 23, 2005 Dec 17, 2006
Bug GEOT-1204 EPSG-WKT caching mechanism hiccup Martin Desruisseaux Jody Garnett Major Open UNRESOLVED Mar 21, 2007 Mar 21, 2007
Bug GEOT-942 JTS.orthodromicDistance fails for DefaultGeographicCRS.WGS84 Martin Desruisseaux Aleksander Bandelj Major Open UNRESOLVED Sep 13, 2006 Jul 06, 2007
Bug GEOT-640 Avoid (OTHER,EAST,NORTH) axis directions for GeocentricCRS when possible Martin Desruisseaux Martin Desruisseaux Major Open UNRESOLVED Jul 27, 2005 Jul 07, 2007
Bug GEOT-1553 CRS equals comparion used by WorldImageReader isn't working Martin Desruisseaux Judd Taylor Major Open UNRESOLVED Oct 29, 2007 Nov 01, 2007
Bug GEOT-1535 GeodeticCalculator return ArithmeticException for valid points Martin Desruisseaux kevin hartwig Major Open UNRESOLVED Oct 23, 2007 Oct 23, 2007
Bug GEOT-1660 An unsupported prj file Martin Desruisseaux Jody Garnett Major Reopened UNRESOLVED Jan 09, 2008 Jan 09, 2008
Bug GEOT-1368 Deadlock while creating a Coordinate Reference System Martin Desruisseaux Urs Reupke Major Open UNRESOLVED Jul 02, 2007 Nov 23, 2007
New Feature GEOT-1757 Support Cassini Solder projection Justin Deoliveira Justin Deoliveira Major Open UNRESOLVED Apr 01, 2008 Apr 04, 2008
Bug GEOT-1783 OperationNotFoundException when sourceCRS is a ProjectedCRS + VerticalCRS Martin Desruisseaux Martin Desruisseaux Major Open UNRESOLVED Apr 24, 2008 Apr 24, 2008
Bug GEOT-1548 More than one Referning Module is Fatal to New Users Martin Desruisseaux Jean-Pierre Fiset Major Open UNRESOLVED Oct 26, 2007 Jun 11, 2008
Bug GEOT-1849 Tolerance error when using EPSG:3408 Martin Desruisseaux Jon Blower Major Open UNRESOLVED Jun 11, 2008 Jun 11, 2008
Bug GEOT-1601 Platform-dependent test failures Martin Desruisseaux Martin Desruisseaux Major Open UNRESOLVED Nov 27, 2007 Jul 10, 2008
Bug GEOT-1917 Build failures on jdk 1.6 Martin Desruisseaux Andrea Aime Major Open UNRESOLVED Jul 09, 2008 Jul 10, 2008
Sub-task GEOT-1390 Verifty functionality of HsqlDialectEpsgFactory Jody Garnett Jody Garnett Major Open UNRESOLVED Jul 12, 2007 Jul 10, 2008
Bug GEOT-1704 FORCE_AXIS_ORDER_HONORING does not work if longitude first is provided as an hint instead as a system variable Martin Desruisseaux Andrea Aime Major Open UNRESOLVED Feb 11, 2008 Sep 04, 2008
Bug GEOT-1580 AUTO and AUTO2 authorities do not seem to work properly Martin Desruisseaux Andrea Aime Major Open UNRESOLVED Nov 11, 2007 Sep 04, 2008
Bug GEOT-1578 Flipped axis CRS do miss some information compared to the original ones Martin Desruisseaux Andrea Aime Major Open UNRESOLVED Nov 11, 2007 Sep 04, 2008
Bug GEOT-1770 EPSG HSQL factory seems to unexpectedly close db connections Martin Desruisseaux Andrea Aime Major Open UNRESOLVED Apr 16, 2008 Sep 23, 2008
Improvement GEOT-1182 Add support for cylindrical equidistant on elliptical datum Martin Desruisseaux Andrea Aime Major Open UNRESOLVED Mar 05, 2007 Sep 23, 2008
Bug GEOT-1835 EPSG factory needs to handle primary keys as integers Martin Desruisseaux Martin Desruisseaux Major Open UNRESOLVED May 28, 2008 Sep 23, 2008
Improvement GEOT-1217 Allow Formattable objects to be turned into WKT specifying both indent and strictness Martin Desruisseaux Andrea Aime Major Open UNRESOLVED Apr 02, 2007 Sep 23, 2008
Improvement GEOT-1286 Add Concurrency Support to CRS Authority Martin Desruisseaux Cory Horner Major Open UNRESOLVED Jun 01, 2007 Sep 23, 2008
Improvement GEOT-1745 MapProjection: relax coordinate checks/make them configurable Martin Desruisseaux Andrea Aime Major Reopened UNRESOLVED Mar 20, 2008 Sep 23, 2008
Improvement GEOT-1710 urn:ogc:def:crs:OGC:1.3:CRS84 is not recognized by the referencing subsystem Martin Desruisseaux Andrea Aime Major Open UNRESOLVED Feb 15, 2008 Sep 23, 2008
Bug GEOT-1862 Build Failure of JDK1.6.0_06 with no JAI or ImageIO Martin Desruisseaux Jody Garnett Major Open UNRESOLVED Jun 23, 2008 Sep 23, 2008
Improvement GEOT-353 Add DatumAuthorityFactory implementation for ISO-19775 Unassigned Martin Desruisseaux Minor Open UNRESOLVED Dec 12, 2004 Feb 04, 2005
Bug GEOT-823 "Timer already cancelled" exception in DeferredAuthorityFactory Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Mar 16, 2006 Mar 17, 2006
Improvement GEOT-521 WarpTransform2D.getWrap(...) should avoid creating WarpAdapter as much as possible Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED May 05, 2005 May 05, 2005
Sub-task GEOT-522 LocalizationGridTransform2D should defines a WarpGrid Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED May 05, 2005 May 05, 2005
Improvement GEOT-598 NADCON transform need to cache the grid files in some temporary directory Unassigned Martin Desruisseaux Minor Open UNRESOLVED Jun 26, 2005 Jun 26, 2005
New Feature GEOT-121 Port the last 2 projections from proj4j to cts-coordtrans Unassigned Rueben Schulz Minor Open UNRESOLVED Mar 13, 2004 Jun 26, 2005
Improvement GEOT-813 Filter returned referencing codes, f.e. 2D only Martin Desruisseaux Matthias Basler Minor Open UNRESOLVED Mar 02, 2006 Mar 03, 2006
Task GEOT-403 Failures in OpenGIS test scripts Unassigned Martin Desruisseaux Minor Open UNRESOLVED Feb 07, 2005 Feb 23, 2007
New Feature GEOT-546 Berkeley DB (JE) Authority Factory Suite Bryce Nordgren Bryce Nordgren Minor Open UNRESOLVED May 31, 2005 Feb 23, 2007
Improvement GEOT-1495 WKT parser should emmit a warning when a unit is incompatible with an axis Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Sep 14, 2007 Sep 14, 2007
Task GEOT-1259 Re-insert modules/plugin/epsg-access in the build Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED May 02, 2007 May 02, 2007
Bug GEOT-380 NADCONTransform does not deal with grids crossing +-180 longitude Rueben Schulz Rueben Schulz Minor Open UNRESOLVED Jan 22, 2005 Jul 07, 2007
Test GEOT-1425 Coordinate System Transformation Error? Martin Desruisseaux Rafal Glowinski Minor Open UNRESOLVED Aug 10, 2007 Aug 10, 2007
Improvement GEOT-1164 Make the WKT parser tolerant to Oracle syntax Martin Desruisseaux Martin Desruisseaux Minor Reopened UNRESOLVED Feb 15, 2007 May 17, 2007
Test GEOT-1428 This coordref test fails!! Martin Desruisseaux Rafal Glowinski Minor Open UNRESOLVED Aug 13, 2007 Aug 13, 2007
Bug GEOT-1554 Orhographic reprojection fails if given an elliptical datum in the CRS Martin Desruisseaux Judd Taylor Minor Open UNRESOLVED Oct 29, 2007 Nov 01, 2007
Improvement GEOT-1512 Add support for EXTENSION[name,value] elements in WKT parsing Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Oct 15, 2007 Oct 15, 2007
Improvement GEOT-1513 Choose Hints default according KEY_RENDERING value Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Oct 15, 2007 Oct 15, 2007
Improvement GEOT-616 Read and write coordinate system information in MIF format Luca S. Percich Luca S. Percich Minor Open UNRESOLVED Jul 12, 2005 Jan 14, 2008
Task GEOT-1656 Remove hack from WarpTransform2D when JAI 1.1.4 will be released Simone Giannecchini Simone Giannecchini Minor Open UNRESOLVED Jan 04, 2008 Jan 04, 2008
Improvement GEOT-410 [Abridged] Molodenski transforms should be invertible. Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Feb 09, 2005 Mar 24, 2008
Improvement GEOT-401 CompoundCRS[Geographic/ProjectedCRS, VerticalCRS] should be treated as 3D-Geographic/ProjectedCRS Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Feb 07, 2005 Mar 24, 2008
Bug GEOT-1721 Referenced Envelope swaps x-values with y-values after a few calls to the class using it Martin Desruisseaux Ashraf Memon Minor Open UNRESOLVED Mar 03, 2008 Apr 08, 2008
Improvement GEOT-1724 GeneralEnvelope should accepts envelopes crossing the antimeridian Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Mar 06, 2008 Apr 17, 2008
Improvement GEOT-1430 Replace HSQL database by H2 for EPSG factory Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Aug 14, 2007 May 19, 2008
Bug GEOT-1826 EPSG:102172 is incorrect Martin Desruisseaux Shaun Forbes Minor Open UNRESOLVED May 19, 2008 May 19, 2008
Bug GEOT-1268 Add a MapProjection.equivalent(MapProjection) method Martin Desruisseaux Saul Farber Minor Open UNRESOLVED May 14, 2007 May 15, 2007
Bug GEOT-1864 CRS.decode("EPSG:4326") cause org.opengis.referencing.FactoryException Martin Desruisseaux Luca Santaniello Minor Open UNRESOLVED Jun 26, 2008 Jun 26, 2008
Sub-task GEOT-1882 plugin/epsg-extension esri/extn .properties need confirmation of origin Martin Desruisseaux Adrian Custer Minor Open UNRESOLVED Jul 04, 2008 Jul 10, 2008
Improvement GEOT-1429 Add CRS:1 and CRS:88 authority codes Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Aug 14, 2007 Sep 23, 2008
Task GEOT-1827 Clean the various EPS thresholds in MapProjection subclasses Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED May 21, 2008 Sep 23, 2008
Bug GEOT-1211 gt2-epsg-access.jar in the classpath prevent gt2-epsg-hsql.jar to work Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED Mar 28, 2007 Sep 23, 2008
Task GEOT-1832 Move spherical parameters out of LambertAzimuthalEqualArea.Provider Martin Desruisseaux Martin Desruisseaux Minor Open UNRESOLVED May 23, 2008 Sep 23, 2008
Improvement GEOT-411 [Abridged] Molodenski transforms should accept 'dim_source' and 'dim_target' arguments Unassigned Martin Desruisseaux Trivial Open UNRESOLVED Feb 10, 2005 Jun 20, 2005
Bug GEOT-584 spherical transverse mercator bug Rueben Schulz Rueben Schulz Trivial Open UNRESOLVED Jun 15, 2005 Nov 15, 2006
Task GEOT-603 Delete unneeded classes from the legacy module Martin Desruisseaux Martin Desruisseaux Trivial Open UNRESOLVED Jun 29, 2005 Jul 07, 2007
Wish GEOT-1307 Consider "osgb" as an authority Martin Desruisseaux Pierrick Brihaye Trivial Open UNRESOLVED Jun 13, 2007 Jun 14, 2007