In CCL, the Aleri ComputeStream "foreignStream" migrates to an CREATE OUTPUT WINDOW statement, and the Store element migrates to a CREATE MEMORY STORE statement.
In this example, the Aleri ComputeStream element has a foreign function that it calls as ColumnExpression. The Aleri foreign function migrates to a CREATE LIBRARY statement, and the foreign function references in the ColumnExpression migrate to Lib_0.intfun( ).
<Store file="store1" id="store1" kind="memory"/> <ComputeStream id="foreignStream" istream="eqInput" store="store1"> <ColumnExpression key="true" name="a">eqInput.a</ColumnExpression> <ColumnExpression key="false" name="intData">foreign("/opt/aleriTests/lib/unit/foreign1.so",intfun,int32)</ColumnExpression> <ColumnExpression key="false" name="charData">foreign("/opt/aleriTests/lib/unit/foreign1.so",stringfun,string)</ColumnExpression> </ComputeStream>
CCL:
CREATE MEMORY STORE store1 PROPERTIES INDEXTYPE ='tree', INDEXSIZEHINT =8; CREATE LIBRARY Lib_0 LANGUAGE C FROM '/opt/aleriTests/lib/unit/foreign1.so' ( INTEGER intfun ( ); ); CREATE LIBRARY Lib_1 LANGUAGE C FROM '/opt/aleriTests/lib/unit/foreign1.so' ( STRING stringfun ( ); ); CREATE OUTPUT WINDOW foreignStream SCHEMA (a INTEGER, intData INTEGER, charData STRING) PRIMARY KEY (a) STORE store1 AS SELECT eqInput.a AS a, Lib_0.intfun( ) AS intData, Lib_1.stringfun( ) AS charData FROM eqInput;