NOAA-PMEL / LAS

Live Access Server
https://ferret.pmel.noaa.gov/LAS/
The Unlicense
13 stars 5 forks source link

Fix LAS capability to create averages with time axis transformations #1073

Open karlmsmith opened 6 years ago

karlmsmith commented 6 years ago

Reported by @noaaroland on 2 Jun 2011 22:38 UTC We would like to create averages that include a transformation on the time axis (like creating an average January by averaging all the Januarys of a monthly data set).

Our efforts to do this now are failing because the LAS product server sees the analysis request to do an average and so it transforms the data URL to an F-TDS data URL that incorporates the average, but the request also includes a "constraint" that is telling LAS that the average should pick out only certain time points to include in the average. The Product Server ignores this constraint.

Having the product server create the F-TDS URL is nice because it means that other backend services can create plots of analysis variables.

To fix the problem averaging every January and to preserve the feature that allows other backends to plot such a request, I suggest we create an "analysis" service that will automatically get invoked anytime an LAS request contains an analysis XML element. This service will be smart enough to look for the constraint that is requesting the time axis transformation and will make sure that constraint is taken into account when making the F-TDS URL. Doing this in a service will mean that we can user Ferret to examine the data files if that is necessary to build the F-TDS URL.

If Ferret has new internal machinery to deal with the complex issue of doing the time axis transformations, then the resulting URLs might be nice and tidy. However, if that logic must live in a script, it might be possible to add that script to the collection of scripts that get deployed with F-TDS so that the service building the F-TDS URL will be able to invoke the script in the expr on the URL instead of cramming all that logic into the URL.

Migrated-From: http://dunkel.pmel.noaa.gov/trac/las/ticket/1067

karlmsmith commented 6 years ago

Comment by steven.c.hankin on 2 Jun 2011 23:01 UTC The idea of a separate service to generate the F-TDS URL seems like a good one. Especially if that new "product" could be smart enough to decide between two modes: a basic mode in which built-in Java logic creates the URL (what we do now); and an extensibility mode in which some other engine (typically Ferret) is invoked to do the job.

Does this seem feasible? If so I see nothing to stop you from getting the basic mode machinery working now. That should produce no outward change to LAS, but position us to solve the seasonal average problem by whatever means we prefer:

  1. a long complex Ferret script
  2. using a modification of LET/REMOTE
  3. exploiting a tbd simplified syntax in Ferret (stand by for a Ferret trac re: this topic)