I've been creating a java web start swing/jython app for awhile now, and =
last week I ran into quite an odd problem. I have yet to track down its =
exact source, but I do know the things that changed right before the =
problem occurred. Let me describe the problem first:
After signing the jar files used by the application and deploying it to =
the server, the application works and is downloadable to the client, and =
will start execution. However, after a point, swing JInternalFrames I =
create fail to ever appear. The interpreted version of the app runs =
fine without this problem. The problem appears after only three =
JInternalFrames have displayed. No tracebacks occur that I can find, =
and the (jython) threads used to display and update these invisible =
JInternalFrames are running (I have a logging window that they each =
write to, and can see output from each thread).
Details:
- I'm running jython 2.1, sun jdk 1.4.1_02, and utilize jfreechart =
(http://www.jfree.org/jfreechart).
- The problem occurs regardless fo what client machine the web start =
app is run from (I.e., its not just my machine being funky)
- The problem did not exist prior to the integration of jfreechart, but =
other code changes were made simultaneously.
- somewhere during these changes, I did something that made me =
(later, when I went to make the jar) run into the ProxyMaker problem and =
was forced to change the -core option of jythonc to use -all instead, =
thanks to this this list =
(http://aspn.activestate.com/ASPN/Mail/Message/724323) I was able to =
find the solution of using -all, but not the reason _why_. None of my =
code calls eval or anything similar, so why does my app suddenly need =
the compile support?
- Due to the security restrictions put in place on web start apps, I =
cannot test the app without signing the jars - could my signing of the =
third-part jfreechart jars have caused this problem? (Until I signed =
them, I still got security errors: what should I do if I am not to sign =
third party jars?)
- how can I trap for exceptions in an eventDispatch thread (or any =
pure-java thread) from jython? I can trap and print traceback =
information for my threads to my logging window, but while runnign the =
app in interpreted mode I sometimes cause a bug that shows up via a =
eventDispatch thread exception - how would I trap for this (or other =
errors) so that I could show the traceback in my own custom logging =
window?
I have probably left out some important detail somewhere that would make =
my problem obvious, but I can't even find an instance of this sort of =
thing being reported. Even if you don't know the solution to the =
overall problem, could someone step up and answer some of the =
sub-questions raised above?
Thank you in advance!
~Jon Franz
|