XChange: A semantic diff approach for XML documents. (December 2020) - Oliveira, Alessandreia; Kohwalter, Troy; Kalinowski, Marcos; Murta, Leonardo; Braganholo, Vanessa
Abstract: XML documents are extensively used in several applications and evolve over time. Identifying the semantics of these changes becomes a fundamental process to understand their evolution. Existing approaches related to understanding changes ( diff ) in XML documents focus only on syntactic changes. These approaches compare XML documents based on their structure, without considering the associated semantics. However, for large XML documents, which have undergone many changes from a version to the next, a large number of syntactic changes in the document may correspond to fewer semantic changes, which are then easier to analyze and understand. For instance, increasing the annual salary and the gross pay, and changing the job title of an employee (three syntactic changes) may mean that this employee was promoted (one semantic change). In this paper, we explore this idea and present the XChange approach. XChange considers the semantics of the changes to calculate the diff of different versions of XML documents. For such, our approach analyzes the granular syntactic changes in XML attributes and elements using inference rules to combine them into semantic changes. Thus, differently from existing approaches, XChange proposes the use of syntactic changes in versions of an XML document to infer the real reason for the change and support the process of semantic diff. Results of an experimental study indicate that XChange can provide higher effectiveness and efficiency when used to understand changes between versions of XML documents when compared with the (syntactic) state-of-the-art approaches. Highlights: Novel approach for inferring the semantic diff between two XML documents. Helps understand the evolution of two sequential versions of the same document. Infers semantic changes from the syntactic changes in XML documents. Semantic identification is more effective in understanding the document evolution. Semantic identification is more efficient in understanding the document evolution.