-
Notifications
You must be signed in to change notification settings - Fork 1
Home
NcSOS adds a OGC SOS service to your existing THREDDS server.
#Table of Contents
Installation
Supported Datasets
Setup for Developers
Development Roadmap
You will need a working THREDDS installation of a least 4.3.16 to run NcSOS. More specific or recent THREDDS dependencies will be described in the release notes or below in the installation section.
# Installation-
Extract
RC8-2.zip.zip
into a local directory -
Copy the
ncSOS.jar
into your$TOMCAT_HOME/webapps/thredds/WEB-INF/lib
directory. -
Copy the
sos-servlet.xml
configuration file into the$TOMCAT_HOME/webapps/thredds/WEB-INF
directory. -
Add two new servlet mappings to your
$TOMCAT_HOME/webapps/thredds/WEB-INF/web.xml
file:<servlet> <servlet-name>sos</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <load-on-startup>1</load-on-startup> </servlet>
<servlet-mapping> <servlet-name>sos</servlet-name> <url-pattern>/sos/*</url-pattern> </servlet-mapping>
-
Add the following service definition to enable SOS in your THREDDS catalog XML files:
<service name="sos" serviceType="SOS" base="/thredds/sos/" />
-
Restart the web application server.
Alternatively, you can download a THREDDS war file that is pre-setup with NcSOS (bypassing the above installation steps) here.
See the known issues for a note on NCML aggregation problems.
Aggregated netcdf files can be served through the catalog by using NCML. NcML is an XML representation of netCDF metadata, more information on NCML can be found at the unidata website here. In short NCML aggregation offers a seemless view and data access across multiple netcdf files.
Unidata also offers a Basic NCML tutorial here, with a tutorial geared towards NCML aggregation here. There are a number of different methods for agreegating Netcdf data through NCML, it is suggest that you read the above tutorials, particually the NCML agreegation one, and decide the best method for aggregating your data.
A simple example aggregation, using a simple union can be seen below. The example implemention outlines some of the steps you should take.
-
identify how you are going to aggregate your netcdf data (in this example taken from Unidata's NCML aggregation page we are using an aggregation on an existing dimension named "time", this might be a typical approach for the aggregation of time series files.
-
generate an NCML file using a text editor, something like this...
<netcdf xmlns="http://www.unidata.ucar.edu/namespaces/netcdf/ncml-2.2">
<aggregation dimName="time" type="joinExisting">
<netcdf location="jan.nc" />
<netcdf location="feb.nc" />
</aggregation>
</netcdf>
In the NCML file we can see the dimension we what to join on ("time"), and the netcdf files we are aggregating together ("jan.nc", "feb.nc"). We could now open this NCML files in something like toolsui (toolsui.jar is a java application available from unidata's website, great for viewing netcdf files)
- With the NCML file generated we just need to add it to the THREDDS catalog, this can be done the same as any other netcdf dataset.
NcSOS works with datasets that can be loaded as an ANY_POINT FeatureType using the NetCDF-Java library. A mapping from CF-1.6 Discrete Sampling Geometries to NetCDF-Java Point Feature Types to NcSOS offerings is below.
Note: NetCDF-Java added support for the CF-1.6 Discrete Sampling Geometries in version 4.3. Any version prior to 4.3 will not work with NcSOS.
CF-1.6 | NetCDF-Java | What NcSOS Offers |
---|---|---|
Point | PointFeature | Point |
Many Points | PointFeatureCollection | Many Points |
Profile | ProfileFeature | Profile |
Many Profiles | ProfileFeatureCollection | Many Profiles |
Timeseries | StationTimeSeriesFeature | Timeseries |
Many Timeseries | StationTimeSeriesFeatureCollection | Many Timeseries |
TimeseriesProfile | StationProfileFeature | TimeseriesProfile |
Many TimeseriesProfiles | StationProfileFeatureCollection | Many TimeseriesProfiles |
Trajectory | TrajectoryFeature | Trajectory |
Many Trajectories | TrajectoryFeatureCollection | Many Trajectories |
TrajectoryProfile | SectionFeature | Trajectory with a profile of data (ranging Z) at each point |
Many TrajectoryProfiles | SectionFeatureCollection | Many Trajectories with a profile of data (ranging Z) at each point |
Working NetCDF templates for all types of the CF-1.6 Discrete Sampling Geometries are available for reference when creating files for NcSOS to serve. Each of these templates aligns with a corresponding CF-1.6 example. Each template folder has a description of the type of data used in each file and when to use such an encoding.
One or more parameters measured at a point in time and space.
Example: You went out on a boat one day and measured a few parameters. Some unrelated time in the future, you went out to a completely different point and measured a few parameters. The measurements have nothing in common. This could be represented as a CF-1.6 Point dataset containing two points.
Templates: https://github.com/asascience-open/CFPointConventions/tree/master/point
One or more parameters measured at a point space with varying time.
Example: Two wind sensors measuring wind speed and wing gust every 6 minutes for a year. The sensors did not move from their geographic location during the year. This could be represented as a CF-1.6 Timeseries dataset containing two 'stations'.
Templates: https://github.com/asascience-open/CFPointConventions/tree/master/timeSeries
A set of data points along a vertical line.
Example: The timeseries produced from bottom mounted ADCP.
Templates: https://github.com/asascience-open/CFPointConventions/tree/master/timeSeriesProfile
A set of data points along a 1D curve in time and space.
Example: A glider moving through the water column in the x,y, and z dimentions, and taking readings at its location.
Templates: https://github.com/asascience-open/CFPointConventions/tree/master/trajectory
Profiles taken along a trajectory.
Example: A glider moving through the water column in the x,y, and z dimentions, making water column profiles as it moves.
Templates: https://github.com/asascience-open/CFPointConventions/tree/master/trajectoryProfile
If you already have your dataset in a THREDDS server, you can test if it will work with NcSOS by using the ToolsUI program from the NetCDF-Java library. You can Webstart the ToolsUI application here: ToolsUI JNLP Webstart.
Enter your OPeNDAP Data endpoint from THREDDS
Into the ToolsUI FeatureTypes / PointFeature tab and press enter:
If you see a row of data here, you are in good shape so far!
All SWE output templates are wrapped in an O&M 1.0 wrapper
- TimeSeries om1.0.0
- **TimeSeries om1.0.0 with quality flags
- TimeSeriesProfile om1.0.0, single station
- TimeSeriesProfile om1.0.0, single station, with quality flags
- Profile om1.0.0 is a degenerate case of TimeSeriesProfile with only one time step
- Grid sensorML1.0.1
- Profile sensorML1.0.1
- Sensor sensorML1.0.1
- TimeSeries(Profile) sensorML1.0.1
- Trajectory sensorML1.0.1
- TrajectoryProfile (Section) sensorML1.0.1
- Grid om1.0.0
- Profile om1.0.0
- TimeSeries om1.0.0
- TimeSeriesProfile om1.0.0
- Trajectory om1.0.0
- TrajectoryProfile (Section) om1.0.0
- Better testing and documentation
- Integration with THREDDS 4.4.1
- Verification of side by side 52North and ncSOS deployments.
- Add GetObservation Trajectory and TrajectoryProfile responses (IOOS SWE Milestone 1.0)
- Add SensorML response for individual sensors
- Crosswalk SensorML generation with the "platform" variable concepts in the US NODC netCDF templates.
- Add csv output format
- Support for SOS, SWE, SensorML, and O&M 2.0
- Add kml output format
- Add geojson output format
- Support for HDF5/netCDF4 hierarchical data sets using groups