Skip to main content

Service that creates tilesets from layer sources and serves them

Project description

Geoserver Schema
A service that allows users to upload/download the geoserver schema.xsd files associated with each layer. More specifically, gsschema is a [Django][1] application which uses the [GeoServer][2] rest api to retrieve the list of layers and then associate a layer with a schema file provided by the user. The schema.xsd file describes a featureType by listing all its attributs as well as the type associated with attribute. The GeoSHAPE project uses the schema file to specify the drop down choices for a given attribute as well as an optional way to indicate that a particular attribute should be populated using datetime picker in [MapLoom][6] (web client) and [Arbiter][5] (mobile client).It is an open-source application that has been developed under the [ROGUE][4] project and is part of the [GeoSHAPE][3] eco-system.

- A "normal" schema can be defined as such:

<?xml version="1.0" encoding="UTF-8"?><xsd:schema xmlns:xsd="" xmlns:geonode="" xmlns:gml="" elementFormDefault="qualified" targetNamespace="">
<xsd:import namespace="" schemaLocation="http://<VM IP Address>/geoserver/schemas/gml/3.1.1/base/gml.xsd"/>
<xsd:complexType name="Hospitals1Type">
<xsd:extension base="gml:AbstractFeatureType">
<xsd:element maxOccurs="1" minOccurs="0" name="geometry" nillable="true" type="gml:PointPropertyType"/>
<xsd:element maxOccurs="1" minOccurs="0" name="name" nillable="true" type="xsd:string"/>
<xsd:element maxOccurs="1" minOccurs="0" name="status" nillable="true">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="open"/>
<xsd:enumeration value="closed"/>
<xsd:element maxOccurs="1" minOccurs="0" name="number_of_beds_available" nillable="true" type="xsd:long"/>
<xsd:element maxOccurs="1" minOccurs="0" name="number_of_beds_total" nillable="true" type="xsd:long"/>
<xsd:element maxOccurs="1" minOccurs="0" name="fotos" nillable="true" type="xsd:string"/>
<xsd:element name="Hospitals1" substitutionGroup="gml:_Feature" type="geonode:Hospitals1Type"/>

- The main lines that are going to be edited are the 'xsd:element' sections.
- The attribute 'type' inside the 'xsd:element' has many options, such as the following:
- 'xsd:date'
- 'xsd:dateTime'
- 'xsd:long'
- 'xsd:string'
- Any other supported 'xsd' type.

API Quick Guide
Since schemas are already created (and each layer is using their own respective schema on MapLoom), GSSchema gives the user the ability to edit any available schema.
To start, you can log onto GSSchema:

*The user **_must_** be logged into GeoSHAPE.*


You will be presented with a dropdown list, containing each layer that Geonode holds.
One a layer is selected, a few action buttons will be presented. These buttons are listed in order of a normal use of GSSchema.

*Describe FeatureType*
This button will allow you to download the schema that is currently being used for the selected layer. After downloading the schema, any text editor can be used to edit the schema and be uploaded with the next button. Editing tips will be covered in [this document][7].

Once a file is chosen for upload, this button will be enabled. This will upload the schema to Geoserver (while immediately reflecting on MapLoom) and make a local backup on the machine. This will then enable the **Download** and **Remove** buttons if it is successfully uploaded.

- Expected results for upload:
- Successful
- Error Uploading: "Invalid file" (Non-XML format, not '.xsd')
- Error Uploading: "Invalid schema"

This button allows you to download a schema that you previously uploaded through /gsschema/. This schema is local to the machine, and if no schemas have been uploaded, this button will be disabled.

This will remove the currently selected layer's schema that is *local to the machine*. It will prompt the user with a window confirming if they want to remove the file. This button will be disabled if there is not a previous schema uploaded for that layer.

[1]: "Django"
[2]: "GeoServer"
[3]: "GeoSHAPE"
[4]: "ROGUE"
[5]: "Arbiter"
[6]: "MapLoom"

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-gsschema-0.1b2.tar.gz (609.2 kB view hashes)

Uploaded source

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page