static public void initDefaultCollectionCache(int minElementsInMemory, int maxElementsInMemory, int period) { // gribCollectionCache = new ucar.nc2.util.cache.FileCache("DefaultGribCollectionCache", minElementsInMemory, maxElementsInMemory, -1, period); gribCollectionCache = new ucar.nc2.util.cache.FileCacheGuava("DefaultGribCollectionCache", maxElementsInMemory); }
@Override public FileCacheable acquire(FileFactory factory, DatasetUrl durl) throws IOException { return acquire(factory, durl.trueurl, durl, -1, null, null); }
@Override public void disable() { clearCache(true); cache = null; }
@BeforeClass static public void before() { GribIosp.debugIndexOnlyCount = 0; GribCollectionImmutable.countGC = 0; PartitionCollectionImmutable.countPC = 0; RandomAccessFile.enableDefaultGlobalFileCache(); RandomAccessFile.setDebugLeaks(true); // Grib.setDebugFlags(new DebugFlagsImpl("Grib/indexOnly")); GribCdmIndex.setGribCollectionCache(new ucar.nc2.util.cache.FileCacheGuava("GribCollectionCacheGuava", 100)); GribCdmIndex.gribCollectionCache.resetTracking(); }
@BeforeClass static public void before() throws IOException { GribIosp.debugIndexOnlyCount = 0; GribCollectionImmutable.countGC = 0; PartitionCollectionImmutable.countPC = 0; RandomAccessFile.enableDefaultGlobalFileCache(); RandomAccessFile.setDebugLeaks(true); // GribIosp.setDebugFlags(new DebugFlagsImpl("Grib/indexOnly")); GribCdmIndex.setGribCollectionCache(new ucar.nc2.util.cache.FileCacheGuava("GribCollectionCacheGuava", 100)); GribCdmIndex.gribCollectionCache.resetTracking(); }
@BeforeClass static public void before() { GribIosp.debugIndexOnlyCount = 0; GribCollectionImmutable.countGC = 0; PartitionCollectionImmutable.countPC = 0; RandomAccessFile.enableDefaultGlobalFileCache(); RandomAccessFile.setDebugLeaks(true); Grib.setDebugFlags(new DebugFlagsImpl("Grib/indexOnly")); GribCdmIndex.setGribCollectionCache(new ucar.nc2.util.cache.FileCacheGuava("GribCollectionCacheGuava", 100)); GribCdmIndex.gribCollectionCache.resetTracking(); }
@BeforeClass static public void before() { GribIosp.debugIndexOnlyCount = 0; GribCollectionImmutable.countGC = 0; PartitionCollectionImmutable.countPC = 0; RandomAccessFile.enableDefaultGlobalFileCache(); RandomAccessFile.setDebugLeaks(true); Grib.setDebugFlags(new DebugFlagsImpl("Grib/indexOnly")); GribCdmIndex.setGribCollectionCache(new ucar.nc2.util.cache.FileCacheGuava("GribCollectionCacheGuava", 100)); GribCdmIndex.gribCollectionCache.resetTracking(); }
@BeforeClass static public void before() { GribIosp.debugIndexOnlyCount = 0; GribCollectionImmutable.countGC = 0; PartitionCollectionImmutable.countPC = 0; RandomAccessFile.enableDefaultGlobalFileCache(); RandomAccessFile.setDebugLeaks(true); Grib.setDebugFlags(new DebugFlagsImpl("Grib/indexOnly")); GribCdmIndex.setGribCollectionCache(new ucar.nc2.util.cache.FileCacheGuava("GribCollectionCacheGuava", 100)); GribCdmIndex.gribCollectionCache.resetTracking(); }
@BeforeClass static public void before() { GribIosp.debugIndexOnlyCount = 0; GribCollectionImmutable.countGC = 0; PartitionCollectionImmutable.countPC = 0; RandomAccessFile.enableDefaultGlobalFileCache(); RandomAccessFile.setDebugLeaks(true); // Grib.setDebugFlags(new DebugFlagsImpl("Grib/indexOnly")); GribCdmIndex.setGribCollectionCache(new ucar.nc2.util.cache.FileCacheGuava("GribCollectionCacheGuava", 100)); GribCdmIndex.gribCollectionCache.resetTracking(); // make sure that the indexes are created with the data files DiskCache2 diskCache = GribIndexCache.getDiskCache2(); diskCache.setNeverUseCache(true); diskCache.setAlwaysUseCache(false); }