Hi All, The implementation, $subject is adding some scripting support for Siddhi. It is as follows,
1. Scripting languages are going to be JavaScript and Scala. 2. New language feature is to be introduced like below, Define script[Language]{//script implementation goes here} 3. Siddhi user can choose the scripting language mentioning it like below in Siddhi, Define script[JavaScript] {//JavaScript implementation goes here} or Define script[Scala]{//Scala implementation goes here} 4. The functions or methods defined are to be available to the user to call it like Siddhi inbuilt function. For example, let's just define and call a Scala-method in Siddhi like below, define script[Scala] { Def *getSymbol*(id: String): String = id } define stream cseEventStream (symbol string, price float, volume string) from cseEventStream select *getSymbol*(symbol), convert(volume,long)/1000 as vol, sum(convert(volume,long)) as sumVolume group by symbol insert into StockQuote; Appreciate your thoughts!!! Thanks, -Ayash -- Ayashkantha Ramasinghe Software Engineer WSO2, Inc. email: ayashkan...@wso2.com <sanj...@wso2.com>; TP: +94 77 7 487 669
_______________________________________________ Architecture mailing list Architecture@wso2.org https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture