Re: [Dev] [Gmail Connector] Error connecting to gmail connector

2016-06-03 Thread Maheeka Jayasuriya
Thanks Hariprasad for taking time on helping to resolve the issue. The
mentioned approach is now working.

Maheeka Jayasuriya
Senior Software Engineer
Mobile : +9450661

On Sat, Jun 4, 2016 at 10:49 AM, Hariprasath Thanarajah <
haripras...@wso2.com> wrote:

> Hi Maheeka,
>
> If you are trying to get the refresh token and accessToken from oAuth
> playground you should refresh the refreshToken in oAuth playground only
> because in oAuth playground it sets the redirect_uri as https%3A%2F%
> 2Fdevelopers.google.com%2Foauthplayground is not your app redirect_uri.
> So after one hour if you trying any method it gave the error.
> Better trying below url[1] to get the code and using [2] to get the
> refresh token.
>
> [1] - https://accounts.google.com/o/oauth2/auth?redirect_uri=* redirect-uri>*&response_type=code&client_id=**&scope=
> https://mail.google.com/+https://www.googleapis.com/auth/gmail.compose+https://www.googleapis.com/auth/gmail.insert+https://www.googleapis.com/auth/gmail.labels+https://www.googleapis.com/auth/gmail.modify+https://www.googleapis.com/auth/gmail.readonly+https://www.googleapis.com/auth/gmail.send&approval_prompt=force&access_type=offline
>
> [2] - I have attached below
>
>
> From [2]  you can get the refresh_token and you can use it in the init
> call. Then you won't get the error.
>
> On Sat, Jun 4, 2016 at 8:09 AM, Malaka Silva  wrote:
>
>> Yes this should be the way. Only use init method before each call.
>>
>> On Sat, Jun 4, 2016 at 8:00 AM, Shakila Sivagnanarajah 
>> wrote:
>>
>>> Hi Maheeka,
>>>
>>> Since the refreshing access token is automated in the connector, you can
>>> use following init configuration.
>>>
>>>  
>>> {$ctx:refreshToken}
>>> {$ctx:clientId}
>>> {$ctx:clientSecret}
>>>
>>> {$ctx:accessTokenRegistryPath}
>>> {$ctx:accessToken}
>>> {$ctx:apiUrl}
>>> {$ctx:userId}
>>> 
>>> 
>>> {$ctx:to}
>>> {$ctx:subject}
>>> {$ctx:from}
>>> {$ctx:messageBody}
>>> {$ctx:cc}
>>> {$ctx:bcc}
>>> 
>>> 
>>>
>>> Thanks
>>>
>>> On Sat, Jun 4, 2016 at 7:40 AM, Shakila Sivagnanarajah >> > wrote:
>>>
 Hi Maheeka,

 I Just have tested it, it is working fine. It seems the access token is
 not set in your call.

 Please try with this configuration.

 
 {$ctx:refreshToken}
 {$ctx:clientId}
 {$ctx:clientSecret}
 {$ctx:grantType}
 
 
 {$ctx:apiUrl}
 {$ctx:userId}
 
 
 {$ctx:to}
 {$ctx:subject}
 {$ctx:from}
 {$ctx:messageBody}
 {$ctx:cc}
 {$ctx:bcc}
 
 


 Thanks

 On Sat, Jun 4, 2016 at 7:33 AM, Malaka Silva  wrote:

> Looping Hariprasath.
>
> On Sat, Jun 4, 2016 at 7:25 AM, Shakila Sivagnanarajah <
> shak...@wso2.com> wrote:
>
>> Hi Maheeka,
>>
>> I will check and update you
>>
>> Thanks
>>
>> On Sat, Jun 4, 2016 at 1:05 AM, Maheeka Jayasuriya 
>> wrote:
>>
>>> Hi Shakila/Malaka,
>>>
>>> I am getting the following errors when using the latest gmail
>>> connector from connector store. I am getting the clientId and 
>>> clientSecret
>>> from the app and the refresh token and access token from playground app.
>>> Used apiUrl as https://www.googleapis.com/gmail.
>>>
>>> Am I doing any configuration wrong?
>>>
>>> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "POST //v1/users/johndoeintcl...@gmail.com/messages/send
>>> HTTP/1.1[\r][\n]"
>>> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "X-Frame-Options: SAMEORIGIN[\r][\n]"
>>> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "Authorization: Bearer [\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "Alt-Svc: quic=":443"; ma=2592000;
>>> v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "Vary: X-Origin[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "X-XSS-Protection: 1; mode=block[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "Expires: Fri, 03 Jun 2016 18:34:43 GMT[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "Alternate-Protocol: 443:quic[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "Content-Type: application/json; charset=UTF-8[\r][\n]"
>>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "Accept-Ranges: none[\r][\n]"
>>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3
>>> << "X-Content-Type-

Re: [Dev] Fwd: GSOC2016: [ML][CEP] Predictive analytic with online data for WSO2 Machine Learner

2016-06-03 Thread Mahesh Dananjaya
Hi Maheshakya,
As you requested i can change other parameters as well such as feature
size(p). Initially i did it with p=3;sure thing. Anyway you can see and run
the code if you want. source is at [1]. the test timing is called with
random data as you requested if you set args[0] to 1. And you can find the
extension and streaming algorithms in gsoc/ directiry[2]. thank you.
BR,
Mahesh.
[1]
https://github.com/dananjayamahesh/GSOC2016/blob/master/spark-examples/first-example/src/main/java/org/sparkexample/StreamingLinearRegression.java
[2] https://github.com/dananjayamahesh/GSOC2016/tree/master/gsoc

On Sat, Jun 4, 2016 at 10:39 AM, Mahesh Dananjaya  wrote:

> Hi supun,
> Though i pushed it yesterday, there was some problems with the network.
> now you can see them in the repo location [1].I added some Matlab plot you
> can see the patter there.you can use ml also. Ok sure thing. I can prepare
> a report or else blog if you want. files are as follows. The y axis is in
> ns and x axis is in batch size. And also i added two pplots as jpegs[2], so
> you can easily compare.
> lr_timing_1000.txt -> batch size incremented by 1000
> lr_timing_1.txt -> batch size incremented by 1
> lr_timing_power10.txt -> batch size incremented by power of 10
>
> In here independent variable is only tha batch size.If you want i can send
> you making other parameters such as step size, number of iteration, feature
> vector size as independent variables. please let me know if you want
> further info. thank you.
> regards,
> Mahesh.
>
>
> [1
> ]https://github.com/dananjayamahesh/GSOC2016/tree/master/spark-examples/first-example/output
> [2]
> https://github.com/dananjayamahesh/GSOC2016/blob/master/spark-examples/first-example/output/lr_timing_1.jpg
>
> On Sat, Jun 4, 2016 at 9:58 AM, Supun Sethunga  wrote:
>
>> Hi Mahesh,
>>
>> I have added those timing reports to my repo [1].
>>
>> Whats the file name? :)
>>
>> Btw, can you compile simple doc (gdoc) with the above results, and bring
>> everything to one place? That way it is easy to compare, and keep track.
>>
>> Thanks,
>> Supun
>>
>> On Fri, Jun 3, 2016 at 7:23 PM, Mahesh Dananjaya <
>> dananjayamah...@gmail.com> wrote:
>>
>>> Hi Maheshkya,
>>> I have added those timing reports to my repo [1].please have a look at.
>>> three files are there. one is using incremet as 1000 for batch sizes
>>> (lr_timing_1000). Otherone is using incremet by 1 (lr_timing_1)
>>> upto 1 million in both scenarios.you can see the reports and figures in the
>>> location [2] in the repo. i also added the streaminglinearregression
>>> classes in the repo gsoc folder.thank you.
>>> regards,
>>> Mahesh.
>>> [1]https://github.com/dananjayamahesh/GSOC2016
>>> [2]
>>> https://github.com/dananjayamahesh/GSOC2016/tree/master/spark-examples/first-example/output
>>>
>>> On Mon, May 30, 2016 at 9:24 AM, Maheshakya Wijewardena <
>>> mahesha...@wso2.com> wrote:
>>>
 Hi Mahesh,

 Thank you for the update. I will look into your implementation.

 And i will be able to send you the timing/performances analysis report
> tomorrow for the SGD functions
>

 Great. Sent those asap so that we can proceed.

 Best regards.

 On Sun, May 29, 2016 at 6:56 PM, Mahesh Dananjaya <
 dananjayamah...@gmail.com> wrote:

>
> Hi maheshakay,
> I have implemented the linear regression with cep siddhi event stream
> with  taking batch sizes as parameters from the cep. Now we can trying the
> moving window method to. Before that i think i should get your opinion on
> data structures to save the streaming data.please check my repo [1]  
> /gsoc/
> folder there you can find all new things i add.. there in the extension
> folder you can find those extension. And i will be able to send you the
> timing/performances analysis report tomorrow for the SGD functions. thank
> you.
> regards,
> Mahesh.
> [1] https://github.com/dananjayamahesh/GSOC2016/tree/master/gsoc
>
>
> On Fri, May 27, 2016 at 12:56 PM, Mahesh Dananjaya <
> dananjayamah...@gmail.com> wrote:
>
>> Hi maheshkaya,
>> i have written some siddhi extension and trying to develop a one for
>> my one. In time series example in the [1], can you please explain me the
>> input format and query lines in that example for my understanding.
>>
>> from baseballData#timeseries:regress(2, 1, 0.95, salary, rbi,
>> walks, strikeouts, errors)
>> select *
>> insert into regResults;
>>
>> i just want to knwo how i give a set of data into this extension and
>> what is baseballData. Is it input stream as usual.or any data file?how 
>> can
>> i find that data set to create dummy input stream like baseballData?
>>
>> thank you.
>> regards,
>> Mahesh.
>> [1]
>> https://docs.wso2.com/display/CEP400/Writing+a+Custom+Stream+Processor+Extension
>>
>> On Thu, May 26, 2016 at 2:5

Re: [Dev] Requesting the parameters for throttling policy configurations in api-manager.xml

2016-06-03 Thread Harsha Kumara
Hi Ushani,

We add that property because, sometime users may not need publishing the
query params to the CEP as they don't have policies associated with them.
Going through the policies applied for a particular API and determine it
has query param conditions and then publishing the query param to the CEP
is expensive. So we have added those configurations.


On Sat, Jun 4, 2016 at 7:46 AM, Ushani Balasooriya  wrote:

> Additionaly why do we need to control EnableQueryParamConditions via
> api-manager.xml when we have a on/off switch button to each conditional
> header in Advanced throttling configuration UI?
> On Jun 4, 2016 7:24 AM, "Ushani Balasooriya"  wrote:
>
>> Hi Amila,
>>
>> So these configurations will be applicable across all tenants?
>>
>> Akso I think it would be better if we can hide Conditional groups when
>> EnableHeaderConditions is set to false or make them disable. Likewise will
>> it be possible to have UI level improvements to notify the admin? Just a
>> thought.
>>
> Yes this would be a good improvement to have in the UI.

> Thanks,
>> On Jun 3, 2016 11:00 PM, "Amila De Silva"  wrote:
>>
>>> Hi Ushani,
>>>
>>> For the new throttling to work you first have to
>>> set EnableAdvanceThrottling to true. When EnableHeaderConditions is set to
>>> true, all the headers in the incoming message will be published to the CEP.
>>> Similarly Setting EnableJWTClaimConditions and EnableQueryParamConditions
>>> to true would publish JWT claims and the query parameters coming with the
>>> request to the CEP. In the latest pack, spike arrest is only enabled
>>> through the UI, so there's no config element for that.
>>>
>>> On Fri, Jun 3, 2016 at 6:35 PM, Ushani Balasooriya 
>>> wrote:
>>>
 Hi APIM Team,

 It would be highly appreciated, if you can let us know the parameters
 that need to be enabled in api-manager.xml when working with throttling
 since the documents are not ready yet.

 E.g., Spike arrest policy parameter, Query param parameter.


 Thanks and regards,
 --
 *Ushani Balasooriya*
 Senior Software Engineer - QA;
 WSO2 Inc; http://www.wso2.com/.


 --
 You received this message because you are subscribed to the Google
 Groups "WSO2 Documentation Group" group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to documentation+unsubscr...@wso2.com.
 For more options, visit https://groups.google.com/a/wso2.com/d/optout.

>>>
>>>
>>>
>>> --
>>> *Amila De Silva*
>>>
>>> WSO2 Inc.
>>> mobile :(+94) 775119302
>>>
>>>


-- 
Harsha Kumara
Software Engineer, WSO2 Inc.
Mobile: +94775505618
Blog:harshcreationz.blogspot.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Fwd: GSOC2016: [ML][CEP] Predictive analytic with online data for WSO2 Machine Learner

2016-06-03 Thread Mahesh Dananjaya
Hi supun,
Though i pushed it yesterday, there was some problems with the network. now
you can see them in the repo location [1].I added some Matlab plot you can
see the patter there.you can use ml also. Ok sure thing. I can prepare a
report or else blog if you want. files are as follows. The y axis is in ns
and x axis is in batch size. And also i added two pplots as jpegs[2], so
you can easily compare.
lr_timing_1000.txt -> batch size incremented by 1000
lr_timing_1.txt -> batch size incremented by 1
lr_timing_power10.txt -> batch size incremented by power of 10

In here independent variable is only tha batch size.If you want i can send
you making other parameters such as step size, number of iteration, feature
vector size as independent variables. please let me know if you want
further info. thank you.
regards,
Mahesh.


[1
]https://github.com/dananjayamahesh/GSOC2016/tree/master/spark-examples/first-example/output
[2]
https://github.com/dananjayamahesh/GSOC2016/blob/master/spark-examples/first-example/output/lr_timing_1.jpg

On Sat, Jun 4, 2016 at 9:58 AM, Supun Sethunga  wrote:

> Hi Mahesh,
>
> I have added those timing reports to my repo [1].
>
> Whats the file name? :)
>
> Btw, can you compile simple doc (gdoc) with the above results, and bring
> everything to one place? That way it is easy to compare, and keep track.
>
> Thanks,
> Supun
>
> On Fri, Jun 3, 2016 at 7:23 PM, Mahesh Dananjaya <
> dananjayamah...@gmail.com> wrote:
>
>> Hi Maheshkya,
>> I have added those timing reports to my repo [1].please have a look at.
>> three files are there. one is using incremet as 1000 for batch sizes
>> (lr_timing_1000). Otherone is using incremet by 1 (lr_timing_1)
>> upto 1 million in both scenarios.you can see the reports and figures in the
>> location [2] in the repo. i also added the streaminglinearregression
>> classes in the repo gsoc folder.thank you.
>> regards,
>> Mahesh.
>> [1]https://github.com/dananjayamahesh/GSOC2016
>> [2]
>> https://github.com/dananjayamahesh/GSOC2016/tree/master/spark-examples/first-example/output
>>
>> On Mon, May 30, 2016 at 9:24 AM, Maheshakya Wijewardena <
>> mahesha...@wso2.com> wrote:
>>
>>> Hi Mahesh,
>>>
>>> Thank you for the update. I will look into your implementation.
>>>
>>> And i will be able to send you the timing/performances analysis report
 tomorrow for the SGD functions

>>>
>>> Great. Sent those asap so that we can proceed.
>>>
>>> Best regards.
>>>
>>> On Sun, May 29, 2016 at 6:56 PM, Mahesh Dananjaya <
>>> dananjayamah...@gmail.com> wrote:
>>>

 Hi maheshakay,
 I have implemented the linear regression with cep siddhi event stream
 with  taking batch sizes as parameters from the cep. Now we can trying the
 moving window method to. Before that i think i should get your opinion on
 data structures to save the streaming data.please check my repo [1]  /gsoc/
 folder there you can find all new things i add.. there in the extension
 folder you can find those extension. And i will be able to send you the
 timing/performances analysis report tomorrow for the SGD functions. thank
 you.
 regards,
 Mahesh.
 [1] https://github.com/dananjayamahesh/GSOC2016/tree/master/gsoc


 On Fri, May 27, 2016 at 12:56 PM, Mahesh Dananjaya <
 dananjayamah...@gmail.com> wrote:

> Hi maheshkaya,
> i have written some siddhi extension and trying to develop a one for
> my one. In time series example in the [1], can you please explain me the
> input format and query lines in that example for my understanding.
>
> from baseballData#timeseries:regress(2, 1, 0.95, salary, rbi,
> walks, strikeouts, errors)
> select *
> insert into regResults;
>
> i just want to knwo how i give a set of data into this extension and
> what is baseballData. Is it input stream as usual.or any data file?how can
> i find that data set to create dummy input stream like baseballData?
>
> thank you.
> regards,
> Mahesh.
> [1]
> https://docs.wso2.com/display/CEP400/Writing+a+Custom+Stream+Processor+Extension
>
> On Thu, May 26, 2016 at 2:58 PM, Mahesh Dananjaya <
> dananjayamah...@gmail.com> wrote:
>
>> Hi Maheshakya,
>> today i got the siddhi and debug the math extention. then did some
>> changes and check. Now i am trying to write same kind of extension in my
>> code base. so i add dependencies and it was built fine. Now i am trying 
>> to
>> debug my extension and i did the same thing as i did in previous case. 
>> Cep
>> is sending data, bu my extension is not firing in relevant break point.
>> 1. So how can i debug the siddhi extension in my new extension.(you
>> can see it in my example repoo)
>>
>> I think if i do it correctly we can built the extension for our
>> purpose. And i will send the relevant timing report of SGD algorithms 
>> very
>> soon as supun was

Re: [Dev] Can we use puppet scripts in wso2/puppet-modules for CEP for a distributed deployment ?

2016-06-03 Thread Isuru Haththotuwa
Hi Sajith,

On Sat, Jun 4, 2016 at 10:18 AM, Imesh Gunaratne  wrote:

> Hi Sajith,
>
> On Sat, Jun 4, 2016 at 12:31 AM, Sajith Ravindra  wrote:
>
>> Hi Imesh,
>>
>> It seems we have still not added the capability to deploy CEP in storm
>> based distributed mode using the puppet scripts in [1].
>>
>
> ​Yes, currently Storm based distributed deployment automation for CEP is
> not there in [1]. If CEP team can contribute to that, that would be great!
>
Adding to what Imesh said, we currently only have two profiles defined for
CEP, presenter+mgt and worker. Would need to improve as we go on.

>
> Thanks
>
> Am i missing something here? or are we still in the process of merging the
>> changes? Is there anything that needs to be done from CEP team to get
>> distributed deployment related changes merged to [1]?
>>
>>
>> [1] - https://github.com/wso2/puppet-modules
>>
>> Thanks
>> *,Sajith Ravindra*
>> Senior Software Engineer
>> WSO2 Inc.; http://wso2.com
>> lean.enterprise.middleware
>>
>> mobile: +94 77 2273550
>> blog: http://sajithr.blogspot.com/
>> 
>>
>
>
>
> --
> *Imesh Gunaratne*
> Software Architect
> WSO2 Inc: http://wso2.com
> T: +94 11 214 5345 M: +94 77 374 2057
> W: https://medium.com/@imesh TW: @imesh
> Lean . Enterprise . Middleware
>
>


-- 
Thanks and Regards,

Isuru H.
+94 716 358 048* *
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Can we use puppet scripts in wso2/puppet-modules for CEP for a distributed deployment ?

2016-06-03 Thread Imesh Gunaratne
Hi Sajith,

On Sat, Jun 4, 2016 at 12:31 AM, Sajith Ravindra  wrote:

> Hi Imesh,
>
> It seems we have still not added the capability to deploy CEP in storm
> based distributed mode using the puppet scripts in [1].
>

​Yes, currently Storm based distributed deployment automation for CEP is
not there in [1]. If CEP team can contribute to that, that would be great!

Thanks

Am i missing something here? or are we still in the process of merging the
> changes? Is there anything that needs to be done from CEP team to get
> distributed deployment related changes merged to [1]?
>
>
> [1] - https://github.com/wso2/puppet-modules
>
> Thanks
> *,Sajith Ravindra*
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: +94 77 2273550
> blog: http://sajithr.blogspot.com/
> 
>



-- 
*Imesh Gunaratne*
Software Architect
WSO2 Inc: http://wso2.com
T: +94 11 214 5345 M: +94 77 374 2057
W: https://medium.com/@imesh TW: @imesh
Lean . Enterprise . Middleware
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Fwd: GSOC2016: [ML][CEP] Predictive analytic with online data for WSO2 Machine Learner

2016-06-03 Thread Supun Sethunga
Hi Mahesh,

I have added those timing reports to my repo [1].

Whats the file name? :)

Btw, can you compile simple doc (gdoc) with the above results, and bring
everything to one place? That way it is easy to compare, and keep track.

Thanks,
Supun

On Fri, Jun 3, 2016 at 7:23 PM, Mahesh Dananjaya 
wrote:

> Hi Maheshkya,
> I have added those timing reports to my repo [1].please have a look at.
> three files are there. one is using incremet as 1000 for batch sizes
> (lr_timing_1000). Otherone is using incremet by 1 (lr_timing_1)
> upto 1 million in both scenarios.you can see the reports and figures in the
> location [2] in the repo. i also added the streaminglinearregression
> classes in the repo gsoc folder.thank you.
> regards,
> Mahesh.
> [1]https://github.com/dananjayamahesh/GSOC2016
> [2]
> https://github.com/dananjayamahesh/GSOC2016/tree/master/spark-examples/first-example/output
>
> On Mon, May 30, 2016 at 9:24 AM, Maheshakya Wijewardena <
> mahesha...@wso2.com> wrote:
>
>> Hi Mahesh,
>>
>> Thank you for the update. I will look into your implementation.
>>
>> And i will be able to send you the timing/performances analysis report
>>> tomorrow for the SGD functions
>>>
>>
>> Great. Sent those asap so that we can proceed.
>>
>> Best regards.
>>
>> On Sun, May 29, 2016 at 6:56 PM, Mahesh Dananjaya <
>> dananjayamah...@gmail.com> wrote:
>>
>>>
>>> Hi maheshakay,
>>> I have implemented the linear regression with cep siddhi event stream
>>> with  taking batch sizes as parameters from the cep. Now we can trying the
>>> moving window method to. Before that i think i should get your opinion on
>>> data structures to save the streaming data.please check my repo [1]  /gsoc/
>>> folder there you can find all new things i add.. there in the extension
>>> folder you can find those extension. And i will be able to send you the
>>> timing/performances analysis report tomorrow for the SGD functions. thank
>>> you.
>>> regards,
>>> Mahesh.
>>> [1] https://github.com/dananjayamahesh/GSOC2016/tree/master/gsoc
>>>
>>>
>>> On Fri, May 27, 2016 at 12:56 PM, Mahesh Dananjaya <
>>> dananjayamah...@gmail.com> wrote:
>>>
 Hi maheshkaya,
 i have written some siddhi extension and trying to develop a one for my
 one. In time series example in the [1], can you please explain me the input
 format and query lines in that example for my understanding.

 from baseballData#timeseries:regress(2, 1, 0.95, salary, rbi,
 walks, strikeouts, errors)
 select *
 insert into regResults;

 i just want to knwo how i give a set of data into this extension and
 what is baseballData. Is it input stream as usual.or any data file?how can
 i find that data set to create dummy input stream like baseballData?

 thank you.
 regards,
 Mahesh.
 [1]
 https://docs.wso2.com/display/CEP400/Writing+a+Custom+Stream+Processor+Extension

 On Thu, May 26, 2016 at 2:58 PM, Mahesh Dananjaya <
 dananjayamah...@gmail.com> wrote:

> Hi Maheshakya,
> today i got the siddhi and debug the math extention. then did some
> changes and check. Now i am trying to write same kind of extension in my
> code base. so i add dependencies and it was built fine. Now i am trying to
> debug my extension and i did the same thing as i did in previous case. Cep
> is sending data, bu my extension is not firing in relevant break point.
> 1. So how can i debug the siddhi extension in my new extension.(you
> can see it in my example repoo)
>
> I think if i do it correctly we can built the extension for our
> purpose. And i will send the relevant timing report of SGD algorithms very
> soon as supun was asking me. thank you.
> regards,
> Mahesh.
>
> On Tue, May 24, 2016 at 11:07 AM, Maheshakya Wijewardena <
> mahesha...@wso2.com> wrote:
>
>> Also note that there is a calculation interval in the siddhi time
>> series regression function[1]. You maybe able get some insight for this
>> from that as well.
>>
>> [1] https://docs.wso2.com/display/CEP400/Regression
>>
>> On Tue, May 24, 2016 at 11:03 AM, Maheshakya Wijewardena <
>> mahesha...@wso2.com> wrote:
>>
>>> Hi Mahesh,
>>>
>>> As we discussed offline, we can use similar mechanism to train
>>> linear regression models, logistic regression models and k-means 
>>> clustering
>>> models.
>>>
>>> It is very interesting that i have found that somethings that can
 make use of our work. In the cep 4.0 documentation there is a Custom 
 Stream
 Processor Extention program [1]. There is a example of
 LinearRegressionStreamProcessor [1].

>>>
>>> As we have to train predictive models with Spark, you can write
>>> wrappers around regression/clustering models of Spark. Refer to Siddhi 
>>> time
>>> series regression source codes[1][2]. You can write a streaming l

Re: [Dev] GSOC 2016 - Project 21 : MongoDB Userstore Development

2016-06-03 Thread Asantha Thilina
Hi Tharindu,

ok sure i will look forward for that

Thanks,
Asantha

On Fri, Jun 3, 2016 at 2:44 PM, Tharindu Edirisinghe 
wrote:

> Hi Asantha,
>
> Shall we have a google hangout tomorrow (Saturday) at 9.00 p.m ? So we can
> discuss about the issues you are facing and get them resolved.
>
> Regards,
> TharinduE
>
> On Fri, Jun 3, 2016 at 11:43 PM, Asantha Thilina  > wrote:
>
>> Hi Tharindu,
>>
>> i fixed the most of the errors appeared in my user store in user
>> management side now it's almost done in user management side now i can add
>> new users ,roles and search roles of users and users of roles only issue i
>> having now is i can't update a user profile of user in user store i getting
>> a exception ,i want to get some advice from you to resolve that error and
>> to implement a logic to commit transaction in mongodb and also another
>> small problem is when i added a new claim where will it save in primary
>> user store ? is there any feature to change the user store  where claims
>> going to save. like it giving an option to select userstore in a dropdown
>> when adding newusers and roles.
>>
>> all the works i have done so far in my repo[1]
>>
>> [1] . https://github.com/asanthamax/mongodbuserstore
>>
>> Thanks,
>> Asantha
>>
>> On Wed, Jun 1, 2016 at 3:00 AM, Asantha Thilina > > wrote:
>>
>>>
>>> -- Forwarded message --
>>> From: Asantha Thilina 
>>> Date: Wed, Jun 1, 2016 at 2:59 AM
>>> Subject: Fwd: GSOC 2016 - Project 21 : MongoDB Userstore Development
>>> To: WSO2 Developers' List , Tharindu Edirisinghe <
>>> tharin...@wso2.com>
>>>
>>>
>>>
>>> -- Forwarded message --
>>> From: Asantha Thilina 
>>> Date: Wed, Jun 1, 2016 at 2:51 AM
>>> Subject: Re: GSOC 2016 - Project 21 : MongoDB Userstore Development
>>> To: Tharindu Edirisinghe 
>>> Cc: WSO2 Developers' List , Lakmal Rupasinghe <
>>> lakma...@sliit.lk>
>>>
>>>
>>> Hi Tharindu,
>>>
>>> I fixed the most of the errors i got now my user store working it is
>>> successfully registered and can add users and roles to user store as well
>>> still there are some issues in other functions those are query errors i
>>> still fixing those as well ,i having some issues  about database
>>> transaction point of view and i need some advice from you, in mongodb there
>>> is no option to rollback transaction if error occurred how can i manage it?
>>> can we arrange a hangout meeting today or any comfortable day for you ? i'm
>>> ok with any time
>>> all the updates up to now i pushed to my repository[1]
>>>
>>> [1] https://github.com/asanthamax/mongodbuserstore
>>>
>>> Thanks,
>>> Asantha
>>>
>>> On Fri, May 27, 2016 at 1:56 AM, Asantha Thilina <
>>> asanthathil...@gmail.com> wrote:
>>>
 Hi Tharindu,

 sure i'll be look forward for that

 Thanks,
 Asantha

 On Thu, May 26, 2016 at 9:37 PM, Tharindu Edirisinghe <
 tharin...@wso2.com> wrote:

> Hi Asantha,
>
> Glad to hear the progress... Sure I'll review over the weekend and
> provide feedback. By next week we'll have a hangout to discuss on how to
> move forward and the difficulties you have faced.  Keep the momentum 
> going !
>
> Regards,
> TharinduE
>
> On Fri, May 27, 2016 at 12:17 AM, Asantha Thilina <
> asanthathil...@gmail.com> wrote:
>
>> Hi Tharindu,
>>
>> i been able to fix the mongodb user store intitalizing error now it
>> working successfully it will be registered as a secondary user store in 
>> IS
>> and when going to add a new users and roles it will show the domain of
>> mongodb userstore still i having small issues in my json query formats 
>> for
>> mongodb i fixing those issues at the moment all the progress so far i 
>> made
>> updated to my github repository[1] and i recently updated my blog[2] as
>> well,can you review my code and give me a feedback?
>>
>> [1]https://github.com/asanthamax/mongodbuserstore
>> [2]http://asanthamax.blogspot.com/
>>
>> Thanks,
>> Asantha
>>
>> On Sun, May 22, 2016 at 3:38 PM, Asantha Thilina <
>> asanthathil...@gmail.com> wrote:
>>
>>> Hi Tharindu,
>>>
>>> I have override all the methods in AbstractUserStoreManager in my
>>> MongoDBUserStoreManager class after that when i try to add new secondary
>>> user store in management console i got following error i attached the
>>> screen shot of the error with this mail
>>> i have pushed all the progress upto now to my github repository[1]
>>> can you give me some tips to solve this issue?
>>> any suggestion would be grateful
>>> [1] https://github.com/asanthamax/mongodbuserstore
>>> Thanks,
>>> Asantha
>>>
>>> On Thu, May 19, 2016 at 11:47 PM, Asantha Thilina <
>>> asanthathil...@gmail.com> wrote:
>>>
 Hi Tharindu,

 sorry for the late reply ,as you advised i remove the scr reference
 and its corresponding meth

Re: [Dev] [Gmail Connector] Error connecting to gmail connector

2016-06-03 Thread Malaka Silva
Yes this should be the way. Only use init method before each call.

On Sat, Jun 4, 2016 at 8:00 AM, Shakila Sivagnanarajah 
wrote:

> Hi Maheeka,
>
> Since the refreshing access token is automated in the connector, you can
> use following init configuration.
>
>  
> {$ctx:refreshToken}
> {$ctx:clientId}
> {$ctx:clientSecret}
>
> {$ctx:accessTokenRegistryPath}
> {$ctx:accessToken}
> {$ctx:apiUrl}
> {$ctx:userId}
> 
> 
> {$ctx:to}
> {$ctx:subject}
> {$ctx:from}
> {$ctx:messageBody}
> {$ctx:cc}
> {$ctx:bcc}
> 
> 
>
> Thanks
>
> On Sat, Jun 4, 2016 at 7:40 AM, Shakila Sivagnanarajah 
> wrote:
>
>> Hi Maheeka,
>>
>> I Just have tested it, it is working fine. It seems the access token is
>> not set in your call.
>>
>> Please try with this configuration.
>>
>> 
>> {$ctx:refreshToken}
>> {$ctx:clientId}
>> {$ctx:clientSecret}
>> {$ctx:grantType}
>> 
>> 
>> {$ctx:apiUrl}
>> {$ctx:userId}
>> 
>> 
>> {$ctx:to}
>> {$ctx:subject}
>> {$ctx:from}
>> {$ctx:messageBody}
>> {$ctx:cc}
>> {$ctx:bcc}
>> 
>> 
>>
>>
>> Thanks
>>
>> On Sat, Jun 4, 2016 at 7:33 AM, Malaka Silva  wrote:
>>
>>> Looping Hariprasath.
>>>
>>> On Sat, Jun 4, 2016 at 7:25 AM, Shakila Sivagnanarajah >> > wrote:
>>>
 Hi Maheeka,

 I will check and update you

 Thanks

 On Sat, Jun 4, 2016 at 1:05 AM, Maheeka Jayasuriya 
 wrote:

