Re: [Geoserver-users] Interceptor for OWS service in custom plugin

2020-06-14 Thread Andrea Aime
Hi Yang,
yes there is, it's called DispatcherCallback

.
If you look at the inheritance hierarchy in a IDE, you'll find numerous
usages, both
for monitoring requests and altering them.

Cheers
Andrea

On Mon, Jun 15, 2020 at 3:24 AM Yang  wrote:

> Is it possible to create a geoserver plugin which can intercept the ows
> request and response.
>
> For example, for a given GetMap/GetFeature request, I can add extra
> parameters(like cql,bbox and etc) dynamically before geoserver execute the
> request. Just like the servlet filter mechanism.
> ___
> Geoserver-users mailing list
>
> Please make sure you read the following two resources before posting to
> this list:
> - Earning your support instead of buying it, but Ian Turton:
> http://www.ianturton.com/talks/foss4g.html#/
> - The GeoServer user list posting guidelines:
> http://geoserver.org/comm/userlist-guidelines.html
>
> If you want to request a feature or an improvement, also see this:
> https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer
>
>
> Geoserver-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>


-- 

Regards, Andrea Aime

== GeoServer Professional Services from the experts! Visit
http://goo.gl/it488V for more information. == Ing. Andrea Aime @geowolf
Technical Lead GeoSolutions S.A.S. Via di Montramito 3/A 55054 Massarosa
(LU) phone: +39 0584 962313 fax: +39 0584 1660272 mob: +39 339 8844549
http://www.geo-solutions.it http://twitter.com/geosolutions_it
--- *Con riferimento
alla normativa sul trattamento dei dati personali (Reg. UE 2016/679 -
Regolamento generale sulla protezione dei dati “GDPR”), si precisa che ogni
circostanza inerente alla presente email (il suo contenuto, gli eventuali
allegati, etc.) è un dato la cui conoscenza è riservata al/i solo/i
destinatario/i indicati dallo scrivente. Se il messaggio Le è giunto per
errore, è tenuta/o a cancellarlo, ogni altra operazione è illecita. Le
sarei comunque grato se potesse darmene notizia. This email is intended
only for the person or entity to which it is addressed and may contain
information that is privileged, confidential or otherwise protected from
disclosure. We remind that - as provided by European Regulation 2016/679
“GDPR” - copying, dissemination or use of this e-mail or the information
herein by anyone other than the intended recipient is prohibited. If you
have received this email by mistake, please notify us immediately by
telephone or e-mail.*
___
Geoserver-users mailing list

Please make sure you read the following two resources before posting to this 
list:
- Earning your support instead of buying it, but Ian Turton: 
http://www.ianturton.com/talks/foss4g.html#/
- The GeoServer user list posting guidelines: 
http://geoserver.org/comm/userlist-guidelines.html

If you want to request a feature or an improvement, also see this: 
https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer


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


Re: [Geoserver-users] Interceptor for OWS service in custom plugin

2020-06-14 Thread Jody Garnett
The codebase is usually one level deeper, there are a callback for
individual components that handle the request once it has been parsed.

In the specific case of WMS there is a "wms reflector" which provides an
end point that fills in extra or missing parameters with good defaults and
then call over to WMS.

- https://docs.geoserver.org/stable/en/user/tutorials/wmsreflector.html

If you want you could make a similar one for WFS :)
--
Jody Garnett


On Sun, 14 Jun 2020 at 18:13, Yang  wrote:

> Is it possible to create a geoserver plugin which can intercept the ows
> request and response.
>
> For example, for a given GetMap/GetFeature request, I can add extra
> parameters(like cql,bbox and etc) dynamically before geoserver execute the
> request. Just like the servlet filter mechanism.
> ___
> Geoserver-users mailing list
>
> Please make sure you read the following two resources before posting to
> this list:
> - Earning your support instead of buying it, but Ian Turton:
> http://www.ianturton.com/talks/foss4g.html#/
> - The GeoServer user list posting guidelines:
> http://geoserver.org/comm/userlist-guidelines.html
>
> If you want to request a feature or an improvement, also see this:
> https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer
>
>
> Geoserver-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>
___
Geoserver-users mailing list

Please make sure you read the following two resources before posting to this 
list:
- Earning your support instead of buying it, but Ian Turton: 
http://www.ianturton.com/talks/foss4g.html#/
- The GeoServer user list posting guidelines: 
http://geoserver.org/comm/userlist-guidelines.html

If you want to request a feature or an improvement, also see this: 
https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer


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


[Geoserver-users] Interceptor for OWS service in custom plugin

