Task #10598 (closed)
Opened 11 years ago
Closed 11 years ago
Bug: stale webstart fails with ClassNotFound
Reported by: | jamoore | Owned by: | atarkowska |
---|---|---|---|
Priority: | critical | Milestone: | OMERO-4.4.9 |
Component: | Deployment | Version: | 4.4.8 |
Keywords: | n.a. | Cc: | java@…, ux@…, wmoore, atarkowska |
Resources: | n.a. | Referenced By: | n.a. |
References: | n.a. | Remaining Time: | n.a. |
Sprint: | n.a. |
Description
Will and I have both seen this issue when clicking on webstart for gretzky:
Caused by: java.lang.ClassNotFoundException: org.libjpegturbo.turbojpeg.TJ at java.net.URLClassLoader$1.run(URLClassLoader.java:202) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at com.sun.jnlp.JNLPClassLoader.findClass(JNLPClassLoader.java:345) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
This is caused by the cached JNLP configuration not being re-downloaded for the same URL in Java 1.6. We need to set the "Last-Modified" header.
See:
Attachments (1)
Change History (7)
Changed 11 years ago by jamoore
comment:1 Changed 11 years ago by jamoore
Started looking at something like this:
c = Context(request, context) d = datetime.datetime.now() rsp = HttpResponse(t.render(c), content_type="application/x-java-jnlp-file") rsp["Expires"] = "Sat, 6 May 1995 12:00:00 GMT" rsp["Cache-Control"] = "no-store, no-cache, must-revalidate" rsp["Pragma"] = "no-cache" rsp['Last-Modified'] = d.strftime('%a, %d %b %Y %H:%M:%S GMT') return rsp
- http://stackoverflow.com/questions/2148454/java-webstart-intermittant-jar-not-updating
- http://www.coderanch.com/t/528570/JNLP-Web-Start/java/jnlp-file-updates
but this likely requires quite a bit of testing of the various versions, etc.
comment:2 Changed 11 years ago by jamoore
- Cc java@… atarkowska added
- Version set to 4.4.8
Are there any changes in the Java JARs that we need to worry about for 4.4.9? (i.e. will the configuration have changed?) If so, I think this counts as a blocker. If not, we can likely push unless someone would like to pick it up.
comment:3 Changed 11 years ago by atarkowska
- Owner set to atarkowska
comment:4 Changed 11 years ago by atarkowska
comment:5 Changed 11 years ago by atarkowska
It is possible to add view decorator
from django.views.decorators.cache import never_cache @never_cache def myview(request): # ...
Result:
Last-Modified = Wed, 18 Sep 2013 12:35:03 GMT Expires = Wed, 18 Sep 2013 12:35:03 GMT Content-Type = application/x-java-jnlp-file Cache-Control = max-age=0
comment:6 Changed 11 years ago by atarkowska
- Resolution set to fixed
- Status changed from new to closed
Workaround: open Java preferences, and delete the cached application.