jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
  • GeoTools
  • GEOT-823

"Timer already cancelled" exception in DeferredAuthorityFactory

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Open Open
  • Priority: Minor Minor
  • Resolution: Unresolved
  • Affects Version/s: 2.2-RC1, 2.3.M0
  • Fix Version/s: 2.7.5
  • Component/s: referencing
  • Labels:
    None
  • Environment:
    Applet

Description

The following error has been reported when reloading a page that contains an applet. The error does not occur every time.

16.03.2006 14:56:33 FactoryRegistry scanForPlugins
WARNUNG: Can't load a service for category CoordinateOperationAuthorityFactory.
sun.misc.ServiceConfigurationError: org.opengis.referencing.operation.CoordinateOperationAuthorityFactory: Provider org.geotools.referencing.factory.epsg.DefaultFactory could not be instantiated: java.lang.IllegalStateException: Timer already cancelled.
   at sun.misc.Service.fail(Service.java:120)
   at sun.misc.Service.access$200(Service.java:111)
   at sun.misc.Service$LazyIterator.next(Service.java:276)
   at org.geotools.factory.FactoryRegistry.scanForPlugins(FactoryRegistry.java:429)
   at org.geotools.factory.FactoryRegistry.getServiceProviders(FactoryRegistry.java:121)
   at org.geotools.factory.FactoryCreator.getServiceProvider(FactoryCreator.java:120)
   at org.geotools.referencing.FactoryFinder.getCoordinateOperationAuthorityFactory(FactoryFinder.java:376)
   at org.geotools.referencing.operation.AuthorityBackedFactory.getAuthorityFactory(AuthorityBackedFactory.java:124)
   at org.geotools.referencing.operation.AuthorityBackedFactory.isReady(AuthorityBackedFactory.java:238)
   at org.geotools.factory.FactoryRegistry$1.filter(FactoryRegistry.java:83)
   at javax.imageio.spi.FilterIterator.advance(ServiceRegistry.java:793)
   at javax.imageio.spi.FilterIterator.<init>(ServiceRegistry.java:787)
   at javax.imageio.spi.ServiceRegistry.getServiceProviders(ServiceRegistry.java:491)
   at org.geotools.factory.FactoryRegistry.getServiceProviders(FactoryRegistry.java:113)
   at org.geotools.factory.FactoryRegistry.getServiceProvider(FactoryRegistry.java:228)
   at org.geotools.factory.FactoryRegistry.getServiceProvider(FactoryRegistry.java:200)
   at org.geotools.factory.FactoryCreator.getServiceProvider(FactoryCreator.java:90)
   at org.geotools.referencing.FactoryFinder.getCoordinateOperationFactory(FactoryFinder.java:251)
   at org.geotools.referencing.CRS.transform(CRS.java:105)
   at org.geotools.renderer.shape.ShapefileRenderer.paint(ShapefileRenderer.java:1278)
   at org.geotools.renderer.shape.ShapefileRenderer.paint(ShapefileRenderer.java:1198)
   at org.geotools.gui.swing2.newShaperenderingJPanel$3.paint(newShaperenderingJPanel.java:180)
   at org.geotools.gui.swing2.newShaperenderingJPanel$3.<init>(newShaperenderingJPanel.java:168)
   at org.geotools.gui.swing2.newShaperenderingJPanel.render(newShaperenderingJPanel.java:165)
   at org.geotools.gui.swing2.newShaperenderingJPanel.focusOnGZ(newShaperenderingJPanel.java:513)
   at newCanvasApplet.focusOnGZ(newCanvasApplet.java:75)
   at newCanvasApplet.access$3(newCanvasApplet.java:74)
   at newCanvasApplet$1.run(newCanvasApplet.java:58)
Caused by: java.lang.IllegalStateException: Timer already cancelled.
   at java.util.Timer.sched(Timer.java:354)
   at java.util.Timer.schedule(Timer.java:222)
   at org.geotools.referencing.factory.DeferredAuthorityFactory.setTimeout(DeferredAuthorityFactory.java:226)
   at org.geotools.referencing.factory.epsg.DefaultFactory.<init>(DefaultFactory.java:132)
   at org.geotools.referencing.factory.epsg.DefaultFactory.<init>(DefaultFactory.java:120)
   at sun.reflect.GeneratedConstructorAccessor107.newInstance(Unknown Source)
   at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
   at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
   at java.lang.Class.newInstance0(Class.java:350)
   at java.lang.Class.newInstance(Class.java:303)
   at sun.misc.Service$LazyIterator.next(Service.java:271)
   ... 25 more

Issue Links

depends upon

Task - A task that needs to be done. GEOT-2117 Review GeoToolkit fixes

  • Minor - Minor loss of function, or other problem where easy workaround is present.
  • Open - The issue is open and ready for the assignee to start work on it.

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • History
  • Activity
Hide
Permalink
Martin Desruisseaux added a comment - 16/Mar/06 5:13 PM
The timer is used in order to close all SQL connections to the EPSG database when it has not been used for a while (connections are automatically opened again when a new request is performed). Connections are closed after some delay in order to release more resources for user's application.
Show
Martin Desruisseaux added a comment - 16/Mar/06 5:13 PM The timer is used in order to close all SQL connections to the EPSG database when it has not been used for a while (connections are automatically opened again when a new request is performed). Connections are closed after some delay in order to release more resources for user's application.
Hide
Permalink
Bernhard Kastner added a comment - 16/Mar/06 11:52 PM
I started the thread in http://sourceforge.net/mailarchive/forum.php?thread_id=9952584&forum_id=12232

Some more informations, that might help

I'm using Geotools 2.2-M0
The applet and all used geotools-libraries are signed with a certificate
I'm opening Shapefiles and rendering with ShapefileRenderer
On reloading the page, the error occurs, not everytime, but in most cases
Some days ago it prevented me from refreshing the page with a new applet (I uploaded a new applet-version, wanted to test it and the old one still showed up)
The error does not occur when loading the page for the first time
Except from the one time, where it prevented me from loading a new version, this error does not affect the functionality of my applet in any way
Show
Bernhard Kastner added a comment - 16/Mar/06 11:52 PM I started the thread in http://sourceforge.net/mailarchive/forum.php?thread_id=9952584&forum_id=12232 Some more informations, that might help I'm using Geotools 2.2-M0 The applet and all used geotools-libraries are signed with a certificate I'm opening Shapefiles and rendering with ShapefileRenderer On reloading the page, the error occurs, not everytime, but in most cases Some days ago it prevented me from refreshing the page with a new applet (I uploaded a new applet-version, wanted to test it and the old one still showed up) The error does not occur when loading the page for the first time Except from the one time, where it prevented me from loading a new version, this error does not affect the functionality of my applet in any way
Hide
Permalink
Martin Desruisseaux added a comment - 17/Mar/06 2:00 AM
Changed the priority to "minor", since it doesn't prevent the AuthorityFactory to work. It probably prevent the resources to be released however. This bug still need to be fixed in order to avoid wasting memory.
Show
Martin Desruisseaux added a comment - 17/Mar/06 2:00 AM Changed the priority to "minor", since it doesn't prevent the AuthorityFactory to work. It probably prevent the resources to be released however. This bug still need to be fixed in order to avoid wasting memory.
Hide
Permalink
Martin Desruisseaux added a comment - 17/Mar/09 3:53 PM
The way DeferredAuthorityFactory (renamed ThreadedAuthorityFactory after Refractions work) disposes the resources have completly changed in geotidy. We now relies much more extensively on the java.util.concurrent package, which is new to Java 5. I believe the new framework to be more robust than the old one, but we need still need more experiments to be sure.
Show
Martin Desruisseaux added a comment - 17/Mar/09 3:53 PM The way DeferredAuthorityFactory (renamed ThreadedAuthorityFactory after Refractions work) disposes the resources have completly changed in geotidy. We now relies much more extensively on the java.util.concurrent package, which is new to Java 5. I believe the new framework to be more robust than the old one, but we need still need more experiments to be sure.

People

  • Assignee:
    Unassigned
    Reporter:
    Martin Desruisseaux
Vote (0)
Watch (2)

Dates

  • Created:
    16/Mar/06 5:07 PM
    Updated:
    21/Dec/11 10:38 AM
  • Atlassian JIRA (v5.0.4#731-sha1:3aa7374)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.