Skip to content
This repository has been archived by the owner on Sep 1, 2022. It is now read-only.

Fix OPV-470285, and several other issues #349

Merged
merged 4 commits into from Jan 4, 2016

Conversation

cwardgar
Copy link
Contributor

@cwardgar cwardgar commented Jan 3, 2016

See individual commit messages.

cwardgar added 4 commits January 3, 2016 15:34
Closeable already implements AutoCloseable as of JDK 7, so this change doesn't lose us any functionality (we can still do try-with-resources).
However, we can now interoperate with code that expects a Closeable.
Previously, the "global-view" CdmNode lists were emptied but the root group was left untouched. That gets emptied (actually, replaced) now as well.
Such entries are still valid (i.e. they haven't changed), so now we're keeping them around.
As a result, we no longer need to recreate the NetcdfDataset object whenever a dataset is reacquired.
Substantial performance win. It's a wonder that this bug has been there this long.

Also:
* Added regression test
* Made similar fix to FileCacheARC
* Nuked crufty test class that didn't test anything useful, nor even use JUnit
… (fixes OPV-470285)

* Using setDatasetAcquireProxy() instead of just leaving nested datasets open
* As a result, no longer need closeDatasets() method. In fact, no aggregations need it, so I removed abstract method from Aggregation superclass.
* All aggregations call ncDataset.finish() at the end of buildNetcdfDataset().
* Added regression tests that verify that all types of Aggregation can reacquire their nested datasets after being closed.
* Added Variable.permitCaching flag. Intended to be used in testing
dopplershift added a commit that referenced this pull request Jan 4, 2016
Fix OPV-470285, and several other issues
@dopplershift dopplershift merged commit e256635 into Unidata:master Jan 4, 2016
@cwardgar cwardgar deleted the cache-aggregations branch January 6, 2016 04:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants