Configure Map Service Provider |
SuperMap iServer supports the following types of map service providers:
Configure a UGC map service providers as follows:
<provider name="ugcMapProvider1" class="com.supermap.services.providers.UGCMapProvider"> <config class="com.supermap.services.providers.UGCMapProviderSetting"> <outputPath>../webapps/iserver/output</outputPath> <outputSite>http://localhost:8090/iserver/output/</outputSite> <workspacePath>server=../samples/data/World/World.sxwu;password=supermap</workspacePath> <cacheVersion>5.0</cacheVersion> <useCompactCache>false</useCompactCache> <multiThread>true</multiThread> <fullLabelEnabled>false</fullLabelEnabled> <!-- Whether to disable the expanded query function --> <inflatDisabled>true</inflatDisabled;> <poolSize>0</poolSize> <preferedPNGType>PNG</preferedPNGType> <queryExpectCount>1000</queryExpectCount> <leftTopCorner> <x>-180.0</x> <y>90.0</y> </leftTopCorner> <dpi>0</dpi> <!-- Set exclusion fields --> <excludedFieldsInMaps> <com.supermap.services.providers.ExcludedFieldsInMap> <mapName>World</mapName> <excludedFieldsInLayers> <com.supermap.services.providers.ExcludedFieldsInLayer> <layerName>Captial@World</layerName> <excludedFields>SMID,NAME</excludedFields> </com.supermap.services.providers.ExcludedFieldsInLayer> </excludedFieldsInLayers> </com.supermap.services.providers.ExcludedFieldsInMap> </excludedFieldsInMaps> </config> </provider>
The class in < provider > identifies the implementation class of the UGC service providers, and the class in <config> identifies the configuration class corresponding to the UGC service provider, that is, UGCMapProviderSetting. The contents in < config > are UGCMapProviderSetting corresponding configuration item:
<workspacePath>server=../samples/data/World/World.sxwu;password=supermap</workspacePath>
In addition, the workspace path supports reading from environment variables and the system config file. It can be written as:
<workspacePath>server=${datapath1}/World.sxwu;password=supermap</workspacePath>For detailed instructions, please refer to: Preset local workspace path
The com.supermap.services.providers.ExcludedFieldsInMap and com.supermap.services.providers.ExcludedFieldsInLayer are implementation classes for field exclusion settings. < mapName > is the map name, < layerName > is the dataset name, and < excludedFields > specifies the excluded fields.
SuperMap iServer also supports Oracle, SQL Server, and DM database-type workspace as service providers. The parameters to be provided are shown in Table 1. No special instructions indicate that the parameters are required for several types.
Table 1 Setting parameters of database-type workspace information
Parameter name | Description |
type | The type of workspace. Currently, the supported database types are Oracle workspace, SQL Server workspace, and DM workspace, and their values are respectively ORACLE、 SQL、DM. ORACLE indicates that the workspace is stored in the oracle database, and SQL indicates that the workspace is saved in a SQL Server database, the DM indicates that the workspace is stored in the DM database. |
name | Name of the workspace in the database. |
username | The user name used to log in to the database. |
password | The password used to log in to the database. |
server | Server name. For an Oracle database, its server name is its TNS service name; for a SQL Server database, its server name is its system DSN (Database System Name); for the DM database, the server name is the IP of the machine where the DM database is located, such as 192.168.110.110. |
database | name |
driver | The name of the driver when using an ODBC connection. Only SQL Server databases use an ODBC connection, and the driver name can be SQL Server or SQL Native Client. |
<workspacePath>type=ORACLE;name=testOralce;username=cq;password=cq;server=ISERVER;database=iserver</workspacePath>
<workspacePath>type=SQL;name=testSQL;username=sa;password=iserver;server=ISERVICE\SQL2005;driver= SQL Server;database=iserver</workspacePath>
<workspacePath>type=DM;name=testDM;username=sa;password=iserver;server=ISERVICE\DM7;database=iserver</workspacePath>
In addition, multiple < providers > can be bound as a whole, that is, as a < providerSet > providing services to service components (< component >). See Configure Service Provider Collection through XML file. <provider> and <providerSet> in the config file are structured as follows:
<server> ... <application> ... <providerSets> ... <providerSet> ... </providerSet> </providerSets> <providers> ... <provider> ... </provider> </providers> </application> </server>
The configuration REST service providers is done in the < provider > node:
<provider name="restMapProvider1" class="com.supermap.services.providers.RESTMapProvider"> <config class="com.supermap.services.providers.RESTMapProviderSetting"> <restServiceRootURL>http://localhost:8090/iserver/services/rest</restServiceRootURL> <token>GsXST0cE0CumxQUFXBX7Oopin4<token> </config> </provider>
The class in < provider > identifies the implementation class of the REST service providers, and the class in <config> identifies the configuration class corresponding to the REST service provider, that is, RESTMapProviderSetting. The contents in <config> are RESTMapProviderSetting corresponding configuration item:
Hypergraph cloud service providers are configured in the < provider > node. The specific configuration is as follows:
<provider name="CloudMapProvider1" class="com.supermap.services.providers.CloudMapProvider"> <config class="com.supermap.services.providers.CloudMapProviderSetting"> <outputPath>../webapps/iserver/output</outputPath> <outputSite>http://localhost:8090/iserver/output/</outputSite> <servicesUrl>http://t2.supermapcloud.com/FileService/image</servicesUrl> <cacheEnabled>true</cacheEnable> </config> </provider>
The class in < provider > identifies the implementation class of hypergraph cloud service providers, and the class in <config> identifies the configuration class corresponding to the hypergraph cloud service provider. Class identifies the configuration class corresponding to the hypergraph cloud service providers, namely CloudMapProviderSetting, and the content in <config> corresponds to CloudMapProviderSetting corresponding configuration item:
GDP map service providers are configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.GDPMapProvider" enabled="true" name="gdpMapProvider-"> <config class="com.supermap.services.providers.GDPMapProviderSetting"> <cacheVersion>5.0</cacheVersion> <filesPath>F:\SuperMap\China_58b994e9-5856-4a10-a0dc-0e0e177d7962\7_0000_0000_192.168.120.42_2014_03_03_14_01_56.zip</filesPath> <dpi>96.0</dpi> <tileSize>256</tileSize> <zoom0ScaleDenator>5.916587109091312E8</zoom0ScaleDenator> </config> </provider>
The class in < provider > identifies the implementation class of GDP service providers, and the class in <config> identifies the configuration class corresponding to the GDP service provider, that is, GDPMapProviderSetting, and the content in < config > corresponds to GDPMapProviderSetting corresponding configuration item:
The MongoDB service providers is configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.MongoDBTileProvider" enabled="true" name="mongoDBMapProvider-China"> <config class="com.supermap.services.providers.MongoDBTileProviderSetting"> <serverAdresses> <string>localhost:27017</string> </serverAdresses> <mapName>China</mapName> <tilesetName>1181328118</tilesetName> <database>smtiles</database> <username>iserver</username> <password>iserver</password> </config> </provider>
The class in < provider > identifies the implementation class of the MongoDB service providers, and The class in <config> identifies the configuration class corresponding to the MongoDB service provider, that is, MongoDB TileProviderSetting, and the content in < config > corresponds to MongoDBTileProviderSetting corresponding configuration item:
The MongoDB MVT service providers is configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.MongoDBMVTTileProvider" enabled="true" name="mongodbMvt-China"> <config class="com.supermap.services.providers.MongoDBTileProviderSetting"> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <serverAdresses> <string>localhost:27017</string> </serverAdresses> <mapName>China</mapName> <tilesetName>China</tilesetName> <database>mvt</database> <username>iserver</username> <password>iserver</password> </config> </provider>
The class in < provider > identifies the implementation class of the MongoDB MVT service providers, and the class in <config> identifies the configuration class corresponding to the MongoDB service provider, that is, MongoDB TileProviderSetting, and the content in < config > corresponds to MongoDBTileProviderSetting corresponding configuration item:
The OTS service providers is configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.OTSTileProvider" enabled="true" name="ots-map"> <config class="com.supermap.services.providers.OTSTileProviderSetting"> <outputPath>D:\SuperMap\SuperMapiServer9D\webapps\iserver\output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <nodeName>cn-hangzhou</nodeName> <instanceName>tileStore</instanceName> <accessKeyId>accessKeyId</accessKeyId> <accessKeySecret>accessKeySecret</accessKeySecret> <fromPublic>true</fromPublic> </config> </provider>
The class in < provider > identifies the implementation class of the OTS service providers, and the class in <config> identifies the configuration class corresponding to the OTS service provider, that is, OTSTileProviderSetting. The content in < config > corresponds to OTSTileProviderSetting corresponding configuration item:
The SMTiles service providers is configured in the < provider > node. The specific configuration is as follows:
<provider name="smtilesMapProvider1" class="com.supermap.services.providers.SMTilesMapProvider"> <config class="com.supermap.services.providers.SMTilesMapProviderSetting"> <filePath>../webapps/iserver/output/sqlite/World_-411043745_256X256_PNG.smtiles</filePath> </config> </provider>
The class in < provider > identifies the implementation class of SMTiles map service providers, and the class in <config> identifies the configuration class corresponding to the SMFiles map service provider, that is, SMTilesMapProviderSetting, and the content in < config > corresponds to SMTilesMapProviderSetting corresponding configuration item:
The SVTiles service providers is configured in the < provider > node. The specific configuration is as follows:
<provider name="svtilesMapProvider1" class="com.supermap.services.providers.SVTilesMapProvider"> <config class="com.supermap.services.providers.SVTilesMapProviderSetting"> <filePath>../webapps/iserver/output/sqlite/World_1715141636_256X256.svtiles</filePath> </config> </provider>
The class in < provider > identifies the implementation class of SVTiles map service providers, and the class in <config> identifies the configuration class corresponding to the SVTiles map service provider, that is, SVTilesMapProviderSetting, and the content in < config > corresponds to SVTilesMapProviderSetting corresponding configuration item:
UGCV5 service providers are configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.UGCV5TileProvider" enabled="true" name="ugcv5-China"> <config class="com.supermap.services.providers.UGCV5TileProviderSetting"> <watermark> <imageUrl>F:/test/test.png</imageUrl> <imageAlpha>0.5</imageAlpha> <txtContent>ABCD</txtContent> <fontSize>5</fontSize> <fontColor> <red>255</red> <green>0</green> <blue>0</blue> <alpha>255</alpha> </fontColor> <fontStyle>Microsoft YaHei</fontStyle> <xIndex>4</xIndex> <yIndex>5</yIndex> <random>50</random> </watermark> <configFile>../webapps/iserver/output/cache/China/China.sci</configFile> </config> </provider>
The class in < provider > identifies the implementation class of UGCV5 service providers, and the class in <config> identifies the configuration class corresponding to the UGCV5 service provider, that is, UGCV5TileProviderSetting, and the content in < config > corresponds to UGCV5TileProviderSetting corresponding configuration item:
In addition, SuperMap iServer supports the configuration of UGCV5 primitive tiles stored in the S3 object storage service as follows:
<provider class="com.supermap.services.providers.UGCV5TileProvider" enabled="true" name="map-China-9"> <config class="com.supermap.services.providers.UGCV5TileProviderSetting"> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <configFile>/iserver-1311973718/picture/png/China/China.sci</configFile> <s3ConnectionInfo> <endpoint>https://cos.ap-beijing.myqcloud.com</endpoint> <region>us-east-1</region> <accessKey>AKIDwlNmxtgJ0UQDqHWYLtCH7C2dx4yRhjs0</accessKey> <secretKey>1Dya5OTSM4av3w4Vr3A3kJoBPREnJfqn</secretKey> </s3ConnectionInfo> </config> </provider>
Among,
The configuration WMS service providers is done in the < provider > node:
<!-- Example of a WMS map service provider using remote WMS services as the data source.--> <provider name="wmsMapProvider" class="com.supermap.services.providers.WMSMapProvider"> <config class="com.supermap.services.providers.WMSMapProviderSetting"> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <cacheEnabled>false</cacheEnabled> <serviceRootURL>http://localhost:7070/geoserver/wms</serviceRootURL> <username></username> <password></password> <version>1.3.0</version> <reverseLayerOrder>false</reverseLayerOrder> <defaultScale>1.0E-5</defaultScale> <reverseCoordinateSRS> <string>EPSG:4326</string> <string>EPSG:3857</string> </reverseCoordinateSRS> </config> </provider>
The class in < provider > identifies the implementation class of the WMS service providers, and the class in <config> identifies the configuration class corresponding to the WMS service provider, that is, WMSMapProviderSetting. The contents in < config > are WMSMapProviderSetting corresponding configuration item:
The configuration WMTS service providers is done in the < provider > node:
<!-- Example of WMTS map service provider, using remote WMTS services as the data source.--> <provider name="wmtsMapProvider" class="com.supermap.services.providers.WMTSMapProvider"> <config class="com.supermap.services.providers.WMTSMapProviderSetting"> <serviceRootURL>http://server:7070/geoserver/wmts</serviceRootURL> <username></username> <password></password> <version>1.0.0</version> <dpi>90.7142857142857</dpi> <layers> <com.supermap.services.providers.WMTSMapLayer> <identifier>world:Countries</identifier> <tileMatrixSet>EPSG:4610</tileMatrixSet> </com.supermap.services.providers.WMTSMapLayer> <com.supermap.services.providers.WMTSMapLayer> <identifier>nurc:Img_Sample</identifier> <tileMatrixSet>EPSG:900913</tileMatrixSet> </com.supermap.services.providers.WMTSMapLayer> </layers> <reverseTopLeftCorner>EPSG:4610</reverseTopLeftCorner> <reverseBoundingBox>urn:ogc:def:crs:EPSG::4610</reverseBoundingBox> <cacheEnabled>true</cacheEnabled> <resolutions>0.01903568804664224,0.00951784402332112,......</resolutions> <calcDefaultScaleByResolution>false</calcDefaultScaleByResolution> <originPoint>-20037508.3427892,20037508.3427892</originPoint> </config> </provider>
The class in < provider > identifies the implementation class of the WMTS service providers, and the class in <config> identifies the configuration class corresponding to the WMTS service provider, that is, WMTSMapProviderSetting. The contents in < config > are WMTSMapProviderSetting corresponding configuration item:
BingMaps service providers takes place in the < provider > node. The specific configuration is as follows:
<provider name="BingMapsMapProvider1" class="com.supermap.services.providers.BingMapsMapProvider"> <config class="com.supermap.services.providers.BingMapsMapProviderSetting"> <outputPath>../webapps/iserver/output</outputPath> <outputSite>http://localhost:8090/iserver/output/</outputSite> <apiKey>fdskjkfdsk</apiKey> <bingmapsRootUrl>http://localhost:9876/bingmaps/</bingmapsRootUrl> <imagerySet>Road</imagerySet> <mapVersion>v1</mapVersion> <cacheEnabled>true</cacheEnable> </config> </provider>
The class in < provider > identifies the implementation class of the BingMaps service providers, and the Class identifies the configuration class corresponding to the BingMaps service providers, that is, BingMapsMapProviderSetting, and the contents in < config > are BingMapsMapProviderSetting corresponding configuration item:
Google Maps map service providers are configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.GoogleMapsMapProvider" enabled="true" name="googlemap"> <config class="com.supermap.services.providers.GoogleMapsMapProviderSetting"> <outputPath/> <outputSite/> <cacheEnabled>false</cacheEnabled> <googleMapLanguage>zh-cn</googleMapLanguage> <googleMapCryptoKey>abcdefghijklmn=</googleMapCryptoKey> <googleMapClientID>myClientID</googleMapClientID> <googleMapWidth>400</googleMapWidth> <googleMapHeight>400</googleMapHeight> <googleProxyAddress>127.0.0.1</googleProxyAddress> <googleProxyPort>8787</googleProxyPort> <useTileImage>true</useTileImage> </config> </provider>
The class in < provider > identifies the implementation class of Google map service providers, and The class in <config> identifies the configuration class corresponding to the Google Maps service provider, that is, GoogleMapsMapProviderSetting, and the content in < config > is GoogleMapsMapProviderSetting corresponding configuration item:
The Baidu map provider is configured in the < provider > node. The specific configuration is as follows:
<provider name="baiduMapProvider1" class="com.supermap.services.providers.BaiduMapProvider"> <config class="com.supermap.services.providers.BaiduMapProviderSetting"> <outputPath>../webapps/iserver/output</outputPath> <outputSite>http://localhost:8090/iserver/output/</outputSite> <mapUrl>http://online0.map.bdimg.com/tile/?qt=tile&x={x}&y={y}&z={z}&styles=pl</mapUrl> <mapName>true</mapName> <cacheEnabled>true</cacheEnable> </config> </provider>
The class in < provider > indicates the implementation class of Baidu map service providers, and the class in <config> identifies the configuration class corresponding to the Baidu Map service provider, namely BaiduMapProviderSetting, and the contents in < config > are BaiduMapProviderSetting corresponding configuration item:
OpenStreetMap map service providers are configured in the < provider > node. The specific configuration is as follows:
<provider name="openStreetMapProvider1" class="com.supermap.services.providers.OpenStreetMapProvider"> <config class="com.supermap.services.providers.OpenStreetMapProviderSetting"> <outputPath>../webapps/iserver/output</outputPath> <outputSite>http://localhost:8090/iserver/output/</outputSite> <mapUrl>http://a.tile.openstreetmap.org/{z}/{x}/{y}.png</mapUrl> <mapName>true</mapName> <cacheEnabled>true</cacheEnable> <apikey>abcdefg</apikey> </config> </provider>
The class in < provider > identifies the implementation class of OpenStreetMap map service providers, and the class in <config> identifies the configuration class corresponding to the OpenStreetMap map service provider, namely OpenStreetMap ProviderSetting, and the contents in < config > are OpenStreetMapProviderSetting corresponding configuration item:
Map service providers are configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.TiandituMapProvider" enabled="true" name="tiandituMapProvider1"> <config class="com.supermap.services.providers.TiandituMapProviderSetting"> <outputPath>../webapps/iserver/output</outputPath> <outputSite>http://localhost:8090/iserver/output/</outputSite> <servicesUrl>http://t5.tianditu.gov.cn</servicesUrl> <cacheEnabled>true</cacheEnable> <key>efb100fb46e3849b93f508c8fb949926</key> </config> </provider>
The class in < provider > identifies the implementation class of the service providers of the world map, and the class in <config> identifies the configuration class corresponding to the Tianditu service provider, namely TiandituMapExtendeSetting, and the contents in < config > are TiandituMapProviderSetting corresponding configuration item:
The ArcGIS REST service providers is configured in the < provider > node. The configuration is as follows:
<provider class="com.supermap.services.providers.ArcGISRestMapProvider" enabled="true" name="arcgis-Countries2"> <config class="com.supermap.services.providers.ArcGISRestMapProviderSetting"> <restServiceRootURL>http://localhost:6080/arcgis/rest/services/mytest/Countries/MapServer</restServiceRootURL> <cacheEnabled>false</cacheEnabled> <token>_jLYzPo-SEJRXfB3Q-W2EearDDnaIZTqQqUfju4GD8Owd6PIiUVmabUJiSdZeX1V</token> <httpReferer>ISERVER</httpReferer> <replaceTRNS>false</replaceTRNS> <customMapName>test</customMapName> </config> </provider>
The class in < provider > identifies the implementation class of ArcGIS REST map service providers, and the class in <config> identifies the configuration class corresponding to the ArcGIS REST map service provider, that is, ArcGISRestMapProviderSetting, and the content in < config > corresponds to ArcGISRestMapProviderSetting corresponding configuration item:
The TPK service providers is configured in the < provider > node. The configuration is as follows:
<provider class="com.supermap.services.providers.TPKMapProvider" enabled="true" name="tpk-map1"> <config class="com.supermap.services.providers.TPKMapProviderSetting"> <tilePackagePath>../samples/data/map1.tpk</tilePackagePath> </config> </provider>
The class in < provider > identifies the implementation class of TPK map service providers, and the class in <config> identifies the configuration class corresponding to the TPK map service provider, that is, TPKMapProviderSetting, and the content in < config > corresponds to TPKMapProviderSetting corresponding configuration item:
The TPKX service providers is configured in the < provider > node. The configuration is as follows:
<provider class="com.supermap.services.providers.TPKXMapProvider" enabled="true" name="tpkx-map1"> <config class="com.supermap.services.providers.TPKXMapProviderSetting"> <tilePackagePath>../samples/data/map1.tpkx</tilePackagePath>
<replaceTRNS>false</replaceTRNS> </config> </provider>
The class in < provider > identifies the implementation class of TPK map service providers, and the class in <config> identifies the configuration class corresponding to the TPK map service provider, that is, TPKMapProviderSetting, and the content in < config > corresponds to TPKXMapProviderSetting corresponding configuration item:
The VTPK service providers is configured in the < provider > node. The configuration is as follows:
<provider class="com.supermap.services.providers.VTPKMapProvider" enabled="true" name="vtpk-map1"> <config class="com.supermap.services.providers.VTPKMapProviderSetting"> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <vectorTilePackagePath>../samples/data/map1.vtpk</vectorTilePackagePath> <center> <x>1.303397289E7</x> <y>4390875.375</y> </center> </config> </provider>
The class in < provider > identifies the implementation class of VTPK map service providers, and the class in <config> identifies the configuration class corresponding to the VTPK map service provider, that is, VTPKMapProviderSetting, and the content in < config > corresponds to VTPKMapProviderSetting corresponding configuration item:
: Set the center point of the map (optional).
The GeoPackage service providers is configured in the < provider > node. The configuration is as follows:
<provider class="com.supermap.services.providers.GeoPackageMapProvider" enabled="true" name="gpkgMap-map"> <config class="com.supermap.services.providers.GeoPackageMapProviderSetting"> <outputPath>F:\dev\trunk\etc\iserver-debug\src\test\webapps\iserver\output</outputPath> <outputSite>http://localhost:8090/iserver/output/</outputSite> <filePath>E:/data/geopackage/map.gpkg</filePath> <defaultMapPrjCoordSys>0</defaultMapPrjCoordSys> <queryExpectCount>1000</queryExpectCount> <axisPositiveDirection>RightUp</axisPositiveDirection> <originalPoint>-180,-90</originalPoint> </config> </provider>
The class in < provider > identifies the implementation class of GeoPackage map service providers, and the class in <config> identifies the configuration class corresponding to the GeoPackage map service provider, that is, GeoPackageMapProviderSetting, and the content in < config > corresponds to GeoPackageMapProviderSetting corresponding configuration item:
The ZXYTiles service providers is configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.ZXYTilesMapProvider" enabled="true" name="zxytest"> <config class="com.supermap.services.providers.ZXYTilesMapProviderSetting"> <outputPath>../../webapps/iserver/output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <filePath>E:/data/ZXYTilesSample.zip</filePath> </provider>
The class in < provider > identifies the implementation class of ZXYTiles map service providers, and the class in <config> identifies the configuration class corresponding to the ZXYTiles map service provider, that is, ZXYTilesMapProviderSetting, and the content in < config > corresponds to ZXYTilesMapProviderSetting corresponding configuration item:
ArcGIS cache service providers are configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.ArcGISCacheMapProvider" enabled="true" name="agscache-WorldCitiesPopulation"> <config class="com.supermap.services.providers.ArcGISCacheMapProviderSetting"> <outputPath>../../webapps/iserver/output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <configFile>E:/data/arcgiscache/sample/World Cities Population/conf.xml</configFile> </config> </provider>
The class in < provider > identifies the implementation class of ArcGIS cache map service providers, and the class in < config > Class identifies the configuration class corresponding to ArcGIS cache service providers, that is, ArcGISCacheMapProviderSetting, and the content in < config > corresponds to ArcGISCacheMapProviderSetting corresponding configuration item:
The ArcGIS Compact Cache (V2) service providers are configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.ArcGISCacheV2MapProvider" enabled="true" name="agscachev2-WorldCitiesPopulation"> <config class="com.supermap.services.providers.ArcGISCacheMapProviderSetting"> <outputPath>../../webapps/iserver/output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <configFile>E:/data/arcgiscachev2/sample/World Cities Population/conf.xml</configFile> </config> </provider>
Where class in < provider > identifies ArcGIS Compact Cache (V2) Implementation class of map service providers. The class in < config > identifies the configuration class corresponding to ArcGIS Compact Cache (V2) service providers, that is, ArcGISCacheMap ProviderSetting . The content in < config > corresponds to ArcGISCacheMap ProviderSetting. corresponding configuration item:
<provider class="com.supermap.services.providers.MVTTileProvider" enabled="true" name="UGCV5-MVT-MAP"> <config class="com.supermap.services.providers.MVTTileProviderSetting"> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <configFilePath>E:/supermap_packages/data/China_mvt/China.sci</configFilePath> </config> </provider>
The class in < provider > identifies the implementation class of UGCV5 (MVT) map service providers, and the class in < config > identifies the configuration class corresponding to the UGCV5 (MVT) service provider, that is, MVTTileProviderSetting. The contents in < config > are MVTTileProviderSetting corresponding configuration item:
Configure a Shapefile map service providers as follows:
<provider class="com.supermap.services.providers.ShapefileMapProvider" enabled="true" name="shapefileMap-"> <config class="com.supermap.services.providers.ShapefileMapProviderSetting"> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <cacheDisabled>false</cacheDisabled> <shpDir>E:/supermap/data/shp</filePath> <styleFile>E:/data/styles/style.json</styleFile> <charset>UTF-8</charset> </config> </provider>
The class in < provider > identifies the implementation class of the Shapefile map service providers, and the class in < config > identifies the configuration class corresponding to the Shapefile map service provider, that is, ShapefileMapProviderSetting, and the content in < config > is the ShapefileMapProviderSetting corresponding to the configuration items in:
PostGIS map service providers are configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.PostgisMapProvider" enabled="true" name="map-postGIS"> <config class="com.supermap.services.providers.PostgisMapProviderSetting"> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <cacheDisabled>false</cacheDisabled>
<dbType>postgis</dbType> <host>192.168.17.212</host> <port>5432</port> <database>postGIS</database> <user>postgres</user> <passwd>iserver</passwd> <styleFile>E:/data/styles/style.json</styleFile> </config> </provider>
The class in < provider > identifies the implementation class of PostGIS map service providers, and the class in < config > identifies the configuration class corresponding to the PostGIS service provider, that is, PostgisMapProviderSetting, and the content in < config > corresponds to PostgisMapProviderSetting corresponding configuration item:
GeoTrellis map service providers are configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.GeoTrellisMapProvider" enabled="true" name="test"> <config class="com.supermap.services.providers.GeoTrellisMapProviderSetting"> <outputPath>../../webapps/iserver/output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <cacheDisabled>false</cacheDisabled> <connInfo> <engineType>HBASE</engineType> <server>localhost</server> <dataBase>test</dataBase> </connInfo> <mapSettings> <com.supermap.services.providers.GeotrellisMapSetting> <mapName>mayimap</mapName> <layerIds> <string>SV1-02_20190321</string> <string>GF2_20160503</string> </layerIds> <enableMultiVersion>true</enableMultiVersion> <versionNames> <string>T2015</string> <string>T2016</string> </versionNames> </com.supermap.services.providers.GeotrellisMapSetting> </mapSettings> </config> </provider>
The class in < provider > identifies the implementation class of GeoTrellis map service providers, and the class in < config > identifies the configuration class corresponding to the GeoTrellis service provider, that is, GeoTrellisProviderSetting, and the content in < config > corresponds to Configuration items corresponding to GeoTrelli's ProviderSetting:
Note: This provider is only used for raster and image data.
The configuration of the multi tiles map provider is done in the < provider > node. There are three combining modes for multi tiles: default, base tileset, and custom scales. Here, take base tileset and custom scales as examples to introduce the configuration of map service providers.
base tileset:
<provider class="com.supermap.services.providers.MultiTilesProvider" enabled="true" name="multiTiles3"> <config class="com.supermap.services.providers.MultiTilesProviderSetting"> <name>ChinaTest</name> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <tilesets> <com.supermap.services.components.commontypes.TilesetSetting> <tilesourceInfo class="com.supermap.services.tilesource.MongoDBTilesourceInfo"> <datastoreType>TILES</datastoreType> <type>MongoDB</type> <serverAdresses> <string>192.168.17.214:27011</string> </serverAdresses> <database>jingjin_transparent</database> <username/> <password/> </tilesourceInfo> <mapName>Map of Beijing Tianjin region</mapName> <tilesetName>1181328118</tilesetName> </com.supermap.services.components.commontypes.TilesetSetting> </tilesets> <baseTileset> <tilesourceInfo class="com.supermap.services.tilesource.SMTilesTileSourceInfo"> <datastoreType>TILES</datastoreType> <outputPath>E:/supermap/China_-1085299276_256X256_PNG.smtiles</outputPath> </tilesourceInfo> <mapName>China</mapName> <tilesetName>smtiles_tileset_1181328119</tilesetName> </baseTileset> <combiningMode>BaseTileset</combiningMode> </config> </provider>
custom scales:
<provider class="com.supermap.services.providers.MultiTilesProvider" enabled="true" name="multiTiles3"> <config class="com.supermap.services.providers.MultiTilesProviderSetting"> <name>ChinaTest</name> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <tilesets> <com.supermap.services.components.commontypes.TilesetSetting> <tilesourceInfo class="com.supermap.services.tilesource.MongoDBTilesourceInfo"> <datastoreType>TILES</datastoreType> <type>MongoDB</type> <serverAdresses> <string>192.168.17.214:27011</string> </serverAdresses> <database>jingjin_transparent</database> <username/> <password/> </tilesourceInfo> <mapName>Map of Beijing Tianjin region</mapName> </com.supermap.services.components.commontypes.TilesetSetting> <com.supermap.services.components.commontypes.TilesetSetting> <tilesourceInfo class="com.supermap.services.tilesource.MongoDBTilesourceInfo"> <datastoreType>TILES</datastoreType> <type>MongoDB</type> <serverAdresses> <string>192.168.17.214:27011</string> </serverAdresses> <database>China4326</database> <username/> <password/> </tilesourceInfo> <mapName>China_4326</mapName> </com.supermap.services.components.commontypes.TilesetSetting> </tilesets> <customScales> <double>4.0E-9</double> <double>8.0E-9</double> <double>1.5625E-8</double> <double>3.125E-8</double> <double>6.25E-8</double> <double>1.25E-7</double> <double>2.5E-7</double> <double>5.0E-7</double> <double>1.0E-6</double> </customScales> <combiningMode>CustomScales</combiningMode> </config> </provider>
The class in < provider > identifies the implementation class of the multi tiles map provider, and the class in < config > identifies the configuration class corresponding to the composite tile service provider, that is, MultiTilesProviderSetting, and the content in < config > corresponds to MultiTilesProviderSetting corresponding configuration item:
File type data source configuration parameters:
The database type configuration parameter:
The MBTiles service providers is configured in the < provider > node. The specific configuration is as follows:
<provider class="com.supermap.services.providers.MBTilesMapProvider" enabled="true" name="mbtiles-R"> <config class="com.supermap.services.providers.MBTilesMapProviderSetting"> <outputPath>./output</outputPath> <outputSite>http://{ip}:{port}/iserver/output/</outputSite> <filePath>D:/R_Boundry.mbtiles</filePath> <vectorFormat>false</vectorFormat> </config> </provider>
The class in < provider > identifies the implementation class of MBTiles map service providers, and the class in < config > identifies the configuration class corresponding to the MBTiles map service provider, that is, the MBTiles Map ProviderSetting, and the content in < config > corresponds to MBTilesMapProviderSetting corresponding configuration item: