Hi Peter,
yes, in general the OGC service allow alternative formats for outputs,
although normally they are found for
data requests such as GetFeature/GetCoverage/GetMap. The capabilities
document must be supported in the mandated
XML variant, and a standard client will look for that format: there is less
incentive to support other formats.

That said, it's possible. Two considerations:

   - You'll have to hand write a JSON encoding for each protocol and
   version (cap documents can be very long, they are typically hand-crafted to
   avoid loading everything in memory)
   - OGC APIs (available as GeoServer community modules) are instead JSON
   native first, although still in flux specification wise
   - If you really want to go that way, I'd look around and see if any
   other project attempted that way, to avoid having multiple incompatible
   JSON variants out there.

Cheers
Andrea


On Mon, Nov 27, 2023 at 2:24 PM Peter Smythe <g...@smythe.co.za> wrote:

> Hi Devs
>
> I notice from
> https://docs.geoserver.org/latest/en/user/services/wms/reference.html#getcapabilities
> <https://fdfdfha.r.bh.d.sendibt3.com/tr/cl/qwFYJc6vj9iZFKooG8ilw9cl-4hWdtuXAwFshG5ZuD4EVZPMILjbVKV8c67D860ziMnSNBdF0epP-ekoU3IYQfUX4ts9rF4EZaLCMkn3DLWLAjReuY99f33Im914lOHEPnwKsWVtvJYnS1Ocde9KUikuooVMwxwfzTK4CYdwelitjfZXWV81AA5_J9nf-nYAA0WqxyoGRQPlvg6uBdHp5Y5gvQfbBOaPDoie65Ga2Puj0ZCOyuPO3WkS_rj7_97bjjerqnoJjdrglNIytMEync7BBMbMQX10_t-E918eQW6tvnXka5BCI-uh6-GtRifMNBwdotNMvtR3gFYmuwAnUQV1vt39KiFjEbEIxl95sqoM0Drk3sMqphpPnVgpE9na>
> and
> https://docs.geoserver.org/latest/en/user/services/wms/vendor.html#getcapabilities-request
> <https://fdfdfha.r.bh.d.sendibt3.com/tr/cl/OHBiJtDmML9l0e7aw-4eY1smv1h74I6YMh3UYbLcwPpEXKD3RnEC1N3LsHfh04vgyS5LrQby7DXGknIDO7910ZDvbhiBkuG3Tyg-JlyXH9h2nxfUV9-azdmoZ7Au-xeLwF4Ie-XMHaJ0xum3j8P4cFvxhSN5b2U2sc1g2jBPeu-URfS-ZThHNIwSMohEkKuRq0YuxD1ZpeUmZuBaImD8ba1ZM0FLHmib3PN_A_qE1s13PNctNlgnAK5avUcPQA1HprIrVpMGypjb0p7-4fIRid03YsC40cRf4SiPnfFI94RBvZDq3tRYL7kJDeTr0VSj_DTGhpytrBTxjrbE0CIpdhzkmx_zIWUYQQLEk0SOt8Xeh7XLH3PduLIR9TawzIAUqGxIH9Y>
> that XML is the only response format option for the GetCapabilities call,
> and I wonder why that is, and if it is technically not possible to return
> the response in application/json format?
>
> I am sure that the OGC spec states XML only, but can JSON be supported as
> a vendor option?
>
> Is there just insufficient demand for the format?
>
> If I wanted to implement this format, can you give me any pointers?  Is
> GetCapabilitiesTransformer.java only for XML and would need an equivalent
> for JSON?
>
> Thanks
>
> Peter
> _______________________________________________
> Geoserver-devel mailing list
> geoserver-de...@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geoserver-devel
>


-- 

Regards,

Andrea Aime

==
GeoServer Professional Services from the experts!

Visit http://bit.ly/gs-services-us for more information.
==

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions Group
phone: +39 0584 962313

fax:     +39 0584 1660272

mob:   +39  339 8844549

https://www.geosolutionsgroup.com/

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
_______________________________________________
GeoTools-Devel mailing list
GeoTools-Devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to