2020-06-14 Thread Yang
Is it possible to create a geoserver plugin which can intercept the ows request 
and response.


For example, for a given GetMap/GetFeature request, I can add extra 
parameters(like cql,bbox and etc) dynamically before geoserver execute the 
request. Just like the servlet filter mechanism.___
Geoserver-users mailing list

Please make sure you read the following two resources before posting to this 
list:
- Earning your support instead of buying it, but Ian Turton: 
http://www.ianturton.com/talks/foss4g.html#/
- The GeoServer user list posting guidelines: 
http://geoserver.org/comm/userlist-guidelines.html

If you want to request a feature or an improvement, also see this: 
https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer


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


Re: [Geoserver-users] SRS is incorrect when creating app-schema layer from a PostGIS database

2020-06-14 Thread Nuno Oliveira
Hi,
explicitly setting the default geometry should do the trick:
https://docs.geoserver.org/stable/en/user/data/app-schema/mapping-file.html#mappings

Something likes this:



mappedfeature1
datastore
mappedfeature
gsml:MappedFeature
true


*gsml:MappedFeature/gsml:shape/gml:Polygon*Hope
it helps, otherwise feel free to open a JIRA ticket, make sure you
describe your mapping and target GML, as well the table definition.

Best regards,
Nuno Oliveira


On Mon, May 25, 2020 at 9:39 AM Lindström Karl 
wrote:

> I have PostGIS database with a table that was exported from a shapefile
> using shp2pgsql. I have verified that the SRID is correct by querying the
> geometry_columns table.
>
> If I use this database table as a data source in Geoserver and create a
> layer from it everything works as expected and the correct SRS is set on
> the layer.
>
> However, when I try to create an app-schema mapping using this table (I'm
> creating the mapping in Hale and exporting it using the direct upload
> method) the correct CRS is not picked up by Geoserver. Instead the Native
> SRS is emtpy and the Declared SRS is EPSG:404000. I also don't get any
> position elements if I preview the GML. I'm assuming this is because the
> SRS is incorrect, but I get the same problem even if I declare the correct
> SRS and use the "Force declared" option.
>
> I think the problem is related to app-schema because if I import the data
> in Hale the correct SRS gets used and if I do a transformation in Hale the
> resulting GML contains position elements for each feature.
>
> Does anyone know what the problem could be?
>
> I'm running Geoserver 2.17.0 on RHEL 8 using Java 1.8.0_252.
>
> Regards,
> Karl Lindström
>
> ___
> Geoserver-users mailing list
>
> Please make sure you read the following two resources before posting to
> this list:
> - Earning your support instead of buying it, but Ian Turton:
> http://www.ianturton.com/talks/foss4g.html#/
> - The GeoServer user list posting guidelines:
> http://geoserver.org/comm/userlist-guidelines.html
>
> If you want to request a feature or an improvement, also see this:
> https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer
>
>
> Geoserver-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>


-- 
Regards,
Nuno Oliveira
==
GeoServer Professional Services from the experts!
Visit http://goo.gl/it488V for more information.
==

Nuno Miguel Carvalho Oliveira
@nmcoliveira
Software Engineer

GeoSolutions S.A.S.
Via di Montramito 3/A
55054  Massarosa (LU)
Italy
phone: +39 0584 962313
fax:  +39 0584 1660272

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

---

Con riferimento alla normativa sul trattamento dei dati
personali (Reg. UE 2016/679 - Regolamento generale sulla
protezione dei dati “GDPR”), si precisa che ogni
circostanza inerente alla presente email (il suo contenuto,
gli eventuali allegati, etc.) è un dato la cui conoscenza
è riservata al/i solo/i destinatario/i indicati dallo
scrivente. Se il messaggio Le è giunto per errore, è
tenuta/o a cancellarlo, ogni altra operazione è illecita.
Le sarei comunque grato se potesse darmene notizia.

This email is intended only for the person or entity to
which it is addressed and may contain information that
is privileged, confidential or otherwise protected from
disclosure. We remind that - as provided by European
Regulation 2016/679 “GDPR” - copying, dissemination or
use of this e-mail or the information herein by anyone
other than the intended recipient is prohibited. If you
have received this email by mistake, please notify
us immediately by telephone or e-mail.
___
Geoserver-users mailing list

Please make sure you read the following two resources before posting to this 
list:
- Earning your support instead of buying it, but Ian Turton: 
http://www.ianturton.com/talks/foss4g.html#/
- The GeoServer user list posting guidelines: 
http://geoserver.org/comm/userlist-guidelines.html

If you want to request a feature or an improvement, also see this: 
https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer


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