-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Would it be possible to also advertise palettes as styles, as in ncWMS? #86
Comments
Just to be clear, you'd like to be able to advertise the available palettes
via the GetCapabilities call even though it may be a bit tricky to parse?
…On Tue, Apr 18, 2017 at 10:14 AM, Rich Signell ***@***.***> wrote:
As discussed here TerriaJS/terriajs#2200
<TerriaJS/terriajs#2200>, generic WMS clients
do not see the list of palettes advertised as styles, as ncWMS2 palettes
are accessed through a custom getMetadata call.
Would it be possible to also allow ncWMS2 service providers to advertise
the palettes as styles also, or at least some subset of palettes?
This would allow workflows like this TerriaJS one to work a lot more
nicely:
[image: 2017-04-18_13-12-12]
<https://cloud.githubusercontent.com/assets/1872600/25143506/b9449ab8-2438-11e7-890c-b47fb94b33fb.jpg>
You can access this TerriaJS example workflow accessing ncWMS2 here:
http://tinyurl.com/k2o8yyn
@yosoyjay <https://github.com/yosoyjay> and @kwilcox
<https://github.com/kwilcox>, would this be something you might be able
to tackle, if it sounds reasonable?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#86>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAJ6N4CZEBEihLBlRF4W17JpqQyQrKg_ks5rxO9fgaJpZM4NAoww>
.
|
I think Rich might be saying 'advertise palettes the old ncWMS way' as a
list of styles available on the server, because the ncWMS 2 way is tricky
to parse
eg ncWMS (old):
<Layer>
<Title>
Total Magnetic Intensity (TMI) Grid of Australia 2015 - sixth edition
</Title>
<Layer>
<Name>mag_tmi_anomaly</Name>
<Title>magnetic_total_magnetic_intensity_anomaly</Title>
<Abstract>magnetic_total_magnetic_intensity_anomaly</Abstract>
<EX_GeographicBoundingBox>
...
</EX_GeographicBoundingBox>
<BoundingBox CRS="CRS:84" minx="112.502949109" maxx="154.662098912" miny="
-43.928564539" maxy="-9.026078500000004"/>
<Style>
<Name>boxfill/alg</Name>
<Title>boxfill/alg</Title>
<Abstract>boxfill style, using the alg palette</Abstract>
<LegendURL width="110" height="264">
<Format>image/png</Format>
<OnlineResource xlink:type="simple" xlink:href="
http://dapds00.nci.org.au/thredds/wms/rr2/National_Coverages/magmap_v6_2015/magmap_v6_2015.nc?REQUEST=GetLegendGraphic&LAYER=mag_tmi_anomaly&PALETTE=alg
"/>
</LegendURL>
</Style>
...all the available styles...
</Layer>
…On 19 April 2017 at 05:22, Jesse Lopez ***@***.***> wrote:
Just to be clear, you'd like to be able to advertise the available palettes
via the GetCapabilities call even though it may be a bit tricky to parse?
On Tue, Apr 18, 2017 at 10:14 AM, Rich Signell ***@***.***>
wrote:
> As discussed here TerriaJS/terriajs#2200
> <TerriaJS/terriajs#2200>, generic WMS clients
> do not see the list of palettes advertised as styles, as ncWMS2 palettes
> are accessed through a custom getMetadata call.
>
> Would it be possible to also allow ncWMS2 service providers to advertise
> the palettes as styles also, or at least some subset of palettes?
>
> This would allow workflows like this TerriaJS one to work a lot more
> nicely:
> [image: 2017-04-18_13-12-12 <13%2012%2012>]
> <https://cloud.githubusercontent.com/assets/1872600/25143506/b9449ab8-
2438-11e7-890c-b47fb94b33fb.jpg>
>
> You can access this TerriaJS example workflow accessing ncWMS2 here:
> http://tinyurl.com/k2o8yyn
>
> @yosoyjay <https://github.com/yosoyjay> and @kwilcox
> <https://github.com/kwilcox>, would this be something you might be able
> to tackle, if it sounds reasonable?
>
> —
> You are receiving this because you were mentioned.
> Reply to this email directly, view it on GitHub
> <#86>, or
mute
> the thread
> <https://github.com/notifications/unsubscribe-auth/
AAJ6N4CZEBEihLBlRF4W17JpqQyQrKg_ks5rxO9fgaJpZM4NAoww>
> .
>
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#86 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AMel1lez-WnI4v2amjlwgYk2kOKCQzo-ks5rxQ1rgaJpZM4NAoww>
.
--
Adam Steer
http://au.linkedin.com/in/adamsteer
+61 427 091 712
skype: adam.d.steer
|
dang, need to add the second half! Thanks early morning fingers..
vs ncWMS2:
<Layer queryable="1">
<Name>FVCOM-NECOFS-GOM3/y</Name>
<Title>y</Title>
<Abstract>nodal y-coordinate</Abstract>
<EX_GeographicBoundingBox>
<westBoundLongitude>-75.68433380126953</westBoundLongitude>
<eastBoundLongitude>-56.850791931152344</eastBoundLongitude>
<southBoundLatitude>35.27653121948242</southBoundLatitude>
<northBoundLatitude>46.14595031738281</northBoundLatitude>
</EX_GeographicBoundingBox>
<BoundingBox CRS="CRS:84" minx="-75.68433380126953" maxx="
-56.850791931152344" miny="35.27653121948242" maxy="46.14595031738281"/>
<Style>
<Name>default-scalar/default</Name>
<Title>default-scalar/default</Title>
<Abstract>
default-scalar style, using the default palette. Available palettes can be
found in the response to
http://geoport.whoi.edu/ncWMS2/wms?request=GetMetadata&item=layerDetails&layerName=FVCOM-NECOFS-GOM3/y
</Abstract>
<LegendURL width="110" height="264">
<Format>image/png</Format>
<OnlineResource xlink:type="simple" xlink:href="
http://geoport.whoi.edu/ncWMS2/wms?REQUEST=GetLegendGraphic&PALETTE=default&LAYERS=FVCOM-NECOFS-GOM3/y&STYLES=default-scalar/default
"/>
</LegendURL>
</Style>
...only one or two more styles
</Layer>
...which lists a subset of available styles, where Rich wants to see all
the styles/colourmaps available per layer (like old ncWMS) in a front end
UI.
I can see how limiting styles per layer is a sane decision - it's also a
thing in Geoserver, which has different constraints (for example it doesn't
make sense to apply a line style to a raster).
I don't know whether it's ultimately worthwhile or not - adding a
getmetadata query to TerriaJS is likely not super difficult. Although
needing to parse JSON for the metadata response, and XML for all the other
stuff is a bit odd.
Not sure if I've helped :/
Regards
Adam
…On 19 April 2017 at 06:10, adam steer ***@***.***> wrote:
I think Rich might be saying 'advertise palettes the old ncWMS way' as a
list of styles available on the server, because the ncWMS 2 way is tricky
to parse
eg ncWMS (old):
<Layer>
<Title>
Total Magnetic Intensity (TMI) Grid of Australia 2015 - sixth edition
</Title>
<Layer>
<Name>mag_tmi_anomaly</Name>
<Title>magnetic_total_magnetic_intensity_anomaly</Title>
<Abstract>magnetic_total_magnetic_intensity_anomaly</Abstract>
<EX_GeographicBoundingBox>
...
</EX_GeographicBoundingBox>
<BoundingBox CRS="CRS:84" minx="112.502949109" maxx="154.662098912" miny="
-43.928564539" maxy="-9.026078500000004"/>
<Style>
<Name>boxfill/alg</Name>
<Title>boxfill/alg</Title>
<Abstract>boxfill style, using the alg palette</Abstract>
<LegendURL width="110" height="264">
<Format>image/png</Format>
<OnlineResource xlink:type="simple" xlink:href="http://
dapds00.nci.org.au/thredds/wms/rr2/National_Coverages/
magmap_v6_2015/magmap_v6_2015.nc?REQUEST=GetLegendGraphic&
LAYER=mag_tmi_anomaly&PALETTE=alg"/>
</LegendURL>
</Style>
...all the available styles...
</Layer>
On 19 April 2017 at 05:22, Jesse Lopez ***@***.***> wrote:
> Just to be clear, you'd like to be able to advertise the available
> palettes
> via the GetCapabilities call even though it may be a bit tricky to parse?
>
> On Tue, Apr 18, 2017 at 10:14 AM, Rich Signell ***@***.***>
> wrote:
>
> > As discussed here TerriaJS/terriajs#2200
> > <TerriaJS/terriajs#2200>, generic WMS clients
> > do not see the list of palettes advertised as styles, as ncWMS2 palettes
> > are accessed through a custom getMetadata call.
> >
> > Would it be possible to also allow ncWMS2 service providers to advertise
> > the palettes as styles also, or at least some subset of palettes?
> >
> > This would allow workflows like this TerriaJS one to work a lot more
> > nicely:
> > [image: 2017-04-18_13-12-12 <13%2012%2012>]
> > <https://cloud.githubusercontent.com/assets/1872600/
> 25143506/b9449ab8-2438-11e7-890c-b47fb94b33fb.jpg>
> >
> > You can access this TerriaJS example workflow accessing ncWMS2 here:
> > http://tinyurl.com/k2o8yyn
> >
> > @yosoyjay <https://github.com/yosoyjay> and @kwilcox
> > <https://github.com/kwilcox>, would this be something you might be able
> > to tackle, if it sounds reasonable?
> >
> > —
> > You are receiving this because you were mentioned.
> > Reply to this email directly, view it on GitHub
> > <#86>, or
> mute
> > the thread
> > <https://github.com/notifications/unsubscribe-auth/AAJ6N4CZE
> BEihLBlRF4W17JpqQyQrKg_ks5rxO9fgaJpZM4NAoww>
> > .
>
> >
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub
> <#86 (comment)>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AMel1lez-WnI4v2amjlwgYk2kOKCQzo-ks5rxQ1rgaJpZM4NAoww>
> .
>
--
Adam Steer
http://au.linkedin.com/in/adamsteer
+61 427 091 712 <0427%20091%20712>
skype: adam.d.steer
--
Adam Steer
http://au.linkedin.com/in/adamsteer
+61 427 091 712
skype: adam.d.steer
|
This was done to avoid GetCaps bloat. Did you try setting the |
I don't need all the palettes advertised as layers, just a few favorites! So like 12 layers instead of 4. If advertised palettes already does this, then great! I just thought that meant advertised in the non-standard, non-layer approach. And of course I'm not suggesting we abandon the new non-bloat approach to listing large numbers of palettes. Just that we allow a few more options for standardized clients. Basically I just want to allow users to select the good ol' rainbow palette. 😜 |
Ah ha. Thanks for filling in there. I go the opposite way, trying hard to
*not* let users select rainbow :)
|
@kwilcox wrote:
@guygriffiths, would If so, is there an example? I tried creating a custom
|
I'll give this a shot right now and see if I can get the setting to stick (and see what it actually does) |
The service starts fine with a config file like so: <?xml version='1.0' encoding='utf-8'?>
<Context>
<Parameter name="defaultPalette" value="div-RdBu" override="true"/>
<Parameter name="advertisedPalettes" value="div-RdBu,div-RdBu-inv,seq-cubeYF" override="true"/>
</Context> But does not change what is advertised in the GetCapabilities! |
@yosoyjay I traced it down to this:
Maybe the file we are creating in the docker container |
Yeah, $CATALINA_HOME/conf/Catalina/localhost/ncWMS.xml should be
$CATALINA_HOME/conf/Catalina/localhost/ncWMS2.xml
Testing now
…On Wed, Apr 19, 2017 at 11:59 AM, Kyle Wilcox ***@***.***> wrote:
@yosoyjay <https://github.com/yosoyjay> I traced it down to this:
1. GetCaps are templated from here
<https://github.com/Reading-eScience-Centre/edal-java/tree/master/wms/src/main/resources/templates>
2. availablePalettes seems to be set correctly here
<https://github.com/Reading-eScience-Centre/edal-java/blob/master/wms/src/main/java/uk/ac/rdg/resc/edal/wms/WmsServlet.java#L693>
.
3. advertisedPalettes seems to be build correctly here
<https://github.com/Reading-eScience-Centre/ncwms/blob/develop/src/main/java/uk/ac/rdg/resc/edal/ncwms/NcwmsServlet.java#L111-L120>
Maybe the file we are creating in the docker container
$CATALINA_HOME/conf/Catalina/localhost/ncWMS.xml isn't actually being
picked up for Servlet context?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#86 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAJ6NyKJsLWvWooHVHll60cGsOl8_JKqks5rxlmUgaJpZM4NAoww>
.
|
Since we deploy the webapp as |
As discussed here TerriaJS/terriajs#2200, generic WMS clients do not see the list of palettes advertised as styles, as ncWMS2 palettes are accessed through a custom getMetadata call.
Would it be possible to also allow ncWMS2 service providers to advertise the palettes as styles also, or at least some subset of palettes?
This would allow workflows like this TerriaJS one to work a lot more nicely:
You can access this TerriaJS example workflow accessing ncWMS2 here:
http://tinyurl.com/k2o8yyn
@yosoyjay and @kwilcox, would this be something you might be able to tackle, if it sounds reasonable?
The text was updated successfully, but these errors were encountered: