[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NJ4 -- Re: Panoply netCDF viewer version 2.6.5 released





Robert B. Schmunk wrote:

John,

Is my memory shot, or is it correct that NJ4 only requires
Java 5? I could have sworn that you announced many months
ago that NJ4 required Java 6.

nj4 requires jdk5+. tds 4 requires 6+


Anyway, I just tried compiling my NJ wrapping code using NJ4
rather NJ22 and ran into the following:

* You moved the AxisType class from the ucar.nc2.dataset
  package to ucar.nc2.constants.

* You eliminated the NetcdfFileCache class. I was calling
  NetcdfFileCache.release(NetcdfFile) when done with a
  dataset. Is that no longer needed?

 Package ucar.nc2.util.cache
   * FileCache uses FileCacheable and FileFactory, replaces NetcdfFileCache, 
NetcdfDatasetCache, HTTPFileCache
   + FileCache no longer static, allows any number of caches. uses 
java.util.concurrent

if you want caching , see NetcdfDataset.acquireFile(), 
NetcdfDataset.acquireDataset(), NetcdfDataset.initNetcdfFileCache()

in any case, you should just use NetcdfFile.close(), which works with the cache 
if enabled.

> * There is no longer a CoordinateAxis1D(VariableDS)
  constructor. Apparently one must now use
  CoordinateAxis1D(NetcdfDataset,VariableDS).

yes


* InvCatalogImpl now uses check(StringBuilder,boolean)
  rather than check(StringBuffer).

yes


* NetcdfFileWriteable.createNew apparently now has an
  explicit throws.

yes


Taking care of those, I can compile and run Panoply and
it seemed happy opening and plotting a netCDF 3 dataset.
I only tried one, a bog standard CAM output dataset.

Beyond that, I have some devo code (not in the public
release) that makes use of NetcdfFileWriteable. Apparently
you've added an explicit throws to that class's
createNew(String,boolean) method.

Some of the above look like they're mentioned in your
transition guide. I need to look at that page a bit
closer as I see some other things mentioned whose
implications I need to consider, e.g., "remove direct
use of ucar.units".

yes, we are hiding ucar.units behind ucar.nc2.units.SimpleUnit facade. In 
particular, we will replace the date/time handling with joda library. We may 
also replace ucar.units with the new standard java units package (jsr-275).

thanks for your comments
> rbs




On Dec 23, 2008, at 17:57, John Caron wrote:

Hi Robert:

When you get a chance, could you try compiling against netcdf-java 4.0, and seeing what problems you see? We are getting ready for release, and there have been some minor API changes which Id like to know how/if they affect users.

Ive started a document to guide the switch over, which ill improve after getting comments from you and others:

 http://www.unidata.ucar.edu/software/netcdf-java/transition4.html

Thanks, and happy holidays.

John




--
Robert B. Schmunk, address@hidden
NASA Goddard Institute for Space Studies, 2880 Broadway, New York, NY 10025