2.4. Interoperability and geospatial Web service standards#

Interoperability is often involved in large projects or national information platforms. Interoperability is to allow software and data from different manufacturers to work together, and the main way to achieve interoperability is to formulate standards. In essence, the standard of Web service is to specify the specific format of request and response, for example, which parameters are included in the request, what type of each parameter is, and what result is included in the returned information of the response. Web map service standards defined by OGC, including WMS, WMTS, WFS, WCS, WPS, CSW and Web service-related standards, as well as KML and GeoRSS.

The meanings of the three most commonly used geo-reference information models are as follows:

  • Web Map Server (WMS)

  • Web Feature Server (WFS)

  • Web Coverage Server (WCS)

2.4.1. Interoperability based on Web Services#

Interoperability is to allow software and data from different manufacturers to work together. In layman’s terms, I can call your data and functions, and you can call my data and functions. The realization technology of GIS interoperability has gone through many stages, and the technology of implementing GIS interoperability has mainly gone through the stages of file format conversion, direct reading plug-ins and Web service standards.

|----------------------|     |--------------------------|     |---------------------|
|File format conversion| --> |Plugins for direct reading| --> |Standard Web Services|
|----------------------|     |--------------------------|     |---------------------|

Early interoperability often involves data conversion, for example, converting the data of one software product into the data format of another software product, or defining a standard file format. Different software products need to be able to input and output this format. The plug-in can be used to directly read and write data in one of the software plug-ins, that is, it can be used to directly read and write data in another software plug-in. In recent years, the interoperability technology has gradually shifted to the level of Web service standards. This method not only avoids the export and import of data formats, but also avoids the trouble of installing plug-in tools locally. Different manufacturers can independently develop their own products according to the industry’s Web service standards. As long as the Web service interface of their products conforms to certain industry standards, the data and functions of their software can be called with each other through Web services to achieve interoperability .

There are mainly the following standardization organizations about geospatial web services.

Taking OGC’s WMS standard as an example, a WMS online map service published by MapServer or GeoServer can be used not only by Esri products, but also by clients that support WMS standards such as Google Earth, NASA WorldWind, OpenLayers, and Gaia. Each client knows what parameters should be sent in the request, and can expect the server to respond in what format.

2.4.2. Standards for Web services#

This section mainly introduces the WMS, WMTS, WFS, WCS, CSW, WPS and OpenLS standards of OGC. Readers can visit the official website of OGC (http://www.opengeospatial.org) to check the detailed documents of these specifications, and check which WebGIS software has been certified by OGC and which standards are supported.

(1) Web Mapping Service (WMS-Web Map Service)#

WMS is a Web service specification developed by OGC for making maps on the Internet. The maps produced by WMS are generally presented in image formats, such as PNG, GIF or JPEG. Any web service that claims to conform to the WMS specification must support the following two necessary requests:

GetCapabitities: Return the description information of the Web service to the client. The format of the returned result is XML, which describes the service’s name, introduction, keywords, coverage, which data layers are included, what coordinate system each layer is, what attributes it has, and whether it can be queried. This metadata also includes the map image file format that the service can generate, the URL of each operation that can be supported, and so on.

GetMap: Make a map according to the client’s GetMap request parameters. The parameters required in the GetMap request include which layers to display, the length and width of the map, and the spatial coordinate system. Some WMS also support styled layer definition (styled layer descriptor, SLD), allowing users to dynamically specify the display symbols of each data layer in the URL request. The returned results are generally images in raster formats such as PNG, GIF, and JPEG.

The WMS specification also provides several optional requests, such as

  • GetFeaturelnfb: query the information of a location on a map, its typical application is that the user clicks a point on the map, and the server returns the coordinate information and attribute information of the geographical elements located at that point.

  • GetLegendGraphic: the legend of the layer can be made and returned according to the layer specified by the client. The return format is generally PNG, GIF and JPEG images.

The WMS specification is widely used and adopted by many organizations. For example, the United States Geological Survey (USGS) provides a series of WMS services, including the National Big Map WMS service, the National Atlas Transportation WMS service, the National Hydrographic Dataset WMS service, and the US real-time fire (mainly refers to wildfires) WMS service .

NASA Earth Observation System (NEO, http://neo.sci.gsfc.nasa.gov/Search.html) WMS ( http://neowms.sci.gsfc.nasa.gov/wms /wms ) and other methods to dynamically provide multi-time-series images of global climate and environmental changes, including sea surface temperature, land surface temperature, vegetation index, precipitation, carbon monoxide concentration, surface cover types, and the solar radiation received by the surface amount, etc.

(2) Web Map tile Service (WMTS-Web Map Tile Service)#

WMTS is a Web service specification for publishing tile maps formulated by OGC. WMTS is different from WMS, and the two complement each other.

WMS is mainly a dynamic map service, that is, the map is generated immediately by the server every time it receives a client request, which is especially suitable for map services whose data is constantly being updated. The map of WMTS is a tile pre-made by the server. This method can improve the performance and scalability of Web services, and is especially suitable for data whose data is relatively static and no longer updated or updated frequently.

The WMTS specification defines two necessary actions and one optional action.

  • GetCapabilities: gets the metadata of the service.

  • GetTile: get the tiles.

  • GetFeaturelnfo: optional, get the feature information that you click on.

(3) Web essential Services (WFS-Web Feature Service)#

WFS is developed by OGC to manipulate vector geographic elements and data on the Internet. It includes Web service specifications such as retrieval, insertion, update and deletion (OGC, 2005). WFS defines the following main operations.

  • GetCapabilities: gets the data of the service.

  • DescribeFeatureType: gets the structure of the feature types supported by WFS.

  • GetFeature: gets the geographic features and their attributes that match a query condition.

  • LockFeature: requests the server to lock one or more geographic features during a transaction.

  • Transaction: request the server to create, update, or delete geographic features.

The above operations are required and optional. According to the supported operations, WFS can be divided into the following two main categories.

  • Basic WFS (Basic WFS): only GetCapabilities, DescribeFeatureType and GetFeature operations are supported It can only query and read elements, so it is also called read-only WFS.

  • Transactional WTFS (TransactionWFS or WFS-T): supports transaction operations in addition to those supported by basic WFS. It can not only support the reading of geographical elements, but also support the online editing and processing of geographical features, also known as read-write WFS.

In the WFS request and response, the information transmission of geographical elements is mainly in GML format. In 2006, OGC adopted the GML simple element specific Standard (GML Simple Features Profile) to accelerate the speed of WFS request and response and simplify the difficulty of WFS implementation. WFS can be used not only for mapping and query, but also for geographic data cutting, projection conversion and online download. For example, the National Weather Service Meteorological Research Laboratory provides a National Digital Weather Forecast Database (NDFD) WFS service. The service allows the public, government agencies and enterprises to obtain data such as temperature, dew point, wind, precipitation probability and precipitation.

(4) Web coverage Service (WCS_Web Coverage Service)#

WCS is a Web service specification for publishing raster geographic data developed by OGC. The raster data it returns is raw data, such as the ground elevation value in digital elevation and the spectral value in satellite images. WMS is different because WMS returns a visualized image that has lost its original value.

The difference between WCS and WFS is that WFS is for vector data, while WCS is for raster data. The WCS specification specifies the following operations (OGC, 2006b):

  • GetCapabilities: returns the metadata for the service.

  • DescribeCoverage: returns the detailed description of the grid data layer in the service Such as time information, coverage, coordinate system and supported output format and so on.

  • GetCoverage: the server operates according to the data layer, space-time range, coordinate system, output format, interpolation method and data cutting and conversion specified by the client.

The National Snow and Ice Data Center (NSIDC) provides WCS services for the polar cryosphere. Users can obtain data on icing areas, including monthly ocean ice and concentration areas, snow coverage, and snow depth contours. Support research on polar ice cap melting and climate change (Maurer, 2007).

(5) Web processing Service (WPS-Web Processing Service)#

WPS is a Web service specification (OGC,2007c) provided by OGC for geographic analysis on the Internet. It defines the input and output (that is, request and response) formats of geographic analysis services, as well as how the client requests the execution of geographic analysis. The geographic data needed by WPS can be transmitted through the Internet, or it can be the data already available on the server. The main operations defined by WPS are GetCapabilities, DescribeProcess, and Execute.

(6) other Web service standards#

Catalog Service for Web (CSW):

Catalog Service is an important technology for sharing geospatial information. CSW supports searching and publishing of geospatial metadata, which allows users to query metadata to discover the geographic data and services they need, and allows providers to publish and update metadata. There are two types of CSW: read-only CSW and transactional CSW. Read-only CSW supports operations such as GetCapabilities, DescribeRecord, GetRecords, GetRecordByld, and GetDomain, and only supports metadata query and reading. Transactional CSW supports metadata reading and writing, allowing users to publish, edit, and delete metadata through transaction and harvest operations (OGC, 2007b). Products such as ArcGIS Geoportal Server provide a CSW interface.

Open location Services (OpenLS-Open Location Service):

this is a series of Web service specifications provided by OGC for location-based services (LBS; see Chapter 5). Including yellow pages search, tracking mobile phone users’ location and navigation services (OGC, 2004).

Sensor Network Integration Framework (SWE—Sensor Web Enablement):

The SWE framework includes a series of Web service standards: Sensor Observation Service (SOS), Sensor Planning Service (SPS), and Sensor Alarm Service (SAS). These standards enable users to discover and obtain sensor data from sensor networks.

2.4.4. Optimization of Web Services#

This section describes how to improve the quality of service (quality of service,QoS) of Web. The quality of service mainly includes the following important indicators.

  • Performance: describes the response efficiency of the system, usually measured by response time

  • Scalability: describes whether the system can maintain high performance with an increase in the number of users, usually measured by the number of users it can support at the same time

  • Availability: describes how accessible and operable a system is, usually as a percentage of the system’s elapsed time. The availability of a system is 99.99% Then the system can only have a maximum of 9 seconds of downtime per day (including accidental downtime caused by failure and artificial downtime required for system maintenance)

  • Security: describes the confidentiality and defense capabilities of the system.

Preprocessing (caching)#

Preprocessing, also known as caching, means that the system generates maps in advance or performs other tasks, and stores the results for later use, instead of generating maps or performing tasks in real time when the system is running and receiving user requests.

As shown in the figure, if there is a cache, the Web server can quickly retrieve the results from the cache, without the need to read data from the database, and complete the mapping and other processing in real time. Cache reduces the burden of GIS server and database server, and is an effective way to improve the quality of WebGIS services.

The Web server can quickly find the results from the cache and respond to user requests quickly, thus reducing the pressure on the GIS server and database, and improving the quality of service caching technology is mainly used to generate maps.

_images/imgvze41.png

Web access map slices#

Map cache, also known as map tiles or slices, is scheduled to generate a series of map slices (or tiles) according to a series of scales for quick display.

_images/imgvze42.png

Map slicing#

The main reasons for making map caching are:

  • Improve the performance, scalability and availability of the system: caching reduces the burden on the server, and users can get a quick response, thus saving users time.

  • Improve the quality of mapping: advanced symbols and complex layers can be used to produce high-quality maps.

  • Industry convention: caching is widely used in the current Web map application, which has become a common practice in the industry. It also changes users’ expectations of WebGIS, and they expect all WebGIS to provide a better user experience such as caching.

Before creating a cache, some planning needs to be done, for example, which coordinate system to use and which tiling scheme to adopt. The tile scheme includes scale level, scale of each level, tile size (eg 256px x 256px), tile start coordinates, tile area and image format (eg JPEG, PNG 8, PNG 24 or PNG 32) .

If your map will be used with ArcGIS Online, Google Maps or Microsoft Bing Maps, then your map should be in the same coordinate system as them, i.e. WGS 84 Web Mercator, and your tile scheme should match them match.

The creation of the cache may take a long time to complete, depending on the complexity of the map and the tile scheme, especially the scale series and the size of the scale. The layers with the largest scale generally occupy most of the time for creating the cache.

Caching is best for maps that change infrequently, such as street maps, imagery maps, topographic maps, and other underlying basemaps. If your data changes frequently, you can regularly update the cache to ensure the tile’s current status, or you can use the dynamic map method without tiles.

Optimization of algorithm and system#

WebGIS should carefully consider software algorithms and the optimization of software and hardware systems to achieve the best performance. Each GIS task has many different implementation methods. Discovering and adopting the optimal algorithm can greatly improve the performance of the system. For example, when map caching is not feasible or not the optimal solution, it is necessary to draw a map dynamically, but it is generally slow to generate a map dynamically. GIS database debugging is also an important part of WebGIS.

Some basic techniques include unifying geographic data into desired projections (eg Web Mercator); creating indexes, including spatial and attribute indexes; Maintain efficient tablespaces; clean up fragmentation of tablespaces and server drives; preload indexes and even data into memory; Update database statistics in a timely manner (so that the database can choose the best execution path when executing queries). The configuration plan of the system needs to consider how many users there are, how many people may be using the system at the same time, what they are doing with the system, how big the data volume of the system is, how the data volume will grow in the future, the response speed and availability required by the project How much is enough software and hardware to configure based on these factors.

Failover and load balancing#

Failover and load balancing are two deployment methods to improve system reliability and availability through redundant configuration. Failover means that when a server fails or needs maintenance, the system can automatically or manually redirect the Web user’s request to another server. Load balancing is assigning user requests to two or more servers, allowing multiple servers to share the work of the system. Large WebGIS systems should consider failover and load balancing. The site uses a Web gateway to accept incoming requests and distribute these requests to multiple GIS servers to achieve load balancing. If a GIS server computer becomes unavailable, the Web gateway can assign requests to the remaining GIS servers, creating a “high availability” architecture.

Reduce the pressure on Internet bandwidth#

The Web service receives the client’s request and returns the result to the client. The data transmission between the two, especially the transmission of geographic data, often requires considerable Internet bandwidth; otherwise, the quality of the Web service will be affected. The following methods can reduce the pressure on Internet bandwidth, which can improve the quality of web services.

  • Take advantage of the browser-side cache: the browser-side cache is different from the server-side cache. The server-side cache is mainly used to generate map tiles or other results in advance. The browser-side cache mainly refers to those content that has been downloaded to the browser, do not download again. The cache content on the browser side is often identified by URL, so the REST-style Web service makes it easy for the system to make full use of the cache on the browser side to improve the performance of the system.

  • Use HTTP compression: enable the compression option of the web server, compress the request and result of the web service, and then transmit it, which can reduce the amount of data transmission by 50% and improve the transmission efficiency of the system.

  • Choose the appropriate data format: for example, in many cases, JS0N and AMF are lighter than XML and easier to transmit than XML.

Security Protection of Web Service#

Many geographic Web services are public and free, but the Web services released by some enterprises and government agencies may contain content that involves the company’s secrets, customer privacy or charges, and these Web services need to be protected. Here are some basic techniques for securing web services.

  • Use of private network and virtual private network: In this solution, the Web service and its users are co-located in the internal network of a certain unit, and are isolated from the external network through firewalls and other methods, so that external network users cannot access. A Virtual Private Network (VPN) creates a secure tunnel on the Internet. Through the VPN, even if the client is not in the office of the unit, still can log in to the intranet and use the web services on the intranet.

  • Authentication: Secure web services with user roles and permissions. User identities can be managed using Lightweight Directory Access Protocol (LDAP), Windows Active Directory, etc.

  • Security token (token):-A token is an encrypted string that contains encrypted authorization information. Tokens are obtained through application or when the user logs in.

  • Secure Hypertext transfer Protocol (HTTPS): HTTPS encrypts data transferred between Web services and customers to prevent information from being intercepted and tampered with.

  • Reverse proxy: use a proxy server to accept connection requests on the Internet, then forward the request to the server on the internal network, and return the result obtained from the server to the client. In this way, the proxy server can hide the GIS server in the intranet, providing a barrier between the GIS server and possible malicious attacks, providing a layer of protection.

_images/imgvze43.png

Geospatial Web service protection#

Web service technology is an important progress in distributed computing and GIS, and it is the core of modern WebGIS. Geospatial Web Services are the driving force behind the transformation of GIS applications from closed systems to open, loosely coupled architectures. It is an important form of building components of geo-converged applications and providing services for cloud GIS. It is the foundation of the next generation spatial data infrastructure and provides a collaborative way based on geographic information. Governments and enterprises can provide their data and functions as Web services and build an ecosystem of Web services. On this basis, a large number of applications with new value can be conceived. This form of mutual cooperation can maximize the social benefits of investment in the field of geospatial.