> Hi Shakila/Malaka,
>
> I am getting the following errors when using the latest gmail
> connector from connector store. I am getting the clientId and clientSecret
> from the app and the refresh token and access token from playground app.
> Used apiUrl as https://www.googleapis.com/gmail.
>
> Am I doing any configuration wrong?
>
> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "POST //v1/users/johndoeintcl...@gmail.com/messages/send
> HTTP/1.1[\r][\n]"
> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "X-Frame-Options: SAMEORIGIN[\r][\n]"
> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Authorization: Bearer [\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Alt-Svc: quic=":443"; ma=2592000;
> v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Vary: X-Origin[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "X-XSS-Protection: 1; mode=block[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Expires: Fri, 03 Jun 2016 18:34:43 GMT[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Alternate-Protocol: 443:quic[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Content-Type: application/json; charset=UTF-8[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Accept-Ranges: none[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "X-Content-Type-Options: nosniff[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Content-Length: 38[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Host: mail.google.com[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "Connection: Keep-Alive[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "User-Agent: Synapse-PT-HttpComponents-NIO[\r][\n]"
> [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "[\r][\n]"
> [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> << "{"raw":"dG86bWFoZWVrYUB3c28yLmNvbQo="}"
> [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> >> "HTTP/1.1 301 Moved Permanently[\r][\n]"
> [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> >> "Location:
> https://www.google.com/v1/users/johndoeintcl...@gmail.com/messages/send[\r][\n]
> "
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> >> "Content-Type: text/html; charset=UTF-8[\r][\n]"
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> >> "X-Content-Type-Options: nosniff[\r][\n]"
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> >> "Date: Fri, 03 Jun 2016 18:34:44 GMT[\r][\n]"
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> >> "Expires: Sun, 03 Jul 2016 18:34:44 GMT[\r][\n]"
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3
> >

Re: [Dev] [Gmail Connector] Error connecting to gmail connector

2016-06-03 Thread Shakila Sivagnanarajah
Hi Maheeka,

Since the refreshing access token is automated in the connector, you can
use following init configuration.

 
{$ctx:refreshToken}
{$ctx:clientId}
{$ctx:clientSecret}

{$ctx:accessTokenRegistryPath}
{$ctx:accessToken}
{$ctx:apiUrl}
{$ctx:userId}


{$ctx:to}
{$ctx:subject}
{$ctx:from}
{$ctx:messageBody}
{$ctx:cc}
{$ctx:bcc}



Thanks

On Sat, Jun 4, 2016 at 7:40 AM, Shakila Sivagnanarajah 
wrote:

> Hi Maheeka,
>
> I Just have tested it, it is working fine. It seems the access token is
> not set in your call.
>
> Please try with this configuration.
>
> 
> {$ctx:refreshToken}
> {$ctx:clientId}
> {$ctx:clientSecret}
> {$ctx:grantType}
> 
> 
> {$ctx:apiUrl}
> {$ctx:userId}
> 
> 
> {$ctx:to}
> {$ctx:subject}
> {$ctx:from}
> {$ctx:messageBody}
> {$ctx:cc}
> {$ctx:bcc}
> 
> 
>
>
> Thanks
>
> On Sat, Jun 4, 2016 at 7:33 AM, Malaka Silva  wrote:
>
>> Looping Hariprasath.
>>
>> On Sat, Jun 4, 2016 at 7:25 AM, Shakila Sivagnanarajah 
>> wrote:
>>
>>> Hi Maheeka,
>>>
>>> I will check and update you
>>>
>>> Thanks
>>>
>>> On Sat, Jun 4, 2016 at 1:05 AM, Maheeka Jayasuriya 
>>> wrote:
>>>
 Hi Shakila/Malaka,

 I am getting the following errors when using the latest gmail connector
 from connector store. I am getting the clientId and clientSecret from the
 app and the refresh token and access token from playground app. Used apiUrl
 as https://www.googleapis.com/gmail.

 Am I doing any configuration wrong?

 [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "POST //v1/users/johndoeintcl...@gmail.com/messages/send
 HTTP/1.1[\r][\n]"
 [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "X-Frame-Options: SAMEORIGIN[\r][\n]"
 [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Authorization: Bearer [\r][\n]"
 [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Alt-Svc: quic=":443"; ma=2592000;
 v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
 [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Vary: X-Origin[\r][\n]"
 [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "X-XSS-Protection: 1; mode=block[\r][\n]"
 [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Expires: Fri, 03 Jun 2016 18:34:43 GMT[\r][\n]"
 [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Alternate-Protocol: 443:quic[\r][\n]"
 [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Content-Type: application/json; charset=UTF-8[\r][\n]"
 [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Accept-Ranges: none[\r][\n]"
 [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "X-Content-Type-Options: nosniff[\r][\n]"
 [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Content-Length: 38[\r][\n]"
 [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Host: mail.google.com[\r][\n]"
 [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "Connection: Keep-Alive[\r][\n]"
 [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "User-Agent: Synapse-PT-HttpComponents-NIO[\r][\n]"
 [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "[\r][\n]"
 [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
 "{"raw":"dG86bWFoZWVrYUB3c28yLmNvbQo="}"
 [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
 "HTTP/1.1 301 Moved Permanently[\r][\n]"
 [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
 "Location:
 https://www.google.com/v1/users/johndoeintcl...@gmail.com/messages/send[\r][\n]
 "
 [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
 "Content-Type: text/html; charset=UTF-8[\r][\n]"
 [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
 "X-Content-Type-Options: nosniff[\r][\n]"
 [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
 "Date: Fri, 03 Jun 2016 18:34:44 GMT[\r][\n]"
 [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
 "Expires: Sun, 03 Jul 2016 18:34:44 GMT[\r][\n]"
 [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
 "Cache-Control: public, max-age=2592000[\r][\n]"
 [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
 "Server: sffe[\r][\n]"
 [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
 "Content-Length: 268[\r][\n]"
 [2016-06-04 00:04:45

Re: [Dev] Requesting the parameters for throttling policy configurations in api-manager.xml

2016-06-03 Thread Ushani Balasooriya
Additionaly why do we need to control EnableQueryParamConditions via
api-manager.xml when we have a on/off switch button to each conditional
header in Advanced throttling configuration UI?
On Jun 4, 2016 7:24 AM, "Ushani Balasooriya"  wrote:

> Hi Amila,
>
> So these configurations will be applicable across all tenants?
>
> Akso I think it would be better if we can hide Conditional groups when
> EnableHeaderConditions is set to false or make them disable. Likewise will
> it be possible to have UI level improvements to notify the admin? Just a
> thought.
>
> Thanks,
> On Jun 3, 2016 11:00 PM, "Amila De Silva"  wrote:
>
>> Hi Ushani,
>>
>> For the new throttling to work you first have to
>> set EnableAdvanceThrottling to true. When EnableHeaderConditions is set to
>> true, all the headers in the incoming message will be published to the CEP.
>> Similarly Setting EnableJWTClaimConditions and EnableQueryParamConditions
>> to true would publish JWT claims and the query parameters coming with the
>> request to the CEP. In the latest pack, spike arrest is only enabled
>> through the UI, so there's no config element for that.
>>
>> On Fri, Jun 3, 2016 at 6:35 PM, Ushani Balasooriya 
>> wrote:
>>
>>> Hi APIM Team,
>>>
>>> It would be highly appreciated, if you can let us know the parameters
>>> that need to be enabled in api-manager.xml when working with throttling
>>> since the documents are not ready yet.
>>>
>>> E.g., Spike arrest policy parameter, Query param parameter.
>>>
>>>
>>> Thanks and regards,
>>> --
>>> *Ushani Balasooriya*
>>> Senior Software Engineer - QA;
>>> WSO2 Inc; http://www.wso2.com/.
>>>
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "WSO2 Documentation Group" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to documentation+unsubscr...@wso2.com.
>>> For more options, visit https://groups.google.com/a/wso2.com/d/optout.
>>>
>>
>>
>>
>> --
>> *Amila De Silva*
>>
>> WSO2 Inc.
>> mobile :(+94) 775119302
>>
>>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [Gmail Connector] Error connecting to gmail connector

2016-06-03 Thread Shakila Sivagnanarajah
Hi Maheeka,

I Just have tested it, it is working fine. It seems the access token is not
set in your call.

Please try with this configuration.


{$ctx:refreshToken}
{$ctx:clientId}
{$ctx:clientSecret}
{$ctx:grantType}


{$ctx:apiUrl}
{$ctx:userId}


{$ctx:to}
{$ctx:subject}
{$ctx:from}
{$ctx:messageBody}
{$ctx:cc}
{$ctx:bcc}




Thanks

On Sat, Jun 4, 2016 at 7:33 AM, Malaka Silva  wrote:

> Looping Hariprasath.
>
> On Sat, Jun 4, 2016 at 7:25 AM, Shakila Sivagnanarajah 
> wrote:
>
>> Hi Maheeka,
>>
>> I will check and update you
>>
>> Thanks
>>
>> On Sat, Jun 4, 2016 at 1:05 AM, Maheeka Jayasuriya 
>> wrote:
>>
>>> Hi Shakila/Malaka,
>>>
>>> I am getting the following errors when using the latest gmail connector
>>> from connector store. I am getting the clientId and clientSecret from the
>>> app and the refresh token and access token from playground app. Used apiUrl
>>> as https://www.googleapis.com/gmail.
>>>
>>> Am I doing any configuration wrong?
>>>
>>> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "POST //v1/users/johndoeintcl...@gmail.com/messages/send
>>> HTTP/1.1[\r][\n]"
>>> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "X-Frame-Options: SAMEORIGIN[\r][\n]"
>>> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Authorization: Bearer [\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Alt-Svc: quic=":443"; ma=2592000;
>>> v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Vary: X-Origin[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "X-XSS-Protection: 1; mode=block[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Expires: Fri, 03 Jun 2016 18:34:43 GMT[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Alternate-Protocol: 443:quic[\r][\n]"
>>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Content-Type: application/json; charset=UTF-8[\r][\n]"
>>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Accept-Ranges: none[\r][\n]"
>>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "X-Content-Type-Options: nosniff[\r][\n]"
>>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Content-Length: 38[\r][\n]"
>>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Host: mail.google.com[\r][\n]"
>>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "Connection: Keep-Alive[\r][\n]"
>>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "User-Agent: Synapse-PT-HttpComponents-NIO[\r][\n]"
>>> [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "[\r][\n]"
>>> [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>>> "{"raw":"dG86bWFoZWVrYUB3c28yLmNvbQo="}"
>>> [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "HTTP/1.1 301 Moved Permanently[\r][\n]"
>>> [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "Location:
>>> https://www.google.com/v1/users/johndoeintcl...@gmail.com/messages/send[\r][\n]
>>> "
>>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "Content-Type: text/html; charset=UTF-8[\r][\n]"
>>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "X-Content-Type-Options: nosniff[\r][\n]"
>>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "Date: Fri, 03 Jun 2016 18:34:44 GMT[\r][\n]"
>>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "Expires: Sun, 03 Jul 2016 18:34:44 GMT[\r][\n]"
>>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "Cache-Control: public, max-age=2592000[\r][\n]"
>>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "Server: sffe[\r][\n]"
>>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "Content-Length: 268[\r][\n]"
>>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "X-XSS-Protection: 1; mode=block[\r][\n]"
>>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "Alternate-Protocol: 443:quic[\r][\n]"
>>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "Alt-Svc: quic=":443"; ma=2592000;
>>> v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
>>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> "[\r][\n]"
>>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>>> ">> content="text/html;charset=utf-8">[\n]"
>>> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatc

Re: [Dev] [Gmail Connector] Error connecting to gmail connector

2016-06-03 Thread Malaka Silva
Looping Hariprasath.

On Sat, Jun 4, 2016 at 7:25 AM, Shakila Sivagnanarajah 
wrote:

> Hi Maheeka,
>
> I will check and update you
>
> Thanks
>
> On Sat, Jun 4, 2016 at 1:05 AM, Maheeka Jayasuriya 
> wrote:
>
>> Hi Shakila/Malaka,
>>
>> I am getting the following errors when using the latest gmail connector
>> from connector store. I am getting the clientId and clientSecret from the
>> app and the refresh token and access token from playground app. Used apiUrl
>> as https://www.googleapis.com/gmail.
>>
>> Am I doing any configuration wrong?
>>
>> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "POST //v1/users/johndoeintcl...@gmail.com/messages/send
>> HTTP/1.1[\r][\n]"
>> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "X-Frame-Options: SAMEORIGIN[\r][\n]"
>> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Authorization: Bearer [\r][\n]"
>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Alt-Svc: quic=":443"; ma=2592000;
>> v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Vary: X-Origin[\r][\n]"
>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "X-XSS-Protection: 1; mode=block[\r][\n]"
>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Expires: Fri, 03 Jun 2016 18:34:43 GMT[\r][\n]"
>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Alternate-Protocol: 443:quic[\r][\n]"
>> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Content-Type: application/json; charset=UTF-8[\r][\n]"
>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Accept-Ranges: none[\r][\n]"
>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "X-Content-Type-Options: nosniff[\r][\n]"
>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Content-Length: 38[\r][\n]"
>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Host: mail.google.com[\r][\n]"
>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "Connection: Keep-Alive[\r][\n]"
>> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "User-Agent: Synapse-PT-HttpComponents-NIO[\r][\n]"
>> [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "[\r][\n]"
>> [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
>> "{"raw":"dG86bWFoZWVrYUB3c28yLmNvbQo="}"
>> [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "HTTP/1.1 301 Moved Permanently[\r][\n]"
>> [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "Location:
>> https://www.google.com/v1/users/johndoeintcl...@gmail.com/messages/send[\r][\n]
>> "
>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "Content-Type: text/html; charset=UTF-8[\r][\n]"
>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "X-Content-Type-Options: nosniff[\r][\n]"
>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "Date: Fri, 03 Jun 2016 18:34:44 GMT[\r][\n]"
>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "Expires: Sun, 03 Jul 2016 18:34:44 GMT[\r][\n]"
>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "Cache-Control: public, max-age=2592000[\r][\n]"
>> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "Server: sffe[\r][\n]"
>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "Content-Length: 268[\r][\n]"
>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "X-XSS-Protection: 1; mode=block[\r][\n]"
>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "Alternate-Protocol: 443:quic[\r][\n]"
>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "Alt-Svc: quic=":443"; ma=2592000;
>> v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "[\r][\n]"
>> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "> content="text/html;charset=utf-8">[\n]"
>> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "301 Moved[\n]"
>> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "301 Moved[\n]"
>> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "The document has moved[\n]"
>> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "https://www.google.com/v1/users/johndoeintcl...@gmail.com/messages/send
>> ">here.[\r][\n]"
>> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
>> "[\r][\n]"
>>
>>
>>
>> 

Re: [Dev] [Gmail Connector] Error connecting to gmail connector

2016-06-03 Thread Shakila Sivagnanarajah
Hi Maheeka,

I will check and update you

Thanks

On Sat, Jun 4, 2016 at 1:05 AM, Maheeka Jayasuriya  wrote:

> Hi Shakila/Malaka,
>
> I am getting the following errors when using the latest gmail connector
> from connector store. I am getting the clientId and clientSecret from the
> app and the refresh token and access token from playground app. Used apiUrl
> as https://www.googleapis.com/gmail.
>
> Am I doing any configuration wrong?
>
> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "POST //v1/users/johndoeintcl...@gmail.com/messages/send HTTP/1.1[\r][\n]"
> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "X-Frame-Options: SAMEORIGIN[\r][\n]"
> [2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Authorization: Bearer [\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Alt-Svc: quic=":443"; ma=2592000;
> v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Vary: X-Origin[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "X-XSS-Protection: 1; mode=block[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Expires: Fri, 03 Jun 2016 18:34:43 GMT[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Alternate-Protocol: 443:quic[\r][\n]"
> [2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Content-Type: application/json; charset=UTF-8[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Accept-Ranges: none[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "X-Content-Type-Options: nosniff[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Content-Length: 38[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Host: mail.google.com[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "Connection: Keep-Alive[\r][\n]"
> [2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "User-Agent: Synapse-PT-HttpComponents-NIO[\r][\n]"
> [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "[\r][\n]"
> [2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
> "{"raw":"dG86bWFoZWVrYUB3c28yLmNvbQo="}"
> [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "HTTP/1.1 301 Moved Permanently[\r][\n]"
> [2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "Location:
> https://www.google.com/v1/users/johndoeintcl...@gmail.com/messages/send[\r][\n]
> "
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "Content-Type: text/html; charset=UTF-8[\r][\n]"
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "X-Content-Type-Options: nosniff[\r][\n]"
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "Date: Fri, 03 Jun 2016 18:34:44 GMT[\r][\n]"
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "Expires: Sun, 03 Jul 2016 18:34:44 GMT[\r][\n]"
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "Cache-Control: public, max-age=2592000[\r][\n]"
> [2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "Server: sffe[\r][\n]"
> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "Content-Length: 268[\r][\n]"
> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "X-XSS-Protection: 1; mode=block[\r][\n]"
> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "Alternate-Protocol: 443:quic[\r][\n]"
> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "Alt-Svc: quic=":443"; ma=2592000;
> v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "[\r][\n]"
> [2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> " content="text/html;charset=utf-8">[\n]"
> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "301 Moved[\n]"
> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "301 Moved[\n]"
> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "The document has moved[\n]"
> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "https://www.google.com/v1/users/johndoeintcl...@gmail.com/messages/send
> ">here.[\r][\n]"
> [2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
> "[\r][\n]"
>
>
>
> -
>
> [2016-06-04 00:53:56,567] ERROR - ClientUtils The system cannot infer the
> transport information from the //users//messages/send URL.
> [2016-06-04 00:53:56,573] ERROR - Axis2Send

Re: [Dev] Requesting the parameters for throttling policy configurations in api-manager.xml

2016-06-03 Thread Ushani Balasooriya
Hi Amila,

So these configurations will be applicable across all tenants?

Akso I think it would be better if we can hide Conditional groups when
EnableHeaderConditions is set to false or make them disable. Likewise will
it be possible to have UI level improvements to notify the admin? Just a
thought.

Thanks,
On Jun 3, 2016 11:00 PM, "Amila De Silva"  wrote:

> Hi Ushani,
>
> For the new throttling to work you first have to
> set EnableAdvanceThrottling to true. When EnableHeaderConditions is set to
> true, all the headers in the incoming message will be published to the CEP.
> Similarly Setting EnableJWTClaimConditions and EnableQueryParamConditions
> to true would publish JWT claims and the query parameters coming with the
> request to the CEP. In the latest pack, spike arrest is only enabled
> through the UI, so there's no config element for that.
>
> On Fri, Jun 3, 2016 at 6:35 PM, Ushani Balasooriya 
> wrote:
>
>> Hi APIM Team,
>>
>> It would be highly appreciated, if you can let us know the parameters
>> that need to be enabled in api-manager.xml when working with throttling
>> since the documents are not ready yet.
>>
>> E.g., Spike arrest policy parameter, Query param parameter.
>>
>>
>> Thanks and regards,
>> --
>> *Ushani Balasooriya*
>> Senior Software Engineer - QA;
>> WSO2 Inc; http://www.wso2.com/.
>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "WSO2 Documentation Group" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to documentation+unsubscr...@wso2.com.
>> For more options, visit https://groups.google.com/a/wso2.com/d/optout.
>>
>
>
>
> --
> *Amila De Silva*
>
> WSO2 Inc.
> mobile :(+94) 775119302
>
>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Script Mediator getMonth issue

2016-06-03 Thread Godwin Shrimal
This is the behavior of Javascript and it returns the month 0-11. Please
check [1] for more information.

[1] http://www.w3schools.com/jsref/jsref_getmonth.asp

Thanks
Godwin


On Fri, Jun 3, 2016 at 3:20 PM, Godwin Shrimal  wrote:

> Hi All,
>
> I am having a problem with getting month using script mediator, it always
> give (month - 1) value, As an example if we pass currentDate as 2015/12/31,
> it gives month as 11 not 12.
> What is the reason for this behavior ??
>
>
> 
>   var currentDate = new Date(mc.getProperty('currentDate')); var
> mm = currentDate.getMonth();
> mc.setProperty("month", currentDateString);
> 
>
>
> Thanks
> Godwin
>
>
> --
> *Godwin Amila Shrimal*
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: *+94772264165*
> linkedin: *http://lnkd.in/KUum6D *
> twitter: https://twitter.com/godwinamila
>



-- 
*Godwin Amila Shrimal*
Senior Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

mobile: *+94772264165*
linkedin: *http://lnkd.in/KUum6D *
twitter: https://twitter.com/godwinamila
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Script Mediator getMonth issue

2016-06-03 Thread Godwin Shrimal
Hi All,

I am having a problem with getting month using script mediator, it always
give (month - 1) value, As an example if we pass currentDate as 2015/12/31,
it gives month as 11 not 12.
What is the reason for this behavior ??



  var currentDate = new Date(mc.getProperty('currentDate')); var mm
= currentDate.getMonth();
mc.setProperty("month", currentDateString);



Thanks
Godwin


-- 
*Godwin Amila Shrimal*
Senior Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

mobile: *+94772264165*
linkedin: *http://lnkd.in/KUum6D *
twitter: https://twitter.com/godwinamila
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [DAS] java.lang.NoSuchMethodError when trying to add Kafka Event Receiver

2016-06-03 Thread Charitha Goonetilleke
Hi,

I'm trying to add kafka event receiver by following steps in the
documentation[1] with Kafka 2.11-0.9.0.1. I'm getting following error when
tried to Add a Kafka Event Receiver.

[2016-06-04 01:25:42,815] ERROR
{org.wso2.carbon.event.receiver.core.EventReceiverDeployer} -  Event
Receiver not deployed, invalid configuration found at
org.wso2.event.receiver.m1.xml, and in inactive state,
scala.Predef$.ArrowAssoc(Ljava/lang/Object;)Ljava/lang/Object;
java.lang.NoSuchMethodError:
scala.Predef$.ArrowAssoc(Ljava/lang/Object;)Ljava/lang/Object;
at
kafka.consumer.ZookeeperConsumerConnector.(ZookeeperConsumerConnector.scala:111)
at
kafka.javaapi.consumer.ZookeeperConsumerConnector.(ZookeeperConsumerConnector.scala:66)
at
kafka.javaapi.consumer.ZookeeperConsumerConnector.(ZookeeperConsumerConnector.scala:69)
at
kafka.consumer.Consumer$.createJavaConsumerConnector(ConsumerConnector.scala:120)
at
kafka.consumer.Consumer.createJavaConsumerConnector(ConsumerConnector.scala)
at
org.wso2.carbon.event.input.adapter.kafka.ConsumerKafkaAdaptor.(ConsumerKafkaAdaptor.java:40)
at
org.wso2.carbon.event.input.adapter.kafka.KafkaEventAdapter.createKafkaAdaptorListener(KafkaEventAdapter.java:132)
at
org.wso2.carbon.event.input.adapter.kafka.KafkaEventAdapter.connect(KafkaEventAdapter.java:66)
at
org.wso2.carbon.event.input.adapter.core.internal.InputAdapterRuntime.start(InputAdapterRuntime.java:75)
at
org.wso2.carbon.event.input.adapter.core.internal.InputAdapterRuntime.startPolling(InputAdapterRuntime.java:65)
at
org.wso2.carbon.event.input.adapter.core.internal.CarbonInputEventAdapterService.create(CarbonInputEventAdapterService.java:113)
at
org.wso2.carbon.event.receiver.core.internal.EventReceiver.(EventReceiver.java:116)
at
org.wso2.carbon.event.receiver.core.internal.CarbonEventReceiverService.addEventReceiverConfiguration(CarbonEventReceiverService.java:323)
at
org.wso2.carbon.event.receiver.core.EventReceiverDeployer.processDeployment(EventReceiverDeployer.java:203)
at
org.wso2.carbon.event.receiver.core.EventReceiverDeployer.executeManualDeployment(EventReceiverDeployer.java:273)
at
org.wso2.carbon.event.receiver.core.internal.util.helper.EventReceiverConfigurationFileSystemInvoker.saveAndDeploy(EventReceiverConfigurationFileSystemInvoker.java:96)
at
org.wso2.carbon.event.receiver.core.internal.util.helper.EventReceiverConfigurationFileSystemInvoker.save(EventReceiverConfigurationFileSystemInvoker.java:80)
at
org.wso2.carbon.event.receiver.core.internal.util.helper.EventReceiverConfigurationFileSystemInvoker.encryptAndSave(EventReceiverConfigurationFileSystemInvoker.java:75)
at
org.wso2.carbon.event.receiver.core.internal.CarbonEventReceiverService.deployEventReceiverConfiguration(CarbonEventReceiverService.java:77)
at
org.wso2.carbon.event.receiver.admin.EventReceiverAdminService.deployJsonEventReceiverConfiguration(EventReceiverAdminService.java:619)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at
org.apache.axis2.rpc.receivers.RPCUtil.invokeServiceClass(RPCUtil.java:212)
at
org.apache.axis2.rpc.receivers.RPCMessageReceiver.invokeBusinessLogic(RPCMessageReceiver.java:117)
at
org.apache.axis2.receivers.AbstractInOutMessageReceiver.invokeBusinessLogic(AbstractInOutMessageReceiver.java:40)
at
org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:110)
at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180)
at
org.apache.axis2.transport.local.LocalTransportReceiver.processMessage(LocalTransportReceiver.java:169)
at
org.apache.axis2.transport.local.LocalTransportReceiver.processMessage(LocalTransportReceiver.java:82)
at
org.wso2.carbon.core.transports.local.CarbonLocalTransportSender.finalizeSendWithToAddress(CarbonLocalTransportSender.java:45)
at
org.apache.axis2.transport.local.LocalTransportSender.invoke(LocalTransportSender.java:77)
at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:442)
at
org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:430)
at
org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:225)
at org.apache.axis2.client.OperationClient.execute(OperationClient.java:149)
at
org.wso2.carbon.event.receiver.stub.EventReceiverAdminServiceStub.deployJsonEventReceiverConfiguration(EventReceiverAdminServiceStub.java:3404)
at
org.apache.jsp.eventreceiver.add_005fevent_005freceiver_005fajaxprocessor_jsp._jspService(add_005fevent_005freceiver_005fajaxprocessor_jsp.java:327)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)
at

[Dev] [Gmail Connector] Error connecting to gmail connector

2016-06-03 Thread Maheeka Jayasuriya
Hi Shakila/Malaka,

I am getting the following errors when using the latest gmail connector
from connector store. I am getting the clientId and clientSecret from the
app and the refresh token and access token from playground app. Used apiUrl
as https://www.googleapis.com/gmail.

Am I doing any configuration wrong?

[2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"POST //v1/users/johndoeintcl...@gmail.com/messages/send HTTP/1.1[\r][\n]"
[2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"X-Frame-Options: SAMEORIGIN[\r][\n]"
[2016-06-04 00:04:44,784] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Authorization: Bearer [\r][\n]"
[2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Alt-Svc: quic=":443"; ma=2592000;
v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
[2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Vary: X-Origin[\r][\n]"
[2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"X-XSS-Protection: 1; mode=block[\r][\n]"
[2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Expires: Fri, 03 Jun 2016 18:34:43 GMT[\r][\n]"
[2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Alternate-Protocol: 443:quic[\r][\n]"
[2016-06-04 00:04:44,785] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Content-Type: application/json; charset=UTF-8[\r][\n]"
[2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Accept-Ranges: none[\r][\n]"
[2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"X-Content-Type-Options: nosniff[\r][\n]"
[2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Content-Length: 38[\r][\n]"
[2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Host: mail.google.com[\r][\n]"
[2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"Connection: Keep-Alive[\r][\n]"
[2016-06-04 00:04:44,786] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"User-Agent: Synapse-PT-HttpComponents-NIO[\r][\n]"
[2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"[\r][\n]"
[2016-06-04 00:04:44,787] DEBUG - wire HTTPS-Sender I/O dispatcher-3 <<
"{"raw":"dG86bWFoZWVrYUB3c28yLmNvbQo="}"
[2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"HTTP/1.1 301 Moved Permanently[\r][\n]"
[2016-06-04 00:04:45,052] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"Location:
https://www.google.com/v1/users/johndoeintcl...@gmail.com/messages/send[\r][\n]
"
[2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"Content-Type: text/html; charset=UTF-8[\r][\n]"
[2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"X-Content-Type-Options: nosniff[\r][\n]"
[2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"Date: Fri, 03 Jun 2016 18:34:44 GMT[\r][\n]"
[2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"Expires: Sun, 03 Jul 2016 18:34:44 GMT[\r][\n]"
[2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"Cache-Control: public, max-age=2592000[\r][\n]"
[2016-06-04 00:04:45,053] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"Server: sffe[\r][\n]"
[2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"Content-Length: 268[\r][\n]"
[2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"X-XSS-Protection: 1; mode=block[\r][\n]"
[2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"Alternate-Protocol: 443:quic[\r][\n]"
[2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"Alt-Svc: quic=":443"; ma=2592000;
v="34,33,32,31,30,29,28,27,26,25"[\r][\n]"
[2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"[\r][\n]"
[2016-06-04 00:04:45,054] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"[\n]"
[2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"301 Moved[\n]"
[2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"301 Moved[\n]"
[2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"The document has moved[\n]"
[2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >> "https://www.google.com/v1/users/johndoeintcl...@gmail.com/messages/send
">here.[\r][\n]"
[2016-06-04 00:04:45,055] DEBUG - wire HTTPS-Sender I/O dispatcher-3 >>
"[\r][\n]"


-

[2016-06-04 00:53:56,567] ERROR - ClientUtils The system cannot infer the
transport information from the //users//messages/send URL.
[2016-06-04 00:53:56,573] ERROR - Axis2Sender Unexpected error during
sending message out
org.apache.axis2.AxisFault: The system cannot infer the transport
information from the //users//messages/send URL.
at
org.apache.axis2.description.ClientUtils.inferOutTransport(ClientUtils.java:81)
at
org.apache.synapse.core.axis2.DynamicAxisOperation$DynamicOperationClie

[Dev] Can we use puppet scripts in wso2/puppet-modules for CEP for a distributed deployment ?

2016-06-03 Thread Sajith Ravindra
Hi Imesh,

It seems we have still not added the capability to deploy CEP in storm
based distributed mode using the puppet scripts in [1]. Am i missing
something here? or are we still in the process of merging the changes? Is
there anything that needs to be done from CEP team to get distributed
deployment related changes merged to [1]?


[1] - https://github.com/wso2/puppet-modules

Thanks
*,Sajith Ravindra*
Senior Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

mobile: +94 77 2273550
blog: http://sajithr.blogspot.com/

___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] GSOC 2016 - Project 21 : MongoDB Userstore Development

2016-06-03 Thread Tharindu Edirisinghe
Hi Asantha,

Shall we have a google hangout tomorrow (Saturday) at 9.00 p.m ? So we can
discuss about the issues you are facing and get them resolved.

Regards,
TharinduE

On Fri, Jun 3, 2016 at 11:43 PM, Asantha Thilina 
wrote:

> Hi Tharindu,
>
> i fixed the most of the errors appeared in my user store in user
> management side now it's almost done in user management side now i can add
> new users ,roles and search roles of users and users of roles only issue i
> having now is i can't update a user profile of user in user store i getting
> a exception ,i want to get some advice from you to resolve that error and
> to implement a logic to commit transaction in mongodb and also another
> small problem is when i added a new claim where will it save in primary
> user store ? is there any feature to change the user store  where claims
> going to save. like it giving an option to select userstore in a dropdown
> when adding newusers and roles.
>
> all the works i have done so far in my repo[1]
>
> [1] . https://github.com/asanthamax/mongodbuserstore
>
> Thanks,
> Asantha
>
> On Wed, Jun 1, 2016 at 3:00 AM, Asantha Thilina 
> wrote:
>
>>
>> -- Forwarded message --
>> From: Asantha Thilina 
>> Date: Wed, Jun 1, 2016 at 2:59 AM
>> Subject: Fwd: GSOC 2016 - Project 21 : MongoDB Userstore Development
>> To: WSO2 Developers' List , Tharindu Edirisinghe <
>> tharin...@wso2.com>
>>
>>
>>
>> -- Forwarded message --
>> From: Asantha Thilina 
>> Date: Wed, Jun 1, 2016 at 2:51 AM
>> Subject: Re: GSOC 2016 - Project 21 : MongoDB Userstore Development
>> To: Tharindu Edirisinghe 
>> Cc: WSO2 Developers' List , Lakmal Rupasinghe <
>> lakma...@sliit.lk>
>>
>>
>> Hi Tharindu,
>>
>> I fixed the most of the errors i got now my user store working it is
>> successfully registered and can add users and roles to user store as well
>> still there are some issues in other functions those are query errors i
>> still fixing those as well ,i having some issues  about database
>> transaction point of view and i need some advice from you, in mongodb there
>> is no option to rollback transaction if error occurred how can i manage it?
>> can we arrange a hangout meeting today or any comfortable day for you ? i'm
>> ok with any time
>> all the updates up to now i pushed to my repository[1]
>>
>> [1] https://github.com/asanthamax/mongodbuserstore
>>
>> Thanks,
>> Asantha
>>
>> On Fri, May 27, 2016 at 1:56 AM, Asantha Thilina <
>> asanthathil...@gmail.com> wrote:
>>
>>> Hi Tharindu,
>>>
>>> sure i'll be look forward for that
>>>
>>> Thanks,
>>> Asantha
>>>
>>> On Thu, May 26, 2016 at 9:37 PM, Tharindu Edirisinghe <
>>> tharin...@wso2.com> wrote:
>>>
 Hi Asantha,

 Glad to hear the progress... Sure I'll review over the weekend and
 provide feedback. By next week we'll have a hangout to discuss on how to
 move forward and the difficulties you have faced.  Keep the momentum going 
 !

 Regards,
 TharinduE

 On Fri, May 27, 2016 at 12:17 AM, Asantha Thilina <
 asanthathil...@gmail.com> wrote:

> Hi Tharindu,
>
> i been able to fix the mongodb user store intitalizing error now it
> working successfully it will be registered as a secondary user store in IS
> and when going to add a new users and roles it will show the domain of
> mongodb userstore still i having small issues in my json query formats for
> mongodb i fixing those issues at the moment all the progress so far i made
> updated to my github repository[1] and i recently updated my blog[2] as
> well,can you review my code and give me a feedback?
>
> [1]https://github.com/asanthamax/mongodbuserstore
> [2]http://asanthamax.blogspot.com/
>
> Thanks,
> Asantha
>
> On Sun, May 22, 2016 at 3:38 PM, Asantha Thilina <
> asanthathil...@gmail.com> wrote:
>
>> Hi Tharindu,
>>
>> I have override all the methods in AbstractUserStoreManager in my
>> MongoDBUserStoreManager class after that when i try to add new secondary
>> user store in management console i got following error i attached the
>> screen shot of the error with this mail
>> i have pushed all the progress upto now to my github repository[1]
>> can you give me some tips to solve this issue?
>> any suggestion would be grateful
>> [1] https://github.com/asanthamax/mongodbuserstore
>> Thanks,
>> Asantha
>>
>> On Thu, May 19, 2016 at 11:47 PM, Asantha Thilina <
>> asanthathil...@gmail.com> wrote:
>>
>>> Hi Tharindu,
>>>
>>> sorry for the late reply ,as you advised i remove the scr reference
>>> and its corresponding methods from user store now it's works fine but i
>>> having another small issue if i wanted to run my mongodb user store as 
>>> as
>>> my primary user store how would i do that?
>>> i added my user store configurations to user-mgt.xml file and
>>> comented the ldap userstore pro

Re: [Dev] GSOC 2016 - Project 21 : MongoDB Userstore Development

2016-06-03 Thread Asantha Thilina
Hi Tharindu,

i fixed the most of the errors appeared in my user store in user management
side now it's almost done in user management side now i can add new users
,roles and search roles of users and users of roles only issue i having now
is i can't update a user profile of user in user store i getting a
exception ,i want to get some advice from you to resolve that error and to
implement a logic to commit transaction in mongodb and also another small
problem is when i added a new claim where will it save in primary user
store ? is there any feature to change the user store  where claims going
to save. like it giving an option to select userstore in a dropdown when
adding newusers and roles.

all the works i have done so far in my repo[1]

[1] . https://github.com/asanthamax/mongodbuserstore

Thanks,
Asantha

On Wed, Jun 1, 2016 at 3:00 AM, Asantha Thilina 
wrote:

>
> -- Forwarded message --
> From: Asantha Thilina 
> Date: Wed, Jun 1, 2016 at 2:59 AM
> Subject: Fwd: GSOC 2016 - Project 21 : MongoDB Userstore Development
> To: WSO2 Developers' List , Tharindu Edirisinghe <
> tharin...@wso2.com>
>
>
>
> -- Forwarded message --
> From: Asantha Thilina 
> Date: Wed, Jun 1, 2016 at 2:51 AM
> Subject: Re: GSOC 2016 - Project 21 : MongoDB Userstore Development
> To: Tharindu Edirisinghe 
> Cc: WSO2 Developers' List , Lakmal Rupasinghe <
> lakma...@sliit.lk>
>
>
> Hi Tharindu,
>
> I fixed the most of the errors i got now my user store working it is
> successfully registered and can add users and roles to user store as well
> still there are some issues in other functions those are query errors i
> still fixing those as well ,i having some issues  about database
> transaction point of view and i need some advice from you, in mongodb there
> is no option to rollback transaction if error occurred how can i manage it?
> can we arrange a hangout meeting today or any comfortable day for you ? i'm
> ok with any time
> all the updates up to now i pushed to my repository[1]
>
> [1] https://github.com/asanthamax/mongodbuserstore
>
> Thanks,
> Asantha
>
> On Fri, May 27, 2016 at 1:56 AM, Asantha Thilina  > wrote:
>
>> Hi Tharindu,
>>
>> sure i'll be look forward for that
>>
>> Thanks,
>> Asantha
>>
>> On Thu, May 26, 2016 at 9:37 PM, Tharindu Edirisinghe > > wrote:
>>
>>> Hi Asantha,
>>>
>>> Glad to hear the progress... Sure I'll review over the weekend and
>>> provide feedback. By next week we'll have a hangout to discuss on how to
>>> move forward and the difficulties you have faced.  Keep the momentum going !
>>>
>>> Regards,
>>> TharinduE
>>>
>>> On Fri, May 27, 2016 at 12:17 AM, Asantha Thilina <
>>> asanthathil...@gmail.com> wrote:
>>>
 Hi Tharindu,

 i been able to fix the mongodb user store intitalizing error now it
 working successfully it will be registered as a secondary user store in IS
 and when going to add a new users and roles it will show the domain of
 mongodb userstore still i having small issues in my json query formats for
 mongodb i fixing those issues at the moment all the progress so far i made
 updated to my github repository[1] and i recently updated my blog[2] as
 well,can you review my code and give me a feedback?

 [1]https://github.com/asanthamax/mongodbuserstore
 [2]http://asanthamax.blogspot.com/

 Thanks,
 Asantha

 On Sun, May 22, 2016 at 3:38 PM, Asantha Thilina <
 asanthathil...@gmail.com> wrote:

> Hi Tharindu,
>
> I have override all the methods in AbstractUserStoreManager in my
> MongoDBUserStoreManager class after that when i try to add new secondary
> user store in management console i got following error i attached the
> screen shot of the error with this mail
> i have pushed all the progress upto now to my github repository[1]
> can you give me some tips to solve this issue?
> any suggestion would be grateful
> [1] https://github.com/asanthamax/mongodbuserstore
> Thanks,
> Asantha
>
> On Thu, May 19, 2016 at 11:47 PM, Asantha Thilina <
> asanthathil...@gmail.com> wrote:
>
>> Hi Tharindu,
>>
>> sorry for the late reply ,as you advised i remove the scr reference
>> and its corresponding methods from user store now it's works fine but i
>> having another small issue if i wanted to run my mongodb user store as as
>> my primary user store how would i do that?
>> i added my user store configurations to user-mgt.xml file and
>> comented the ldap userstore properties and i added MongoDBUserStore to
>> tenant-mgt.xml as well but then i get error as datasource cannot be 
>> casted
>> to MongoDB db source while deploying thats mean its still referring to
>> Default Activator inside carbon core module how would i set it to my
>> activator to reffer?
>> any suggestion or help would be grateful
>> Thanks,
>> Asantha
>>
>> On Wed, May 18, 2016 at 10:29 PM,

Re: [Dev] [GSOC 16] Initial Project Progress

2016-06-03 Thread Osura Rathnayake
Hi mentors,

please find the updated membership scheme here [1].
Can you please tell me how to test the membership scheme? Also how can I
get the parameters that are passed into the constructor of the membership
class? Also where is the membership class invoked.

[1]https://github.com/osuran/azure-membership-scheme

Thanks,




On Thu, Jun 2, 2016 at 10:38 AM, Imesh Gunaratne  wrote:

>
>
> On Thu, Jun 2, 2016 at 10:33 AM, Osura Rathnayake 
> wrote:
>
>> Hi mentors,
>>
>> When developing the membership scheme, from where can I get
>> the HazelcastMembershipScheme interface? I Googled but couldn't find an
>> appropriate jar file or anything. the one that netbeans suggests also
>> cannot be downloaded.
>>
>
>
> https://github.com/wso2/carbon-kernel/blob/4.4.x/core/org.wso2.carbon.core/src/main/java/org/wso2/carbon/core/clustering/hazelcast/HazelcastMembershipScheme.java
>
>
> ​Will implement this for Carbon 4.4.x.
>
> Thanks​
>
>
>> Thanks,
>>
>> On Mon, May 30, 2016 at 1:49 AM, Osura Rathnayake 
>> wrote:
>>
>>> Hi Isuru,
>>>
>>> Thank you
>>> I have updated my Git repository with this sample code, please find it
>>> here [1].
>>>
>>> [1] https://github.com/osuran/azure-membership-scheme
>>>
>>> Thanks
>>>
>>> On Sun, May 29, 2016 at 8:41 AM, Isuru Haththotuwa 
>>> wrote:
>>>
 Hi Osura,

 On Sun, May 29, 2016 at 12:32 AM, Osura Rathnayake 
 wrote:

> Hi Isuru,
>
> Please find the attached project zip. From line 108 to 148 I hard
> coded because I was getting errors with StringTokenizer and I didn't want
> to focus much on that.
> Okay I'm right on writing the actual membership scheme.
>
 Thanks. Will have a look.

 It would be better if you can commit this to a github repository. By
 doing that, your sample is available for anyone to use/refer. Make sure to
 remove any sensitive information (passwords, etc.) before doing so.

>
> thanks
>
> On Sat, May 28, 2016 at 10:19 PM, Isuru Haththotuwa 
> wrote:
>
>> Hi Osura,
>>
>> These are great findings!
>>
>> Can you please share the sample code that you wrote?
>>
>> The next step would be to start writing the actual membership scheme.
>> Please refer the Kubernetes Membership scheme as a reference.
>>
>>
>> On Sat, May 28, 2016 at 9:06 PM, Osura Rathnayake > > wrote:
>>
>>> Hi All,
>>>
>>>
>>>
>>> This is the summary of everything that I have done so far.
>>>
>>>
>>>
>>> Pre requisite: VMs which has WSO2 Application Server running should
>>> have been added to a particular network security group (NSG). In my case
>>> it’s ASNSG
>>>
>>>
>>>
>>> First the java app should be authenticated. Then it query for the
>>> information on ASNSG. Response of that API call includes names of all 
>>> the
>>> network interfaces that are existed in ASNSG. Then each and every 
>>> network
>>> interface is queried using their names to get private IP addresses of 
>>> each
>>> of them. As the final outcome we get a list of IP addresses of VMs which
>>> has WSO2 Application Server running.
>>>
>>>
>>>
>>> *Authentication*
>>>
>>> In order to work with Azure Resource Manager (ARM) REST API, first
>>> of all our app has to be authenticated. ARM provides two methods for 
>>> this
>>> purpose,
>>>
>>>
>>>
>>> 1) Authenticate using service principal
>>>
>>> 2) Authenticate using organizational account.
>>>
>>>
>>>
>>> I have used the first method that is authenticating using a service
>>> principal.  A Service Principal is an instance of an application that is
>>> within your Active Directory that is allowed access to one or more
>>> resources or an entire resource group. How to set up a service 
>>> principal is
>>> well described here [1]. Once you successfully set up a service 
>>> principal,
>>> you will have the following information in hand.
>>>
>>>
>>>
>>> 1)  Client ID
>>>
>>> 2)  Client secret
>>>
>>> 3)  Tenant ID
>>>
>>> Above parameters and Azure subscription ID are used in the java app
>>> for authentication purpose. I have used Active Directory Authentication
>>> Library (ADAL) [2] for authentication. Once the authentication is
>>> successful, an authentication token will be issued and it will be used 
>>> in
>>> the rest of the program as to make calls to API.
>>>
>>>
>>>
>>> *Getting information on ASNSG*
>>>
>>> For this purpose, [3] API reference is used. As the response we get
>>> a JSON string which includes names of NICs which are available in ASNSG.
>>>
>>>
>>>
>>> *Getting private IP address of each NIC*
>>>
>>> With the NIC names we received from previous API call, we can use
>>> this [4] API referenc

Re: [Dev] Requesting the parameters for throttling policy configurations in api-manager.xml

2016-06-03 Thread Amila De Silva
Hi Ushani,

For the new throttling to work you first have to
set EnableAdvanceThrottling to true. When EnableHeaderConditions is set to
true, all the headers in the incoming message will be published to the CEP.
Similarly Setting EnableJWTClaimConditions and EnableQueryParamConditions
to true would publish JWT claims and the query parameters coming with the
request to the CEP. In the latest pack, spike arrest is only enabled
through the UI, so there's no config element for that.

On Fri, Jun 3, 2016 at 6:35 PM, Ushani Balasooriya  wrote:

> Hi APIM Team,
>
> It would be highly appreciated, if you can let us know the parameters that
> need to be enabled in api-manager.xml when working with throttling since
> the documents are not ready yet.
>
> E.g., Spike arrest policy parameter, Query param parameter.
>
>
> Thanks and regards,
> --
> *Ushani Balasooriya*
> Senior Software Engineer - QA;
> WSO2 Inc; http://www.wso2.com/.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "WSO2 Documentation Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to documentation+unsubscr...@wso2.com.
> For more options, visit https://groups.google.com/a/wso2.com/d/optout.
>



-- 
*Amila De Silva*

WSO2 Inc.
mobile :(+94) 775119302
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Fwd: GSOC2016: [ML][CEP] Predictive analytic with online data for WSO2 Machine Learner

2016-06-03 Thread Mahesh Dananjaya
Hi Maheshkya,
I have added those timing reports to my repo [1].please have a look at.
three files are there. one is using incremet as 1000 for batch sizes
(lr_timing_1000). Otherone is using incremet by 1 (lr_timing_1)
upto 1 million in both scenarios.you can see the reports and figures in the
location [2] in the repo. i also added the streaminglinearregression
classes in the repo gsoc folder.thank you.
regards,
Mahesh.
[1]https://github.com/dananjayamahesh/GSOC2016
[2]
https://github.com/dananjayamahesh/GSOC2016/tree/master/spark-examples/first-example/output

On Mon, May 30, 2016 at 9:24 AM, Maheshakya Wijewardena  wrote:

> Hi Mahesh,
>
> Thank you for the update. I will look into your implementation.
>
> And i will be able to send you the timing/performances analysis report
>> tomorrow for the SGD functions
>>
>
> Great. Sent those asap so that we can proceed.
>
> Best regards.
>
> On Sun, May 29, 2016 at 6:56 PM, Mahesh Dananjaya <
> dananjayamah...@gmail.com> wrote:
>
>>
>> Hi maheshakay,
>> I have implemented the linear regression with cep siddhi event stream
>> with  taking batch sizes as parameters from the cep. Now we can trying the
>> moving window method to. Before that i think i should get your opinion on
>> data structures to save the streaming data.please check my repo [1]  /gsoc/
>> folder there you can find all new things i add.. there in the extension
>> folder you can find those extension. And i will be able to send you the
>> timing/performances analysis report tomorrow for the SGD functions. thank
>> you.
>> regards,
>> Mahesh.
>> [1] https://github.com/dananjayamahesh/GSOC2016/tree/master/gsoc
>>
>>
>> On Fri, May 27, 2016 at 12:56 PM, Mahesh Dananjaya <
>> dananjayamah...@gmail.com> wrote:
>>
>>> Hi maheshkaya,
>>> i have written some siddhi extension and trying to develop a one for my
>>> one. In time series example in the [1], can you please explain me the input
>>> format and query lines in that example for my understanding.
>>>
>>> from baseballData#timeseries:regress(2, 1, 0.95, salary, rbi,
>>> walks, strikeouts, errors)
>>> select *
>>> insert into regResults;
>>>
>>> i just want to knwo how i give a set of data into this extension and
>>> what is baseballData. Is it input stream as usual.or any data file?how can
>>> i find that data set to create dummy input stream like baseballData?
>>>
>>> thank you.
>>> regards,
>>> Mahesh.
>>> [1]
>>> https://docs.wso2.com/display/CEP400/Writing+a+Custom+Stream+Processor+Extension
>>>
>>> On Thu, May 26, 2016 at 2:58 PM, Mahesh Dananjaya <
>>> dananjayamah...@gmail.com> wrote:
>>>
 Hi Maheshakya,
 today i got the siddhi and debug the math extention. then did some
 changes and check. Now i am trying to write same kind of extension in my
 code base. so i add dependencies and it was built fine. Now i am trying to
 debug my extension and i did the same thing as i did in previous case. Cep
 is sending data, bu my extension is not firing in relevant break point.
 1. So how can i debug the siddhi extension in my new extension.(you can
 see it in my example repoo)

 I think if i do it correctly we can built the extension for our
 purpose. And i will send the relevant timing report of SGD algorithms very
 soon as supun was asking me. thank you.
 regards,
 Mahesh.

 On Tue, May 24, 2016 at 11:07 AM, Maheshakya Wijewardena <
 mahesha...@wso2.com> wrote:

> Also note that there is a calculation interval in the siddhi time
> series regression function[1]. You maybe able get some insight for this
> from that as well.
>
> [1] https://docs.wso2.com/display/CEP400/Regression
>
> On Tue, May 24, 2016 at 11:03 AM, Maheshakya Wijewardena <
> mahesha...@wso2.com> wrote:
>
>> Hi Mahesh,
>>
>> As we discussed offline, we can use similar mechanism to train linear
>> regression models, logistic regression models and k-means clustering 
>> models.
>>
>> It is very interesting that i have found that somethings that can
>>> make use of our work. In the cep 4.0 documentation there is a Custom 
>>> Stream
>>> Processor Extention program [1]. There is a example of
>>> LinearRegressionStreamProcessor [1].
>>>
>>
>> As we have to train predictive models with Spark, you can write
>> wrappers around regression/clustering models of Spark. Refer to Siddhi 
>> time
>> series regression source codes[1][2]. You can write a streaming linear
>> regression class for ML in a similar fashion by wrapping Spark mllib
>> implementations. You can use the methods "addEvent", "removeEvent", etc.
>> (may have to be changed according to requirements) for the similar 
>> purpose.
>> You can introduce trainLinearRegression/LogisticRegression/Kmeans which
>> does a similar thing as in createLinearRegression in those time series
>> functions. In the processData method you can use Sp

[Dev] Requesting the parameters for throttling policy configurations in api-manager.xml

2016-06-03 Thread Ushani Balasooriya
Hi APIM Team,

It would be highly appreciated, if you can let us know the parameters that
need to be enabled in api-manager.xml when working with throttling since
the documents are not ready yet.

E.g., Spike arrest policy parameter, Query param parameter.


Thanks and regards,
-- 
*Ushani Balasooriya*
Senior Software Engineer - QA;
WSO2 Inc; http://www.wso2.com/.
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] IS as KM functionality test with P2

2016-06-03 Thread Bhathiya Jayasekara
I tested IS as KM with locally built IS pack on last Tuesday. It was
successful.

Thanks,
Bhathiya

On Fri, Jun 3, 2016 at 4:51 PM, Kavitha Subramaniyam 
wrote:

> + [DEV] & AmilaD
>
> On Fri, Jun 3, 2016 at 4:27 PM, Ushani Balasooriya 
> wrote:
>
>> + Pulasthi
>>
>> On Fri, Jun 3, 2016 at 3:36 PM, Ushani Balasooriya 
>> wrote:
>>
>>> Hi IS team,
>>>
>>> It would be great if you can confirm this ASAP for us to proceed with IS
>>> as KM testing in APIM 2.0.
>>>
>>> Thanks,
>>>
>>> On Fri, Jun 3, 2016 at 3:06 PM, Kavitha Subramaniyam 
>>> wrote:
>>>
 Sorry. I missed to give the links.

 APIM 2.0.0 SNAPSHOT nightly build[2]
 P2 repo provided [3]


 [2]
 https://svn.wso2.org/repos/wso2/scratch/2016/apim-2.0.0/wso2am-2.0.0-SNAPSHOT-01-06-2016.zip
 [3]
 https://svn.wso2.org/repos/wso2/scratch/2016/apim-2.0.0/p2-repos/pre-beta/p2-repo.zip



 On Fri, Jun 3, 2016 at 2:44 PM, Kavitha Subramaniyam 
 wrote:

> Hi Johann/ Pushpalanka,
>
> $subject, we got the P2 repo from APIM team and we need to confirm
> that we can carryout the test with pre-RC pack available here[1]; or if
> there is a latest build available to compatible with P2, can you please
> share with us.
>
>
> [1] https://svn.wso2.com/wso2/custom/projects/scratch/thanuja/wso2is-
> 5.2.0-SNAPSHOT.zip
>
> Thanks,
> --
> Kavitha.S
> *Software Engineer -QA*
> Mobile : +94 (0) 771538811 <%2B94%20%280%29%20773%20451194>
> kavi...@wso2.com 
>



 --
 Kavitha.S
 *Software Engineer -QA*
 Mobile : +94 (0) 771538811 <%2B94%20%280%29%20773%20451194>
 kavi...@wso2.com 

>>>
>>>
>>>
>>> --
>>> *Ushani Balasooriya*
>>> Senior Software Engineer - QA;
>>> WSO2 Inc; http://www.wso2.com/.
>>> Mobile; +94772636796
>>>
>>>
>>
>>
>> --
>> *Ushani Balasooriya*
>> Senior Software Engineer - QA;
>> WSO2 Inc; http://www.wso2.com/.
>> Mobile; +94772636796
>>
>>
>
>
> --
> Kavitha.S
> *Software Engineer -QA*
> Mobile : +94 (0) 771538811 <%2B94%20%280%29%20773%20451194>
> kavi...@wso2.com 
>



-- 
*Bhathiya Jayasekara*
*Senior Software Engineer,*
*WSO2 inc., http://wso2.com *

*Phone: +94715478185*
*LinkedIn: http://www.linkedin.com/in/bhathiyaj
*
*Twitter: https://twitter.com/bhathiyax *
*Blog: http://movingaheadblog.blogspot.com
*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] IS as KM functionality test with P2

2016-06-03 Thread Kavitha Subramaniyam
+ [DEV] & AmilaD

On Fri, Jun 3, 2016 at 4:27 PM, Ushani Balasooriya  wrote:

> + Pulasthi
>
> On Fri, Jun 3, 2016 at 3:36 PM, Ushani Balasooriya 
> wrote:
>
>> Hi IS team,
>>
>> It would be great if you can confirm this ASAP for us to proceed with IS
>> as KM testing in APIM 2.0.
>>
>> Thanks,
>>
>> On Fri, Jun 3, 2016 at 3:06 PM, Kavitha Subramaniyam 
>> wrote:
>>
>>> Sorry. I missed to give the links.
>>>
>>> APIM 2.0.0 SNAPSHOT nightly build[2]
>>> P2 repo provided [3]
>>>
>>>
>>> [2]
>>> https://svn.wso2.org/repos/wso2/scratch/2016/apim-2.0.0/wso2am-2.0.0-SNAPSHOT-01-06-2016.zip
>>> [3]
>>> https://svn.wso2.org/repos/wso2/scratch/2016/apim-2.0.0/p2-repos/pre-beta/p2-repo.zip
>>>
>>>
>>>
>>> On Fri, Jun 3, 2016 at 2:44 PM, Kavitha Subramaniyam 
>>> wrote:
>>>
 Hi Johann/ Pushpalanka,

 $subject, we got the P2 repo from APIM team and we need to confirm that
 we can carryout the test with pre-RC pack available here[1]; or if there is
 a latest build available to compatible with P2, can you please share with
 us.


 [1] https://svn.wso2.com/wso2/custom/projects/scratch/thanuja/wso2is-
 5.2.0-SNAPSHOT.zip

 Thanks,
 --
 Kavitha.S
 *Software Engineer -QA*
 Mobile : +94 (0) 771538811 <%2B94%20%280%29%20773%20451194>
 kavi...@wso2.com 

>>>
>>>
>>>
>>> --
>>> Kavitha.S
>>> *Software Engineer -QA*
>>> Mobile : +94 (0) 771538811 <%2B94%20%280%29%20773%20451194>
>>> kavi...@wso2.com 
>>>
>>
>>
>>
>> --
>> *Ushani Balasooriya*
>> Senior Software Engineer - QA;
>> WSO2 Inc; http://www.wso2.com/.
>> Mobile; +94772636796
>>
>>
>
>
> --
> *Ushani Balasooriya*
> Senior Software Engineer - QA;
> WSO2 Inc; http://www.wso2.com/.
> Mobile; +94772636796
>
>


-- 
Kavitha.S
*Software Engineer -QA*
Mobile : +94 (0) 771538811 <%2B94%20%280%29%20773%20451194>
kavi...@wso2.com 
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [Test Automation] How can we attach a file with post request in a test case

2016-06-03 Thread Dharshana Warusavitharana
Hi Mahesh,

You have to add a generic rest client for your module. We have a sample on
Greg at [1]. You need to use that.

[1].
https://github.com/wso2/product-greg/blob/master/modules/integration/tests-common/integration-test-utils/src/main/java/org/wso2/greg/integration/common/utils/GenericRestClient.java

Thank you,
Dharshana.

On Fri, Jun 3, 2016 at 2:34 PM, Irham Iqbal  wrote:

> Adding
>
> On Thu, Jun 2, 2016 at 4:51 PM, Mahesh Chinthaka  wrote:
>
>> Hi,
>>
>> I want to attach a file for a post request along with some other
>> parameters and values.
>> What is the usual practice we follow in wso2 test automation framework ?
>>
>> --
>> *Mahesh Chinthaka Vidanagama* | Software Engineer
>> WSO2, Inc | lean. enterprise. middleware.
>> #20, Palm Grove, Colombo 03, Sri Lanka
>> Mobile: +94 71 63 63 083 | Work: +94 112 145 345
>> Email: mahe...@wso2.com | Web: www.wso2.com
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Irham Iqbal
> Software Engineer - Test Automation
> WSO2, Inc.: http://wso2.com
> lean. enterprise. middleware
> phone: +94 777888452
>



-- 

Dharshana Warusavitharana
Senior Software Engineer , Test Automation
WSO2 Inc. http://wso2.com
email : dharsha...@wso2.com 
Tel  : +94 11 214 5345
Fax :+94 11 2145300
cell : +94770342233
blog : http://dharshanaw.blogspot.com

lean . enterprise . middleware
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [wso2/siddhi] Has problems with Siddhi group by with a time window (#154)

2016-06-03 Thread Tishan Dahanayakage
Ralph,

Please find inline.

On Fri, Jun 3, 2016 at 4:06 PM, Liangfei.Su  wrote:

> Sorry, i don't catch here. Let's say the second time of query call back,
> should be two group results (why the first tuple not expect to be in the
> groups)?
>
​In ExternalTimeWindow when a new event arrives, a copy will be stored and
original will be sent out as a current event alongside with any other
stored events which are expired. ​In this case no events will be expired
within the period input is received. So every-time only one event will
arrive at callback(There can be a situation where events can be grouped
because they are published in quick succession. But that is not
guaranteed). Output of the ExternalTimeBatch window does not represent the
events that resides inside the window at that time. Hope this clear your
doubt.

>
>
>
> Understand the external time batch as i was working on it. :)
>

​Oh OK. So you are @RalphSu. Just connected the dots :) Thanks again for
your contribution.

/Tishan​


>
>
> Ralph
>
>
> On Fri, Jun 3, 2016 at 5:57 PM, Tishan Dahanayakage 
> wrote:
>
>> Yeah. So if that block is inside your siddhiBolt.queryCallback, Then
>> each time you receive an event you will create a new Map(tempMap). Hence
>> your count will always be 1. For your requirement you have to use external
>> time batch window as Charini mentioned earlier.
>>
>> /Tishan
>>
>> On Fri, Jun 3, 2016 at 3:21 PM, Liangfei.Su  wrote:
>>
>>> Garrett might provide more details.
>>>
>>> There is format issue in github. Follow the code, basically, the output
>>> try to read the event data into Map of instanceUUid -> List>> different similarity> , then print the count of each instanceUuid.
>>>
>>> See
>>>
>>> String message = String.format("Count: %s; message=%s, timestamp=%s, 
>>> similarityId=%s,
>>>
>>>
>>>
>>>
>>>
>>> On Fri, Jun 3, 2016 at 2:59 PM, Tishan Dahanayakage 
>>> wrote:
>>>
 Ralph,

 Does following code recide inside your siddhiBolt.queryCallback?

 Map> tempMap = new HashMap>();
 for (Event event : inEvents) {
 Object[] data = event.getData();
 BootCorrelationAggregationData aggregateData = new
 BootCorrelationAggregationData();
 aggregateData.setSimilarityId((String) data[0]);
 aggregateData.setMessage((String) data[1]);
 aggregateData.setUuid((String) data[2]);
 aggregateData.setTimestamp((Long) data[3]);
 if (!tempMap.containsKey(aggregateData.getUuid())) {
 tempMap.put(aggregateData.getUuid(), new ArrayList());
 }
 tempMap.get(aggregateData.getUuid()).add(aggregateData);
 }

 Thanks
 /Tishan

 On Fri, Jun 3, 2016 at 11:47 AM, Liangfei.Su 
 wrote:

> +Garrett
>
> Understand the output based on each input data. The question here is,
> the count is always 1, i'm expecting count=1/2/3. e.g. when second input
> message send in, the first input message should still kept in the windows,
> so expect there should be two groups...
>
>
>
>
>
> On Fri, Jun 3, 2016 at 11:14 AM, Charini Nanayakkara <
> chari...@wso2.com> wrote:
>
>> Hi Liangfei.Su,
>>
>> This is the expected behavior of external time window. Since it's a
>> moving time window, you get an output for each incoming event. Due to the
>> presence of the group by keyword, it would give an aggregate output by
>> considering the events with the same uuid and similarityId, which arrived
>> within last two minutes.
>>
>> If you need only one output per group use the external time batch
>> window instead. Ensure that all the events come within the time duration
>> which you specify here.
>>
>> Regards,
>> Charini
>>
>> On Fri, Jun 3, 2016 at 6:16 AM, Liangfei.Su 
>> wrote:
>>
>>> +WSO2 @DL
>>>
>>> Could someone eligible to explain?
>>>
>>> https://github.com/wso2/siddhi/issues/154
>>>
>>>
>>> Thanks,
>>> Ralph
>>>
>>>
>>> On Fri, Jun 3, 2016 at 8:21 AM, Garrett 
>>> wrote:
>>>
 Has problems with Siddhi group by with a time window, I am able to
 get the correct result aggregations for the group, but I receive one
 aggregated result per event, not one per group.

 Here is the query:
 define stream bootCorrelationStream (logLevel string, message
 string, similarityId string, timestamp long, uuid string); @info(name =
 'bootCorrelation') from
 bootCorrelationStream[logLevel=='ERROR']#window.externalTime(timestamp,
  2
 min) select similarityId, adanos:first(message) as message, 
 min(timestamp)
 as startTime, max(timestamp) as endTime group by uuid, similarityId 
 insert
 into tempStream;

 Here is the output:
 Count: 1; message=ERROR first message, timestamp=2016-05-21
 01:22:07.579
 Count: 1; message=ERROR second message, timestamp=2016-05

Re: [Dev] [GSoC 2016]Proposal 03: [ML]Visual(Deep) Neural Network Builder -Project Progress

2016-06-03 Thread Lakini Senanayaka
Hi,

Thank you very much Chathurike.It will be really helpful for my NN Builder.

Thank you.

On Fri, Jun 3, 2016 at 10:50 AM, CD Athuraliya  wrote:

> Hi Lakini,
>
> You can gain some insight for your NN builder from TensorFlow Playground
> [1]. It is also open source under Apache 2.0 licence [2].
>
> [1] http://playground.tensorflow.org
> [2] https://github.com/tensorflow/playground
>
> Regards,
> CD
>
> On Thu, Jun 2, 2016 at 8:00 AM, Upul Bandara  wrote:
>
>> Yes at the moment this looks OK.
>>
>> Please put some effort to create a basic version of the NN builder and
>> let's have a quick demo.
>>
>> Let me know if you have further questions or clarifications.
>>
>> Thanks,
>> Upul
>>
>> On Wed, Jun 1, 2016 at 11:29 PM, Lakini Senanayaka <
>> lakinisenanayak...@gmail.com> wrote:
>>
>>> Hi,
>>>
>>> Thank you very much Upul. I will submit a demo soon.
>>>
>>> I have drawn a sketch of NN builder front end[1]. Basically it will be
>>> like this UI[2].(The content will be changed.)
>>>
>>> [1]Sketch of NN Builder
>>> 
>>> [2]https://www.draw.io/  
>>>
>>> In [1],under "layers" users can select the type of the
>>> layer-Input,Hidden or Output layer.
>>> Under "node" and "Connectors"-users can drag and drop nodes and
>>> connectors to the working area and they can build their NN as they wish.
>>>
>>> In the right hand side,there is a setting area.From that user can set
>>> Optimization algorithms,iterations,learning rates,seed etc. of the neural
>>> network.
>>>
>>> Could you please give me comments and your thoughts regrading this?
>>>
>>> Thank you.
>>>
>>>
>>>
>>> On Wed, Jun 1, 2016 at 2:19 PM, Upul Bandara  wrote:
>>>
 Hi,

 Good progress.

 The key parts of the project are designing the front-end of NN builder,
 communicating between the front-end and the Deeplearning4J back-end.
 So at this stage of the project, it is better to put your effort on
 above the components. Later, we can integrate what you have built with WSO2
 Machine Learning server.

 Once you have completed a basic NN builder (ability to build a simple
 feedforward  is enough) we would like to have a quick demo.

 Let me know if you have further questions or clarifications.

 Thanks,
 Upul

 On Wed, Jun 1, 2016 at 10:42 AM, Lakini Senanayaka <
 lakinisenanayak...@gmail.com> wrote:

> Hi,
>
> I'm sorry for the late response.Thank you very much for the last
> email.I have gone through JQueryUI and I have implemented some samples
> using JQueryUI.I have gone through the  WSO2 machine learner and I have
> identified the place to insert this jaggery page(replace the
> hyper-parameter page in the ML UI).
> Currently I'm designing the sketch of the Deep Neural Network
> Builder-the front end.
> I'll send my sketch before tonight.Based on your comments I can start
> implementations.
>
> Thank you.
>
>
> On Wed, Jun 1, 2016 at 9:29 AM, Supun Sethunga 
> wrote:
>
>> Hi Lakini,
>>
>> Any update on the progress?
>>
>> Regards,
>> Supun
>>
>> On Fri, May 27, 2016 at 5:34 PM, Supun Sethunga 
>> wrote:
>>
>>> Hi Lakini,
>>>
>>> Sorry for the delayed response. As the first part of the project,
>>> you can start the work on the UI/drag and drop feature, as the core of 
>>> your
>>> project is based around that. Therefore, shall we try to get a basic
>>> version of drag and drop UI, by the mid-term evaluation? (No need to
>>> connect the UI with the dl4j, for the first phase)  So this would be
>>> include:
>>>
>>>- A link/re-direct to go to Visual builder, upon selecting the
>>>Neural Netowrks (as the algorithm)
>>>- The drawing/dropping area and a panel to pick the objects to
>>>be dragged (objects as in, nodes, layers, links, etc)
>>>
>>> This drag and drop page should replace the hyper-parameter page in
>>> the ML UI. More precisely, In the Machine Learner wizard, when a user 
>>> picks
>>> the algorithm name as Neural Network, and proceed, this drag and drop 
>>> page
>>> should be prompted instead of the hyper-parameters page. You can create 
>>> the
>>> overall page as a jaggery page (.jag). It would be easier for you to 
>>> get a
>>> copy of an existing page, and modifying the content. That will preserve 
>>> the
>>> existing styles, session handling etc.
>>>
>>> Please feel free to raise any question you come across during
>>> implementing.
>>>
>>> Regards,
>>> Supun
>>>
>>> On Tue, May 24, 2016 at 8:09 PM, Lakini Senanayaka <
>>> lakinisenanayak...@gmail.com> wrote:
>>>
 Hi,

 Thank you very much for the suggestions.I will be using JQueryUI.

Re: [Dev] [wso2/siddhi] Has problems with Siddhi group by with a time window (#154)

2016-06-03 Thread Liangfei.Su
Sorry, i don't catch here. Let's say the second time of query call back,
should be two group results (why the first tuple not expect to be in the
groups)?



Understand the external time batch as i was working on it. :)


Ralph


On Fri, Jun 3, 2016 at 5:57 PM, Tishan Dahanayakage  wrote:

> Yeah. So if that block is inside your siddhiBolt.queryCallback, Then each
> time you receive an event you will create a new Map(tempMap). Hence your
> count will always be 1. For your requirement you have to use external time
> batch window as Charini mentioned earlier.
>
> /Tishan
>
> On Fri, Jun 3, 2016 at 3:21 PM, Liangfei.Su  wrote:
>
>> Garrett might provide more details.
>>
>> There is format issue in github. Follow the code, basically, the output
>> try to read the event data into Map of instanceUUid -> List> different similarity> , then print the count of each instanceUuid.
>>
>> See
>>
>> String message = String.format("Count: %s; message=%s, timestamp=%s, 
>> similarityId=%s,
>>
>>
>>
>>
>>
>> On Fri, Jun 3, 2016 at 2:59 PM, Tishan Dahanayakage 
>> wrote:
>>
>>> Ralph,
>>>
>>> Does following code recide inside your siddhiBolt.queryCallback?
>>>
>>> Map> tempMap = new HashMap>();
>>> for (Event event : inEvents) {
>>> Object[] data = event.getData();
>>> BootCorrelationAggregationData aggregateData = new
>>> BootCorrelationAggregationData();
>>> aggregateData.setSimilarityId((String) data[0]);
>>> aggregateData.setMessage((String) data[1]);
>>> aggregateData.setUuid((String) data[2]);
>>> aggregateData.setTimestamp((Long) data[3]);
>>> if (!tempMap.containsKey(aggregateData.getUuid())) {
>>> tempMap.put(aggregateData.getUuid(), new ArrayList());
>>> }
>>> tempMap.get(aggregateData.getUuid()).add(aggregateData);
>>> }
>>>
>>> Thanks
>>> /Tishan
>>>
>>> On Fri, Jun 3, 2016 at 11:47 AM, Liangfei.Su 
>>> wrote:
>>>
 +Garrett

 Understand the output based on each input data. The question here is,
 the count is always 1, i'm expecting count=1/2/3. e.g. when second input
 message send in, the first input message should still kept in the windows,
 so expect there should be two groups...





 On Fri, Jun 3, 2016 at 11:14 AM, Charini Nanayakkara >>> > wrote:

> Hi Liangfei.Su,
>
> This is the expected behavior of external time window. Since it's a
> moving time window, you get an output for each incoming event. Due to the
> presence of the group by keyword, it would give an aggregate output by
> considering the events with the same uuid and similarityId, which arrived
> within last two minutes.
>
> If you need only one output per group use the external time batch
> window instead. Ensure that all the events come within the time duration
> which you specify here.
>
> Regards,
> Charini
>
> On Fri, Jun 3, 2016 at 6:16 AM, Liangfei.Su 
> wrote:
>
>> +WSO2 @DL
>>
>> Could someone eligible to explain?
>>
>> https://github.com/wso2/siddhi/issues/154
>>
>>
>> Thanks,
>> Ralph
>>
>>
>> On Fri, Jun 3, 2016 at 8:21 AM, Garrett 
>> wrote:
>>
>>> Has problems with Siddhi group by with a time window, I am able to
>>> get the correct result aggregations for the group, but I receive one
>>> aggregated result per event, not one per group.
>>>
>>> Here is the query:
>>> define stream bootCorrelationStream (logLevel string, message
>>> string, similarityId string, timestamp long, uuid string); @info(name =
>>> 'bootCorrelation') from
>>> bootCorrelationStream[logLevel=='ERROR']#window.externalTime(timestamp, 
>>> 2
>>> min) select similarityId, adanos:first(message) as message, 
>>> min(timestamp)
>>> as startTime, max(timestamp) as endTime group by uuid, similarityId 
>>> insert
>>> into tempStream;
>>>
>>> Here is the output:
>>> Count: 1; message=ERROR first message, timestamp=2016-05-21
>>> 01:22:07.579
>>> Count: 1; message=ERROR second message, timestamp=2016-05-21
>>> 01:22:08.314
>>> Count: 1; message=ERROR third message, timestamp=2016-05-21
>>> 01:22:15.017
>>> Count: 1; message=ERROR fourth message, timestamp=2016-05-21
>>> 01:25:07.017
>>>
>>> Here is the major code:
>>> register callback
>>> `
>>> this.siddhiRuntime = new SiddhiRuntimeHolder();
>>> this.siddhiRuntime.siddhiManager = new SiddhiManager();
>>> ExecutionPlanRuntime executionPlanRuntime =
>>> this.siddhiRuntime.siddhiManager.createExecutionPlanRuntime(this.getExecutionPlan());
>>> this.siddhiRuntime.inputHandler =
>>> executionPlanRuntime.getInputHandler(this.getStreamName());
>>>
>>> final SiddhiBolt siddhiBolt = this;
>>> this.siddhiRuntime.queryCallback = new QueryCallback() {
>>> @Override
>>> public void receive(long timeStamp, 
>>> org.wso2.siddhi.core.event.Event[] inEvents,
>>>

Re: [Dev] [wso2/siddhi] Has problems with Siddhi group by with a time window (#154)

2016-06-03 Thread Tishan Dahanayakage
Yeah. So if that block is inside your siddhiBolt.queryCallback, Then each
time you receive an event you will create a new Map(tempMap). Hence your
count will always be 1. For your requirement you have to use external time
batch window as Charini mentioned earlier.

/Tishan

On Fri, Jun 3, 2016 at 3:21 PM, Liangfei.Su  wrote:

> Garrett might provide more details.
>
> There is format issue in github. Follow the code, basically, the output
> try to read the event data into Map of instanceUUid -> List different similarity> , then print the count of each instanceUuid.
>
> See
>
> String message = String.format("Count: %s; message=%s, timestamp=%s, 
> similarityId=%s,
>
>
>
>
>
> On Fri, Jun 3, 2016 at 2:59 PM, Tishan Dahanayakage 
> wrote:
>
>> Ralph,
>>
>> Does following code recide inside your siddhiBolt.queryCallback?
>>
>> Map> tempMap = new HashMap>();
>> for (Event event : inEvents) {
>> Object[] data = event.getData();
>> BootCorrelationAggregationData aggregateData = new
>> BootCorrelationAggregationData();
>> aggregateData.setSimilarityId((String) data[0]);
>> aggregateData.setMessage((String) data[1]);
>> aggregateData.setUuid((String) data[2]);
>> aggregateData.setTimestamp((Long) data[3]);
>> if (!tempMap.containsKey(aggregateData.getUuid())) {
>> tempMap.put(aggregateData.getUuid(), new ArrayList());
>> }
>> tempMap.get(aggregateData.getUuid()).add(aggregateData);
>> }
>>
>> Thanks
>> /Tishan
>>
>> On Fri, Jun 3, 2016 at 11:47 AM, Liangfei.Su 
>> wrote:
>>
>>> +Garrett
>>>
>>> Understand the output based on each input data. The question here is,
>>> the count is always 1, i'm expecting count=1/2/3. e.g. when second input
>>> message send in, the first input message should still kept in the windows,
>>> so expect there should be two groups...
>>>
>>>
>>>
>>>
>>>
>>> On Fri, Jun 3, 2016 at 11:14 AM, Charini Nanayakkara 
>>> wrote:
>>>
 Hi Liangfei.Su,

 This is the expected behavior of external time window. Since it's a
 moving time window, you get an output for each incoming event. Due to the
 presence of the group by keyword, it would give an aggregate output by
 considering the events with the same uuid and similarityId, which arrived
 within last two minutes.

 If you need only one output per group use the external time batch
 window instead. Ensure that all the events come within the time duration
 which you specify here.

 Regards,
 Charini

 On Fri, Jun 3, 2016 at 6:16 AM, Liangfei.Su 
 wrote:

> +WSO2 @DL
>
> Could someone eligible to explain?
>
> https://github.com/wso2/siddhi/issues/154
>
>
> Thanks,
> Ralph
>
>
> On Fri, Jun 3, 2016 at 8:21 AM, Garrett 
> wrote:
>
>> Has problems with Siddhi group by with a time window, I am able to
>> get the correct result aggregations for the group, but I receive one
>> aggregated result per event, not one per group.
>>
>> Here is the query:
>> define stream bootCorrelationStream (logLevel string, message string,
>> similarityId string, timestamp long, uuid string); @info(name =
>> 'bootCorrelation') from
>> bootCorrelationStream[logLevel=='ERROR']#window.externalTime(timestamp, 2
>> min) select similarityId, adanos:first(message) as message, 
>> min(timestamp)
>> as startTime, max(timestamp) as endTime group by uuid, similarityId 
>> insert
>> into tempStream;
>>
>> Here is the output:
>> Count: 1; message=ERROR first message, timestamp=2016-05-21
>> 01:22:07.579
>> Count: 1; message=ERROR second message, timestamp=2016-05-21
>> 01:22:08.314
>> Count: 1; message=ERROR third message, timestamp=2016-05-21
>> 01:22:15.017
>> Count: 1; message=ERROR fourth message, timestamp=2016-05-21
>> 01:25:07.017
>>
>> Here is the major code:
>> register callback
>> `
>> this.siddhiRuntime = new SiddhiRuntimeHolder();
>> this.siddhiRuntime.siddhiManager = new SiddhiManager();
>> ExecutionPlanRuntime executionPlanRuntime =
>> this.siddhiRuntime.siddhiManager.createExecutionPlanRuntime(this.getExecutionPlan());
>> this.siddhiRuntime.inputHandler =
>> executionPlanRuntime.getInputHandler(this.getStreamName());
>>
>> final SiddhiBolt siddhiBolt = this;
>> this.siddhiRuntime.queryCallback = new QueryCallback() {
>> @Override
>> public void receive(long timeStamp, 
>> org.wso2.siddhi.core.event.Event[] inEvents,
>> org.wso2.siddhi.core.event.Event[] removeEvents) {
>> siddhiBolt.queryCallback(timeStamp, inEvents, removeEvents);
>> }
>> };
>> executionPlanRuntime.addCallback("query", 
>> this.siddhiRuntime.queryCallback);
>> executionPlanRuntime.start();
>>
>>
>> query details
>>
>> public static String generateExecutionPlan() {
>> // make sure the fields' name sorted
>

Re: [Dev] [wso2/siddhi] Has problems with Siddhi group by with a time window (#154)

2016-06-03 Thread Liangfei.Su
Garrett might provide more details.

There is format issue in github. Follow the code, basically, the output try
to read the event data into Map of instanceUUid -> List , then print the count of each instanceUuid.

See

String message = String.format("Count: %s; message=%s, timestamp=%s,
similarityId=%s,





On Fri, Jun 3, 2016 at 2:59 PM, Tishan Dahanayakage  wrote:

> Ralph,
>
> Does following code recide inside your siddhiBolt.queryCallback?
>
> Map> tempMap = new HashMap>();
> for (Event event : inEvents) {
> Object[] data = event.getData();
> BootCorrelationAggregationData aggregateData = new
> BootCorrelationAggregationData();
> aggregateData.setSimilarityId((String) data[0]);
> aggregateData.setMessage((String) data[1]);
> aggregateData.setUuid((String) data[2]);
> aggregateData.setTimestamp((Long) data[3]);
> if (!tempMap.containsKey(aggregateData.getUuid())) {
> tempMap.put(aggregateData.getUuid(), new ArrayList());
> }
> tempMap.get(aggregateData.getUuid()).add(aggregateData);
> }
>
> Thanks
> /Tishan
>
> On Fri, Jun 3, 2016 at 11:47 AM, Liangfei.Su  wrote:
>
>> +Garrett
>>
>> Understand the output based on each input data. The question here is, the
>> count is always 1, i'm expecting count=1/2/3. e.g. when second input
>> message send in, the first input message should still kept in the windows,
>> so expect there should be two groups...
>>
>>
>>
>>
>>
>> On Fri, Jun 3, 2016 at 11:14 AM, Charini Nanayakkara 
>> wrote:
>>
>>> Hi Liangfei.Su,
>>>
>>> This is the expected behavior of external time window. Since it's a
>>> moving time window, you get an output for each incoming event. Due to the
>>> presence of the group by keyword, it would give an aggregate output by
>>> considering the events with the same uuid and similarityId, which arrived
>>> within last two minutes.
>>>
>>> If you need only one output per group use the external time batch window
>>> instead. Ensure that all the events come within the time duration which you
>>> specify here.
>>>
>>> Regards,
>>> Charini
>>>
>>> On Fri, Jun 3, 2016 at 6:16 AM, Liangfei.Su 
>>> wrote:
>>>
 +WSO2 @DL

 Could someone eligible to explain?

 https://github.com/wso2/siddhi/issues/154


 Thanks,
 Ralph


 On Fri, Jun 3, 2016 at 8:21 AM, Garrett 
 wrote:

> Has problems with Siddhi group by with a time window, I am able to get
> the correct result aggregations for the group, but I receive one 
> aggregated
> result per event, not one per group.
>
> Here is the query:
> define stream bootCorrelationStream (logLevel string, message string,
> similarityId string, timestamp long, uuid string); @info(name =
> 'bootCorrelation') from
> bootCorrelationStream[logLevel=='ERROR']#window.externalTime(timestamp, 2
> min) select similarityId, adanos:first(message) as message, min(timestamp)
> as startTime, max(timestamp) as endTime group by uuid, similarityId insert
> into tempStream;
>
> Here is the output:
> Count: 1; message=ERROR first message, timestamp=2016-05-21
> 01:22:07.579
> Count: 1; message=ERROR second message, timestamp=2016-05-21
> 01:22:08.314
> Count: 1; message=ERROR third message, timestamp=2016-05-21
> 01:22:15.017
> Count: 1; message=ERROR fourth message, timestamp=2016-05-21
> 01:25:07.017
>
> Here is the major code:
> register callback
> `
> this.siddhiRuntime = new SiddhiRuntimeHolder();
> this.siddhiRuntime.siddhiManager = new SiddhiManager();
> ExecutionPlanRuntime executionPlanRuntime =
> this.siddhiRuntime.siddhiManager.createExecutionPlanRuntime(this.getExecutionPlan());
> this.siddhiRuntime.inputHandler =
> executionPlanRuntime.getInputHandler(this.getStreamName());
>
> final SiddhiBolt siddhiBolt = this;
> this.siddhiRuntime.queryCallback = new QueryCallback() {
> @Override
> public void receive(long timeStamp, 
> org.wso2.siddhi.core.event.Event[] inEvents,
> org.wso2.siddhi.core.event.Event[] removeEvents) {
> siddhiBolt.queryCallback(timeStamp, inEvents, removeEvents);
> }
> };
> executionPlanRuntime.addCallback("query", 
> this.siddhiRuntime.queryCallback);
> executionPlanRuntime.start();
>
>
> query details
>
> public static String generateExecutionPlan() {
> // make sure the fields' name sorted
> StringBuilder executionPlane = new StringBuilder(" define stream
> bootCorrelationStream ");
> executionPlane.append("(logLevel string, message string, similarityId
> string, timestamp long, uuid string); ");
> executionPlane.append(" @info(name = 'bootCorrelation') ");
> // externalTimeBatch(timestamp, 5 min), batch time window for
> specified timestamp
> executionPlane.append("from
> bootCorrelationStream[logLevel=='ERROR']#window.externalTime(timestamp, 2
> min

Re: [Dev] Why YAML configuration files in C5 has extension .yml instead of .yaml?

2016-06-03 Thread Afkham Azeez
Let's use yaml as the extension.

On Fri, Jun 3, 2016 at 2:37 PM, SajithAR Ariyarathna 
wrote:

> Hi All,
>
> Is there any reason behind $subject. As per YAML.org FAQ '.yaml' is the
> recommended extension for YAML files [1].
>
> [1] http://www.yaml.org/faq.html
>
> Thanks.
> --
> Sajith Janaprasad Ariyarathna
> Software Engineer; WSO2, Inc.;  http://wso2.com/
>



-- 
*Afkham Azeez*
Director of Architecture; WSO2, Inc.; http://wso2.com
Member; Apache Software Foundation; http://www.apache.org/
* *
*email: **az...@wso2.com* 
* cell: +94 77 3320919blog: **http://blog.afkham.org*

*twitter: **http://twitter.com/afkham_azeez*

*linked-in: **http://lk.linkedin.com/in/afkhamazeez
*

*Lean . Enterprise . Middleware*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Why YAML configuration files in C5 has extension .yml instead of .yaml?

2016-06-03 Thread SajithAR Ariyarathna
Hi All,

Is there any reason behind $subject. As per YAML.org FAQ '.yaml' is the
recommended extension for YAML files [1].

[1] http://www.yaml.org/faq.html

Thanks.
-- 
Sajith Janaprasad Ariyarathna
Software Engineer; WSO2, Inc.;  http://wso2.com/
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [Test Automation] How can we attach a file with post request in a test case

2016-06-03 Thread Irham Iqbal
Adding

On Thu, Jun 2, 2016 at 4:51 PM, Mahesh Chinthaka  wrote:

> Hi,
>
> I want to attach a file for a post request along with some other
> parameters and values.
> What is the usual practice we follow in wso2 test automation framework ?
>
> --
> *Mahesh Chinthaka Vidanagama* | Software Engineer
> WSO2, Inc | lean. enterprise. middleware.
> #20, Palm Grove, Colombo 03, Sri Lanka
> Mobile: +94 71 63 63 083 | Work: +94 112 145 345
> Email: mahe...@wso2.com | Web: www.wso2.com
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Irham Iqbal
Software Engineer - Test Automation
WSO2, Inc.: http://wso2.com
lean. enterprise. middleware
phone: +94 777888452
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Predictive analytic with streaming data for WSO2 Machine Learner

2016-06-03 Thread Ishani Pathinayake
Hi all,

I'm Ishani from SLIIT an undergraduate of Software Engineering. I am trying
to do the "Predictive analytic with streaming data for WSO2 Machine
Learner" for an academic purpose.

I would like to know what is the structure of streaming data or what type
of streaming data you except to handle here?

Thank you.

-- 
*Cheers !*
Ishani Pathinayake.
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Need AS 6.0.0 Pack

2016-06-03 Thread Nisala Nanayakkara
Hi all,

I have managed to build the product-as. I was using java7 before building
the product-as.So I moved to java8 using the command 'sudo
update-alternatives --config java'. But it doesn't update the JAVA_HOME
into java8.So I had to manually configure it.Thanks all for the quick
responses.

Thanks,
Nisala

On Thu, Jun 2, 2016 at 9:05 PM, Nisala Nanayakkara  wrote:

> Hi all,
>
> I am trying to build the product-as in order to get the AS-6.0.0 pack. But
> it gives the following error.
>
> *[ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-compiler-plugin:3.5.1:compile
> (default-compile) on project appserver-utils: Fatal error compiling:
> invalid target release: 1.8 -> [Help 1]*
>
> *org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute
> goal org.apache.maven.plugins:maven-compiler-plugin:3.5.1:compile
> (default-compile) on project appserver-utils: Fatal error compiling*
>
> *at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)*
>
> *at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)*
>
> *at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)*
>
> *at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)*
>
> *at
> org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)*
>
> *at
> org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)*
>
> *at
> org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)*
>
> *at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)*
>
> *at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)*
>
> *at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)*
>
> *at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)*
>
> *at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)*
>
> *at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)*
>
> *at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)*
>
> *at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)*
>
> *at java.lang.reflect.Method.invoke(Method.java:606)*
>
> *at
> org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)*
>
> *at
> org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)*
>
> *at
> org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)*
>
> *at
> org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)*
>
> *Caused by: org.apache.maven.plugin.MojoExecutionException: Fatal error
> compiling*
>
> *at
> org.apache.maven.plugin.compiler.AbstractCompilerMojo.execute(AbstractCompilerMojo.java:897)*
>
> *at
> org.apache.maven.plugin.compiler.CompilerMojo.execute(CompilerMojo.java:129)*
>
> *at
> org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)*
>
> *at
> org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)*
>
> *... 19 more*
>
> *Caused by: org.codehaus.plexus.compiler.CompilerException: invalid target
> release: 1.8*
>
> *at
> org.codehaus.plexus.compiler.javac.JavaxToolsCompiler.compileInProcess(JavaxToolsCompiler.java:172)*
>
> *at
> org.codehaus.plexus.compiler.javac.JavacCompiler.performCompile(JavacCompiler.java:171)*
>
> *at
> org.apache.maven.plugin.compiler.AbstractCompilerMojo.execute(AbstractCompilerMojo.java:886)*
>
> *... 22 more*
>
> *Caused by: java.lang.IllegalArgumentException: invalid target release:
> 1.8*
>
> *at
> com.sun.tools.javac.main.RecognizedOptions$GrumpyHelper.error(RecognizedOptions.java:88)*
>
> *at
> com.sun.tools.javac.main.RecognizedOptions$10.process(RecognizedOptions.java:359)*
>
> *at
> com.sun.tools.javac.api.JavacTool.processOptions(JavacTool.java:242)*
>
> *at com.sun.tools.javac.api.JavacTool.getTask(JavacTool.java:199)*
>
> *at com.sun.tools.javac.api.JavacTool.getTask(JavacTool.java:68)*
>
> *at
> org.codehaus.plexus.compiler.javac.JavaxToolsCompiler.compileInProcess(JavaxToolsCompiler.java:124)*
>
> *... 24 more*
>
>
> Then I download the built pack of AS 6.0.0 from jenkins. When I run it, it
> gives the following error.
>
> *02-Jun-2016 20:32:01.358 SEVERE [main]
> org.apache.tomcat.util.digester.Digester.startElement Begin event threw
> error*
>
> *java.lang.UnsupportedClassVersionError:
> org/wso2/appserver/configuration/listeners/ServerConfigurationLoader :
> Unsupported major.minor version 52.0*
>
> *at java.lang.ClassLoader.defineClass1(Native Method)*
>
> *at java.lang.ClassLoader.defineClass(ClassLoader.java:800)*
>
> *at
> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)*
>
> *at java.net.URLClassLoader.def

Re: [Dev] Unexpected error occured when generating SAML2 bearer token using API manager- IS integrated setup.

2016-06-03 Thread Sewmini Jayaweera
Hi Bhathiya,

SAML2 bearer token generation for tenant user was successful when sending
domain query parameter in token endpoint. Furthermore It fixed issue [1]
occurred when invoking an API using the generated access token.

Furthermore I could overcome getting an 'access forbidden' when invoking an
api using a token generated using OAuth2 custom grant type by adding the
scope in the curl command. Below I have shared steps how I tested OAuth2
custom grant type in API manager - IS as key manager  setup.

*Test Steps*

1. Configure IS by following documentation [2].
2. Create an application in API store and generate production keys. (SP
relevant to the application will get created in IS)
3. Use below curl command and generate an access token. (Make sure that we
specify the scope accurately)

*Curl command*

curl --user 97XddkX6TBOtSRUoaMB0MStxo8oa:jVYekhO2oEbRUjxYfuHA4_rIfpka -k -d
"grant_type=mobile&mobileNumber=0333444&scope=PRODUCTION" -H "Content-Type:
application/x-www-form-urlencoded" https://localhost:9443/oauth2/token
[1]. https://wso2.org/jira/browse/APIMANAGER-4930
[2].
https://docs.wso2.com/display/IS510/Writing+a+Custom+OAuth+2.0+Grant+Type


Sewmini Jayaweera
*Software Engineer - QA Team*
Mobile: +94 (0) 773 381 250
sewm...@wso2.com

On Thu, Jun 2, 2016 at 7:29 PM, Bhathiya Jayasekara 
wrote:

> Hi Sewmini,
>
> Could you please confirm your observations after using tenantDomain only
> with samlsso URL (for tenants)?
>
> Thanks,
> Bhathiya
>
> On Thu, Jun 2, 2016 at 10:16 AM, Nuwan Dias  wrote:
>
>> Ok thanks, if there is no API change we don't have to worry.
>>
>> Thanks,
>> NuwanD.
>>
>> On Thu, Jun 2, 2016 at 10:10 AM, Johann Nallathamby 
>> wrote:
>>
>>> Hi Nuwan,
>>>
>>> For SAML2 SSO this is how it has been all this time. Because we can't
>>> guarantee the issuer will be unique across tenants unlike the client id in
>>> oauth2, which is a UUID.
>>>
>>> In IS even for OAuth2 we were sending the tenantDomain to token endpoint
>>> for all the grant types. However later found that in APIM it has been
>>> working without sending it due to a different reason, and that is why we
>>> did a fix to make tenant domain optional to token endpoint.
>>>
>>> I don't think in SAML2 SSO we can change it that way.
>>>
>>> Johann.
>>>
>>> On Thu, Jun 2, 2016 at 9:40 AM, Nuwan Dias  wrote:
>>>
 So for tenant users, the samlsso url has changed (requires tenantDomain
 query param)? Does this mean that for tenant users who are migrating to the
 new version, they have to change their Application's SSO handling code?

 Thanks,
 NuwanD.

 On Thu, Jun 2, 2016 at 8:48 AM, Farasath Ahamed 
 wrote:

> Hi Chamara,
>
> Sorry, I missed out some details. I tested the SAML Bearer Grant with
> an Identity Server 5.3.0 M1 pack.  I had to change the samlsso URL to 
> *https://localhost:9443/samlsso?tenantDomain=wso2.com
>  *to log in as
> a user in the tenant domain in the travelocity App. Thereafter the SAML2
> Bearer grant was sent to https://localhost:9443/oauth2/token
>  endpoint without
> passing the tenantDomain as a query param in the URL.
>
> The fix [1] was done after Identity Server 5.2.0-beta so if we are
> testing with a 5.2.0-beta or earlier IS pack we would have to send in the
> tenantDomain as a query param (ie.
> https://localhost:9443/oauth2/token?tenantDomain=) to
> the token endpoint for SPs in a tenantDomain  as Pushpalanka has pointed
> out earlier .Otherwise, it will be taken as cabon.super.
>
>
> [1] https://wso2.org/jira/browse/IDENTITY-4531
>
>
> Thanks,
>
> Farasath Ahamed
> Software Engineer,
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
>
> Email: farasa...@wso2.com
> Mobile: +94777603866
> Blog: blog.farazath.com
> Twitter: @farazath619 
>
> On Thu, Jun 2, 2016 at 7:43 AM, Chamara Ariyarathne  > wrote:
>
>> Hi Farsath, Some unclear points.
>>
>> On Thu, Jun 2, 2016 at 2:47 AM, Farasath Ahamed 
>> wrote:
>>
>>> Hi,
>>>
>>> I tested the SAML2 bearer grant with travelocity app for a tenant
>>> user and I was able to get an access token with any issue.
>>>
>> "with" or "without"?
>>
>>
>>> I had to change the samlsso URL to 
>>> *https://localhost:9443/samlsso?tenantDomain=wso2.com
>>>  *to get the
>>> sample working for a tenant user.
>>>
>> So, is it still needed?
>>
>>
>>> However, I was able to generate the token without sending the
>>> tenantDomain as a query param.
>>>
>> For which grant type? Are you still talking about the saml2-bearer
>> grant type?
>>
>>>
>>>
>>> Thanks,
>>> Farasa

[Dev] WSO2 IS Analytics v1.0.0-ALPHA Released

2016-06-03 Thread Damith Wickramasinghe
*WSO2 IS Analytics v1.0.0-ALPHA Released*

We are pleased to announce the alpha release of WSO2 IS Analytics v1.0.0 [1
]
which is powered by WSO2 Data Analytics Server. IS Analytics can be used to
monitor authentication related analytics for residence and federated
authentication scenarios.[2
] Please use the
nightly build IS pack [3
]
which includes necessary instruments to publish data to analytics IS.Your
feedback is highly appreciated, any bugs or issues can be reported here [4
].

This release contains the following capabilities:-

   1. View Authentication analytics for Federated Identity scenarios which
   includes viewing overall success and failure login attempts and
   authentication attempts views for multiple dimensions of Service Provider,
   Identity Providers,Users and also first time login of service Providers.
   2. View Authentication analytics for Federated scenarios which includes
   viewing
   overall success and failure login attempts and authentication attempts
   views for multiple dimensions of service provider, roles , user and
   user-stores

[1]
https://github.com/wso2/analytics-is/releases/download/v1.0.0-alpha/wso2analytics-is-1.0.0-alpha.zip
[2] https://docs.wso2.com/display/IS520/WSO2+IS+Analytics
[3] *https://svn.wso2.org/repos/wso2/people/mohan/is-5.2.0-with-analytics
*
[4] *https://wso2.org/jira/browse/ANLYIS
*


Analytics IS Team


-- 
Software Engineer
WSO2 Inc.; http://wso2.com

lean.enterprise.middleware

mobile: *+94728671315*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Identity Server 5.0.0 as API-M Key Manager

2016-06-03 Thread rohit
Hi Farasath,

Thank you so much for your reply, and your solution did work but I had to
replace the/ hostname / as well as the /MgtHostName/ tags to actual ip for
the solution to work. Anyway thanks a ton!

Regards,
Rohit



--
View this message in context: 
http://wso2-oxygen-tank.10903.n7.nabble.com/Identity-Server-5-0-0-as-API-M-Key-Manager-tp136062p137629.html
Sent from the WSO2 Development mailing list archive at Nabble.com.
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [wso2/siddhi] Has problems with Siddhi group by with a time window (#154)

2016-06-03 Thread Tishan Dahanayakage
Ralph,

Does following code recide inside your siddhiBolt.queryCallback?

Map> tempMap = new HashMap>();
for (Event event : inEvents) {
Object[] data = event.getData();
BootCorrelationAggregationData aggregateData = new
BootCorrelationAggregationData();
aggregateData.setSimilarityId((String) data[0]);
aggregateData.setMessage((String) data[1]);
aggregateData.setUuid((String) data[2]);
aggregateData.setTimestamp((Long) data[3]);
if (!tempMap.containsKey(aggregateData.getUuid())) {
tempMap.put(aggregateData.getUuid(), new ArrayList());
}
tempMap.get(aggregateData.getUuid()).add(aggregateData);
}

Thanks
/Tishan

On Fri, Jun 3, 2016 at 11:47 AM, Liangfei.Su  wrote:

> +Garrett
>
> Understand the output based on each input data. The question here is, the
> count is always 1, i'm expecting count=1/2/3. e.g. when second input
> message send in, the first input message should still kept in the windows,
> so expect there should be two groups...
>
>
>
>
>
> On Fri, Jun 3, 2016 at 11:14 AM, Charini Nanayakkara 
> wrote:
>
>> Hi Liangfei.Su,
>>
>> This is the expected behavior of external time window. Since it's a
>> moving time window, you get an output for each incoming event. Due to the
>> presence of the group by keyword, it would give an aggregate output by
>> considering the events with the same uuid and similarityId, which arrived
>> within last two minutes.
>>
>> If you need only one output per group use the external time batch window
>> instead. Ensure that all the events come within the time duration which you
>> specify here.
>>
>> Regards,
>> Charini
>>
>> On Fri, Jun 3, 2016 at 6:16 AM, Liangfei.Su  wrote:
>>
>>> +WSO2 @DL
>>>
>>> Could someone eligible to explain?
>>>
>>> https://github.com/wso2/siddhi/issues/154
>>>
>>>
>>> Thanks,
>>> Ralph
>>>
>>>
>>> On Fri, Jun 3, 2016 at 8:21 AM, Garrett 
>>> wrote:
>>>
 Has problems with Siddhi group by with a time window, I am able to get
 the correct result aggregations for the group, but I receive one aggregated
 result per event, not one per group.

 Here is the query:
 define stream bootCorrelationStream (logLevel string, message string,
 similarityId string, timestamp long, uuid string); @info(name =
 'bootCorrelation') from
 bootCorrelationStream[logLevel=='ERROR']#window.externalTime(timestamp, 2
 min) select similarityId, adanos:first(message) as message, min(timestamp)
 as startTime, max(timestamp) as endTime group by uuid, similarityId insert
 into tempStream;

 Here is the output:
 Count: 1; message=ERROR first message, timestamp=2016-05-21 01:22:07.579
 Count: 1; message=ERROR second message, timestamp=2016-05-21
 01:22:08.314
 Count: 1; message=ERROR third message, timestamp=2016-05-21 01:22:15.017
 Count: 1; message=ERROR fourth message, timestamp=2016-05-21
 01:25:07.017

 Here is the major code:
 register callback
 `
 this.siddhiRuntime = new SiddhiRuntimeHolder();
 this.siddhiRuntime.siddhiManager = new SiddhiManager();
 ExecutionPlanRuntime executionPlanRuntime =
 this.siddhiRuntime.siddhiManager.createExecutionPlanRuntime(this.getExecutionPlan());
 this.siddhiRuntime.inputHandler =
 executionPlanRuntime.getInputHandler(this.getStreamName());

 final SiddhiBolt siddhiBolt = this;
 this.siddhiRuntime.queryCallback = new QueryCallback() {
 @Override
 public void receive(long timeStamp, 
 org.wso2.siddhi.core.event.Event[] inEvents,
 org.wso2.siddhi.core.event.Event[] removeEvents) {
 siddhiBolt.queryCallback(timeStamp, inEvents, removeEvents);
 }
 };
 executionPlanRuntime.addCallback("query", 
 this.siddhiRuntime.queryCallback);
 executionPlanRuntime.start();


 query details

 public static String generateExecutionPlan() {
 // make sure the fields' name sorted
 StringBuilder executionPlane = new StringBuilder(" define stream
 bootCorrelationStream ");
 executionPlane.append("(logLevel string, message string, similarityId
 string, timestamp long, uuid string); ");
 executionPlane.append(" @info(name = 'bootCorrelation') ");
 // externalTimeBatch(timestamp, 5 min), batch time window for specified
 timestamp
 executionPlane.append("from
 bootCorrelationStream[logLevel=='ERROR']#window.externalTime(timestamp, 2
 min) ");
 executionPlane.append(" select similarityId, adanos:first(message) as
 message, uuid, ");
 executionPlane.append(" min(timestamp) as startTime, max(timestamp) as
 endTime ");
 executionPlane.append(" group by uuid, similarityId ");
 executionPlane.append(" insert into tempStream; ");
 appendLogs(executionPlane.toString());
 return executionPlane.toString();
 }

 callback details

 Map> tempMap = new HashMap>();
 for (Event event : inEvents) {
 Object[] data = event.getDa