Hi, I have tried to summarize the conclusions of the discussion up to now and put them in a shared google doc that we can use from on to add more conclusions that could arise. https://docs.google.com/document/d/11bD-tWz7CA1iVww1Kteob3kf8DJ0AZRNr6pQhJnY-LI/edit In the document, I have tried to show concrete examples of the involved messages, base on my knowledge of NGSI and the feedback that Tali has provided. It would be great Tali if you could review that last part, to check if everything is ok from CEP point of view or fix otherwise (please tell me your google id to provide writing permission in the document, if you like). As I think somebody has already mentioned, we need to know which kind of entities, attributes and CEP processings Outmart needs (note that in the document I have used a "dummy" example). Who should provide that information? Of course, everybody is welcome to read the document and provide feedback. Comments are open to everybody, so you can use that to provide your feedback in specify parts of the documents. Best regards, ------ Fermín El 19/02/2013 12:27, Tali Yatzkar-Haham escribió: Hi Fano and all, In the CEP, the application developer defines the CEP input and output events types as part of the application definition that contains events, rules, producer, consumer,... This is usually done through the CEP Web UI. Each event type has a name and a set of attributes, where each attribute has a type and a name. The definition of the event types will not be done using the CEP <-> P/S adapter. At run time, the CEP expect to get only events instances from defined event type. The CEP expects to get it in a flat JSON format of key value pairs. The name (type) of the event is given in an attribute called "Name" Example(you can find them in the wiki<http://forge.fi-ware.eu/plugins/mediawiki/wiki/fiware/index.php/Complex_Event_Processing_Open_RESTful_API_Specification_%28PRELIMINARY%29#Getting_Events_API>): 1. TrafficReport input event with only one attribute called volume: {"Name":"TrafficReport", "volume":"1000"} 2. TrafficReport output event with one attribute called volume and several auto-generated CEP attributes {"Cost":"0.0","Certainty":"0.0","Name":"TrafficReport","EventSource":"","Duration":"0.0","Annotation":"", "volume":"1000","EventId":"e206b5e8-9f3a-4711-9f46-d0e9431fe215","DetectionTime":"1350311378034"} Note that all the attributes are given as Strings (the CEP parses them internally according to the attributes defined type), the attributes are not ordered. Please tell me if you have any questions about the event format. Regards, Tali Yatzkar-Haham Event-based Middleware & Solutions Group IBM Haifa Research Lab ________________________________ Phone: 972-4-829-6320 | Mobile: 972-54-4388482 E-mail: TALI at il.ibm.com<mailto:TALI at il.ibm.com> Haifa University, Mount Carmel Haifa, 31905 Israel From: <fano.ramparany at orange.com><mailto:fano.ramparany at orange.com> To: Tali Yatzkar-Haham/Haifa/IBM at IBMIL, Cc: "fiware-data at lists.fi-ware.eu"<mailto:fiware-data at lists.fi-ware.eu> <fiware-data at lists.fi-ware.eu><mailto:fiware-data at lists.fi-ware.eu> Date: 19/02/2013 12:32 PM Subject: RE: [Fiware-data] CEP<->P/S ________________________________ Hi Tali, You'll find attached a queryContextResponse xml document to give you an idea. Although in our case we need the document contained in a notifyContext message. I've got a message from the ngsi mailinglist with a link to such NGSI messages samples, but unfortunately and can't find it right now... Regards, Fano De : Tali Yatzkar-Haham [mailto:TALI at il.ibm.com] Envoyé : mardi 19 février 2013 08:12 à : RAMPARANY Fano OLNC/OLPS Cc : fiware-data at lists.fi-ware.eu<mailto:fiware-data at lists.fi-ware.eu> Objet : Re: [Fiware-data] CEP<->P/S Hi Fano, and all, Yes, as I wrote in my previous mail - the CEP can activate external REST API for sending CEP output events (In my previous mail, I point to the documentation of it). Maybe you can send us an example of an P/S event and we can see how to transform it to CEP event. If you also know what is the event data you expect the CEP to generate, we can then transform it back to P/S event. Do you have such an example? Regards, Tali Yatzkar-Haham Event-based Middleware & Solutions Group IBM Haifa Research Lab ________________________________ Phone: 972-4-829-6320 | Mobile: 972-54-4388482 E-mail: TALI at il.ibm.com<mailto:TALI at il.ibm.com> Haifa University, Mount Carmel Haifa, 31905 Israel From: fano.ramparany at orange.com<mailto:fano.ramparany at orange.com> To: Fermín Galán Márquez <fermin at tid.es<mailto:fermin at tid.es>>, Cc: BELLABAS Alia OLNC/OLPS <alia.bellabas at orange.com<mailto:alia.bellabas at orange.com>>, "fiware-data at lists.fi-ware.eu<mailto:fiware-data at lists.fi-ware.eu>" <fiware-data at lists.fi-ware.eu<mailto:fiware-data at lists.fi-ware.eu>> Date: 18/02/2013 06:44 PM Subject: Re: [Fiware-data] CEP<->P/S Sent by: fiware-data-bounces at lists.fi-ware.eu<mailto:fiware-data-bounces at lists.fi-ware.eu> ________________________________ Hi Fermin and all, My feedback inline... De : Fermín Galán Márquez [mailto:fermin at tid.es] Objet : Re: [Fiware-data] CEP<->P/S ... So, if I'm understanding correctly, we need two adaptation steps: 1. PubSub -> (Adaptator1) -> CEP. In this case, the best approach would be to subscribe Adaptator1 to notifications of Outsmart data/context events in PubSub, so when a new event is received from OutSmart IoT, then PubSub will send a NGSI10 notifyContext to Adaptator.1 Then, Adaptator1 will transform this NGSI to a REST request according to the CEP "Sending Events" API described at http://forge.fi-ware.eu/plugins/mediawiki/wiki/fiware/index.php/Complex_Event_Processing_Open_RESTful_API_Specification_%28PRELIMINARY%29#Sending_Events_API. [FR] This seems to me the right thing to do. The content of the notifyContext message and how it should be transformed into CEP event description has to be elaborated though. 2. CEP -> (Adaptator2) -> PubSub. In this case, I understand that the CEP is not capable of pro-actively send data/context events (please, tell me if I'm wrong), so Adaptator2 will need to periodically poll CEP using the CEP "Getting events"API described at http://forge.fi-ware.eu/plugins/mediawiki/wiki/fiware/index.php/Complex_Event_Processing_Open_RESTful_API_Specification_%28PRELIMINARY%29#Getting_Events_API, sending NGSI10 updateContext to PubSub when a new event (or change) is detected. [FR] As far as I understand, Tali can correct me if I'm wrong, CEP can pro-actively create event and there's a CEP API for being notified of new events (based itself on a polling mechanism which is transparent to the component using this API, except for setting up the polling frequency). This simplifies your design which for the rest I agree with. (Adaptator1 and Adaptator2 are logical entities; of course they can be implemented by the same piece of software). Is my interpretation correct? If it is right, I would suggest as next step to write "reference messages" for the four cases (notifyContext, "Sending events", "Gettings events" and updateContext). Best regards, ------ Fermín El 18/02/2013 16:11, fano.ramparany at orange.com<mailto:fano.ramparany at orange.com> escribió: Dear all, Determining the respective roles of the CEP and P/S in the overall architecture is very important and will dictate what additional components need to be implemented. In the discussion so far, it is considered that P/S is an event source that feeds the CEP with events, which I think is fine. I think that conversely the CEP should be a context provider for the P/S. Because if an application would like a pattern of events to be detected such as in the case of OUTSMART UC "a street lamp is not switched on whereas it is dusk", it should subscribe to the P/S. The simplest scenario I foresee is that the CEP create an event which corresponds to this situation (this pattern of events) as soon as is occurrs and push it towards the P/S. The application would then be notified, provided that it has subscribed to this event. More generally, could we draw the overall architecture depicting the GEs and the dataflow they exchange? It will then be clearer for UC projects, how they can use the GE involved. Best regards, Fano De : fiware-data-bounces at lists.fi-ware.eu<mailto:fiware-data-bounces at lists.fi-ware.eu> [mailto:fiware-data-bounces at lists.fi-ware.eu] De la part de Moltchanov Boris Envoyé : vendredi 15 février 2013 07:18 à : fermin at tid.es<mailto:fermin at tid.es>; fiware-data at lists.fi-ware.eu<mailto:fiware-data at lists.fi-ware.eu> Objet : Re: [Fiware-data] CEP<->P/S yes, P/S NGSI. BR, B ?????????? ? Samsung Mobile Fermín Galán Márquez <fermin at tid.es><mailto:fermin at tid.es> ???????: Dear Boris, I have two doubts regarding this topic: * Is the interface exposed by CEP documented in some place (e.g. URL in the FIWARE wiki)? * I understand you are considering NGSI as the interface exposed by P/S, right? Thanks! Best regards, ------ Fermín El 14/02/2013 17:57, Moltchanov Boris escribió: Dear All, The conclusion after our AC would be that, as WP6, we need an intermediate component (converter, middleware, platform) performing the following functions between the CEP and P/S GEs: - Subscribe the P/S only for needed data/scope/entityIDs. - Enrich events containing the data, becoming the context, with entityIDs and scopes taken from events attribute; - Parse the context, becoming the events, and build the events integrating into the event structure the entityID and scopes as the attributes for feeding the CEP with the event coming from context P/S flow; - Converting JSON2XML and vice versa XML2JSON. This piece could be used also for other components , GEs, etc. in FI-WARE and UCPs. Then, given the application (UCP or generically application domain) the P/S will be subscribed only to that context, which is relevant for the event generation for that UCP, or generally speaking application domain, by the CEP. Best Regards, Boris Questo messaggio e i suoi allegati sono indirizzati esclusivamente alle persone indicate. La diffusione, copia o qualsiasi altra azione derivante dalla conoscenza di queste informazioni sono rigorosamente vietate. Qualora abbiate ricevuto questo documento per errore siete cortesemente pregati di darne immediata comunicazione al mittente e di provvedere alla sua distruzione, Grazie. This e-mail and any attachments is confidential and may contain privileged information intended for the addressee(s) only. Dissemination, copying, printing or use by anybody else is unauthorised. If you are not the intended recipient, please delete this message and any attachments and advise the sender by return e-mail, Thanks. Rispetta l'ambiente. Non stampare questa mail se non è necessario. _______________________________________________ Fiware-data mailing list Fiware-data at lists.fi-ware.eu<mailto:Fiware-data at lists.fi-ware.eu> http://lists.fi-ware.eu/listinfo/fiware-data ________________________________ Este mensaje se dirige exclusivamente a su destinatario. Puede consultar nuestra política de envío y recepción de correo electrónico en el enlace situado más abajo. This message is intended exclusively for its addressee. We only send and receive email on the basis of the terms set out at: http://www.tid.es/ES/PAGINAS/disclaimer.aspx _________________________________________________________________________________________________________________________ Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration, France Telecom - Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci. This message and its attachments may contain confidential or privileged information that may be protected by law; they should not be distributed, used or copied without authorisation. If you have received this email in error, please notify the sender and delete this message and its attachments. As emails may be altered, France Telecom - Orange is not liable for messages that have been modified, changed or falsified. Thank you. ________________________________ Este mensaje se dirige exclusivamente a su destinatario. Puede consultar nuestra política de envío y recepción de correo electrónico en el enlace situado más abajo. This message is intended exclusively for its addressee. We only send and receive email on the basis of the terms set out at: http://www.tid.es/ES/PAGINAS/disclaimer.aspx _________________________________________________________________________________________________________________________ Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration, France Telecom - Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci. This message and its attachments may contain confidential or privileged information that may be protected by law; they should not be distributed, used or copied without authorisation. If you have received this email in error, please notify the sender and delete this message and its attachments. As emails may be altered, France Telecom - Orange is not liable for messages that have been modified, changed or falsified. Thank you. _______________________________________________ Fiware-data mailing list Fiware-data at lists.fi-ware.eu<mailto:Fiware-data at lists.fi-ware.eu> http://lists.fi-ware.eu/listinfo/fiware-data _________________________________________________________________________________________________________________________ Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration, France Telecom - Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci. This message and its attachments may contain confidential or privileged information that may be protected by law; they should not be distributed, used or copied without authorisation. If you have received this email in error, please notify the sender and delete this message and its attachments. As emails may be altered, France Telecom - Orange is not liable for messages that have been modified, changed or falsified. Thank you. [attachment "queryContextResponse-VehicleLocation0.xml" deleted by Tali Yatzkar-Haham/Haifa/IBM] _______________________________________________ Fiware-data mailing list Fiware-data at lists.fi-ware.eu<mailto:Fiware-data at lists.fi-ware.eu> http://lists.fi-ware.eu/listinfo/fiware-data ________________________________ Este mensaje se dirige exclusivamente a su destinatario. Puede consultar nuestra política de envío y recepción de correo electrónico en el enlace situado más abajo. This message is intended exclusively for its addressee. We only send and receive email on the basis of the terms set out at: http://www.tid.es/ES/PAGINAS/disclaimer.aspx -------------- next part -------------- An HTML attachment was scrubbed... URL: <https://lists.fiware.org/private/old-fiware-data/attachments/20130219/fd9c7f50/attachment.html>
You can get more information about our cookies and privacy policies clicking on the following links: Privacy policy Cookies policy