Re: [thredds] Remote OPENDAP dataset through WMS

Hi Harbil,

Jon is right. The URL he gives below will function as a WMS endpoint for
the NOAA/ESRL/PSD OPeNDAP URL given in the "dataset" parameter. The
downside is that, with <WMS><allowRemote> set to true, this form of WMS
URL can be used by any user to serve any remote dataset over WMS. Which
is why WMS/allowRemote is set to false by default.

If you want similar functionality for this dataset without opening your
server up to serve any remote dataset by WMS, you can add the remote
dataset to your catalog and control the advertised services. Something like:

> <dataset name="My DBSS OBIL 1984" ID="myDbssObil1984" 
> urlPath="myDbssObil1984">
>   <metadata inherited="true">
>       <serviceName>all</serviceName>
>       <dataType>Grid</dataType>
>   </metadata>
> 
>   <netcdf xmlns="http://www.unidata.ucar.edu/namespaces/netcdf/ncml-2.2";
>           
> location="http://www.esrl.noaa.gov/psd/thredds/dodsC/Datasets/godas/dbss_obil.1984.nc";
>  />
> </dataset>

The WMS endpoint would then be

http://localhost:8080/thredds/wms/myDbssObil1984

Hope that helps,

Ethan

On 8/24/2011 10:33 AM, Jon Blower wrote:
> Hi Harbil,
> 
> When you serve remote datasets, you don't need to add them to the
> catalog (at least, I think that's true). The URL is itself a WMS
> endpoint. So if you have remote datasets enabled, you can point your WMS
> client to the URL:
> 
> http://localhost:8080/thredds/wms?dataset=http://www.esrl.noaa.gov/psd/thredds/dodsC/Datasets/godas/dbss_obil.1984.nc
> 
> and it should work.
> 
> If you want to add a remote dataset to the catalog you probably have
> to do something different.
> 
> (Someone who knows more about THREDDS than I do will hopefully
> correct me if I'm wrong!)
> 
> HTH,
> Jon
> 
> ----------------------------------------------------------------------
> 
> Message: 1
> Date: Tue, 23 Aug 2011 12:56:18 +0200
> From: Harbil Arregui <harbil.arregui@xxxxxxxxx>
> To: thredds@xxxxxxxxxxxxxxxx
> Subject: [thredds] Remote OPENDAP dataset through WMS
> Message-ID:
>       <CAMQ488GRvYVEjWbPeRBmff851_CmdtSv-hWMmjo4FZcwOWb-4A@xxxxxxxxxxxxxx>
> Content-Type: text/plain; charset="iso-8859-1"
> 
> Hello everyone,
> 
> I apologize in case I'm asking this in the wrong place. I have setup a 
> Thredds server and I'd like to offer WMS access to several remote datasets.
> This remote datasets are given in OPENDAP and HTTPServer.
> I cannot make the method shown
> here<http://www.unidata.ucar.edu/projects/THREDDS/tech/tds4.2/reference/WMS.html>work.
> 
> In catalog.xml I put:
> <dataset name="Remote" ID="dbss_obil" serviceName="wms" urlPath="
> http://localhost:8080/thredds/wms?dataset=http://www.esrl.noaa.gov/psd/thredds/dodsC/Datasets/godas/dbss_obil.1984.nc";
> dataType="Grid"/>
> 
> I already changed the threddsConfig.xml file including:
>   <WMS>
>     <allow>true</allow>
>     <allowRemote>true</allowRemote>
>   </WMS>
> 
> It gives me this error:
> <ServiceExceptionReport version="1.3.0" xsi:schemaLocation="
> http://www.opengis.net/ogc
> http://schemas.opengis.net/wms/1.3.0/exceptions_1_3_0.xsd
> "><ServiceException>
>         Failed to open dataset, "
> http://www.esrl.noaa.gov/psd/thredds/dodsC/Datasets/godas/dbss_obil.1984.nc?service=WMS
> ".
> </ServiceException></ServiceExceptionReport>
> 
> 
> So, am I trying to do something non-sense, expecting that my server should be 
> able to do the direct conversion from the remote .nc file to WMS? Is there 
> any way to do this?
> 
> Many thanks,
> Harbil

-- 
Ethan Davis                                       UCAR Unidata Program
edavis@xxxxxxxxxxxxxxxx                    http://www.unidata.ucar.edu