1

I'm trying to setup a geotiff folder inside ImageMosaic plugin after following this https://docs.geoserver.org/latest/en/user/tutorials/imagemosaic_timeseries/imagemosaic_timeseries.html

Using the samples files from the tutorial I'm ok, but if I try to use my own geotiff files I get the following error.

17 Feb 10:45:21 WARN [gce.geotiff] - File /home/geoserver/data_dir/data/swiss is a directory.
Caused by: java.io.IOException: File /home/geoserver/data_dir/data/swiss is a directory.
17 Feb 10:45:24 INFO [geoserver.web] - Getting list of coverages for saved store file:data/swiss/
java.lang.RuntimeException: Could not list layers for this store, an error occurred retrieving them: Failed to create reader from file:data/swiss/ and hints Hints:
  EXECUTOR_SERVICE = java.util.concurrent.ThreadPoolExecutor@2186fe12[Running, pool size = 0, active threads = 0, queued tasks = 0, completed tasks = 0]
  REPOSITORY       = org.geoserver.catalog.CatalogRepository@26aa7b11
System defaults:
  LENIENT_DATUM_SHIFT              = true
  FILTER_FACTORY                   = FilterFactoryImpl
  COMPARISON_TOLERANCE             = 1.0E-8
  GRID_COVERAGE_FACTORY            = GridCoverageFactory
    TILE_ENCODING                  = null
  STYLE_FACTORY                    = StyleFactoryImpl
  FORCE_LONGITUDE_FIRST_AXIS_ORDER = true
  FORCE_AXIS_ORDER_HONORING        = http
  FEATURE_FACTORY                  = org.geotools.feature.LenientFeatureFactoryImpl@5827af16
        at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:804)
2
  • it can depend from the filename data? ingestion:java.util.Date. IN the sample I see this forma YYYYMMDD but my file has YYYYMMDDhhmm. I changed the regex as regex=[0-9]{12}. I need to separe hours and days? – Andrea Feb 17 '20 at 10:56
  • Even using [0-9]{8}[0-9]{4} doesn't work. – Andrea Feb 17 '20 at 11:04
3

According to the ImageMosaic configuration documentation:

In case of custom format datetimes in filename, an additional format element should be added after the regex, preceded by a comma, defining the custom representation.

So in your case, the regex in your timeregex.properties file (or whatever you named it in indexer.properties file) should be something like this:

regex=[0-9]{12},format=yyyyMMddHHmm

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.