Hi all!
I would like to contribute a few enhancements to the script community module. Justin already has really nice rest config support for WPS scripts. You can currently list WPS scripts, get a WPS script, and add or update a WPS script. I would like to add the ability to delete WPS scripts. And I would like to extend rest config support to other script extension points: apps, functions, and wfs transactions. The current rest config support also only support JSON as a return type, I would like add support for XML and HTML. Here is a pull request that implements all of these changes (with unit tests):
https://github.com/geoserver/geoserver/pull/556
and JIRA issue:
https://jira.codehaus.org/browse/GEOS-6439
This does break backwards compatibility because the default rest config url returns HTML instead of JSON and the JSON format has changed. Also, this is my first attempt at working with GeoServer rest config, so I am completely open to suggestions. My rationale for this work, is that currently, you need to edit scripts on the server. With these changes you can use GeoServer's rest api. This should make using the script module easier. In the future it would be really nice to have a UI, but that can come later.
Thanks,
Jared
Awesome stuff Jared! I think all the changes make sense. Can you include a quick sample of what the JSON output looks like now?
With regards to backward compatibility that is fine. I don’t know of many folks if any who are tied to the current api, and regardless it is still a community module so we still have freedom to make such changes.
Great stuff!
···
On Mon, Apr 7, 2014 at 8:59 PM, Jared Erickson <jared.erickson@anonymised.com> wrote:
Hi all!
I would like to contribute a few enhancements to the script community module. Justin already has really nice rest config support for WPS scripts. You can currently list WPS scripts, get a WPS script, and add or update a WPS script. I would like to add the ability to delete WPS scripts. And I would like to extend rest config support to other script extension points: apps, functions, and wfs transactions. The current rest config support also only support JSON as a return type, I would like add support for XML and HTML. Here is a pull request that implements all of these changes (with unit tests):
https://github.com/geoserver/geoserver/pull/556
and JIRA issue:
https://jira.codehaus.org/browse/GEOS-6439
This does break backwards compatibility because the default rest config url returns HTML instead of JSON and the JSON format has changed. Also, this is my first attempt at working with GeoServer rest config, so I am completely open to suggestions. My rationale for this work, is that currently, you need to edit scripts on the server. With these changes you can use GeoServer’s rest api. This should make using the script module easier. In the future it would be really nice to have a UI, but that can come later.
Thanks,
Jared
Put Bad Developers to Shame
Dominate Development with Jenkins Continuous Integration
Continuously Automate Build, Test & Deployment
Start a new project now. Try Jenkins in the cloud.
http://p.sf.net/sfu/13600_Cloudbees
Geoserver-devel mailing list
Geoserver-devel@anonymised.comsts.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel
–
Justin Deoliveira
Vice President, Engineering | Boundless
jdeolive@anonymised.com
@j_deolive
Thanks Justin! The JSON looks like:
{
“scripts”:{
“script”:[
{
“name”:“buffer.groovy”,
“href”:“http://localhost:8080/geoserver/rest/scripts/wps/buffer.groovy”
},
{
“name”:“centroid.groovy”,
“href”:“http://localhost:8080/geoserver/rest/scripts/wps/centroid.groovy”
}
]
}
}
and the XML looks like:
Both formats are very similar to other GeoServer restful endpoints.
Jared
···
On Mon, Apr 7, 2014 at 8:59 PM, Jared Erickson <jared.erickson@anonymised.com> wrote:
Hi all!
I would like to contribute a few enhancements to the script community module. Justin already has really nice rest config support for WPS scripts. You can currently list WPS scripts, get a WPS script, and add or update a WPS script. I would like to add the ability to delete WPS scripts. And I would like to extend rest config support to other script extension points: apps, functions, and wfs transactions. The current rest config support also only support JSON as a return type, I would like add support for XML and HTML. Here is a pull request that implements all of these changes (with unit tests):
https://github.com/geoserver/geoserver/pull/556
and JIRA issue:
https://jira.codehaus.org/browse/GEOS-6439
This does break backwards compatibility because the default rest config url returns HTML instead of JSON and the JSON format has changed. Also, this is my first attempt at working with GeoServer rest config, so I am completely open to suggestions. My rationale for this work, is that currently, you need to edit scripts on the server. With these changes you can use GeoServer’s rest api. This should make using the script module easier. In the future it would be really nice to have a UI, but that can come later.
Thanks,
Jared
Put Bad Developers to Shame
Dominate Development with Jenkins Continuous Integration
Continuously Automate Build, Test & Deployment
Start a new project now. Try Jenkins in the cloud.
http://p.sf.net/sfu/13600_Cloudbees
Geoserver-devel mailing list
Geoserver-devel@anonymised.comsts.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel
–
Justin Deoliveira
Vice President, Engineering | Boundless
jdeolive@anonymised.com
@j_deolive