AH, missed that part

Chris Snider
Senior Software Engineer
Intelligent Software Solutions, A Polaris Alpha Company
[Description: Description: Description: cid:[email protected]]

From: Torben Barsballe [mailto:[email protected]]
Sent: Tuesday, July 11, 2017 2:29 PM
To: Chris Snider <[email protected]>
Cc: Jody Garnett <[email protected]>; Andrea Aime 
<[email protected]>; GeoServer 
<[email protected]>
Subject: Re: [Geoserver-devel] GSIP 161



On Tue, Jul 11, 2017 at 1:17 PM, Chris Snider 
<[email protected]<mailto:[email protected]>> wrote:
I know there is a recalculate REST endpoint we use when we upload new files 
through our process.

Using this XML and endpoint

<featureType>
         <enabled>%s</enabled>
         <advertised>%s</advertised>
         <maxFeatures>0</maxFeatures>
         <numDecimals>0</numDecimals>
</featureType>"


String path = 
String.format("rest/workspaces/%s/datastores/%s/featuretypes/%s.xml", 
workspace, dataStore, layerName);

Map<String, String> queryParams = new HashMap<>();
queryParams.put("recalculate", "nativebbox,latlonbbox");

And process as a PUT request

Documented at
http://docs.geoserver.org/stable/en/user/rest/api/featuretypes.html#rest-api-featuretypes-recalculate


That is just for the featuretypes endpoint though, so while quite useful for 
dealing with layers, doesn't help with recalculating LayerGroup bounds (as is 
being discussed here). I don't think there is an equivalent for LayerGroups yet.

Torben
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to