[preface] .[big]*OGC® Engineering Report* *COPYRIGHT* Copyright © 2016 Open Geospatial Consortium. To obtain additional rights of use, visit http://www.opengeospatial.org/ *WARNING* This document is not an OGC® Standard. This document is an OGC® Public Engineering Report created as a deliverable in an OGC® Interoperability Initiative and is not an official position of the OGC® membership. It is distributed for review and comment. It is subject to change without notice and may not be referred to as an OGC® Standard. Further, any OGC® Engineering Report should not be referenced as required or mandatory technology in procurements. However, the discussions in this document could very well lead to the definition of an OGC® Standard. <<<< *LICENSE AGREEMENT* [small]#Permission is hereby granted by the Open Geospatial Consortium, ("Licensor"), free of charge and subject to the terms set forth below, to any person obtaining a copy of this Intellectual Property and any associated documentation, to deal in the Intellectual Property without restriction (except as set forth below), including without limitation the rights to implement, use, copy, modify, merge, publish, distribute, and/or sublicense copies of the Intellectual Property, and to permit persons to whom the Intellectual Property is furnished to do so, provided that all copyright notices on the intellectual property are retained intact and that each person to whom the Intellectual Property is furnished agrees to the terms of this Agreement.# [small]#If you modify the Intellectual Property, all copies of the modified Intellectual Property must include, in addition to the above copyright notice, a notice that the Intellectual Property includes modifications that have not been approved or adopted by LICENSOR.# [small]#THIS LICENSE IS A COPYRIGHT LICENSE ONLY, AND DOES NOT CONVEY ANY RIGHTS UNDER ANY PATENTS THAT MAY BE IN FORCE ANYWHERE IN THE WORLD. THE INTELLECTUAL PROPERTY IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS NOTICE DO NOT WARRANT THAT THE FUNCTIONS CONTAINED IN THE INTELLECTUAL PROPERTY WILL MEET YOUR REQUIREMENTS OR THAT THE OPERATION OF THE INTELLECTUAL PROPERTY WILL BE UNINTERRUPTED OR ERROR FREE. ANY USE OF THE INTELLECTUAL PROPERTY SHALL BE MADE ENTIRELY AT THE USER’S OWN RISK. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR ANY CONTRIBUTOR OF INTELLECTUAL PROPERTY RIGHTS TO THE INTELLECTUAL PROPERTY BE LIABLE FOR ANY CLAIM, OR ANY DIRECT, SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM ANY ALLEGED INFRINGEMENT OR ANY LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR UNDER ANY OTHER LEGAL THEORY, ARISING OUT OF OR IN CONNECTION WITH THE IMPLEMENTATION, USE, COMMERCIALIZATION OR PERFORMANCE OF THIS INTELLECTUAL PROPERTY.# [small]#This license is effective until terminated. You may terminate it at any time by destroying the Intellectual Property together with all copies in any form. The license will also terminate if you fail to comply with any term or condition of this Agreement. Except as provided in the following sentence, no such termination of this license shall require the termination of any third party end-user sublicense to the Intellectual Property which is in force as of the date of notice of such termination. In addition, should the Intellectual Property, or the operation of the Intellectual Property, infringe, or in LICENSOR’s sole opinion be likely to infringe, any patent, copyright, trademark or other right of a third party, you agree that LICENSOR, in its sole discretion, may terminate this license without any compensation or liability to you, your licensees or any other party. You agree upon termination of any kind to destroy or cause to be destroyed the Intellectual Property together with all copies in any form, whether held by you or by any third party.# [small]#Except as contained in this notice, the name of LICENSOR or of any other holder of a copyright in all or part of the Intellectual Property shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Intellectual Property without prior written authorization of LICENSOR or such copyright holder. LICENSOR is and shall at all times be the sole entity that may authorize you or any third party to use certification marks, trademarks or other special designations to indicate compliance with any LICENSOR standards or specifications.# [small]#This Agreement is governed by the laws of the Commonwealth of Massachusetts. The application to this Agreement of the United Nations Convention on Contracts for the International Sale of Goods is hereby expressly excluded. In the event any provision of this Agreement shall be deemed unenforceable, void or invalid, such provision shall be modified so as to make it valid and enforceable, and as so modified the entire Agreement shall remain in full force and effect. No decision, action or inaction by LICENSOR shall be construed to be a waiver of any rights or remedies available to it.# [small]#None of the Intellectual Property or underlying information or technology may be downloaded or otherwise exported or reexported in violation of U.S. export laws and regulations. In addition, you are responsible for complying with any local laws in your jurisdiction which may impact your right to import, export or use the Intellectual Property, and you represent that you have complied with any regulations or registration procedures required by applicable law to make this license enforceable.# <<< toc::[] <<< .[big]*Abstract* This engineering report describes a protocol for synchronizing data between two enterprise servers. While the protocol itself is generic, this engineering report describes its application to web feature servers. In the simplest terms, the protocol involves each synchronization peer accessing the other’s "Sync" resource to get the set of changed objects since the last time the "Sync" resource was accessed. In the case of web feature servers, the objects are features. The requesting peer then compare that list of changed features with the identically identified features in its data store and performs any necessary changes so that the feature states match. Continuing the work done in Testbed-11, this engineering report describes the implementation of a Sync operation in a WFS server that: . Enhances the Sync operation from Testbed-11 to include an abstract query element where each service type can then substitute their specific query syntax for identifying the specific sub-set of changed features to be synchronized. In the case of the WFS, several query syntaxes may be used including the wfs:Query element and a REST based feature type URI with query parameters. . Extends the definition of the Sync operation with the addition of a "resultType" parameter to allow a client to obtain a hit count of the number of features that a Sync operation shall return. . Shall investigate the proper procedure for handling resource references. Implementing the resolvePath parameter alone is not sufficient to ensure complete data set synchronization. . Shall investigate concurrency and consistency issues. NOTE: With regard to the resolvePath parameter; in order to be able to test the use of this parameter, the feature encoding needs to support the ability to reference resources (i.e. property values, other features, etc.). Although Testbed-11 used GeoJSON, this format is not sufficiently mature in this regard and so we propose using GML as the feature encoding format for this round of sync testing. .[big]*Business Value* Data synchronization is a fundamental means by which data consistency is achieved and maintained over time between a source and target data system. It is fundamental to a wide variety of applications including, for example, file synchronization and synchronization between mobile devices and especially in a low-connectivity environment such as might exist after a natural disaster. Anyone who has ever synchronized their iPod/iPhone with iTunes has experienced data synchronization in action. .[big]*What does this ER mean for the Working Group and OGC® in general* With regard to the WFS/FES SWG, this engineering report defines the means by which peer-to-peer data synchronization can be performed with web feature services. This can be synchronization between two web feature services or synchronization between a web feature service and some other system (e.g. a web processing service that manages geopackages). With regard to the GeoSynchronization 1.0 SWG, the current draft GSS standard defines a publish-subscribe architecture for synchronization between services with the GeoSynchronization service acting as the broker. This engineering report describes and alternative synchronization architecture that should be considered by the GSS SWG. Although the testing platform for synchronization for Testbed-12 is the web feature service, the protocol described in this engineering report is applicable to a number of OGC® standards and so there is a strong likelihood that some of the elements of the description should end up in the OWS Common standard. For the OGC® in general, this engineering report defines a generic synchronization protocol that can be used to maintain data consistency across a variety of systems ranging from the very small (e.g. mobile devices with geopackages) to the very large (e.g. enterprise level data services such as web feature services). .[big]*How does this ER relates to the work of the Working Group* Although the protocol described in this engineering report is generic, the web feature service was used as the testing platform in Testbed 12. As such, this engineering report describes modification and extensions to the web feature service standard that need to be considered by the WFS/FES SWG. As mentioned above, one part of the GSS draft standard describes a publish-subscribe architecture for synchronization. The work described in this engineering report is directly related to synchronization and is thus directly related to the work of the GSS SWG. Although the WFS was used as a testing platform, the synchronization protocol described in this engineering report is generic and could be applicable to a variety of OGC® standards. As such, it is related to one of the primary purposes of the OWS Common 1.2 SWG which is to collect common elements among OGC® standards (e.g. BBOX encoding) into a single standard where this information can be referenced rather than be copied over and over. .[big]*Keywords* ogcdocs, testbed-12, synchronization, web feature service, WFS, filter, change set, low connectivity, checkpoint, service identifier, REST, XML, KVP .[big]*Proposed OGC® Working Group for Review and Approval* This engineering report shall be submitted to the WFS/FES SWG, the GeoSynchronization 1.0 SWG and the OWS Common 1.2 SWG for review and comment.