
452
|
Chapter 8, Building the Geospatial Web
#89 Publish Your Geodata to the Web with GeoServer
HACK
Next go to the FeatureType page and hit New. The tables of your PostGIS
database should show up appended to the DataStore ID that you gave your
newly created Store. Select one that you would like to make available to the
geospatial web.
After hitting New, you will be taken to the FeatureTypeEditor screen. This
information is primarily for the Capabilities document; it is the meta-infor-
mation about the FeatureType. The SRS is probably the most important
field; it should be an EPSG number—a serial number allocated by the Euro-
pean Petroleum Survey Group—for the projection of your data. You can
also edit the schema information to hide certain attributes and to make oth-
ers mandatory. GeoServer generates the DescribeFeatureType responses
automatically, depending on how you configure these attributes. After edit-
ing your feature, submit it and click Apply. Your feature should then show
up in the Capabilities documents for WMS and WFS, and you can even
query it.
If in doubt, you can use an SRS of EPSG:4326, which corre-
sponds to geographic coordinates (i.e. lat/long) referenced to
the WGS84 spheroid and datum. If you need to use a differ-
ent spatial reference system, try looking through the con-
tents of the
spatial_ref_sys table in your PostGIS database
to see what other EPSG codes are standard.
Viewing ...