Re: bundles, scripts question

Hi Don, thanks for the reply.

About jnlp bundles referencing other bundles, can the reference be a url one, i.e. http, or it is limited to files? The nice thing about the base64 encoded bundle being bundled by value as it were is that the bundle is self-contained.

If I did change to a bundle reference, what arguments list should I have? Currently, and this works great, I have the regular

   <application-desc main-class="ucar.unidata.idv.DefaultIdv">
            <argument>-nodefault</argument>
            <argument>-b64bundle</argument>
            <argument>BUNDLEHERE</argument>

I used a base64 encoder I found online to convert the .xidv bundle file, after I had run Ant's replace task on it to get the 'latest' urls. I then add the jnlp header and footer and this works.

What are the appropriate arguments if referencing an external .xidv bundle file? You mention %pathtobundle% as the sole argument?

Two minor points, relating to opening IDV with the bundle-containing jnlp file. First is that the world coastline map is displayed, even though it was not displayed when I saved the bundle (and I doubt that my bundle editing of url paths could have affected the coastline??), and second is that the Field Selector window appears, even though I had closed it before I saved the bundle. These are no big deal, the user can easily work around them. Maybe I am expecting too much of the 'save state' feature of the IDV, which I must say is mighty impressive.

One last point is that I see from the jnlp trail that you an expert in the jnlp spec. When I discovered that I could specify something as heavyweight as Java3d, with its native lib, to be downloadable via jnlp, I was well pleased. Too many times I have seen jnlp delivered apps with the caveat 'you need Java3d installed'. Then I look in your jnlps and see that you have that feature too! Nice one.

BTW, I'll look into your suggestion of using a 'latest' data set and url referencing scheme.

Stuart Maclean


When you save a bundle as a JNLP file, the bundle (.xidv) gets
base64 encoded and placed in the JNLP file.  You can also
have the bundle reference an external bundle, so I think a better
solution would be to create the bundle as an xidv file and
have the JNLP file reference that.  To do this:

- load in your datasource, set up the displays, etc.
- save the display as a bundle.
- modify the IDV's default JNLP file to point to the bundle.
  - from the IDV webstart page:
    http://www.unidata.ucar.edu/software/idv/webstart/IDV
    right click on the link to start the IDV and save the JNLP
    file to your local disk.
  - edit the JNLP file as follows:
    change:

     <application-desc main-class="ucar.unidata.idv.DefaultIdv"/>

    to:

      <application-desc main-class="ucar.unidata.idv.DefaultIdv">
       <argument>%pathtobundle%</argument>
      </application>

where %pathtobundle% would be the path to the bundle file.  You
could use this as a template for use with multiple bundle files.

Now, for the bundle, you could do one of two things:

- have a symbolic link to the latest model file which
(e.g. latest.nc) and use that when you create the bundle.
That way, you wouldn't have to edit the bundle (we don't
recommend editing bundles).
- edit the bundle every time, modifying the data source
entry.

Would this work for you?

Don



  • 2006 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the idvusers archives: