...
- Download NVCLConfig.zip.
Extract it into
%GEOSERVER_INSTANCE_HOME%/data/workspaces.Create the file
%GEOSERVER_INSTANCE_HOME%/WEB-INF/classes/app-schema.propertiesand insert the following text replacing %PLACEHOLDERS%with appropriate values:Code Block language bash # Oracle connection parameters borehole.dbtype = oracle borehole.jndi = jdbc/borehole nvcl.dbtype = oracle nvcl.jndi = jdbc/nvcl # The codeSpace URL used for gml:name borehole.codespace1 = http://www.ietf.org/rfc/rfc2616 borehole.codespace2 = %CLIENT_HOME_URL% # eg. http://www.csiro.au # Client's Borehole url borehole.uri = http://%SERVER_HOST_NAME%/resource/feature/%CUSTODIAN_SHORT_NAME%/borehole/ # eg http://geossdi.dmp.wa.gov.au/resource/feature/GSWA/borehole/ # Client's O&M url om.uri = http://%SERVER_HOST_NAME%/resource/feature/%CUSTODIAN_SHORT_NAME%/samplingfeaturecollection/ # eg http://www.mrt.tas.gov.au/resource/feature/MRT/samplingfeaturecollection/ # Core Custodian borehole.custodian = %CUSTODIAN_LONG_NAME% # eg Mineral Resources Tasmania # Metadata URI gsmlp.metadata.uri = http://researchdata.ands.org.au/%BOREHOLE_SERVICE%
Replace all
%PLACEHOLDERS%with appropriate values and insert the following <resource> elements into the geoserver <context> element of the file%TOMCAT_HOME%/conf/server.xml:Code Block language xml <Resource name="jdbc/borehole" auth="Container" type="javax.sql.DataSource" url="jdbc:oracle:thin:@%DB_HOSTNAME%:1521:%BOREHOLE_DB_NAME%" driverClassName="oracle.jdbc.OracleDriver" username="%DB_USERNAME%" password="%DB_PASSWORD%" maxTotal="2000" maxIdle="10" minIdle="2" maxWaitMillis="10000" minEvictableIdleTimeMillis="300000" timeBetweenEvictionRunsMillis="300000" numTestsPerEvictionRun="20" poolPreparedStatements="true" maxOpenPreparedStatements="100" testOnBorrow="true" validationQuery="SELECT 1 FROM DUAL" /> <Resource name="jdbc/nvcl" auth="Container" type="javax.sql.DataSource" url="jdbc:oracle:thin:@%DB_HOSTNAME%:1521:%NVCL_DB_NAME%" driverClassName="oracle.jdbc.OracleDriver" username="%DB_USERNAME%" password="%DB_PASSWORD%" maxTotal="2000" maxIdle="10" minIdle="2" maxWaitMillis="10000" minEvictableIdleTimeMillis="300000" timeBetweenEvictionRunsMillis="300000" numTestsPerEvictionRun="20" poolPreparedStatements="true" maxOpenPreparedStatements="100" testOnBorrow="true" validationQuery="SELECT 1 FROM DUAL" />Replace all %PLACEHOLDERS%with appropriate values and add the following inside the <IfModule mod_rewrite.c> tag of your http Server configuration file:
Code Block language bash RewriteRule ^/resource/feature/%CUSTODIAN_NAME%/borehole/(.*) http://%SERVER_HOST_NAME%/%GEOSERVER_INSTANCE_NAME%/wfs?service=WFS&version=1.1.0&request=GetFeature&typeName=gsml:Borehole&featureid=gsml.borehole.$1 [NC,R=303,L] RewriteRule ^/resource/feature/%CUSTODIAN_NAME%/samplingfeaturecollection/(.*) http://%SERVER_HOST_NAME%/%GEOSERVER_INSTANCE_NAME%/wfs?service=WFS&version=1.1.0&request=GetFeature&typeName=sa:SamplingFeatureCollection&featureid=sa.samplingfeaturecollection.$1 [NC,R=303,L]
Edit %GEOSERVER_DATA_DIR%/workspaces/gsmlp/BoreholeView/BoreholeView/featuretype.xml and replace the 2 %PLACEHOLDERS%with appropriate values :
Code Block language xml <title>Borehole Portrayal View</title> <abstract>GeoSciML Portrayal Borehole View for NVCL Borehole</abstract> <keywords> <string>association:http://%SERVER_HOST_NAME%/resource/feature/%CUSTODIAN_SHORT_NAME%/gsmlp/borehole/</string> </keywords>
...