[Geoserver-users] Trouble with simple setup of Image Mosaic over a working GRIB2 file

Greetings,

I am attempting to setup a time based image mosaic over a series of GRIB2 files. Setup of a GRIB store with the file succeeds with no issues, and allows me to visualize the contents in geoserver. When I put the same GRIB in a directory, and attempt to create an image mosaic from it, it fails. I’ve tried just pointing image mosaic at the directory where the GRIB sits with no additional files, and it fails. I’ve tried also with a datastore.properties, indexer.xml, and _auxiliary.xml and this also fails. I am at my wits end trying to get this going with image mosaic.

This is the file I am attempting :

http://nomads.ncep.noaa.gov/cgi-bin/filter_hiresconus.pl?file=hiresw.t00z.arw_5km.f00.conus.grib2&all_lev=on&var_TMP=on&leftlon=0&rightlon=360&toplat=90&bottomlat=-90&dir=%2Fhiresw.20160809

my indexer.xml looks like this :

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>

time

the_geom:Polygon,imageindex:Integer,time:java.util.Date

Temperature_surface

Temperature_surface

My _auxiliary.xml looks like :

<?xml version="1.0" encoding="UTF-8"?>

the_geom:Polygon,imageindex:Integer,time:java.util.Date

Temperature_surface

Temperature_surface

My datastore.properties contains details to connect to postgres, this has worked fine with other stores so I trust it.

The latest error I get is :

09 Aug 21:34:10 ERROR [imagemosaic.Utils] - Invalid mosaic schema SimpleFeatureTypeImpl Temperature_surface identified extends Feature(the_geom:the_geom,imageindex:imageindex,time:time), it should have a geometry and a location property of name null

java.lang.IllegalArgumentException: Invalid mosaic schema SimpleFeatureTypeImpl Temperature_surface identified extends Feature(the_geom:the_geom,imageindex:imageindex,time:time), it should have a geometry and a location property of name null

at org.geotools.gce.imagemosaic.catalog.GTDataStoreGranuleCatalog.checkMosaicSchema(GTDataStoreGranuleCatalog.java:284)

at org.geotools.gce.imagemosaic.catalog.GTDataStoreGranuleCatalog.createType(GTDataStoreGranuleCatalog.java:617)

at org.geotools.gce.imagemosaic.catalog.CachingDataStoreGranuleCatalog.createType(CachingDataStoreGranuleCatalog.java:104)

at org.geotools.gce.imagemosaic.RasterManager.createStore(RasterManager.java:1283)

at org.geotools.gce.imagemosaic.ImageMosaicReader.createCoverage(ImageMosaicReader.java:1129)

at org.geotools.gce.imagemosaic.ImageMosaicConfigHandler.updateConfiguration(ImageMosaicConfigHandler.java:880)

at org.geotools.gce.imagemosaic.ImageMosaicWalker.handleFile(ImageMosaicWalker.java:210)

at org.geotools.gce.imagemosaic.ImageMosaicDirectoryWalker$MosaicDirectoryWalker.handleFile(ImageMosaicDirectoryWalker.java:98)

at org.apache.commons.io.DirectoryWalker.walk(DirectoryWalker.java:367)

at org.apache.commons.io.DirectoryWalker.walk(DirectoryWalker.java:335)

at org.geotools.gce.imagemosaic.ImageMosaicDirectoryWalker$MosaicDirectoryWalker.(ImageMosaicDirectoryWalker.java:114)

at org.geotools.gce.imagemosaic.ImageMosaicDirectoryWalker.run(ImageMosaicDirectoryWalker.java:196)

at org.geotools.gce.imagemosaic.Utils.createMosaic(Utils.java:363)

Any help or advice would be greatly appreciated, I am uncertain how to resolve this.

Thanks!

image001.jpg

image002.png

image003.png

image004.png

···

cid:image001.jpg@anonymised.com

Steve Ferguson
Senior Software Systems Engineer

Forest Service Contractor

Digital Visions Enterprise Team

p: 919-999-4930 (PST)
sferguson@anonymised.com

cid:image002.png@anonymised.com9...cid:image003.png@anonymised.comcid:image004.png@anonymised.com

Caring for the land and serving people

Steve,

I found that omitting location:String from the schema resulted in failure with an exception message similar to that you report:

