Reference System Transformation Potential Pitfalls

Copyright © 2010 Open Geospatial Consortium, Inc. 97 geometry, a time or some thematic property is the same as the one that will later be filtered upon. In other words, the filter operations can easily be performed. It is also possible to ignore the reference systems completely and to assume that they are the same. An example of an according filter statement would be “air temperature is below 10” and of an appropriate event “observation air temperature is 8.7 °C”. However, in an Event Architecture this may not always be the case. Here, an Event Service can offer functionality to automatically transform the values of the filter operands and those of the incoming events to a compatible reference system so that the filter operation can be executed. The Sensor Event Service OGC Discussion Paper 08-133 defines support for unit conversion. It does not define a generic mechanism to solve the issue. Further work to define such a mechanism would be beneficial, especially with respect to the heterogeneity of events and event sources in a cross-domain Event Architecture.

9.2 Filter Processing Languages

9.2.1 Filter Encoding

The OGC Filter Encoding Specification FES supports filtering of generic XML instances. This is achieved via XPath expressions that are used to point to attributes or elements in the XML. These properties provide the values that a filter operates upon. FES supports a wide range of filter functionality temporal, spatial and thematic filters. It also supports additional functions which can be vendor specific or defined in standards. Applications need to take care that the namespace-prefix binding used for XPath expressions of a filter statement are preserved – this is explained in more detail in the following section.

9.2.2 XPath

The XML Path Language XPath 4 supports filtering of XML instance documents. It provides simple comparison functions but also logical and temporal operations 5 . So far no spatial operations are supported. In addition, operations do not take into account the possible meaning of a complex XML element – like a gml:TimePeriod element contained in the XML instance. Applications need to take care that the namespace-prefix binding used in an XPath expression are preserved and not destroyed by changing the namespace prefixes of XML instances. This can result in the expression no longer being able to identify the correct XML attributes and elements in other words: the event properties. 4 http:www.w3.orgTRxpath20 5 http:www.w3.orgTRxpath-functions 98 Copyright © 2010 Open Geospatial Consortium, Inc. One way to solve this issue could be to convert the XPath expression into a simple XQuery expression. For example, if the XPath expression would be: [abc:PropertyX] then it could easily be augmented by prepending a list of namespace declarations according to the XQuery specification. The resulting XQuery expression would then be: declare namespace abc = http:www.opengis.netabc1.0; [abc:PropertyX] This requires a service to support XQuery transformations. However, this mechanism could also become an OGC extension of XPath that would be well-documented in the appropriate documents. As described in section 9.1.1, an XPath expression used to filter events needs to be evaluated by an Event Service to a boolean expression. The service can then unambiguously determine if a given event matches a subscription’s filter criteria. When using XPath as a filter language in an Event Service, the service should apply an implicit boolean function call to the results of an XPath expression – evaluated according to the XPath functions specification 6 .

9.2.3 Event Pattern Markup Language

Filtering not only single events but whole event streams is what the Event Processing domain is concerned with. The order of events in the stream, their timing as well as patterns that can be detected are of interest here, among others. Detection of event patterns allow the derivation of higher level information from low level events. Critical information shall be produced as soon as possible in order to react to it. Event processing nowadays is primarily concerned with financial applications. However, the techniques are more and more also used in other domains as well – also in the geospatial domain. The Event Pattern Markup Language EML; OGC 08-132 defines basic event processing functionality. The pattern language can be incorporated in processing languages like SensorML but may also extend the filter and processing functionality offered by OGC event services. When using EML, one should keep in mind that it is currently an OGC Discussion Paper and not an approved OGC Standard. Therefore, the concepts described in the specification as well as the markup language to express event patterns may change significantly in the future even though that may not be intended at this time. In addition, no standards have been defined in the event processing domain yet. In other words, there is no SQL for Event Processing – even though some vendors may claim that their 6 http:www.w3.orgTRxpath-functionsfunc-boolean