ImageJ via Webstart

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

ImageJ via Webstart

Boris Epstein
Hello listmates,

I am attempting to run ImageJ web-based using Webstart to launch it. It
seems to come up OK except that it lacks all of the additional plugins.

Does anybody know how to compensate for that?

Thanks.

--
*Boris Epstein
National Resource For Imaging Mass Spectrometry
<http://www.nrims.hms.harvard.edu/>
Cambridge, MA
Mobile: (617) 816-9654*


The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.
Reply | Threaded
Open this post in threaded view
|

Re: ImageJ via Webstart

dscho
Hi,

On Wed, 7 Apr 2010, Boris Epstein wrote:

> I am attempting to run ImageJ web-based using Webstart to launch it. It
> seems to come up OK except that it lacks all of the additional plugins.
>
> Does anybody know how to compensate for that?

The problem is that you cannot list all files in a remote
(http://) directory.

For Fiji, Benjamin Schmid provided some additional code which is in
ImageJA. I recently worked a bit on it to update it to the current
codebase of Fiji, but did not have time or need to finalize that work.

If you're interested, you can see the current state here:

http://pacific.mpi-cbg.de/cgi-bin/gitweb.cgi?p=fiji.git;a=shortlog;h=refs/heads/jnlp

Ciao,
Johannes
Reply | Threaded
Open this post in threaded view
|

Re: ImageJ via Webstart

Boris Epstein
Johannes Schindelin wrote:

> Hi,
>
> On Wed, 7 Apr 2010, Boris Epstein wrote:
>
>  
>> I am attempting to run ImageJ web-based using Webstart to launch it. It
>> seems to come up OK except that it lacks all of the additional plugins.
>>
>> Does anybody know how to compensate for that?
>>    
>
> The problem is that you cannot list all files in a remote
> (http://) directory.
>
> For Fiji, Benjamin Schmid provided some additional code which is in
> ImageJA. I recently worked a bit on it to update it to the current
> codebase of Fiji, but did not have time or need to finalize that work.
>
> If you're interested, you can see the current state here:
>
> http://pacific.mpi-cbg.de/cgi-bin/gitweb.cgi?p=fiji.git;a=shortlog;h=refs/heads/jnlp
>
> Ciao,
> Johannes
>
>  

Thanks Johannes!

This sounds interesting. I am wondering if things would work if I
encapsulated all the code I need in one JAR file.

--
*Boris Epstein
National Resource For Imaging Mass Spectrometry
<http://www.nrims.hms.harvard.edu/>
Cambridge, MA
Mobile: (617) 816-9654*


The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.
Reply | Threaded
Open this post in threaded view
|

Re: ImageJ via Webstart

dscho
Hi,

On Wed, 7 Apr 2010, Boris Epstein wrote:

> I am wondering if things would work if I encapsulated all the code I
> need in one JAR file.

Not without editing IJ_Props.txt.

Hth,
Johannes
Reply | Threaded
Open this post in threaded view
|

Re: ImageJ via Webstart

Boris Epstein
OK, I did edit the IJ_Props.txt file to point to the proper classes and
they seem to be in the class path (or, rather, they are in the JARs that
the .jnlp file contains) yet the plugins would still not run. Any idea why?

Thanks.

Boris.

Johannes Schindelin wrote:

> Hi,
>
> On Wed, 7 Apr 2010, Boris Epstein wrote:
>
>  
>> I am wondering if things would work if I encapsulated all the code I
>> need in one JAR file.
>>    
>
> Not without editing IJ_Props.txt.
>
> Hth,
> Johannes
>  

--
*Boris Epstein
National Resource For Imaging Mass Spectrometry
<http://www.nrims.hms.harvard.edu/>
Cambridge, MA
Mobile: (617) 816-9654*


The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.
Reply | Threaded
Open this post in threaded view
|

Re: ImageJ via Webstart

dscho
Hi,

On Fri, 9 Apr 2010, Boris Epstein wrote:

> OK, I did edit the IJ_Props.txt file to point to the proper classes and
> they seem to be in the class path (or, rather, they are in the JARs that
> the .jnlp file contains) yet the plugins would still not run.

That is not enough information to work with. There is one way it can
succeed. But thousands of ways it can fail, and you leave me guessing.

If I had your problem, I would probably patch ij.jar to spit out several
interesting things, such as the output of Class.forName(name) and
IJ.getClassLoader.loadClass(name).

Good luck,
Johannes
Reply | Threaded
Open this post in threaded view
|

Re: ImageJ via Webstart

Boris Epstein
Thanks Johannes,

How about this: I have now put all the classes in just one JAR. No issue
with JARs being or not being in the classpath.

Still the same thing, pretty much: the right classes are invoked
correctly locally or via the applet, but not via the WebStart.

I tried putting the classes to the top or under the plugins directory in
the JAR - same difference.

Boris.



Johannes Schindelin wrote:

> Hi,
>
> On Fri, 9 Apr 2010, Boris Epstein wrote:
>
>  
>> OK, I did edit the IJ_Props.txt file to point to the proper classes and
>> they seem to be in the class path (or, rather, they are in the JARs that
>> the .jnlp file contains) yet the plugins would still not run.
>>    
>
> That is not enough information to work with. There is one way it can
> succeed. But thousands of ways it can fail, and you leave me guessing.
>
> If I had your problem, I would probably patch ij.jar to spit out several
> interesting things, such as the output of Class.forName(name) and
> IJ.getClassLoader.loadClass(name).
>
> Good luck,
> Johannes
>  

--
*Boris Epstein
National Resource For Imaging Mass Spectrometry
<http://www.nrims.hms.harvard.edu/>
Cambridge, MA
Mobile: (617) 816-9654*


The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.
Reply | Threaded
Open this post in threaded view
|

Re: ImageJ via Webstart

Boris Epstein
In reply to this post by dscho
Johannes,

Thanks, forget this for now. How about the following: I now use one JAR
- one and only one. It contains all I need. It is called signedij.jar

My plugin is invoked via the following class name:
com/nrims/NRIMS_Plugin.class

OK, let's see here:

----------------------------

[dellfluor@bepstein][~/imagej/ij_jar_factory2] jar tvf signedij.jar |
grep NRIMS
142209 Mon Apr 12 15:39:06 EDT 2010 META-INF/NRIMS.SF
1017 Mon Apr 12 15:39:06 EDT 2010 META-INF/NRIMS.DSA
1140 Fri Apr 09 14:19:02 EDT 2010 com/nrims/NRIMS_Plugin.class
[dellfluor@bepstein][~/imagej/ij_jar_factory2]

----------------------------

So, looks like the classpath is fine.

And if I run it directly:

java -jar signedij.jar

it works fine.

Same if I run it as an applet.

But it fails to find the plugin if I run it via Web Start! That's what
is so puzzling!

Boris.

Johannes Schindelin wrote:

> Hi,
>
> On Fri, 9 Apr 2010, Boris Epstein wrote:
>
>  
>> OK, I did edit the IJ_Props.txt file to point to the proper classes and
>> they seem to be in the class path (or, rather, they are in the JARs that
>> the .jnlp file contains) yet the plugins would still not run.
>>    
>
> That is not enough information to work with. There is one way it can
> succeed. But thousands of ways it can fail, and you leave me guessing.
>
> If I had your problem, I would probably patch ij.jar to spit out several
> interesting things, such as the output of Class.forName(name) and
> IJ.getClassLoader.loadClass(name).
>
> Good luck,
> Johannes
>  

--
*Boris Epstein
National Resource For Imaging Mass Spectrometry
<http://www.nrims.hms.harvard.edu/>
Cambridge, MA
Mobile: (617) 816-9654*


The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.
Reply | Threaded
Open this post in threaded view
|

Re: ImageJ via Webstart

dscho
In reply to this post by Boris Epstein
Hi,

[I will probably miss some of your mails if you do not Cc: me]

On Mon, 12 Apr 2010, Boris Epstein wrote:

> How about this: I have now put all the classes in just one JAR. No issue
> with JARs being or not being in the classpath.
>
> Still the same thing, pretty much: the right classes are invoked
> correctly locally or via the applet, but not via the WebStart.
>
> I tried putting the classes to the top or under the plugins directory in
> the JAR - same difference.

I was serious when I talked about the IJ.getClassLoader().loadClass()
call. There are some details that you obviously do not understand, such as
the Java WebStart not using the same class loader as is the fallback class
loader for the plugins in ImageJ.

So I was really serious about the need to dig into the code, outputting
debug messages until you understand what is happening.

Good luck,
Johannes