java.lang.IllegalArgumentException: Invalid mosaic schema SimpleFeatureTypeImpl Pressure_surface identified extends Feature(the_geom:the_geom,imageindex:imageindex,time:time), it should have a geometry and a location property of name null

I found that it was necessary to use a schema like this:

<attributes>the_geom:Polygon,location:String,imageindex:Integer,time:java.util.Date</attributes>

See:
https://github.com/bencaradocdavies/geoserver/wiki/RAP-Native-Grid-ImageMosaic

Kind regards,
Ben.

On 10/08/16 09:52, Ferguson, Steve -FS wrote:

Greetings,

I am attempting to setup a time based image mosaic over a series of GRIB2 files. Setup of a GRIB store with the file succeeds with no issues, and allows me to visualize the contents in geoserver. When I put the same GRIB in a directory, and attempt to create an image mosaic from it, it fails. I've tried just pointing image mosaic at the directory where the GRIB sits with no additional files, and it fails. I've tried also with a datastore.properties, indexer.xml, and _auxiliary.xml and this also fails. I am at my wits end trying to get this going with image mosaic.

This is the file I am attempting :

http://nomads.ncep.noaa.gov/cgi-bin/filter_hiresconus.pl?file=hiresw.t00z.arw_5km.f00.conus.grib2&all_lev=on&var_TMP=on&leftlon=0&rightlon=360&toplat=90&bottomlat=-90&dir=%2Fhiresw.20160809

my indexer.xml looks like this :

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Indexer>
  <domains>
    <domain name="time">
      <attributes><attribute>time</attribute></attributes>
    </domain>
  </domains>

    <coverages>
        <coverage>
            <schema name="Temperature_surface">
                <attributes>the_geom:Polygon,imageindex:Integer,time:java.util.Date</attributes>
            </schema>
      <domains>
        <domain ref="time" />
      </domains>

            <origName>Temperature_surface</origName>
            <name>Temperature_surface</name>
        </coverage>
    </coverages>
  <parameters>
    <parameter name="AuxiliaryFile" value="/gdata/grib/nomads_img/_auxiliary.xml" />

    <parameter name="AbsolutePath" value="true" />
  </parameters>

</Indexer>

My _auxiliary.xml looks like :

<?xml version="1.0" encoding="UTF-8"?><Indexer>
  <coverages>
    <coverage>
      <schema name="Temperature_surface">
        <attributes>the_geom:Polygon,imageindex:Integer,time:java.util.Date</attributes>
      </schema>
      <origName>Temperature_surface</origName>
      <name>Temperature_surface</name>
    </coverage>
  </coverages>
</Indexer>

My datastore.properties contains details to connect to postgres, this has worked fine with other stores so I trust it.

The latest error I get is :

09 Aug 21:34:10 ERROR [imagemosaic.Utils] - Invalid mosaic schema SimpleFeatureTypeImpl Temperature_surface identified extends Feature(the_geom:the_geom,imageindex:imageindex,time:time), it should have a geometry and a location property of name null
java.lang.IllegalArgumentException: Invalid mosaic schema SimpleFeatureTypeImpl Temperature_surface identified extends Feature(the_geom:the_geom,imageindex:imageindex,time:time), it should have a geometry and a location property of name null
        at org.geotools.gce.imagemosaic.catalog.GTDataStoreGranuleCatalog.checkMosaicSchema(GTDataStoreGranuleCatalog.java:284)
        at org.geotools.gce.imagemosaic.catalog.GTDataStoreGranuleCatalog.createType(GTDataStoreGranuleCatalog.java:617)
        at org.geotools.gce.imagemosaic.catalog.CachingDataStoreGranuleCatalog.createType(CachingDataStoreGranuleCatalog.java:104)
        at org.geotools.gce.imagemosaic.RasterManager.createStore(RasterManager.java:1283)
        at org.geotools.gce.imagemosaic.ImageMosaicReader.createCoverage(ImageMosaicReader.java:1129)
        at org.geotools.gce.imagemosaic.ImageMosaicConfigHandler.updateConfiguration(ImageMosaicConfigHandler.java:880)
        at org.geotools.gce.imagemosaic.ImageMosaicWalker.handleFile(ImageMosaicWalker.java:210)
        at org.geotools.gce.imagemosaic.ImageMosaicDirectoryWalker$MosaicDirectoryWalker.handleFile(ImageMosaicDirectoryWalker.java:98)
        at org.apache.commons.io.DirectoryWalker.walk(DirectoryWalker.java:367)
        at org.apache.commons.io.DirectoryWalker.walk(DirectoryWalker.java:335)
        at org.geotools.gce.imagemosaic.ImageMosaicDirectoryWalker$MosaicDirectoryWalker.<init>(ImageMosaicDirectoryWalker.java:114)
        at org.geotools.gce.imagemosaic.ImageMosaicDirectoryWalker.run(ImageMosaicDirectoryWalker.java:196)
        at org.geotools.gce.imagemosaic.Utils.createMosaic(Utils.java:363)

Any help or advice would be greatly appreciated, I am uncertain how to resolve this.

Thanks!

[cid:image001.jpg@anonymised.com]

Steve Ferguson
Senior Software Systems Engineer

Forest Service Contractor
Digital Visions Enterprise Team

p: 919-999-4930 (PST)
sferguson@anonymised.com<mailto:sferguson@anonymised.com>
[cid:image002.png@anonymised.com]<http://usda.gov/&gt;\[cid:image003\.png@anonymised\.com\]&lt;https://twitter.com/forestservice&gt;\[cid:image004\.png@anonymised\.com\]&lt;http://facebook.com/USDA&gt;

Caring for the land and serving people

This electronic message contains information generated by the USDA solely for the intended recipients. Any unauthorized interception of this message or the use or disclosure of the information it contains may violate the law and subject the violator to civil or criminal penalties. If you believe you have received this message in error, please notify the sender and delete the email immediately.

------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are
consuming the most bandwidth. Provides multi-vendor support for NetFlow,
J-Flow, sFlow and other flows. Make informed decisions using capacity
planning reports. http://sdm.link/zohodev2dev

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Ben Caradoc-Davies <ben@anonymised.com>
Director
Transient Software Limited <http://transient.nz/&gt;
New Zealand

Ben, that worked! Thank you so much!

Steve

-----Original Message-----
From: Ben Caradoc-Davies [mailto:ben@…6881…]
Sent: Tuesday, August 09, 2016 3:45 PM
To: Ferguson, Steve -FS <sferguson@...102...>; geoserver-users@lists.sourceforge.net
Subject: Re: [Geoserver-users] Trouble with simple setup of Image Mosaic over a working GRIB2 file

Steve,

I found that omitting location:String from the schema resulted in failure with an exception message similar to that you report:

java.lang.IllegalArgumentException: Invalid mosaic schema SimpleFeatureTypeImpl Pressure_surface identified extends Feature(the_geom:the_geom,imageindex:imageindex,time:time), it should have a geometry and a location property of name null

I found that it was necessary to use a schema like this:

<attributes>the_geom:Polygon,location:String,imageindex:Integer,time:java.util.Date</attributes>

See:
https://github.com/bencaradocdavies/geoserver/wiki/RAP-Native-Grid-ImageMosaic

Kind regards,
Ben.

On 10/08/16 09:52, Ferguson, Steve -FS wrote:

Greetings,

I am attempting to setup a time based image mosaic over a series of GRIB2 files. Setup of a GRIB store with the file succeeds with no issues, and allows me to visualize the contents in geoserver. When I put the same GRIB in a directory, and attempt to create an image mosaic from it, it fails. I've tried just pointing image mosaic at the directory where the GRIB sits with no additional files, and it fails. I've tried also with a datastore.properties, indexer.xml, and _auxiliary.xml and this also fails. I am at my wits end trying to get this going with image mosaic.

This is the file I am attempting :

http://nomads.ncep.noaa.gov/cgi-bin/filter_hiresconus.pl?file=hiresw.t
00z.arw_5km.f00.conus.grib2&all_lev=on&var_TMP=on&leftlon=0&rightlon=3
60&toplat=90&bottomlat=-90&dir=%2Fhiresw.20160809

my indexer.xml looks like this :

<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <Indexer>
  <domains>
    <domain name="time">
      <attributes><attribute>time</attribute></attributes>
    </domain>
  </domains>

    <coverages>
        <coverage>
            <schema name="Temperature_surface">
                <attributes>the_geom:Polygon,imageindex:Integer,time:java.util.Date</attributes>
            </schema>
      <domains>
        <domain ref="time" />
      </domains>

            <origName>Temperature_surface</origName>
            <name>Temperature_surface</name>
        </coverage>
    </coverages>
  <parameters>
    <parameter name="AuxiliaryFile"
value="/gdata/grib/nomads_img/_auxiliary.xml" />

    <parameter name="AbsolutePath" value="true" />
  </parameters>

</Indexer>

My _auxiliary.xml looks like :

<?xml version="1.0" encoding="UTF-8"?><Indexer>
  <coverages>
    <coverage>
      <schema name="Temperature_surface">
        <attributes>the_geom:Polygon,imageindex:Integer,time:java.util.Date</attributes>
      </schema>
      <origName>Temperature_surface</origName>
      <name>Temperature_surface</name>
    </coverage>
  </coverages>
</Indexer>

My datastore.properties contains details to connect to postgres, this has worked fine with other stores so I trust it.

The latest error I get is :

09 Aug 21:34:10 ERROR [imagemosaic.Utils] - Invalid mosaic schema
SimpleFeatureTypeImpl Temperature_surface identified extends
Feature(the_geom:the_geom,imageindex:imageindex,time:time), it should
have a geometry and a location property of name null
java.lang.IllegalArgumentException: Invalid mosaic schema SimpleFeatureTypeImpl Temperature_surface identified extends Feature(the_geom:the_geom,imageindex:imageindex,time:time), it should have a geometry and a location property of name null
        at org.geotools.gce.imagemosaic.catalog.GTDataStoreGranuleCatalog.checkMosaicSchema(GTDataStoreGranuleCatalog.java:284)
        at org.geotools.gce.imagemosaic.catalog.GTDataStoreGranuleCatalog.createType(GTDataStoreGranuleCatalog.java:617)
        at org.geotools.gce.imagemosaic.catalog.CachingDataStoreGranuleCatalog.createType(CachingDataStoreGranuleCatalog.java:104)
        at org.geotools.gce.imagemosaic.RasterManager.createStore(RasterManager.java:1283)
        at org.geotools.gce.imagemosaic.ImageMosaicReader.createCoverage(ImageMosaicReader.java:1129)
        at org.geotools.gce.imagemosaic.ImageMosaicConfigHandler.updateConfiguration(ImageMosaicConfigHandler.java:880)
        at org.geotools.gce.imagemosaic.ImageMosaicWalker.handleFile(ImageMosaicWalker.java:210)
        at org.geotools.gce.imagemosaic.ImageMosaicDirectoryWalker$MosaicDirectoryWalker.handleFile(ImageMosaicDirectoryWalker.java:98)
        at org.apache.commons.io.DirectoryWalker.walk(DirectoryWalker.java:367)
        at org.apache.commons.io.DirectoryWalker.walk(DirectoryWalker.java:335)
        at org.geotools.gce.imagemosaic.ImageMosaicDirectoryWalker$MosaicDirectoryWalker.<init>(ImageMosaicDirectoryWalker.java:114)
        at org.geotools.gce.imagemosaic.ImageMosaicDirectoryWalker.run(ImageMosaicDirectoryWalker.java:196)
        at
org.geotools.gce.imagemosaic.Utils.createMosaic(Utils.java:363)

Any help or advice would be greatly appreciated, I am uncertain how to resolve this.

Thanks!

[cid:image001.jpg@...7759...]

Steve Ferguson
Senior Software Systems Engineer

Forest Service Contractor
Digital Visions Enterprise Team

p: 919-999-4930 (PST)
sferguson@...102...<mailto:sferguson@…102…>
[cid:image002.png@...7759...]<http://usda.gov/&gt;\[cid:image003.pn
g@...7759...]<https://twitter.com/forestservice&gt;\[cid:image004.p
ng@...7759...]<http://facebook.com/USDA&gt;

Caring for the land and serving people

This electronic message contains information generated by the USDA solely for the intended recipients. Any unauthorized interception of this message or the use or disclosure of the information it contains may violate the law and subject the violator to civil or criminal penalties. If you believe you have received this message in error, please notify the sender and delete the email immediately.

----------------------------------------------------------------------
-------- What NetFlow Analyzer can do for you? Monitors network
bandwidth and traffic patterns at an interface-level. Reveals which
users, apps, and protocols are consuming the most bandwidth. Provides
multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make
informed decisions using capacity planning reports.
http://sdm.link/zohodev2dev

_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
Ben Caradoc-Davies <ben@...6881...>
Director
Transient Software Limited <http://transient.nz/&gt; New Zealand