Skip to main content
===============
featureserver
===============

---------------------------------------
Simple Python geographic feature server
---------------------------------------

:Author: labs@metacarta.com
:Date: 2008-05-06
:Version: 1.12
:Manual group: GIS Utilities

DESCRIPTION
===========
FeatureServer is a simple Python-based geographic feature server. It allows
you to store geogrpahic vector features in a number of different backends,
and interact with them -- creating, updating, and deleting -- via a
REST-based API.

FeatureServer will run under Python CGI, mod_python, or as a standalone server.

FeatureServer was designed as a companion to OpenLayers, the BSD licensed web
mapping interface. For help with setting up FeatureServer for use with
OpenLayers, please feel free to stop by #featureserver, on irc.freenode.net, or
to send email to featureserver@featureserver.org.

FeatureServer is released under a copyright only open source license similar
to the BSD license.

RUNNING UNDER CGI
=================

* Extract the code to some web directory (e.g. in /var/www).
* Edit featureserver.cfg to point the 'file' attribute of the 'scribble'
datasource to the location you wish to save your database.
* Permit CGI execution in the FeatureServer directory.
For example, if FeatureServer is to be run with Apache, the
following must be added in your Apache configuration,
where /var/www/featureserver is the directory resulting from
the code extraction.

::

<Directory /var/www/featureserver>
AddHandler cgi-script .cgi
Options +ExecCGI
</Directory>

* Visit:

http://example.com/yourdir/featureserver.cgi/scribble/all.atom

* If you see an empty GeoRSS feed, you have set up your configuration
correctly. Congrats!

Python Prerequisites
--------------------
In order to use the default demo included with FeatureServer, you must have
the simplejson module installed. If you do not, you can add it by doing the
following:

$ wget http://cheeseshop.python.org/packages/source/s/simplejson/simplejson-1.7.1.tar.gz
$ tar -zvxf simplejson-1.7.1.tar.gz
$ cp -r simplejson-1.7.1/simplejson /var/www/featureserver

Note that these instructions are for Linux systems: the end goal is to extract
the simplejson directory from the distribution and put it in the root of your
FeatureServer install.

Other dependancies for DataSources and Services are outlined in their
respective documentation files.

Non-standard Python Location
----------------------------
If your Python is not at /usr/bin/python on your system, you will need to
change the first line of featureserver.cgi to reference the location of your
Python binary. A common example is:

::

#!/usr/local/bin/python

Under Apache, you might see an error message like:

::

[Wed Mar 14 19:55:30 2007] [error] [client 127.0.0.1] (2)No such file or
directory: exec of '/www/featureserver.cgi' failed

to indicate this problem.

You can typically locate where Python is installed on your system via the
command 'which python'.

Windows users: If you are using Windows, you should change the first line
of featureserver.cgi to read:

::

#!C:/Python/python.exe -u

C:/Python should match the location Python is installed under on your
system. In Python 2.5, this location is C:/Python25 by default.

RUNNING UNDER MOD_PYTHON
========================

* Extract the code to some web directory (e.g. /var/www).
* Edit featureserver.cfg to point the 'file' attribute of the 'scribble'
datasource to the location you wish to save your database.
* Add the following to your Apache configuration, under a <Directory> heading:

::

AddHandler python-program .py
PythonPath sys.path+['/path/to/featureserver/FeatureServer', '/path/to/featureserver']
PythonHandler FeatureServer.Server
PythonOption FeatureServerConfig /path/to/featureserver.cfg

* An example might look like:

::

<Directory /var/www/featureserver/>
AddHandler python-program .py
PythonPath sys.path+['/var/www/featureserver/FeatureServer', '/var/www/featureserver']
PythonHandler FeatureServer.Server
PythonOption FeatureServerConfig /var/www/featureserver/featureserver.cfg
</Directory>

* In this example, /var/www/featureserver is the directory resulting from
the code extraction.
* Visit the URL described above, replacing featureserver.cgi with
featureserver.py
* If you see an empty GeoRSS file you have set up your configuration correctly.
Congrats!
* Note that mod_python has not yet been well tested, and may not work well
for all data sources.


RUNNING STANDALONE (UNDER WSGI)
===============================

FeatureServer comes with a standalone HTTP server which uses the WSGI handler.
This implementation depends on *Python Paste*, which can be downloaded from:

http://cheeseshop.python.org/pypi/Paste

For versions of Python earlier than 2.5, you will also need to install
wsgiref:

http://cheeseshop.python.org/pypi/wsgiref

Once you have all the prerequisites installed, simply run:

::

python featureserver_http_server.py

This will start a webserver listening on port 8080, after which you should
be able to open:

::

http://hostname:8080/scribble/all.atom

to see your first file.

RUNNING UNDER FASTCGI
=====================

FeatureServer comes with a fastcgi implementation. In order to use this
implementation, you will need to install flup, available from:

http://trac.saddi.com/flup

This implementation also depends on Python Paste, which can be downloaded
from:

http://cheeseshop.python.org/pypi/Paste

Once you have done this, you can configure your fastcgi server to use
featureserver.fcgi.

Configuring FastCGI is beyond the scope of this documentation.

CONFIGURATION
=============
FeatureServer is configured by a config file, defaulting to featureserver.cfg.
FeatureServer data source documentation is available in doc/DataSources.

USING FEATURESERVER WITH OPENLAYERS
===================================

To run OpenLayers with FeatureServer, the URL passed to the
OpenLayers.Layer.WFS constructor must point to the FeatureServer script,
i.e. featureserver.cgi or featureserver.py. As an example see the
index.html file included in the FeatureServer distribution.

Note: index.html assumes FeatureServer is set up under CGI (see above).
If you set up FeatureServer under mod_python you'd need to slighly
modify index.html: the URL passed to the OpenLayers.Layer.WFS constructor
must point to the mod_python script as opposed to the CGI script, so replace
featureserver.cgi with featureserver.py. Similarly, you would need to edit
this URL if you were to use FeatureServer with the standalone HTTP Server
or FastCGI.

SEE ALSO
========

http://featureserver.org/

http://openlayers.org/

Metadata

Release files for FeatureServer 1.12

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for FeatureServer 1.12
File Size Uploaded Provenance Actions
FeatureServer-1.12.tar.gz 28.4 kB Without provenance Details for FeatureServer-1.12.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for FeatureServer 1.12
File Interpreter ABI Platform Actions
FeatureServer-1.12-py2.5.egg Legacy Egg format - - Details for FeatureServer-1.12-py2.5.egg
FeatureServer-1.12-py2.4.egg Legacy Egg format - - Details for FeatureServer-1.12-py2.4.egg

Total release size: 231.2 kB

Release files / FeatureServer-1.12.tar.gz

Download URL FeatureServer-1.12.tar.gz
Size 28.4 kB
Tags Source
SHA-256 checksum
How to use checksums
a97ad970d1b8e2b0221820f311128dc0c135a4b43eb53439fa6e41908e790a39
BLAKE2b-256 checksum
How to use checksums
109a6a03e1c09ce1b05df816dc1eab62f33e171897eb8d34ac6d15aad197b4a4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / FeatureServer-1.12-py2.5.egg

Download URL FeatureServer-1.12-py2.5.egg
Size 100.6 kB
Tags Egg
SHA-256 checksum
How to use checksums
615e7c5065b20f86cff8e25918563b2335b53f69ddba6f4e5697f8c056030686
BLAKE2b-256 checksum
How to use checksums
7a676aa457870911854ab98f5d448d5aa7b49c74a9b5b1eaa970b40923a909d0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / FeatureServer-1.12-py2.4.egg

Download URL FeatureServer-1.12-py2.4.egg
Size 102.1 kB
Tags Egg
SHA-256 checksum
How to use checksums
3dfb098f7c59f39aae29f4c13afd9086c00118e89a638282894068ee69ddca73
BLAKE2b-256 checksum
How to use checksums
6938a6acb00c1bbb4faa6fa218eae16f6d137981ae81abcb6017501a5e985267
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for FeatureServer 1.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.12 This release

3 release files No provenance

1.06

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page