[Geoserver-users] Adding CoverageStores programmatically

Hi,

I have a large number of World Image files to add to my GeoServer instance. Is there a command line bulk loader, or an easy way to do this programmatically (in Java, presumably)?

Thanks!

Greg

--
| E R G O N O S I S
| Greg Ederer
| Lead Developer
| greg@anonymised.com
| 360.774.6848
|

Hi Greg,

Unfortunately not. The way people do this sort of thing is to write their own little scripts that generate out the catalog.xml file, as well as the info.xml for all the individual coverages.

Not ideal, I know, but something we are working on. There is work going on currently to build a rest api for this sort of programmatic configuration, but its still pretty alpha at this point.

-Justin

Greg Ederer wrote:

Hi,

I have a large number of World Image files to add to my GeoServer instance. Is there a command line bulk loader, or an easy way to do this programmatically (in Java, presumably)?

Thanks!

Greg

--
Justin Deoliveira
Software Engineer, OpenGeo
http://opengeo.org

Hi Justin,

Does GeoServer perform some sort of transformation of the raster data when I add it to the server using the web interface? Or, is it just a question of putting the data files in an accessible directory, and making entries in the XML files? If it's the latter, it should be a piece of cake for me to write a script.

Thanks!

Greg

Justin Deoliveira wrote:

Hi Greg,

Unfortunately not. The way people do this sort of thing is to write their own little scripts that generate out the catalog.xml file, as well as the info.xml for all the individual coverages.

Not ideal, I know, but something we are working on. There is work going on currently to build a rest api for this sort of programmatic configuration, but its still pretty alpha at this point.

-Justin

Greg Ederer wrote:

Hi,

I have a large number of World Image files to add to my GeoServer instance. Is there a command line bulk loader, or an easy way to do this programmatically (in Java, presumably)?

Thanks!

Greg

--
| E R G O N O S I S
| Greg Ederer
| Lead Developer
| greg@anonymised.com
| 360.774.6848
|

There is no transformation per se... but there are things that are inferred from the raster, like its reference system, extend, dimensions, etc... So if you have all that information around then its just a matter of putting the data files in the right place and generating the files.

Although some of the above properties if not located in the file will be autogenerated.... but i am not 100% sure. The coverage experts should know more about that.

-Justin

Greg Ederer wrote:

Hi Justin,

Does GeoServer perform some sort of transformation of the raster data when I add it to the server using the web interface? Or, is it just a question of putting the data files in an accessible directory, and making entries in the XML files? If it's the latter, it should be a piece of cake for me to write a script.

Thanks!

Greg

Justin Deoliveira wrote:

Hi Greg,

Unfortunately not. The way people do this sort of thing is to write their own little scripts that generate out the catalog.xml file, as well as the info.xml for all the individual coverages.

Not ideal, I know, but something we are working on. There is work going on currently to build a rest api for this sort of programmatic configuration, but its still pretty alpha at this point.

-Justin

Greg Ederer wrote:

Hi,

I have a large number of World Image files to add to my GeoServer instance. Is there a command line bulk loader, or an easy way to do this programmatically (in Java, presumably)?

Thanks!

Greg

--
Justin Deoliveira
Software Engineer, OpenGeo
http://opengeo.org

I'm not a GeoServer developer, but I think I can answer this:

From my observation, GeoServer does nothing to the files themselves. You may even set up your filesystem so that the 'user' executing your servlet container has no write rights to the files in question. If you make the entries in the XML config file, you must reload the catalog to the running webapp, which can be done with simple Web service calls. If I'm not mistaken, you can use /geoserver/admin/login.do and /geoserver/admin/loadFromXML.do. I understand that one of the long-range projects for GeoServer is to recode the config structure in a more sophisticated way:

http://geoserver.org/display/GEOS/Roadmap
(see "New Configuration System")

and more immediately, to provide RESTful access to config:

http://geoserver.org/display/GEOSDOC/RESTful+Configuration+API

You must be sure that your files are in a form that your version of GeoServer can handle. WorldImage is safe because it is one of the base types that GeoServer can handle without extra code.

---
A. Soroka / Digital Scholarship Services R & D
the University of Virginia Library

On Aug 13, 2008, at 8:31 PM, Greg Ederer wrote:

Hi Justin,

Does GeoServer perform some sort of transformation of the raster data
when I add it to the server using the web interface? Or, is it just a
question of putting the data files in an accessible directory, and
making entries in the XML files? If it's the latter, it should be a
piece of cake for me to write a script.

Thanks!

Greg

Justin Deoliveira wrote:

Hi Greg,

Unfortunately not. The way people do this sort of thing is to write
their own little scripts that generate out the catalog.xml file, as
well as the info.xml for all the individual coverages.

Not ideal, I know, but something we are working on. There is work
going on currently to build a rest api for this sort of programmatic
configuration, but its still pretty alpha at this point.

-Justin

Greg Ederer wrote:

Hi,

I have a large number of World Image files to add to my GeoServer
instance. Is there a command line bulk loader, or an easy way to do
this programmatically (in Java, presumably)?

Thanks!

Greg

--
| E R G O N O S I S
| Greg Ederer
| Lead Developer
| greg@anonymised.com
| 360.774.6848
|

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Hello,

This can be done using Java and HTTP.

http://www.olympianengine.com/tutorials/geoserver/index.html

There used to be a GeoServer tutorial that the above page was based on, but
didn't find it with a cursory 'google'.

Good Luck,
-Sam

gederer wrote:

Hi,

I have a large number of World Image files to add to my GeoServer
instance. Is there a command line bulk loader, or an easy way to do
this programmatically (in Java, presumably)?

Thanks!

Greg

--
| E R G O N O S I S
| Greg Ederer
| Lead Developer
| greg@anonymised.com
| 360.774.6848
|

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's
challenge
Build the coolest Linux based applications with Moblin SDK & win great
prizes
Grand prize is a trip for two to an Open Source event anywhere in the
world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
View this message in context: http://www.nabble.com/Adding-CoverageStores-programmatically-tp18973309p19034750.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

Thanks, Sam! I will definitely give this a go.

Cheers,

Greg

SamuelToepke wrote:

ยทยทยท
-- 
| E R G O N O S I S
| Greg Ederer
| Lead Developer
| [greg@anonymised.com](mailto:greg@anonymised.com)
| 360.774.6848
|