Re: [Dev] [SP][UX]Dashboard widget drill down views

2018-07-23 Thread Udara Rathnayake
Thanks Eranga!

On Mon, Jul 23, 2018 at 11:52 AM, Eranga Liyanage  wrote:

> Hi Udara,
>
> Yes, it's the UX approach I was referring to, Had an offline chat with
> Janak as well.
>
> Yes, existing drill-down sample can be used as the baseline. But it needs
> an improvement as well. It does not support returning to the default state
> at the moment. A drill-down option should clearly provide a way to return
> to the default state.
>
> Best regards
> Eranga
>
> On Fri, Jul 20, 2018 at 3:24 PM Udara Rathnayake  wrote:
>
>> Hi Eranga,
>>
>> I hope what you have mentioned is the recommended UX approach.
>> If the above assumption is wrong, Can we come up with a set guideline for
>> this? Can we use the existing drill-down sample as the baseline for
>> developing the drill-down widgets?
>>
>> This will be useful for all other SP based dashboards in the future.
>>
>> Thanks!
>> -UdaraR
>>
>>
>> On Fri, Jul 20, 2018 at 10:30 AM, Eranga Liyanage 
>> wrote:
>>
>>> + Analytics
>>>
>>> Hi Janak,
>>>
>>> Providing a popup view is not a good practice. If you have consistent
>>> views its good to show on the same widget. If you have a totally different
>>> view or too much data to show, it's better to direct to a  different page.
>>>
>>> Best regards
>>> Eranga
>>>
>>> On Fri, Jul 20, 2018 at 10:18 AM Imesh Chandrasiri 
>>> wrote:
>>>
>>>> Hi Janak,
>>>>
>>>> When it comes to a drilled down chat, the user clearly should know that
>>>> the chart is showing more detailed data in it, while interacting with it.
>>>> Furthermore I found an article[1] which discuss how an intuitive drilled
>>>> down chart should be designed and the points we should consider when
>>>> designing one.
>>>>
>>>> [1] - https://www.fusioncharts.com/charting-best-practices/
>>>> drill-down-interface/
>>>>
>>>> *Thanks and Best Regards,*
>>>> Imesh Ashandimal Chandrasiri
>>>> *Software Engineer*
>>>> WSO2, Inc.
>>>> lean . enterprise . middleware
>>>> *E:* ime...@wso2.com | *P:* 0716519187
>>>>
>>>>
>>>> Disclaimer: This communication may contain privileged or other
>>>> confidential information and is intended exclusively for the addressee/s.
>>>> If you are not the intended recipient/s, or believe that you may have
>>>> received this communication in error, please reply to the sender indicating
>>>> that fact and delete the copy you received and in addition, you should not
>>>> print, copy, retransmit, disseminate, or otherwise use the information
>>>> contained in this communication. Internet communications cannot be
>>>> guaranteed to be timely, secure, error or virus-free. The sender does not
>>>> accept liability for any errors or omissions.
>>>>
>>>>
>>>> On Thu, Jul 19, 2018 at 8:27 PM Janak Amarasena  wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> What is the best practice when creating a drilled down view in a
>>>>> widget? Is it to completely replace the existing view with the new one or
>>>>> to give a popped up view of the details(which may be overlayed over other
>>>>> widgets). It is also required to move back and forth between the main view
>>>>> and the drilled down view.
>>>>>
>>>>> Thank you,
>>>>> Best Regards,
>>>>>
>>>>> --
>>>>> *Janak Amarasena*
>>>>>
>>>>> Software Engineer
>>>>>
>>>>> Email: ja...@wso2.com
>>>>>
>>>>> Mobile: +9464144
>>>>>
>>>>> Web: https://wso2.com
>>>>>
>>>>>
>>>>> <http://wso2.com/signature>
>>>>> ___
>>>>> Dev mailing list
>>>>> Dev@wso2.org
>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>>
>>>> ___
>>>> Dev mailing list
>>>> Dev@wso2.org
>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>
>>>
>>>
>>> --
>>> *Eranga Liyanage*
>>> Senior UX Engineer | WSO2
>>> Mob : +94 77 395 
>>> Blog : https://medium.com/@erangatl
>>> Linkedin : https://www.linkedin.com/in/erangaliyanage
>>>
>>>
>>
>>
>> --
>> Regards,
>> UdaraR <http://bit.ly/udarakr>
>>
>
>
> --
> *Eranga Liyanage*
> Senior UX Engineer | WSO2
> Mob : +94 77 395 
> Blog : https://medium.com/@erangatl
> Linkedin : https://www.linkedin.com/in/erangaliyanage
>
>


-- 
Regards,
UdaraR <http://bit.ly/udarakr>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [SP][UX]Dashboard widget drill down views

2018-07-20 Thread Udara Rathnayake
Hi Eranga,

I hope what you have mentioned is the recommended UX approach.
If the above assumption is wrong, Can we come up with a set guideline for
this? Can we use the existing drill-down sample as the baseline for
developing the drill-down widgets?

This will be useful for all other SP based dashboards in the future.

Thanks!
-UdaraR


On Fri, Jul 20, 2018 at 10:30 AM, Eranga Liyanage  wrote:

> + Analytics
>
> Hi Janak,
>
> Providing a popup view is not a good practice. If you have consistent
> views its good to show on the same widget. If you have a totally different
> view or too much data to show, it's better to direct to a  different page.
>
> Best regards
> Eranga
>
> On Fri, Jul 20, 2018 at 10:18 AM Imesh Chandrasiri 
> wrote:
>
>> Hi Janak,
>>
>> When it comes to a drilled down chat, the user clearly should know that
>> the chart is showing more detailed data in it, while interacting with it.
>> Furthermore I found an article[1] which discuss how an intuitive drilled
>> down chart should be designed and the points we should consider when
>> designing one.
>>
>> [1] - https://www.fusioncharts.com/charting-best-practices/
>> drill-down-interface/
>>
>> *Thanks and Best Regards,*
>> Imesh Ashandimal Chandrasiri
>> *Software Engineer*
>> WSO2, Inc.
>> lean . enterprise . middleware
>> *E:* ime...@wso2.com | *P:* 0716519187
>>
>>
>> Disclaimer: This communication may contain privileged or other
>> confidential information and is intended exclusively for the addressee/s.
>> If you are not the intended recipient/s, or believe that you may have
>> received this communication in error, please reply to the sender indicating
>> that fact and delete the copy you received and in addition, you should not
>> print, copy, retransmit, disseminate, or otherwise use the information
>> contained in this communication. Internet communications cannot be
>> guaranteed to be timely, secure, error or virus-free. The sender does not
>> accept liability for any errors or omissions.
>>
>>
>> On Thu, Jul 19, 2018 at 8:27 PM Janak Amarasena  wrote:
>>
>>> Hi,
>>>
>>> What is the best practice when creating a drilled down view in a widget?
>>> Is it to completely replace the existing view with the new one or to give a
>>> popped up view of the details(which may be overlayed over other widgets).
>>> It is also required to move back and forth between the main view and the
>>> drilled down view.
>>>
>>> Thank you,
>>> Best Regards,
>>>
>>> --
>>> *Janak Amarasena*
>>>
>>> Software Engineer
>>>
>>> Email: ja...@wso2.com
>>>
>>> Mobile: +9464144
>>>
>>> Web: https://wso2.com
>>>
>>>
>>> 
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>
>
> --
> *Eranga Liyanage*
> Senior UX Engineer | WSO2
> Mob : +94 77 395 
> Blog : https://medium.com/@erangatl
> Linkedin : https://www.linkedin.com/in/erangaliyanage
>
>


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


Re: [Dev] [SP] What is our dashboard packaging modal

2018-07-10 Thread Udara Rathnayake
Also if we are to move EI/API Analytics to the SP, to ship the default
dashboard we will need this.

On Tue, Jul 10, 2018 at 3:15 PM, Lasantha Samarakoon 
wrote:

> +1 on that. This will be a must-have feature when it comes to solutions.
>
> Instead of aggregating FS stored dashboards with the DB stored dashboards,
> we can simply copy the predefined dashboards from the FS to DB on server
> startup.
>
> On Tue, Jul 10, 2018 at 3:01 PM Nisala Nanayakkara 
> wrote:
>
>> Hi Udara,
>>
>> Currently, we keep the widgets in the file system and the dashboard JSONs
>> in the database. So we have to copy/paste the widgets into the file system
>> and create a DB entry with the dashboard JSON using our REST API.
>>
>> But AFAIK your requirement is to support dashboard packaging in the build
>> time. Since we do not have the control over the DB at the build time. We
>> need to think about an alternative way of achieving your requirement.
>>
>> @Lasantha Samarakoon  Shall we provide a file system
>> location to keep the predefined dashboard JSONs? So that we can get an
>> aggregated value of file system dashboard JSONs and DB dashboard JSONs to
>> show it in dashboard listing page. WDYT?
>>
>> Thanks,
>> Nisala
>>
>> On Mon, Jul 9, 2018 at 9:48 PM Udara Rathnayake  wrote:
>>
>>> Similar to what we had earlier in DS do we have an option to package a
>>> dashboard?
>>>
>>> My requirement is to design/develop a custom dashboard with all
>>> dependencies then deploy in SP programmatically along with a streaming app.
>>> ​
>>>
>>> --
>>> Regards,
>>> UdaraR <http://bit.ly/udarakr>
>>>
>>
>>
>> --
>> *Nisala Niroshana Nanayakkara,*
>> Senior Software Engineer
>> Mobile | +94 717600022
>> WSO2 Inc | http://wso2.com/
>>
>
>
> --
> *Lasantha Samarakoon* | Senior Software Engineer
> WSO2, Inc.
> #20, Palm Grove, Colombo 03, Sri Lanka
> <https://maps.google.com/?q=20,+Palm+Grove,+Colombo+03,+Sri+Lanka=gmail=g>
> Mobile: +94 (71) 214 1576
> Email:  lasant...@wso2.com
> Web:www.wso2.com
>
> lean . enterprise . middleware
>



-- 
Regards,
UdaraR <http://bit.ly/udarakr>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [SP] What is our dashboard packaging modal

2018-07-09 Thread Udara Rathnayake
Similar to what we had earlier in DS do we have an option to package a
dashboard?

My requirement is to design/develop a custom dashboard with all
dependencies then deploy in SP programmatically along with a streaming app.
​

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


Re: [Dev] [IS] Adding conditional authentication script programatically

2018-05-20 Thread Udara Rathnayake
Hi Ruwan,

Thank you for the input.

On Sun, May 20, 2018 at 1:43 PM, Ruwan Abeykoon <ruw...@wso2.com> wrote:

> Hi Udara,
> Adding script programmatically negates the very reason we introduce
> scripts. Script has to be external to the code inside DB or file.
>
+1

>
> What is the testing you are trying to achieve here ? If you looking at
> Integration tests, please refer [1]
>
​Our script is not yet finalized, so we need to modify this going forward.
(word testing is a bit misleading sorry about that :) )


> [1] https://github.com/wso2/product-is/blob/b210a95ba9c289b98c812d9ad493a4
> d5f279e594/modules/integration/tests-integration/
> tests-backend/src/test/java/org/wso2/identity/integration/test/auth/
> ConditionalAuthenticationTestCase.java
>
> Cheers,
> Ruwan
>
>
>
> On Sun, May 20, 2018 at 10:03 AM, Udara Rathnayake <uda...@wso2.com>
> wrote:
>
>> Hi,
>>
>> In a typical IS as a KM setup, We have a KM extension written to attach
>> 2steps(1st- basic, 2nd- smsotp) authentication during application creation
>> time. With IS 5.6.0-M6 we need to add a conditional authentication script
>> to the same KM extension.
>>
>> I was able to do this with the following,
>>
>> LocalAndOutboundAuthenticationConfig localAndOutboundAuthenticationConfig
>>> = new LocalAndOutboundAuthenticationConfig();
>>> AuthenticationScriptConfig scriptConfig = new
>>> AuthenticationScriptConfig();
>>> scriptConfig.setContent();
>>> scriptConfig.setEnabled(true);
>>> localAndOutboundAuthenticationConfig.setAuthenticationScript
>>> Config(scriptConfig);
>>>
>>
>> ​For the testing purpose I have added the JavaScript code within the
>> ​same. What is the recommended approach to keep the conditional
>> authentication script in a similar situation?
>>
>> Reading from a config file outside km extension or keeping inside the
>> same Java code?
>>
>> Until we finalize the conditional authentication script there is an
>> advantage in the following approach as we don't need to build the source
>> again and again for testing.
>>
>> Thanks!
>>
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
>
> *Ruwan Abeykoon*
> *Associate Director/Architect**,*
> *WSO2, Inc. http://wso2.com <https://wso2.com/signature> *
> *lean.enterprise.middleware.*
>
>


-- 
Regards,
UdaraR <http://bit.ly/udarakr>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [IS] Adding conditional authentication script programatically

2018-05-19 Thread Udara Rathnayake
Hi,

In a typical IS as a KM setup, We have a KM extension written to attach
2steps(1st- basic, 2nd- smsotp) authentication during application creation
time. With IS 5.6.0-M6 we need to add a conditional authentication script
to the same KM extension.

I was able to do this with the following,

LocalAndOutboundAuthenticationConfig localAndOutboundAuthenticationConfig =
> new LocalAndOutboundAuthenticationConfig();
> AuthenticationScriptConfig scriptConfig = new AuthenticationScriptConfig();
> scriptConfig.setContent();
> scriptConfig.setEnabled(true);
>
> localAndOutboundAuthenticationConfig.setAuthenticationScriptConfig(scriptConfig);
>

​For the testing purpose I have added the JavaScript code within the ​same.
What is the recommended approach to keep the conditional authentication
script in a similar situation?

Reading from a config file outside km extension or keeping inside the same
Java code?

Until we finalize the conditional authentication script there is an
advantage in the following approach as we don't need to build the source
again and again for testing.

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


Re: [Dev] Dashboard Component - Hierarchical Page Support

2017-08-29 Thread Udara Rathnayake
On Tue, Aug 29, 2017 at 9:44 AM, Nisala Nanayakkara <nis...@wso2.com> wrote:

> Hi Udara,
>
> Please find my comments inline.
>
> Assume we have a page2, which is going to be listed under page0>page1. So
> are we going to have a object like "page0/page1/page2" : {}
>  ? This bit is not clear in the above.
>
> Yes. we are going to keep an object as mentioned above.
>
> Also better if you can explain what is a *page resource URL* so others
> can understand.
>
> It simply means the resource path of the page URL.  Ex:-
> "page0/page1/page2"
>
> {
> "id": "1",
> "url": "sampledashboard",
> "name": "Sample Dashboard",
> "version": "2.0.0",
> "description": "Lorem ipsum dolor sit amet DAS",
> "owner": "admin",
> "lastUpdatedBy": "admin",
> "createdTime": 150282009,
> "lastUpdatedTime": 1502820091112,
> "isShared": false,
> "parentId": "1",
>
> Yes. We are going to have a dashboard to dashboard relationship. As an
> example, if someone personalizes a dashboard and save it, we are going
> maintain its original dashboard id as the parentId.
>
​Ok. above sample doesn't explain this :) both id and parentId are same​


>
> Thanks,
> Nisala
>
>
> On Tue, Aug 29, 2017 at 8:37 AM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi Nisala,
>>
>> Assume we have a page2, which is going to be listed under page0>page1. So
>> are we going to have a object like "page0/page1/page2" : {}
>>  ? This bit is not clear in the above.
>>
>> ​Also better if you can explain what is a *page resource URL* so others
>> can understand.
>>
>>
>> On Mon, Aug 28, 2017 at 11:26 PM, Nisala Nanayakkara <nis...@wso2.com>
>> wrote:
>>
>>> Hi all,
>>>
>>> We are in the process of re-writing dashboard component using React.
>>> Currently we have dashboard view component with following features,
>>>
>>>- Dashboard listing (will retrieve the dashboard from the DB and
>>>list down)
>>>- Backend API support for dashboard CRUD activities.
>>>- Dashboard view support (This will retrieve the selected dashboard
>>>from DB and render using Golden Layout)
>>>- Multiple pages support for dashboards (This will introduce
>>>multiple pages at the same level, We need to support hierarchical page
>>>support )
>>>- Internal routing between dashboard listing and dashboard view
>>>
>>> Since we are using the golden layout for layouting, we keep the content
>>> of the each page with respect to page resource url. When we are going to
>>> implement the hierarchical pages support, we are going to process these
>>> page urls and display the hierarchical menu according these page urls.
>>> Please find the sample dashboard json given below,
>>>
>>>> {
>>>> "id": "1",
>>>> "url": "sampledashboard",
>>>> "name": "Sample Dashboard",
>>>> "version": "2.0.0",
>>>> "description": "Lorem ipsum dolor sit amet DAS",
>>>> "owner": "admin",
>>>> "lastUpdatedBy": "admin",
>>>> "createdTime": 150282009,
>>>> "lastUpdatedTime": 1502820091112,
>>>> "isShared": false,
>>>> "parentId": "1",
>>>>
>>> ​Also what is the use of parentId here?​
>>
>> ​Are we going to have any dashboard to dashboard relationship? ​
>>
>>> "content": [
>>>> {
>>>> "page0": {
>>>> *content of page0*
>>>> },
>>>> "page1": {
>>>> *content of page1*
>>>> }
>>>> }
>>>> ]
>>>> }
>>>
>>>
>>>
>>> So we do not keep any mapping between pages and its hierarchy as in the
>>> previous versions of the dashboard component. But we may need to maintain
>>> some addit

Re: [Dev] Dashboard Component - Hierarchical Page Support

2017-08-28 Thread Udara Rathnayake
Hi Nisala,

Assume we have a page2, which is going to be listed under page0>page1. So
are we going to have a object like "page0/page1/page2" : {}
 ? This bit is not clear in the above.

​Also better if you can explain what is a *page resource URL* so others can
understand.


On Mon, Aug 28, 2017 at 11:26 PM, Nisala Nanayakkara 
wrote:

> Hi all,
>
> We are in the process of re-writing dashboard component using React.
> Currently we have dashboard view component with following features,
>
>- Dashboard listing (will retrieve the dashboard from the DB and list
>down)
>- Backend API support for dashboard CRUD activities.
>- Dashboard view support (This will retrieve the selected dashboard
>from DB and render using Golden Layout)
>- Multiple pages support for dashboards (This will introduce multiple
>pages at the same level, We need to support hierarchical page support )
>- Internal routing between dashboard listing and dashboard view
>
> Since we are using the golden layout for layouting, we keep the content of
> the each page with respect to page resource url. When we are going to
> implement the hierarchical pages support, we are going to process these
> page urls and display the hierarchical menu according these page urls.
> Please find the sample dashboard json given below,
>
>> {
>> "id": "1",
>> "url": "sampledashboard",
>> "name": "Sample Dashboard",
>> "version": "2.0.0",
>> "description": "Lorem ipsum dolor sit amet DAS",
>> "owner": "admin",
>> "lastUpdatedBy": "admin",
>> "createdTime": 150282009,
>> "lastUpdatedTime": 1502820091112,
>> "isShared": false,
>> "parentId": "1",
>>
> ​Also what is the use of parentId here?​

​Are we going to have any dashboard to dashboard relationship? ​

> "content": [
>> {
>> "page0": {
>> *content of page0*
>> },
>> "page1": {
>> *content of page1*
>> }
>> }
>> ]
>> }
>
>
>
> So we do not keep any mapping between pages and its hierarchy as in the
> previous versions of the dashboard component. But we may need to maintain
> some additional attributes such as Page title, isHidden and etc wrt page
> URL. In that case, I think it is better to maintain a separate mapping
> between these attributes and page URLs as in the previous dashboard
> component. Please find the sample dashboard json given below.
>
>> {
>> "id": "1",
>> "url": "sampledashboard",
>> "name": "Sample Dashboard",
>> "version": "2.0.0",
>> "description": "Lorem ipsum dolor sit amet DAS",
>> "owner": "admin",
>> "lastUpdatedBy": "admin",
>> "createdTime": 150282009,
>> "lastUpdatedTime": 1502820091112,
>> "isShared": false,
>> "parentId": "1",
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> *"menu": {"page0": {"ishidden": false,
>> "title": "Page 0"},"page1": {"ishidden":
>> false,"title": "Page 1"}}*,
>> "content": [
>> {
>> "page0": {},
>> "page1": {}
>> }
>> ]
>> }
>>
> Because It will give a clear separation between dashboard content and the
> pages’ menu attributes. WDYT?
>
> Thanks,
> Nisala
>
> --
> *Nisala Niroshana Nanayakkara,*
> Software Engineer
> Mobile | +94 717600022
> WSO2 Inc | http://wso2.com/
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


[Dev] User-pref implementation for the UUF based dashboard view component

2017-04-24 Thread Udara Rathnayake
*What is user-pref?*
This allows end-user configuration options within a widget.


*Implementation*
Widget author can enable user-prefs and provide necessary
implementation(HTML/JS) within the widget. End-user specific user-prefs
will be kept in the dashboard json and saved in the DB with a user
reference(Similar to the dashboard personalization). This dashboard config
will have high priority during dashboard rendering than the default
configuration for the logged-in user.


*​End-user experience*
Widget content may flip similar to the previous implementation and render
the configuration UI.
User can fill whatever required data and save the configuration. This
particular widget will be rendered with the new configuration.

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


Re: [Dev] Dynamically redraw grid-stack content through UUFClient

2017-04-24 Thread Udara Rathnayake
Solution is to get the response (HTML) within the callback and do append
part within our logic.
Following is my onSuccess function,

onSuccess: function (data) {
> $('.grid-stack').append(data);
> }
> }
>

On Mon, Apr 24, 2017 at 5:21 PM, Rajith Roshan <raji...@wso2.com> wrote:

> Hi,
>
> I once had a offline discussion with SajithAR regarding zoneMaps not
> initializing. He said zone maps are initialized once  because its a heavy
> operation. He asked me to use renderFragment method without passing the
> defzone attribute. I am not sure whether this will be a valid for your use
> case.
>
> Thanks !
> Rajith
>
> On Mon, Apr 24, 2017 at 11:45 AM, Udara Rathnayake <uda...@wso2.com>
> wrote:
>
>> I tried populateZonesMap(); before calling renderFragmentImpl() inside
>> UUFClient.renderFragment function. This works.
>>
>> Can we make this a configuration property if there is no other way?
>>
>>
>>
>>
>> On Mon, Apr 24, 2017 at 10:56 AM, Udara Rathnayake <uda...@wso2.com>
>> wrote:
>>
>>> ​Assume we have following grid-stack div rendered through the UUFClient.​
>>>
>>>
>>>
>>> ​
>>> ​Now I want to re-render the same with a different content (Eg:- Change
>>> the dashboard layout )
>>> There is a grid-stack function to destroy the existing content[1].
>>>
>>> $('.grid-stack').data('gridstack').destroy(true);
>>>>
>>>
>>> So this will basically remove following also, used by the UUF to append
>>> the content.
>>>
>>> 
>>>> 
>>>>
>>>
>>> Tried manually adding above before calling the
>>> UUFClient.renderFragment() but it seems not working. zonesMap which is
>>> there in the UUFClient still contains the gridContent zone.
>>>
>>> Any idea?
>>>
>>> [1] https://github.com/troolee/gridstack.js/tree/develop/doc#des
>>> troydetachgrid​
>>>
>>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Rajith Roshan
> Software Engineer, WSO2 Inc.
> Mobile: +94-72-642-8350 <%2B94-71-554-8430>
>



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


Re: [Dev] Dynamically redraw grid-stack content through UUFClient

2017-04-24 Thread Udara Rathnayake
I tried populateZonesMap(); before calling renderFragmentImpl() inside
UUFClient.renderFragment function. This works.

Can we make this a configuration property if there is no other way?




On Mon, Apr 24, 2017 at 10:56 AM, Udara Rathnayake <uda...@wso2.com> wrote:

> ​Assume we have following grid-stack div rendered through the UUFClient.​
>
>
>
> ​
> ​Now I want to re-render the same with a different content (Eg:- Change
> the dashboard layout )
> There is a grid-stack function to destroy the existing content[1].
>
> $('.grid-stack').data('gridstack').destroy(true);
>>
>
> So this will basically remove following also, used by the UUF to append
> the content.
>
> 
>> 
>>
>
> Tried manually adding above before calling the UUFClient.renderFragment()
> but it seems not working. zonesMap which is there in the UUFClient still
> contains the gridContent zone.
>
> Any idea?
>
> [1] https://github.com/troolee/gridstack.js/tree/develop/doc#
> destroydetachgrid​
>
>


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


[Dev] Dynamically redraw grid-stack content through UUFClient

2017-04-23 Thread Udara Rathnayake
​Assume we have following grid-stack div rendered through the UUFClient.​



​
​Now I want to re-render the same with a different content (Eg:- Change the
dashboard layout )
There is a grid-stack function to destroy the existing content[1].

$('.grid-stack').data('gridstack').destroy(true);
>

So this will basically remove following also, used by the UUF to append the
content.


> 
>

Tried manually adding above before calling the UUFClient.renderFragment()
but it seems not working. zonesMap which is there in the UUFClient still
contains the gridContent zone.

Any idea?

[1]
https://github.com/troolee/gridstack.js/tree/develop/doc#destroydetachgrid​
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] VizGrammar polluting the JS global scope

2017-04-22 Thread Udara Rathnayake
Looks like we are doing the $subject.

While looking at the window object, noticed we have following[1], Shall we
try to update the library by only adding vizg to the global scope?

[1]
"d3", "vg", "getPieMark", "getPieMidText", "getPieText", "getAreaMark",
"getBarMark", "getStackBarMark", "getGroupBarMark", "calculateBarGap",
"getLineMark", "getTopoJson", "getMapMark", "getMapSignals",
"getMapPredicates", "getMapLegends", "loadGeoMapCodes", "getMapCode",
"getScatterMark", "getScatterToolTipMark", "checkConfig", "buildTable",
"buildData", "getSymbolMark", "getSignals", "bindTooltip", "createTooltip",
"cumulativeOffset", "getXYAxes", "getXYScales", "getRangeSignals",
"getRangeMark", "getLegend", "drawChart", "arc", "area", "bar", "vizg",
"line", "map", "number", "scatter", "table", "extend", "stack"

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


[Dev] Widget generation for the UUF based dashboard component

2017-04-19 Thread Udara Rathnayake
While working on the new dashboard UUF component we noticed, there can be
ID conflicts due to the lack of widget isolation.

Eg:-
In a widget hbs we declare a simple div so later we can append/draw the
widget content(graph etc..)

> 


​Then we provide data and config to the VizGrammar library and then draw
the content inside above defined div.


> var lineChart = new vizg(data, config);
> lineChart.draw("#bar");​


*​Problem​*

​With this approach one can't have multiple instances(with different
data-source/configs) of the same bar-chart widget.

​We evaluated some technologies like web-components, shadow-dom in-order to
overcome this.
Shadow-dom is a viable solution but with the current implementation of
VizGrammar we can't directly go with that[1].



*Current solution*
As we identified, most of the time above problem can occur with the widgets
generated through the widget-gen tool where end-users use the same
templated widget to create multiple instances. Simplest way to solve this
is to have a placeholder when we define the div ID and within the script,
then dynamically replace this placeholders with the widget-id(or some other
unique value) during widget generation process.

[1] Creating a widget web-component using existing charting libraries

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


Re: [Dev] Creating a widget web-component using existing charting libraries

2017-03-24 Thread Udara Rathnayake
It was my mistake. We have used VizGrammer for DS2.X and continuing.

On Fri, Mar 24, 2017 at 2:22 PM, Pawan Gunaratne <pa...@wso2.com> wrote:

> Hi,
>
> I need to clarify that gadget creation in carbon-dashboard, are we still
> using that lgviz library or moved to VizGrammer ?
>
> Thanks.
>
> On Thu, Mar 23, 2017 at 12:37 PM, Udara Rathnayake <uda...@wso2.com>
> wrote:
>
>> Thanks Tharik!
>>
>> Updated my wso2-widget WC to use VizGrammer, but it seems we have a bunch
>> of document.getElementById()s which is not going to search inside shadow
>> roots. So this is not going to work :( . Let me look into other
>> alternatives.
>>
>> On Thu, Mar 23, 2017 at 12:11 PM, Tharik Kanaka <tha...@wso2.com> wrote:
>>
>>> Hi Udara,
>>>
>>> Igviz library is no longer used and we have replaced that with
>>> VizGrammar. In VizGrammar you can use draw() function to draw the chart in
>>> a div. If you want to insert records to update the chart you can use
>>> insert(). You can try samples [1] and all the library content along with
>>> samples are available in  github repository [2].
>>>
>>> *var data = {*
>>> *  "metadata" : {*
>>> *  "names" : ["rpm","torque","horsepower", "EngineType"],*
>>> *  "types" : ["linear","linear", "ordinal","ordinal"]*
>>> *  },*
>>> *  "data": [*
>>> *[1, 10, 1, "Piston"],  [2, 12, 5, "Piston"]]*
>>> *};*
>>>
>>> *var config = {*
>>> *charts : [{type: "area",  x : "rpm", y : "torque"}],*
>>> *maxLength: 10,*
>>> *width: 400,*
>>> *height: 200*
>>> *}*
>>>
>>> *var chart = new vizg(data, **config**);*
>>>
>>> *chart.draw("#chartDiv");*
>>>
>>> *chart.insert([[8000, 74, 120, "Rotary"]]);*
>>>
>>> [1] http://wso2.github.io/VizGrammar/samples/
>>>
>>> [2] https://github.com/wso2/VizGrammar/
>>>
>>> Thanks,
>>>
>>>
>>> On Thu, Mar 23, 2017 at 11:42 AM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Hi all,
>>>>
>>>> I'm trying to create a web component (wso2-widget) to try-out
>>>> capabilities which we can incorporate in to our widget rendering framework.
>>>>
>>>> ​Within my renderWidget function[1] I'm using the usual igviz.plot but
>>>> unable to draw the chart inside container element which exists inside a
>>>> shadow-root.​ Did some debugging but unable to find the place which
>>>> breaks(No errors too).
>>>>
>>>> ​Appreciate any feedback on this.​
>>>>
>>>> PS:- If you need to try out this, host the source within "wc" branch
>>>> inside apache2 and use Google chrome.
>>>>
>>>> ​[1] https://github.com/udarakr/uuf-sample-gadget/blob/wc/wso2-wi
>>>> dget/wso2-widget.comp.html#L121
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>>
>>>
>>>
>>>
>>> --
>>>
>>> *Tharik Kanaka*
>>>
>>> WSO2, Inc | lean . enterprise . middleware
>>>
>>> Email: tha...@wso2.com | Web: www.wso2.com
>>>
>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> *Pawan Gunaratne*
> Software Engineering Intern
> *WSO2*
> *Mob : 0770373556*
>



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


Re: [Dev] Creating a widget web-component using existing charting libraries

2017-03-24 Thread Udara Rathnayake
I think you need to re-render the widget periodically, probably with a
setInterval().

On Fri, Mar 24, 2017 at 2:46 PM, Pawan Gunaratne <pa...@wso2.com> wrote:

> Hi all,
>
> Thanks all for providing those information. So with the use of
> VizGrammer.js at the moment can we see the real time updates of widgets (eg
> : in a chart ) ?
>
> On Fri, Mar 24, 2017 at 2:36 PM, Dunith Dhanushka <dun...@wso2.com> wrote:
>
>> Hi Pawan,
>>
>> VizGrammer.js is a rewrite of igviz.js, which has been deprecated at the
>> moment. VizGrammar has lot of improvements over igviz.js on
>> - Drill down capabilities
>> - Interactiveness through event listeners
>> - Improved visualization components
>> - Wizard integration etc
>>
>> So we highly recommend you to go with VizGrammar for future visualization
>> purposes.
>>
>> Thanks,
>> Dunith
>>
>> On Fri, Mar 24, 2017 at 2:22 PM, Pawan Gunaratne <pa...@wso2.com> wrote:
>>
>>> Hi,
>>>
>>> I need to clarify that gadget creation in carbon-dashboard, are we still
>>> using that lgviz library or moved to VizGrammer ?
>>>
>>> Thanks.
>>>
>>> On Thu, Mar 23, 2017 at 12:37 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Thanks Tharik!
>>>>
>>>> Updated my wso2-widget WC to use VizGrammer, but it seems we have a
>>>> bunch of document.getElementById()s which is not going to search
>>>> inside shadow roots. So this is not going to work :( . Let me look into
>>>> other alternatives.
>>>>
>>>> On Thu, Mar 23, 2017 at 12:11 PM, Tharik Kanaka <tha...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi Udara,
>>>>>
>>>>> Igviz library is no longer used and we have replaced that with
>>>>> VizGrammar. In VizGrammar you can use draw() function to draw the chart in
>>>>> a div. If you want to insert records to update the chart you can use
>>>>> insert(). You can try samples [1] and all the library content along with
>>>>> samples are available in  github repository [2].
>>>>>
>>>>> *var data = {*
>>>>> *  "metadata" : {*
>>>>> *  "names" : ["rpm","torque","horsepower", "EngineType"],*
>>>>> *  "types" : ["linear","linear", "ordinal","ordinal"]*
>>>>> *  },*
>>>>> *  "data": [*
>>>>> *[1, 10, 1, "Piston"],  [2, 12, 5, "Piston"]]*
>>>>> *};*
>>>>>
>>>>> *var config = {*
>>>>> *charts : [{type: "area",  x : "rpm", y : "torque"}],*
>>>>> *maxLength: 10,*
>>>>> *width: 400,*
>>>>> *height: 200*
>>>>> *}*
>>>>>
>>>>> *var chart = new vizg(data, **config**);*
>>>>>
>>>>> *chart.draw("#chartDiv");*
>>>>>
>>>>> *chart.insert([[8000, 74, 120, "Rotary"]]);*
>>>>>
>>>>> [1] http://wso2.github.io/VizGrammar/samples/
>>>>>
>>>>> [2] https://github.com/wso2/VizGrammar/
>>>>>
>>>>> Thanks,
>>>>>
>>>>>
>>>>> On Thu, Mar 23, 2017 at 11:42 AM, Udara Rathnayake <uda...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> Hi all,
>>>>>>
>>>>>> I'm trying to create a web component (wso2-widget) to try-out
>>>>>> capabilities which we can incorporate in to our widget rendering 
>>>>>> framework.
>>>>>>
>>>>>> ​Within my renderWidget function[1] I'm using the usual igviz.plot
>>>>>> but unable to draw the chart inside container element which exists 
>>>>>> inside a
>>>>>> shadow-root.​ Did some debugging but unable to find the place which
>>>>>> breaks(No errors too).
>>>>>>
>>>>>> ​Appreciate any feedback on this.​
>>>>>>
>>>>>> PS:- If you need to try out this, host the source within "wc" branch
>>>>>> inside apache2 and use Google chrome.
>>>>>>
>>>>>> ​[1] https://github.com/udarakr/uuf-sample-gadget/blob/wc/wso2-wi
>>>>>> dget/wso2-widget.comp.html#L121
>>>>>>
>>>>>> --
>>>>>> Regards,
>>>>>> UdaraR
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>>
>>>>> *Tharik Kanaka*
>>>>>
>>>>> WSO2, Inc | lean . enterprise . middleware
>>>>>
>>>>> Email: tha...@wso2.com | Web: www.wso2.com
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>>
>>>> ___
>>>> Dev mailing list
>>>> Dev@wso2.org
>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>
>>>>
>>>
>>>
>>> --
>>> *Pawan Gunaratne*
>>> Software Engineering Intern
>>> *WSO2*
>>> *Mob : 0770373556*
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Regards,
>>
>> Dunith Dhanushka,
>> Associate Technical Lead
>> WSO2 Inc,
>>
>> Mobile - +94 71 8615744 <+94%2071%20861%205744>
>> Blog - *https://medium.com/@dunithd <https://medium.com/@dunithd>*
>> Twitter - @dunithd <http://twitter.com/dunithd>
>>
>
>
>
> --
> *Pawan Gunaratne*
> Software Engineering Intern
> *WSO2*
> *Mob : 0770373556*
>



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


Re: [Dev] Creating a widget web-component using existing charting libraries

2017-03-23 Thread Udara Rathnayake
Thanks Tharik!

Updated my wso2-widget WC to use VizGrammer, but it seems we have a bunch
of document.getElementById()s which is not going to search inside shadow
roots. So this is not going to work :( . Let me look into other
alternatives.

On Thu, Mar 23, 2017 at 12:11 PM, Tharik Kanaka <tha...@wso2.com> wrote:

> Hi Udara,
>
> Igviz library is no longer used and we have replaced that with VizGrammar.
> In VizGrammar you can use draw() function to draw the chart in a div. If
> you want to insert records to update the chart you can use insert(). You
> can try samples [1] and all the library content along with samples are
> available in  github repository [2].
>
> *var data = {*
> *  "metadata" : {*
> *  "names" : ["rpm","torque","horsepower", "EngineType"],*
> *  "types" : ["linear","linear", "ordinal","ordinal"]*
> *  },*
> *  "data": [*
> *[1, 10, 1, "Piston"],  [2, 12, 5, "Piston"]]*
> *};*
>
> *var config = {*
> *charts : [{type: "area",  x : "rpm", y : "torque"}],*
> *maxLength: 10,*
> *width: 400,*
> *height: 200*
> *}*
>
> *var chart = new vizg(data, **config**);*
>
> *chart.draw("#chartDiv");*
>
> *chart.insert([[8000, 74, 120, "Rotary"]]);*
>
> [1] http://wso2.github.io/VizGrammar/samples/
>
> [2] https://github.com/wso2/VizGrammar/
>
> Thanks,
>
>
> On Thu, Mar 23, 2017 at 11:42 AM, Udara Rathnayake <uda...@wso2.com>
> wrote:
>
>> Hi all,
>>
>> I'm trying to create a web component (wso2-widget) to try-out
>> capabilities which we can incorporate in to our widget rendering framework.
>>
>> ​Within my renderWidget function[1] I'm using the usual igviz.plot but
>> unable to draw the chart inside container element which exists inside a
>> shadow-root.​ Did some debugging but unable to find the place which
>> breaks(No errors too).
>>
>> ​Appreciate any feedback on this.​
>>
>> PS:- If you need to try out this, host the source within "wc" branch
>> inside apache2 and use Google chrome.
>>
>> ​[1] https://github.com/udarakr/uuf-sample-gadget/blob/wc/wso2-
>> widget/wso2-widget.comp.html#L121
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
>
> *Tharik Kanaka*
>
> WSO2, Inc | lean . enterprise . middleware
>
> Email: tha...@wso2.com | Web: www.wso2.com
>



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


[Dev] Creating a widget web-component using existing charting libraries

2017-03-23 Thread Udara Rathnayake
Hi all,

I'm trying to create a web component (wso2-widget) to try-out capabilities
which we can incorporate in to our widget rendering framework.

​Within my renderWidget function[1] I'm using the usual igviz.plot but
unable to draw the chart inside container element which exists inside a
shadow-root.​ Did some debugging but unable to find the place which
breaks(No errors too).

​Appreciate any feedback on this.​

PS:- If you need to try out this, host the source within "wc" branch inside
apache2 and use Google chrome.

​[1]
https://github.com/udarakr/uuf-sample-gadget/blob/wc/wso2-widget/wso2-widget.comp.html#L121

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


[Dev] Configuring WSO2_METRICS_DB with MSSQL

2017-01-15 Thread Udara Rathnayake
Hi,

Noticed we are using jtds driver as per the default configuration. I think
we used to have sqljdbc4 in other products. Are we recommending jtds driver
for metrics?

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


Re: [Dev] [Gadgets] [vizGrammar] Support for Pie-Charts and corresponding Documentation

2016-12-04 Thread Udara Rathnayake
Have a look at the source here[1]

@ Tharik, Dunith Can we include this into our sample site?

[1]
https://github.com/wso2/VizGrammar/blob/7b2d16e9385748a80c2fa6874be3275d98d37e82/samples/charts/arc/index.html#L233-L274

On Mon, Dec 5, 2016 at 11:46 AM, Dilan Udara Ariyaratne 
wrote:

> Hi Folks,
>
> I am currently in the process of developing some application gadgets using
> WSO2 Dashboard Server gadget capabilities and
> vizGrammar as the library for visualizing some pie-charts.
>
> I went through online documentation, but could not find any useful
> information on configuring a pie-chart. Do we already have support for
> pie-charts ?
> If so, where can I find corresponding documentation for configuring the
> same using Java-script ?
>
> Can someone help me on this ?
>
> Thanks,
> Dilan.
>
> *Dilan U. Ariyaratne*
> Senior Software Engineer
> WSO2 Inc. 
> Mobile: +94766405580 <%2B94766405580>
> lean . enterprise . middleware
>
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


[Dev] Dashboards (UUF component) 3.0.0-M1 Released

2016-11-23 Thread Udara Rathnayake
Hi All,

We are pleased to announce the 1st milestone release of Dashboard
components, which is based on the WSO2 Carbon Unified Framework(UUF).

Features:
- Dashboard view
- UUF based widget container
- Inter widget communication

You can use following maven dependency within a UUF based application.


> org.wso2.carbon.dashboards
> org.wso2.carbon.dashboards.view
> 3.0.0-m1
> zip
> uuf-component
> 
>

You can find the release tag here[1]. Help us to improve the component,
report issue here[2].

[1] https://github.com/wso2/carbon-dashboards/releases/tag/v3.0.0-m1
[2] https://github.com/wso2/carbon-dashboards/issues


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


Re: [Dev] [UUF] How to do i18n with UUF?

2016-11-03 Thread Udara Rathnayake
On Thu, Nov 3, 2016 at 7:14 PM, Thusitha Kalugamage 
wrote:

> Hi Ruwan,
>
> I think it is decided by the Browser locale,
> Not sure about it's implementation.
> @Udara?
>
​You are correct Thusitha. We are using the HTTP Accept-Language header​

​and the maximum quality value to determine the locale of the user.​

>
> Regards,
>
> On Thu, Nov 3, 2016 at 6:55 PM, Ruwan Abeykoon  wrote:
>
>> Hi Thusitha,
>> Thank you. It works!
>>
>> What triggers change of the language bundle? is it a system property or
>> the browser locale?
>>
>> Cheers,
>> Ruwan
>>
>>
>> On Thu, Nov 3, 2016 at 6:20 PM, Thusitha Kalugamage 
>> wrote:
>>
>>> Hi Ruwan,
>>>
>>> You can refer the sample that is with carbon-uuf [1]
>>> Inside [2] you'll find file called en_US.properties. This is the
>>> property file which you can use to store keys and values of keywords or
>>> messages which written in English.
>>> You can put key values pairs as below.
>>>
>>> :
>>> *Ex:- pets-store.all=See all our amazing pets*
>>>
>>> When you need to refer these values inside a .hbs you can use the
>>> following handlebar helper.
>>>
>>> *{{t ""}}*
>>> *Ex:-  {{t "pets-store.all”}}*
>>>
>>>
>>> [1] https://github.com/wso2/carbon-uuf/tree/master/samples
>>> 
>>> [2] https://github.com/wso2/carbon-uuf/blob/master/samples/a
>>> pps/org.wso2.carbon.uuf.sample.pets-store/src/main/lang/en_US.properties
>>> 
>>>
>>> Hope this helps.
>>> Regards,
>>>
>>> On Thu, Nov 3, 2016 at 5:47 PM, Ruwan Abeykoon  wrote:
>>>
 Hi Devs,
 What is the recommended way for $subject

 Cheers,
 Ruwan



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


>>>
>>>
>>> --
>>> Thusitha Kalugamage
>>> *Software Engineer*
>>> Mobile : +94 (0) 774 074370
>>> Tel   : +94 (0) 112 145 345
>>> thusi...@wso2.com
>>>
>>
>>
>>
>> --
>>
>> *Ruwan Abeykoon*
>> *Associate Director/Architect**,*
>> *WSO2, Inc. http://wso2.com  *
>> *lean.enterprise.middleware.*
>>
>>
>
>
> --
> Thusitha Kalugamage
> *Software Engineer*
> Mobile : +94 (0) 774 074370
> Tel   : +94 (0) 112 145 345
> thusi...@wso2.com
>



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


[Dev] UUF based Gadget hot deployment

2016-11-02 Thread Udara Rathnayake
Hi All,

We need to come up with the $subject for the new UUF based dashboard
feature.

All default gadgets will be packaged inside the portal component as
fragments. This is enough for the current ESB/API analytics dashboards.

Future we have to provision end-user's to upload their custom gadgets and
create gadgets through the gadget generation wizard. Ideally these custom
gadgets should not go inside the portal component, rather placed as
different UUF components.

We need to hot deploy these custom gadgets. Since we don't have similar
support shall we add this to UUF roadmap?

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


[Dev] Distinguish dashboard customize functionalities

2016-10-27 Thread Udara Rathnayake
In current dashboard server, we have two functionalities enabling end-users
to customize their dashboard view.

1. Within dashboard view resize gadgets(by dragging the edge), relocate
gadgets etc.. and persist.
2. Go to the dashboard designer and do extensive customization, by deleting
existing gadgets and add new ones which user do have access to.

​Nothing above affects on the original dashboard.​
​We need to come-up with better naming to distinguish these two
functions(in the menu etc..).

Thoughts?​

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


Re: [Dev] [VizGrammar] igviz.plot/chart.draw alternatives

2016-10-24 Thread Udara Rathnayake
Hi Dinesh,

On Tue, Oct 25, 2016 at 9:15 AM, Dinesh J Weerakkody <dine...@wso2.com>
wrote:

> Hi Udara,
>
> If you are considering to revamp the charting library, I strongly believe
> that we need to reconsider the VizGrammer due to the limitations in this
> library (No offense :) ). This is based on what I experienced when I'm
> using it. If you are going to allow users of the product to create gadgets,
> this will be really helpful for them.
>

​Not really trying to replace/revamp the library, but trying to look at
rendering options which we can implement. Ideally we should not limit
anyone to use igviz or vizgrammer, rather provide an extension point so
anyone can plug there own library and visualize.​

​Right now gagdet is that extension point.

Going forward we are planning to make an uuf component which represents a
gadget. So anyone can create there own component with any charting library.
BTW we might not have an extensive use case now, where users go and create
there own gadgets/components.

Further it's better if you can explain those limitations so Tharik can have
a look and may be we can improve in future.
​

>
> If we want to be with D3 based library I think we can use nvd3, which is
> also published under Apache 2.0. Otherwise there are many JS libraries
> available.
>
> [1] http://nvd3.org/
>
> Thanks
>
> *Dinesh J. Weerakkody*
> Senior Software Engineer
> WSO2 Inc.
> lean | enterprise | middleware
> M : +94 727 868676 | E : dine...@wso2.com | W : www.wso2.com
>
> On Mon, Oct 24, 2016 at 5:23 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Thanks Jerad and Tharik!
>>
>> Hi Tharik,
>>
>> So we do the configuration part in server-side and draw in client-side?
>> Please correct me if I'm wrong.
>>
>>
>>
>> On Mon, Oct 24, 2016 at 2:16 PM, Tharik Kanaka <tha...@wso2.com> wrote:
>>
>>> Hi Udara,
>>>
>>> Its not possible. Instead of generating HTML in server side,  can't you
>>> generate  a chart spec from the server side and use that spec to render in
>>> the browser?
>>>
>>> Regards,
>>>
>>> On Mon, Oct 24, 2016 at 2:04 PM, Jerad Rutnam <je...@wso2.com> wrote:
>>>
>>>> Hi Udara,
>>>>
>>>> AFAIK currently it's not possible.
>>>>
>>>> Cheers,
>>>> Jerad
>>>>
>>>> On Mon, Oct 24, 2016 at 1:14 PM, Udara Rathnayake <uda...@wso2.com>
>>>> wrote:
>>>>
>>>>> ​Hi All,
>>>>>
>>>>> $subject? ​
>>>>> Is there a way to directly get the html content itself rather pointing
>>>>> a div and draw?
>>>>>
>>>>> I'm trying to figure out possibilities of rendering a gadget in
>>>>> serverside.
>>>>>
>>>>> --
>>>>> Regards,
>>>>> UdaraR
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> *Jerad Rutnam*
>>>> *Software Engineer*
>>>>
>>>> WSO2 Inc.
>>>> lean | enterprise | middleware
>>>> M : +94 77 959 1609 | E : je...@wso2.com | W : www.wso2.com
>>>>
>>>> <https://wso2.com/signature>
>>>>
>>>
>>>
>>>
>>> --
>>>
>>> *Tharik Kanaka*
>>>
>>> WSO2, Inc | lean . enterprise . middleware
>>>
>>> Email: tha...@wso2.com | Web: www.wso2.com
>>>
>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>


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


Re: [Dev] [VizGrammar] igviz.plot/chart.draw alternatives

2016-10-24 Thread Udara Rathnayake
Thanks Jerad and Tharik!

Hi Tharik,

So we do the configuration part in server-side and draw in client-side?
Please correct me if I'm wrong.



On Mon, Oct 24, 2016 at 2:16 PM, Tharik Kanaka <tha...@wso2.com> wrote:

> Hi Udara,
>
> Its not possible. Instead of generating HTML in server side,  can't you
> generate  a chart spec from the server side and use that spec to render in
> the browser?
>
> Regards,
>
> On Mon, Oct 24, 2016 at 2:04 PM, Jerad Rutnam <je...@wso2.com> wrote:
>
>> Hi Udara,
>>
>> AFAIK currently it's not possible.
>>
>> Cheers,
>> Jerad
>>
>> On Mon, Oct 24, 2016 at 1:14 PM, Udara Rathnayake <uda...@wso2.com>
>> wrote:
>>
>>> ​Hi All,
>>>
>>> $subject? ​
>>> Is there a way to directly get the html content itself rather pointing a
>>> div and draw?
>>>
>>> I'm trying to figure out possibilities of rendering a gadget in
>>> serverside.
>>>
>>> --
>>> Regards,
>>> UdaraR
>>>
>>
>>
>>
>> --
>> *Jerad Rutnam*
>> *Software Engineer*
>>
>> WSO2 Inc.
>> lean | enterprise | middleware
>> M : +94 77 959 1609 | E : je...@wso2.com | W : www.wso2.com
>>
>> <https://wso2.com/signature>
>>
>
>
>
> --
>
> *Tharik Kanaka*
>
> WSO2, Inc | lean . enterprise . middleware
>
> Email: tha...@wso2.com | Web: www.wso2.com
>



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


[Dev] [VizGrammar] igviz.plot/chart.draw alternatives

2016-10-24 Thread Udara Rathnayake
​Hi All,

$subject? ​
Is there a way to directly get the html content itself rather pointing a
div and draw?

I'm trying to figure out possibilities of rendering a gadget in serverside.

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


Re: [Dev] Staging repository for UUF 1.0.0-m5

2016-10-23 Thread Udara Rathnayake
released the repo.

On Mon, Oct 24, 2016 at 10:20 AM, Udara Rathnayake <uda...@wso2.com> wrote:

> subject should be "Staging repository for UUF maven tools 1.0.0-m5"
>
> On Mon, Oct 24, 2016 at 10:18 AM, Udara Rathnayake <uda...@wso2.com>
> wrote:
>
>> Find the following $subject
>>
>> ​https://maven.wso2.org/nexus/content/repositories/orgwso2ca
>> rbonuufmaven-1001​
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
> Regards,
> UdaraR
>



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


Re: [Dev] Staging repository for UUF 1.0.0-m5

2016-10-23 Thread Udara Rathnayake
subject should be "Staging repository for UUF maven tools 1.0.0-m5"

On Mon, Oct 24, 2016 at 10:18 AM, Udara Rathnayake <uda...@wso2.com> wrote:

> Find the following $subject
>
> ​https://maven.wso2.org/nexus/content/repositories/
> orgwso2carbonuufmaven-1001​
>
> --
> Regards,
> UdaraR
>



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


[Dev] Staging repository for UUF 1.0.0-m5

2016-10-23 Thread Udara Rathnayake
Find the following $subject

​
https://maven.wso2.org/nexus/content/repositories/orgwso2carbonuufmaven-1001
​

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


Re: [Dev] Removing/Replacing shindig from wso2 dashboard framework

2016-09-30 Thread Udara Rathnayake
right now gadget is a combination of few html/css/js files. Aren't we make
it a bit complex by treating as a UUF component?


On Fri, Sep 30, 2016 at 2:36 PM, Dulitha Wijewantha <duli...@wso2.com>
wrote:

> IMO - isolation is not a requirement for the current use cases. Best would
> be to build the components separately and style them using SASS (using
> inheritance of CSS classes). Web components would be useful to be build
> components but the component story is already filled up with UUF right?
>
> On Fri, Sep 30, 2016 at 1:37 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi All,
>>
>> Currently we are utilizing shindig[1] as the underlying gadget container,
>> mainly to support gadget level isolation.  We faced problems with shindig
>> in the past due to the usage of iframes etc.. and shindig is a retired
>> project also.
>>
>> With the current set of use-cases around dashboards (Analytics dashboard
>> etc.), we are evaluating capabilities around web-components[2] to build the
>> infrastructure for dashboards.
>>
>> Further if we take a look at igviz samples[3], similarly we can do the
>> dashboard without iframes etc.. Only concern is isolation (if required,
>> with current use-cases) which can introduce through web-components.
>>
>> Appreciate your thoughts.
>>
>> [1] https://shindig.apache.org/
>> [2] https://developer.mozilla.org/en-US/docs/Web/Web_Components
>> [3] http://dunithd.github.io/igviz-site/samples/index.html
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
> Dulitha Wijewantha (Chan)
> Software Engineer - Mobile Development
> WSO2 Inc
> Lean.Enterprise.Middleware
>  * ~Email   duli...@wso2.com <duli...@wso2mobile.com>*
> *  ~Mobile +94712112165 <%2B94712112165>*
> *  ~Website   dulitha.me <http://dulitha.me>*
> *  ~Twitter @dulitharw <https://twitter.com/dulitharw>*
>   *~Github @dulichan <https://github.com/dulichan>*
>   *~SO @chan <http://stackoverflow.com/users/813471/chan>*
>



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


[Dev] Removing/Replacing shindig from wso2 dashboard framework

2016-09-30 Thread Udara Rathnayake
Hi All,

Currently we are utilizing shindig[1] as the underlying gadget container,
mainly to support gadget level isolation.  We faced problems with shindig
in the past due to the usage of iframes etc.. and shindig is a retired
project also.

With the current set of use-cases around dashboards (Analytics dashboard
etc.), we are evaluating capabilities around web-components[2] to build the
infrastructure for dashboards.

Further if we take a look at igviz samples[3], similarly we can do the
dashboard without iframes etc.. Only concern is isolation (if required,
with current use-cases) which can introduce through web-components.

Appreciate your thoughts.

[1] https://shindig.apache.org/
[2] https://developer.mozilla.org/en-US/docs/Web/Web_Components
[3] http://dunithd.github.io/igviz-site/samples/index.html

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


Re: [Dev] [EMM] WebApp Permission Handling at UI

2016-09-07 Thread Udara Rathnayake
On Thu, Sep 8, 2016 at 5:17 AM, Rasika Perera  wrote:

> Hi All,
>
> With the current migration of EMM webapp from UUF v0.1 to v0.2 (jaggery
> based implementation) we are trying to standardize the permission check for
> UI bits. We need to check permissions for “pages” level as well as granular
> to the “units” level. For example; show/hide a button based on UI
> permission. Also should notice that these permissions are not unique to the
> front-end, thus can be directly mapped into the respective back-end osgi
> services. For example; device enroll permission will be checked on the
> enrollment page(front-end), as well as the inside the respective enrollment
> osgi service(back-end).
>
> And also there’s a requirement that any third-party application should be
> able to write their own UI based on our web apis. Hence we are expecting to
> expose isAuthorized() via JAX-RS too. SOAP clients will be able to directly
> call admin-service.
>
> [image: Inline image 1]
>
>
>
> As per the diagram, when a EMM web app receives a page render request from
> the browser, UUF will execute the the method isAuthorized() at the back-end
> JavaScript layer. JavaScript will include the “carbon” jaggery module which
> will import the RealmService OSGi service. Using RealmService we can invoke
> the Authorizer.isRoleAuthorized().
>
> Whenever, third-party application requests for a permission check via
> EMM-API(JAX-RS), final result should be given invoking same
> Authorizer.isRoleAuthorized() method.
>
> One concern on this design was how to improve the *performance* of OSGi
> calls per permission check. One such suggestion is to retrieve all
> permissions for the current user and persist it on the “session”. IMO this
> would results some unforeseen issues and permission update on the backend
> will not immediately applied on the already logged users(eg. longer session
> timeouts). For example: users will still see the action buttons when
> clicked on it, it will return permission error. On the other hand, managing
> caching coherency is an extra effort for this approach. My suggestion is to
> utilize the permission check cache(if exists) at the user-core level which
> would be consistent across the platform.
>
> WDYT?
>
> @DS/UUF Team: I hope we need the similar permission check feature with the
> {{permission}} handlebar helper.
>
​Isn't this similar to what we are trying to solve with secured helper with
permission?​


>
> --
> With Regards,
>
> *Rasika Perera*
> Software Engineer
> LinkedIn: http://lk.linkedin.com/in/rasika90
>
> [image: wso2-signature-general.png] 
>
> WSO2 Inc. www.wso2.com
> lean.enterprise.middleware
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] [Jaggery] [WebSocket] [CEP] Closing the Web Socket Connection from server side

2016-08-29 Thread Udara Rathnayake
what we can do right now is ask client to close the connection from the
server, which is not feasible for CEP guys as I heard.

@dilini can explain the full use case.

On Mon, Aug 29, 2016 at 1:49 PM, Nipuna Chandradasa 
wrote:

> Hi All,
>
> There is a requirement to close the WebSocket connection from server side.
> Currently there is no close() functionality available for WebSocket from
> the jaggery side.
>
> 1. Is there a reason to why didn't we implement this in the first place?
> 2. Is there any other way of terminating a web socket connection?
>
> Thank you,
>
> --
> Nipuna Marcus
> *Software Engineer*
> WSO2 Inc.
> http://wso2.com/ - "lean . enterprise . middleware"
> Mobile : +94 (0) 713 667906
> nipu...@wso2.com
>



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


Re: [Dev] Add a default theme for gadgets in DS/DAS

2016-07-15 Thread Udara Rathnayake
are we going to inherit DS theme across gadgets?


On Fri, Jul 15, 2016 at 11:14 AM, Jerad Rutnam  wrote:

> Hi Sinthuja,
>
>
> Just summarizing the offline discussion we had yesterday,
>
> So the basic idea is that, since we ship a default theme with the
> Dashboard Server. We should also add a default theme for precooked gadgets,
> that we ship with the Dashboard Server.
>
> And also this should apply to the gadgets that are generated by the Gadget
> Create Wizard. Then generated gadgets will have a default theme and gadget
> generator(user) does not has to worry about the styling of it, unless
> he/she wants a fully customized UI. We can have a configuration to disable
> this theme if anyone wants.
>
> If the default theme is enabled on gadgets, it should apply the default
> stylesheet for the gadgets along with the chart template core styles.
>
> Also there should be a gadget extension stylesheet available for the theme
> developers. So he/she can overwrite the default gadget styling + theme
> styling (e.g. "gadget.css", just like we have for dashboard and portal).
>
>
> Let me know the thought.
>
>
> Cheers!
> --
> *Jerad Rutnam*
> *Software Engineer*
>
> WSO2 Inc.
> lean | enterprise | middleware
> M : +94 77 959 1609 | E : je...@wso2.com | W : www.wso2.com
>



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


Re: [Dev] Add a default theme for gadgets in DS/DAS

2016-07-15 Thread Udara Rathnayake
Hi Jerad,

One more thing, considering gadget generation as a one-time thing, how we
are going to support dashboard view theme update functionality. As I
remember we have a functionality to do this right now. So in that case
gadgets need to aware of the current theme and update dynamically.

On Fri, Jul 15, 2016 at 1:12 PM, Jerad Rutnam <je...@wso2.com> wrote:

> Hi Udara,
>
> Not the entire DS theme. But a theme for gadgets that will have a
> consistent UI to match the default DS theme. So users can generate gadgets
> without worrying about the look and feel of it.
>
> Because currently users have to style the gadget from the scratch once
> they generate it using the Gadget Generate Wizard.
>
> Cheers!
> Jerad
>
> On Fri, Jul 15, 2016 at 12:07 PM, Udara Rathnayake <uda...@wso2.com>
> wrote:
>
>> are we going to inherit DS theme across gadgets?
>>
>>
>> On Fri, Jul 15, 2016 at 11:14 AM, Jerad Rutnam <je...@wso2.com> wrote:
>>
>>> Hi Sinthuja,
>>>
>>>
>>> Just summarizing the offline discussion we had yesterday,
>>>
>>> So the basic idea is that, since we ship a default theme with the
>>> Dashboard Server. We should also add a default theme for precooked gadgets,
>>> that we ship with the Dashboard Server.
>>>
>>> And also this should apply to the gadgets that are generated by the
>>> Gadget Create Wizard. Then generated gadgets will have a default theme and
>>> gadget generator(user) does not has to worry about the styling of it,
>>> unless he/she wants a fully customized UI. We can have a configuration to
>>> disable this theme if anyone wants.
>>>
>>> If the default theme is enabled on gadgets, it should apply the default
>>> stylesheet for the gadgets along with the chart template core styles.
>>>
>>> Also there should be a gadget extension stylesheet available for the
>>> theme developers. So he/she can overwrite the default gadget styling +
>>> theme styling (e.g. "gadget.css", just like we have for dashboard and
>>> portal).
>>>
>>>
>>> Let me know the thought.
>>>
>>>
>>> Cheers!
>>> --
>>> *Jerad Rutnam*
>>> *Software Engineer*
>>>
>>> WSO2 Inc.
>>> lean | enterprise | middleware
>>> M : +94 77 959 1609 | E : je...@wso2.com | W : www.wso2.com
>>>
>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>


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


Re: [Dev] [DEV][DAS] Cannot delete dashboard added through registry

2016-07-12 Thread Udara Rathnayake
Can you add relevant permissions from dashboard settings page and retry
this?

@Nisala, I think we allow only dashboard owner to delete the dashboard
right?

On Tue, Jul 12, 2016 at 8:41 PM, Chamila De Alwis  wrote:

> I forgot to mention that this is seen in DAS 3.1.0 Beta.
>
>
> Regards,
> Chamila de Alwis
> Committer and PMC Member - Apache Stratos
> Software Engineer | WSO2 | +94772207163
> Blog: code.chamiladealwis.com
>
>
>
> On Tue, Jul 12, 2016 at 9:48 AM, Chamila De Alwis 
> wrote:
>
>> Hi,
>>
>> If an already created dashboard is added through the registry, it cannot
>> be deleted in the dashboard server. When clicked on the "Delete" button,
>> there is no feedback, and there is no error in the logs to be seen.
>>
>> This issue is not there for dashboards created in the dashboard server.
>>
>> Regards,
>> Chamila de Alwis
>> Committer and PMC Member - Apache Stratos
>> Software Engineer | WSO2 | +94772207163
>> Blog: code.chamiladealwis.com
>>
>>
>>
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] [DEV] Changing the name of publisher in ES

2016-07-01 Thread Udara Rathnayake
Hi All,

I remember adding ES store/publisher apps along with the APIM store
publisher apps. (can't remember whether we have renamed ES stuff or APIM :(
). Does anyone remember this?

On Thu, Jun 30, 2016 at 9:08 AM, Megala Uthayakumar  wrote:

> Hi All,
>
> Is it possible to change the default name of publisher in ES to a
> customized one(i.e publisher -> wso2-publisher)? If so how to achieve it ?
>
> Thanks.
>
> Regards,
> Megala
>
> --
> Megala Uthayakumar
>
> Software Engineer
> Mobile : 0779967122
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] [DS] Support primitive edit operations (moving and delete gadgets) operations in the view mode

2016-06-28 Thread Udara Rathnayake
Meeting notes:

1. Dashboard designer can enable gadget delete option. We need to check
this property before enabling gadget delete in view mode.

2. We are going to have theme switch (light & dark), enable edit (within
dashboard), dashboard settings(redirect to designer), logout witihn the top
right drop down menu.

3. Dashboard page restore option to be provided.

4. Personalization/customization should be enabled at the dashboard
settings level.

On Tue, Jun 28, 2016 at 11:52 AM, Sinthuja Ragendran <sinth...@wso2.com>
wrote:

> Hi Udara,
>
> Can you please arrange a meeting on this, lets come to an agreement on how
> are we going to handle this there.
>
> Thanks,
> Sinthuja.
>
> On Tue, Jun 28, 2016 at 11:33 AM, Udara Rathnayake <uda...@wso2.com>
> wrote:
>
>>
>>
>> On Tue, Jun 28, 2016 at 11:28 AM, Lasantha Samarakoon <lasant...@wso2.com
>> > wrote:
>>
>>> ​So as I understood after this change a viewer cannot go to the designer
>>> mode, right? Or are we keeping the existing customize button for such
>>> personalization capability. Plus, if we are enabling in page customization
>>> in the view mode, then should provide a way to reset as well.​
>>>
>> ​No. even with this we are allowing user to go and do changes from the
>> designer mode. We can't allow add gadget change layout(select a different
>> layout or create his own) etc from dashboard itself.​
>>
>>
>>>
>>> *Lasantha Samarakoon* | Software Engineer
>>> WSO2, Inc.
>>> #20, Palm Grove, Colombo 03, Sri Lanka
>>> Mobile: +94 (71) 214 1576
>>> Email:  lasant...@wso2.com
>>> Web:www.wso2.com
>>>
>>> lean . enterprise . middleware
>>>
>>> On Tue, Jun 28, 2016 at 9:24 AM, Jerad Rutnam <je...@wso2.com> wrote:
>>>
>>>> Hi Udara,
>>>>
>>>> I like the suggestion. But what I was thinking is that edit dashboard
>>>> is not the primary use case of the dashboard. It's a secondary use case
>>>> when it comes to the dashboard view. IMO I think its better we give an
>>>> option to the user to enable the editing mode by giving a switcher/button
>>>> etc ...
>>>>
>>>> WDYT?
>>>>
>>>> Cheers!
>>>> Jerad
>>>>
>>>> On Mon, Jun 27, 2016 at 9:45 PM, Sinthuja Ragendran <sinth...@wso2.com>
>>>> wrote:
>>>>
>>>>>
>>>>> On Mon, Jun 27, 2016 at 9:39 PM, Udara Rathnayake <uda...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> Hi All,
>>>>>>
>>>>>> Based on above feedback suggesting following approach.
>>>>>>
>>>>>> Within dashboard view mode we make gadget toolbar clickable. (on
>>>>>> mouse hover we can change the cursor value appropriately)
>>>>>> - Once user click on the toolbar we enable delete button (hiding
>>>>>> maximize button and make selected gadget active while others are not) 
>>>>>> also
>>>>>> enable resize option at the bottom right-hand corner.
>>>>>> - At this point we can make gadget draggable from the toolbar (by
>>>>>> changing mouse pointer tocmove cursor) similar in designer.
>>>>>>
>>>>>> WDYT?
>>>>>>
>>>>>
>>>>> +1.
>>>>>
>>>>> Thanks,
>>>>> Sinthuja.
>>>>>
>>>>>
>>>>>>
>>>>>> On Mon, Jun 27, 2016 at 2:15 PM, Jerad Rutnam <je...@wso2.com> wrote:
>>>>>>
>>>>>>> Hi Sinthuja,
>>>>>>>
>>>>>>> +1, I also think its better. We can simply enable designer mode only
>>>>>>> for designers and admins. And end users will have the capable of doing
>>>>>>> simple modifications on view mode it self.
>>>>>>>
>>>>>>> I believe in this case we will have a dynamic layout on view mode by
>>>>>>> default.
>>>>>>>
>>>>>>> Cheers!
>>>>>>> Jerad
>>>>>>>
>>>>>>> On Mon, Jun 27, 2016 at 1:35 PM, Sinthuja Ragendran <
>>>>>>> sinth...@wso2.com> wrote:
>>>>>>>
>>>>>>>> Hi Udara,
>>>>>>>>
>>>>>>>> On Mon, Jun 27, 2016 at 1:27 PM, Tanya Madurapperuma

Re: [Dev] [DS] Support primitive edit operations (moving and delete gadgets) operations in the view mode

2016-06-28 Thread Udara Rathnayake
On Tue, Jun 28, 2016 at 11:28 AM, Lasantha Samarakoon <lasant...@wso2.com>
wrote:

> ​So as I understood after this change a viewer cannot go to the designer
> mode, right? Or are we keeping the existing customize button for such
> personalization capability. Plus, if we are enabling in page customization
> in the view mode, then should provide a way to reset as well.​
>
​No. even with this we are allowing user to go and do changes from the
designer mode. We can't allow add gadget change layout(select a different
layout or create his own) etc from dashboard itself.​


>
> *Lasantha Samarakoon* | Software Engineer
> WSO2, Inc.
> #20, Palm Grove, Colombo 03, Sri Lanka
> Mobile: +94 (71) 214 1576
> Email:  lasant...@wso2.com
> Web:www.wso2.com
>
> lean . enterprise . middleware
>
> On Tue, Jun 28, 2016 at 9:24 AM, Jerad Rutnam <je...@wso2.com> wrote:
>
>> Hi Udara,
>>
>> I like the suggestion. But what I was thinking is that edit dashboard is
>> not the primary use case of the dashboard. It's a secondary use case when
>> it comes to the dashboard view. IMO I think its better we give an option to
>> the user to enable the editing mode by giving a switcher/button etc ...
>>
>> WDYT?
>>
>> Cheers!
>> Jerad
>>
>> On Mon, Jun 27, 2016 at 9:45 PM, Sinthuja Ragendran <sinth...@wso2.com>
>> wrote:
>>
>>>
>>> On Mon, Jun 27, 2016 at 9:39 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Hi All,
>>>>
>>>> Based on above feedback suggesting following approach.
>>>>
>>>> Within dashboard view mode we make gadget toolbar clickable. (on mouse
>>>> hover we can change the cursor value appropriately)
>>>> - Once user click on the toolbar we enable delete button (hiding
>>>> maximize button and make selected gadget active while others are not) also
>>>> enable resize option at the bottom right-hand corner.
>>>> - At this point we can make gadget draggable from the toolbar (by
>>>> changing mouse pointer tocmove cursor) similar in designer.
>>>>
>>>> WDYT?
>>>>
>>>
>>> +1.
>>>
>>> Thanks,
>>> Sinthuja.
>>>
>>>
>>>>
>>>> On Mon, Jun 27, 2016 at 2:15 PM, Jerad Rutnam <je...@wso2.com> wrote:
>>>>
>>>>> Hi Sinthuja,
>>>>>
>>>>> +1, I also think its better. We can simply enable designer mode only
>>>>> for designers and admins. And end users will have the capable of doing
>>>>> simple modifications on view mode it self.
>>>>>
>>>>> I believe in this case we will have a dynamic layout on view mode by
>>>>> default.
>>>>>
>>>>> Cheers!
>>>>> Jerad
>>>>>
>>>>> On Mon, Jun 27, 2016 at 1:35 PM, Sinthuja Ragendran <sinth...@wso2.com
>>>>> > wrote:
>>>>>
>>>>>> Hi Udara,
>>>>>>
>>>>>> On Mon, Jun 27, 2016 at 1:27 PM, Tanya Madurapperuma <ta...@wso2.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Hi Udara,
>>>>>>>
>>>>>>>
>>>>>>> On Mon, Jun 27, 2016 at 12:41 PM, Udara Rathnayake <uda...@wso2.com>
>>>>>>> wrote:
>>>>>>>
>>>>>>>> Hi UX team,
>>>>>>>>
>>>>>>>> Requirement is to provide simple dashboard viewer level
>>>>>>>> customization within the dashboard view rather redirecting to the 
>>>>>>>> designer.
>>>>>>>>
>>>>>>> If a user in the designer role logs into the dashboard, do we
>>>>>>> redirect him/her to designer view or do we allow them also to do minor
>>>>>>> changes being on the view mode ? Or is this just for personalization.
>>>>>>>
>>>>>>
>>>>>> The main idea is to avoid user to switch the modes (ie, switching
>>>>>> between designer/view modes) when doing such simple personalization
>>>>>> modifications. Hence IMHO we should not again ask for go to 
>>>>>> simple/advanced
>>>>>> designing, rather by default the view mode should have the simple 
>>>>>> designing
>>>>>> enabled where as he/she should be able to drag the gadgets, and delete 
>

Re: [Dev] [DS] Support primitive edit operations (moving and delete gadgets) operations in the view mode

2016-06-27 Thread Udara Rathnayake
Hi All,

Based on above feedback suggesting following approach.

Within dashboard view mode we make gadget toolbar clickable. (on mouse
hover we can change the cursor value appropriately)
- Once user click on the toolbar we enable delete button (hiding maximize
button and make selected gadget active while others are not) also enable
resize option at the bottom right-hand corner.
- At this point we can make gadget draggable from the toolbar (by changing
mouse pointer tocmove cursor) similar in designer.

WDYT?

On Mon, Jun 27, 2016 at 2:15 PM, Jerad Rutnam <je...@wso2.com> wrote:

> Hi Sinthuja,
>
> +1, I also think its better. We can simply enable designer mode only for
> designers and admins. And end users will have the capable of doing simple
> modifications on view mode it self.
>
> I believe in this case we will have a dynamic layout on view mode by
> default.
>
> Cheers!
> Jerad
>
> On Mon, Jun 27, 2016 at 1:35 PM, Sinthuja Ragendran <sinth...@wso2.com>
> wrote:
>
>> Hi Udara,
>>
>> On Mon, Jun 27, 2016 at 1:27 PM, Tanya Madurapperuma <ta...@wso2.com>
>> wrote:
>>
>>> Hi Udara,
>>>
>>>
>>> On Mon, Jun 27, 2016 at 12:41 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Hi UX team,
>>>>
>>>> Requirement is to provide simple dashboard viewer level customization
>>>> within the dashboard view rather redirecting to the designer.
>>>>
>>> If a user in the designer role logs into the dashboard, do we redirect
>>> him/her to designer view or do we allow them also to do minor changes being
>>> on the view mode ? Or is this just for personalization.
>>>
>>
>> The main idea is to avoid user to switch the modes (ie, switching between
>> designer/view modes) when doing such simple personalization modifications.
>> Hence IMHO we should not again ask for go to simple/advanced designing,
>> rather by default the view mode should have the simple designing enabled
>> where as he/she should be able to drag the gadgets, and delete them if
>> he/she doesn't want it.
>>
>> Thanks,
>> Sinthuja.
>>
>> Thanks,
>>> Tanya
>>>
>>>>
>>>> Simple customization includes(as per the RM),
>>>> 1. Deleting a gadget
>>>> 2. Moving a gadget
>>>> 3. Resize a gadget
>>>>
>>>> Still, viewer should be able to go to the designer for extensive
>>>> customizations.
>>>>
>>>> How should we distinguish these two operations in the dashboard view?
>>>> Right now we have following menu item,
>>>>
>>>>
>>>> ​
>>>>
>>>> Shall we get an input from the user once he/she press the Customize
>>>> Dashboard menu and continue?
>>>>
>>>> Eg:-
>>>>
>>>>
>>>> ​
>>>>
>>>> Even with this kind of an interaction(simple vs extensive) it's hard to
>>>> convey what is the difference between these two types.
>>>>
>>>> Appreciate your feedback.
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>>
>>>
>>>
>>>
>>> --
>>> Tanya Madurapperuma
>>>
>>> Senior Software Engineer,
>>> WSO2 Inc. : wso2.com
>>> Mobile : +94718184439
>>> Blog : http://tanyamadurapperuma.blogspot.com
>>>
>>
>>
>>
>> --
>> *Sinthuja Rajendran*
>> Technical Lead
>> WSO2, Inc.:http://wso2.com
>>
>> Blog: http://sinthu-rajan.blogspot.com/
>> Mobile: +94774273955
>>
>>
>>
>
>
> --
> *Jerad Rutnam*
> *Software Engineer*
>
> WSO2 Inc.
> lean | enterprise | middleware
> M : +94 77 959 1609 | E : je...@wso2.com | W : www.wso2.com
>



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


[Dev] [DS] Support primitive edit operations (moving and delete gadgets) operations in the view mode

2016-06-27 Thread Udara Rathnayake
Hi UX team,

Requirement is to provide simple dashboard viewer level customization
within the dashboard view rather redirecting to the designer.

Simple customization includes(as per the RM),
1. Deleting a gadget
2. Moving a gadget
3. Resize a gadget

Still, viewer should be able to go to the designer for extensive
customizations.

How should we distinguish these two operations in the dashboard view? Right
now we have following menu item,


​

Shall we get an input from the user once he/she press the Customize
Dashboard menu and continue?

Eg:-


​

Even with this kind of an interaction(simple vs extensive) it's hard to
convey what is the difference between these two types.

Appreciate your feedback.

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


Re: [Dev] How to create a signed auth request using sso module within jaggery-extensions

2016-06-02 Thread Udara Rathnayake
On Thu, Jun 2, 2016 at 12:12 PM, Malithi Edirisinghe <malit...@wso2.com>
wrote:

>
> Hi,
>
> On Wed, Jun 1, 2016 at 9:25 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi All,
>>
>> We have buildAuthenticationRequest[1] wrapped within our sso client js
>> module. Noticed following error after enabling sso with signature
>> validation,
>>
>> WARN
>> {org.wso2.carbon.identity.sso.saml.processors.SPInitSSOAuthnRequestProcessor}
>> -  Destination validation for Authentication Request failed. Received: [
>> *null*]. Expected one in the list: [https://localhost:9443/samlsso
>> <https://www.google.com/url?q=https%3A%2F%2Flocalhost%3A9443%2Fsamlsso=D=1=AFQjCNFEktbwY50oRm419Cu2qmnUw2Z_vw>
>> ]
>>
>> Seems we have to set other properties like destination etc.. within SAML
>> request inorder to support signature validation. @Darshana please confirm.
>>
>
> Yes. destination should be there [1]. Further the request should contain
> the signature also, which I do not see in the code segment being pointed.
>
​Thanks Malithi. We will fix this.​


>
> Found buildSignedAuthRequest[2] within APIM SSO hostobject which supports
>> this. Have we encounted this problem during ES/UES testing previously?
>>
>> [1]
>> https://github.com/wso2/jaggery-extensions/blob/master/sso/resources/org.jaggeryjs.modules.sso/src/main/java/org/jaggeryjs/modules/sso/common/builders/AuthReqBuilder.java#L38
>> [2]
>> https://github.com/wso2/carbon-apimgt/blob/8e5b065f3149d75e9eea3d63fe3f68b24503e6b4/components/sso-hostobject/org.wso2.carbon.hostobjects.sso/src/main/java/org/wso2/carbon/hostobjects/sso/internal/builder/AuthReqBuilder.java#L83
>>
>> --
>> Regards,
>> UdaraR
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
> [1]
> https://github.com/wso2-extensions/identity-inbound-auth-saml/blob/master/components/org.wso2.carbon.identity.sso.saml/src/main/java/org/wso2/carbon/identity/sso/saml/processors/SPInitSSOAuthnRequestProcessor.java#L72
>
> Thanks,
> Malithi.
> --
>
> *Malithi Edirisinghe*
> Senior Software Engineer
> WSO2 Inc.
>
> Mobile : +94 (0) 718176807
> malit...@wso2.com
>



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


[Dev] How to create a signed auth request using sso module within jaggery-extensions

2016-06-01 Thread Udara Rathnayake
Hi All,

We have buildAuthenticationRequest[1] wrapped within our sso client js
module. Noticed following error after enabling sso with signature
validation,

WARN
{org.wso2.carbon.identity.sso.saml.processors.SPInitSSOAuthnRequestProcessor}
-  Destination validation for Authentication Request failed. Received: [
*null*]. Expected one in the list: [https://localhost:9443/samlsso

]

Seems we have to set other properties like destination etc.. within SAML
request inorder to support signature validation. @Darshana please confirm.

Found buildSignedAuthRequest[2] within APIM SSO hostobject which supports
this. Have we encounted this problem during ES/UES testing previously?

[1]
https://github.com/wso2/jaggery-extensions/blob/master/sso/resources/org.jaggeryjs.modules.sso/src/main/java/org/jaggeryjs/modules/sso/common/builders/AuthReqBuilder.java#L38
[2]
https://github.com/wso2/carbon-apimgt/blob/8e5b065f3149d75e9eea3d63fe3f68b24503e6b4/components/sso-hostobject/org.wso2.carbon.hostobjects.sso/src/main/java/org/wso2/carbon/hostobjects/sso/internal/builder/AuthReqBuilder.java#L83

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


Re: [Dev] [DS] UI Design - Multiple views support for page based on roles (Designer View)

2016-06-01 Thread Udara Rathnayake
On Wed, Jun 1, 2016 at 11:51 AM, Tanya Madurapperuma <ta...@wso2.com> wrote:

> Hi,
>
> On Wed, Jun 1, 2016 at 11:09 AM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi Tanya,
>>
>> On Wed, Jun 1, 2016 at 10:56 AM, Tanya Madurapperuma <ta...@wso2.com>
>> wrote:
>>
>>> Hi Udara,
>>>
>>> From where can we select the layout for the view? Or do we enforce using
>>> the same layout for all the views of a single page?
>>>
>> ​We should open the layout selection panel and move to the newly created
>> tab (role based view) once user select the role(s) and create the view​
>> ​.​
>>
>> ​I think we should not restrict and enforce the same layout.
>>
> My question was because I assume a user has to click on (+) to create a
> new view. If so I believe we have to have the UI design for getting layout
> selection pane as well, because it is not same as getting it for creating a
> new page.
>
​Ya I missed the layout selection part in above design.​

​Hope above explanation clarifies your doubts.​

>
>>> On Tue, May 31, 2016 at 9:09 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Thanks Dakshika & Sinthuja.
>>>>
>>>> On Tue, May 31, 2016 at 7:10 PM, Sinthuja Ragendran <sinth...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi Udara,
>>>>>
>>>>> As discussed offline we need to have following as well.
>>>>>
>>>>> - A name for each view so that if a user could see both views he/she
>>>>> should be able switch.
>>>>> - A default view should not be existing, and that should be associated
>>>>> with roles selection option when the 'role based view' option is selected
>>>>> in the left pane.
>>>>>
>>>> ​We have to revisit this a bit. Assume a scenario, where dashboard
>>>> designer already have a default view.​
>>>>
>>>> ​At that point we should not just disable the default view and provide
>>>> role selection option.
>>>>
>>> Even if they have a default view, they should have set a viewers role in
>>> the dashboard settings page. So can't we use that role as the roles for
>>> that page and get rid of default view.
>>>
>> Since we are bringing gadget level roles now, we might have to remove
>> some gadgets from the default view in that case. This might confuse the
>> designer. ​
>>
>>
> We need to have a verdict on this. Say based on the gadget level roles
> dashboard designer can see gadget A, B and C. And he is going to design a
> dashboard for a viewer and that viewer is authorized to see gadget A, B and
> D. But the gadget D will not be in the gadget listing for designer as he is
> not authorized to see that gadget. But gadget C will be in the designers
> listing even though viewer is not authorized to see the gadget C. How does
> having a default view solve this problem?
>
​We had an offline chat yesterday regarding this. Megala is going to setup
a meeting this friday and let's include this discussion also.  ​


> Thanks,
>>> Tanya
>>>
>>>>
>>>> - As Dakshika mentioned, the view tab settings will be required to
>>>>> edit/update as well.
>>>>> - During the personalization of dashboard mode, we shouldn't show the
>>>>> options of editing the roles, etc for a view table, and only show the view
>>>>> names in the tabs. Hence the user can't actually do any changes to the 
>>>>> view
>>>>> or anything, but he/she can add or delete gadgets, change layout, etc
>>>>> according to their personal interest.
>>>>>
>>>>> Thanks,
>>>>> Sinthuja.
>>>>>
>>>>>
>>>>> On Tue, May 31, 2016 at 2:33 PM, Udara Rathnayake <uda...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> Came up with following modifications to the existing dashboard
>>>>>> designer UI to cater the $Subject.
>>>>>>
>>>>>> Designer can select and enable page view based on role(s) from the
>>>>>> settings.
>>>>>>
>>>>>>
>>>>>> ​
>>>>>> ​Once this is enabled, we can update the dashboard designer with a
>>>>>> drop down where dashboard designer can select a role and create the
>>>>>> particular view. When th

Re: [Dev] [DS] UI Design - Multiple views support for page based on roles (Designer View)

2016-05-31 Thread Udara Rathnayake
Hi Tanya,

On Wed, Jun 1, 2016 at 10:56 AM, Tanya Madurapperuma <ta...@wso2.com> wrote:

> Hi Udara,
>
> From where can we select the layout for the view? Or do we enforce using
> the same layout for all the views of a single page?
>
​We should open the layout selection panel and move to the newly created
tab (role based view) once user select the role(s) and create the view​
​.​

​I think we should not restrict and enforce the same layout.

>
> On Tue, May 31, 2016 at 9:09 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Thanks Dakshika & Sinthuja.
>>
>> On Tue, May 31, 2016 at 7:10 PM, Sinthuja Ragendran <sinth...@wso2.com>
>> wrote:
>>
>>> Hi Udara,
>>>
>>> As discussed offline we need to have following as well.
>>>
>>> - A name for each view so that if a user could see both views he/she
>>> should be able switch.
>>> - A default view should not be existing, and that should be associated
>>> with roles selection option when the 'role based view' option is selected
>>> in the left pane.
>>>
>> ​We have to revisit this a bit. Assume a scenario, where dashboard
>> designer already have a default view.​
>>
>> ​At that point we should not just disable the default view and provide
>> role selection option.
>>
> Even if they have a default view, they should have set a viewers role in
> the dashboard settings page. So can't we use that role as the roles for
> that page and get rid of default view.
>
Since we are bringing gadget level roles now, we might have to remove some
gadgets from the default view in that case. This might confuse the
designer. ​


>
> Thanks,
> Tanya
>
>>
>> - As Dakshika mentioned, the view tab settings will be required to
>>> edit/update as well.
>>> - During the personalization of dashboard mode, we shouldn't show the
>>> options of editing the roles, etc for a view table, and only show the view
>>> names in the tabs. Hence the user can't actually do any changes to the view
>>> or anything, but he/she can add or delete gadgets, change layout, etc
>>> according to their personal interest.
>>>
>>> Thanks,
>>> Sinthuja.
>>>
>>>
>>> On Tue, May 31, 2016 at 2:33 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Hi,
>>>>
>>>> Came up with following modifications to the existing dashboard designer
>>>> UI to cater the $Subject.
>>>>
>>>> Designer can select and enable page view based on role(s) from the
>>>> settings.
>>>>
>>>>
>>>> ​
>>>> ​Once this is enabled, we can update the dashboard designer with a drop
>>>> down where dashboard designer can select a role and create the particular
>>>> view. When the dashboard designer browse gadgets/widgets section from this
>>>> particular view(role based), we should only list down gadgets enabled for
>>>> the selected role(have to come up with a gadget level config for this).
>>>>
>>>>
>>>>
>>>> ​ ​
>>>> This role list can be a simple drop down (if we support one role per
>>>> page) or can be a list with check-boxes, so we can support multiple roles
>>>> per page view. (gadget listing for particular view should be the union of
>>>> selected roles)
>>>>
>>>>
>>>> ​
>>>>  Designer UI after adding a role based page view,
>>>>
>>>>
>>>> ​
>>>>
>>>> ​Appreciate your feedback on this.
>>>> ​
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>>
>>>
>>>
>>>
>>> --
>>> *Sinthuja Rajendran*
>>> Associate Technical Lead
>>> WSO2, Inc.:http://wso2.com
>>>
>>> Blog: http://sinthu-rajan.blogspot.com/
>>> Mobile: +94774273955
>>>
>>>
>>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
> Tanya Madurapperuma
>
> Senior Software Engineer,
> WSO2 Inc. : wso2.com
> Mobile : +94718184439
> Blog : http://tanyamadurapperuma.blogspot.com
>



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


Re: [Dev] Help setup SSO in APIM

2016-05-31 Thread Udara Rathnayake
On Wed, Jun 1, 2016 at 8:53 AM, Megala Uthayakumar  wrote:

> Hi All,
>
> I am trying to configure SSO in APIM 2.0.x by following [1]. Publisher and
> Store jaggery apps work as expected but when I try to login to portal
> app(Portal of Dashboard Server) using SSO, it works fine when I am logging
> in as super-tenant user but whenever I try to login in as a user from other
> tenants, it throws following error,
>
> org.opensaml.xml.validation.ValidationException: Signature did not
> validate against the credential's key
>
​For the moment, shall we disable the signature validation and try?​


> at
> org.opensaml.xml.signature.SignatureValidator.validate(SignatureValidator.java:79)
> at
> org.jaggeryjs.modules.sso.common.util.Util.validateSignature(Util.java:290)
> 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.mozilla.javascript.MemberBox.invoke(MemberBox.java:126)
> at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:225)
> at org.mozilla.javascript.optimizer.OptRuntime.callN(OptRuntime.java:52)
> at
> org.jaggeryjs.rhino..scripts.c0._c_anonymous_3(/scripts/sso.client.js:57)
> at org.jaggeryjs.rhino..scripts.c0.call(/scripts/sso.client.js)
> at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
> at
> org.jaggeryjs.rhino.portal.controllers.c3._c_anonymous_1(/portal/controllers/acs.jag:77)
> at
> org.jaggeryjs.rhino.portal.controllers.c3.call(/portal/controllers/acs.jag)
> at org.mozilla.javascript.optimizer.OptRuntime.call0(OptRuntime.java:23)
> at
> org.jaggeryjs.rhino.portal.controllers.c3._c_script_0(/portal/controllers/acs.jag:20)
> at
> org.jaggeryjs.rhino.portal.controllers.c3.call(/portal/controllers/acs.jag)
> at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:394)
> at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3091)
> at
> org.jaggeryjs.rhino.portal.controllers.c3.call(/portal/controllers/acs.jag)
> at
> org.jaggeryjs.rhino.portal.controllers.c3.exec(/portal/controllers/acs.jag)
> at
> org.jaggeryjs.scriptengine.engine.RhinoEngine.execScript(RhinoEngine.java:567)
> at org.jaggeryjs.scriptengine.engine.RhinoEngine.exec(RhinoEngine.java:273)
> at
> org.jaggeryjs.jaggery.core.manager.WebAppManager.exec(WebAppManager.java:587)
> at
> org.jaggeryjs.jaggery.core.manager.WebAppManager.execute(WebAppManager.java:507)
> at org.jaggeryjs.jaggery.core.JaggeryServlet.doPost(JaggeryServlet.java:29)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:650)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
> at
> org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:747)
> at
> org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:485)
> at
> org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:377)
> at
> org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:337)
> at org.jaggeryjs.jaggery.core.JaggeryFilter.doFilter(JaggeryFilter.java:21)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
> at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)
> at
> org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:505)
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169)
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
> at
> org.wso2.carbon.tomcat.ext.valves.CompositeValve.continueInvocation(CompositeValve.java:99)
> at
> org.wso2.carbon.tomcat.ext.valves.CarbonTomcatValve$1.invoke(CarbonTomcatValve.java:47)
> at
> org.wso2.carbon.webapp.mgt.TenantLazyLoaderValve.invoke(TenantLazyLoaderValve.java:57)
> at
> org.wso2.carbon.event.receiver.core.internal.tenantmgt.TenantLazyLoaderValve.invoke(TenantLazyLoaderValve.java:48)
> at
> org.wso2.carbon.tomcat.ext.valves.TomcatValveContainer.invokeValves(TomcatValveContainer.java:47)
> at
> 

Re: [Dev] [DS] UI Design - Multiple views support for page based on roles (Designer View)

2016-05-31 Thread Udara Rathnayake
Thanks Dakshika & Sinthuja.

On Tue, May 31, 2016 at 7:10 PM, Sinthuja Ragendran <sinth...@wso2.com>
wrote:

> Hi Udara,
>
> As discussed offline we need to have following as well.
>
> - A name for each view so that if a user could see both views he/she
> should be able switch.
> - A default view should not be existing, and that should be associated
> with roles selection option when the 'role based view' option is selected
> in the left pane.
>
​We have to revisit this a bit. Assume a scenario, where dashboard designer
already have a default view.​

​At that point we should not just disable the default view and provide role
selection option.

- As Dakshika mentioned, the view tab settings will be required to
> edit/update as well.
> - During the personalization of dashboard mode, we shouldn't show the
> options of editing the roles, etc for a view table, and only show the view
> names in the tabs. Hence the user can't actually do any changes to the view
> or anything, but he/she can add or delete gadgets, change layout, etc
> according to their personal interest.
>
> Thanks,
> Sinthuja.
>
>
> On Tue, May 31, 2016 at 2:33 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi,
>>
>> Came up with following modifications to the existing dashboard designer
>> UI to cater the $Subject.
>>
>> Designer can select and enable page view based on role(s) from the
>> settings.
>>
>>
>> ​
>> ​Once this is enabled, we can update the dashboard designer with a drop
>> down where dashboard designer can select a role and create the particular
>> view. When the dashboard designer browse gadgets/widgets section from this
>> particular view(role based), we should only list down gadgets enabled for
>> the selected role(have to come up with a gadget level config for this).
>>
>>
>>
>> ​ ​
>> This role list can be a simple drop down (if we support one role per
>> page) or can be a list with check-boxes, so we can support multiple roles
>> per page view. (gadget listing for particular view should be the union of
>> selected roles)
>>
>>
>> ​
>>  Designer UI after adding a role based page view,
>>
>>
>> ​
>>
>> ​Appreciate your feedback on this.
>> ​
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
> *Sinthuja Rajendran*
> Associate Technical Lead
> WSO2, Inc.:http://wso2.com
>
> Blog: http://sinthu-rajan.blogspot.com/
> Mobile: +94774273955
>
>
>


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


[Dev] [DS] UI Design - Multiple views support for page based on roles (Designer View)

2016-05-31 Thread Udara Rathnayake
Hi,

Came up with following modifications to the existing dashboard designer UI
to cater the $Subject.

Designer can select and enable page view based on role(s) from the settings.


​
​Once this is enabled, we can update the dashboard designer with a drop
down where dashboard designer can select a role and create the particular
view. When the dashboard designer browse gadgets/widgets section from this
particular view(role based), we should only list down gadgets enabled for
the selected role(have to come up with a gadget level config for this).



​ ​
This role list can be a simple drop down (if we support one role per page)
or can be a list with check-boxes, so we can support multiple roles per
page view. (gadget listing for particular view should be the union of
selected roles)


​
 Designer UI after adding a role based page view,


​

​Appreciate your feedback on this.
​

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


Re: [Dev] Jaggery 0.12.5 released to staging

2016-05-10 Thread Udara Rathnayake
thanks kasun

On Tue, May 10, 2016 at 6:24 PM, KasunG Gajasinghe <kas...@wso2.com> wrote:

> Released.
>
> On Tue, May 10, 2016 at 6:02 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi Kasun,
>>
>> Can you please release this?
>>
>> Thanks!
>>
>> On Tue, May 10, 2016 at 5:33 PM, Bhathiya Jayasekara <bhath...@wso2.com>
>> wrote:
>>
>>> Hi Udara,
>>>
>>> Jaggery feature installation completed successfully.
>>>
>>> Thanks,
>>> Bhathiya
>>>
>>> On Tue, May 10, 2016 at 5:18 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Thanks Kasun,
>>>>
>>>> @Bhathiya, Can you do a APIM build with this and confirm?
>>>>
>>>> On Tue, May 10, 2016 at 5:16 PM, KasunG Gajasinghe <kas...@wso2.com>
>>>> wrote:
>>>>
>>>>>
>>>>> Staged -
>>>>> https://maven.wso2.org/nexus/content/repositories/orgjaggeryjs-1004
>>>>>
>>>>> On Tue, May 10, 2016 at 5:04 PM, Udara Rathnayake <uda...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> Please close this and provide the repo URL.
>>>>>>
>>>>>> --
>>>>>> Regards,
>>>>>> UdaraR
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>>
>>>>> *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
>>>>> email: kasung AT spamfree wso2.com
>>>>> linked-in: http://lk.linkedin.com/in/gajasinghe
>>>>> blog: http://kasunbg.org
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>>
>>>
>>>
>>>
>>> --
>>> *Bhathiya Jayasekara*
>>> *Senior Software Engineer,*
>>> *WSO2 inc., http://wso2.com <http://wso2.com>*
>>>
>>> *Phone: +94715478185 <%2B94715478185>*
>>> *LinkedIn: http://www.linkedin.com/in/bhathiyaj
>>> <http://www.linkedin.com/in/bhathiyaj>*
>>> *Twitter: https://twitter.com/bhathiyax <https://twitter.com/bhathiyax>*
>>> *Blog: http://movingaheadblog.blogspot.com
>>> <http://movingaheadblog.blogspot.com/>*
>>>
>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
>
> *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
> email: kasung AT spamfree wso2.com
> linked-in: http://lk.linkedin.com/in/gajasinghe
> blog: http://kasunbg.org
>
>
>



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


Re: [Dev] Jaggery 0.12.5 released to staging

2016-05-10 Thread Udara Rathnayake
Hi Kasun,

Can you please release this?

Thanks!

On Tue, May 10, 2016 at 5:33 PM, Bhathiya Jayasekara <bhath...@wso2.com>
wrote:

> Hi Udara,
>
> Jaggery feature installation completed successfully.
>
> Thanks,
> Bhathiya
>
> On Tue, May 10, 2016 at 5:18 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Thanks Kasun,
>>
>> @Bhathiya, Can you do a APIM build with this and confirm?
>>
>> On Tue, May 10, 2016 at 5:16 PM, KasunG Gajasinghe <kas...@wso2.com>
>> wrote:
>>
>>>
>>> Staged -
>>> https://maven.wso2.org/nexus/content/repositories/orgjaggeryjs-1004
>>>
>>> On Tue, May 10, 2016 at 5:04 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Hi,
>>>>
>>>> Please close this and provide the repo URL.
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>>
>>>
>>>
>>>
>>> --
>>>
>>> *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
>>> email: kasung AT spamfree wso2.com
>>> linked-in: http://lk.linkedin.com/in/gajasinghe
>>> blog: http://kasunbg.org
>>>
>>>
>>>
>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
> *Bhathiya Jayasekara*
> *Senior Software Engineer,*
> *WSO2 inc., http://wso2.com <http://wso2.com>*
>
> *Phone: +94715478185 <%2B94715478185>*
> *LinkedIn: http://www.linkedin.com/in/bhathiyaj
> <http://www.linkedin.com/in/bhathiyaj>*
> *Twitter: https://twitter.com/bhathiyax <https://twitter.com/bhathiyax>*
> *Blog: http://movingaheadblog.blogspot.com
> <http://movingaheadblog.blogspot.com/>*
>



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


Re: [Dev] Why we don't have latest carbon-identity release tags in github?

2016-05-10 Thread Udara Rathnayake
Thanks Darshana!

On Tue, May 10, 2016 at 5:51 PM, Darshana Gunawardana <darsh...@wso2.com>
wrote:

> Hi Udara,
>
> Carbon-Identity repository is deprecated now and active development going
> on other repositories. Refer the README of the carbon-identity repo on
> exact details.
>
> [1] https://github.com/wso2/carbon-identity/blob/master/README.md
>
> Thanks,
>
> On Tue, May 10, 2016 at 5:25 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> or are we still on 5.0.9-SNAPSHOT?
>>
>> On Tue, May 10, 2016 at 5:20 PM, Udara Rathnayake <uda...@wso2.com>
>> wrote:
>>
>>> $subject?
>>>
>>> https://github.com/wso2/carbon-identity/releases
>>>
>>> --
>>> Regards,
>>> UdaraR
>>>
>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Regards,
>
>
> *Darshana Gunawardana*Senior Software Engineer
> WSO2 Inc.; http://wso2.com
>
> *E-mail: darsh...@wso2.com <darsh...@wso2.com>*
> *Mobile: +94718566859 <%2B94718566859>*Lean . Enterprise . Middleware
>



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


Re: [Dev] Why we don't have latest carbon-identity release tags in github?

2016-05-10 Thread Udara Rathnayake
or are we still on 5.0.9-SNAPSHOT?

On Tue, May 10, 2016 at 5:20 PM, Udara Rathnayake <uda...@wso2.com> wrote:

> $subject?
>
> https://github.com/wso2/carbon-identity/releases
>
> --
> Regards,
> UdaraR
>



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


[Dev] Why we don't have latest carbon-identity release tags in github?

2016-05-10 Thread Udara Rathnayake
$subject?

https://github.com/wso2/carbon-identity/releases

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


Re: [Dev] Jaggery 0.12.5 released to staging

2016-05-10 Thread Udara Rathnayake
Thanks Kasun,

@Bhathiya, Can you do a APIM build with this and confirm?

On Tue, May 10, 2016 at 5:16 PM, KasunG Gajasinghe <kas...@wso2.com> wrote:

>
> Staged -
> https://maven.wso2.org/nexus/content/repositories/orgjaggeryjs-1004
>
> On Tue, May 10, 2016 at 5:04 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi,
>>
>> Please close this and provide the repo URL.
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
>
> *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
> email: kasung AT spamfree wso2.com
> linked-in: http://lk.linkedin.com/in/gajasinghe
> blog: http://kasunbg.org
>
>
>



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


[Dev] Jaggery 0.12.5 released to staging

2016-05-10 Thread Udara Rathnayake
Hi,

Please close this and provide the repo URL.

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


Re: [Dev] carbon-dashboard 1.0.16 released to staging

2016-04-26 Thread Udara Rathnayake
Hi Jayanga,

Please drop above, as we have encounted some problems.
At the same time please close the new repo and provide us the repo URL.

Thanks!

On Tue, Apr 26, 2016 at 9:09 PM, Jayanga Dissanayake <jaya...@wso2.com>
wrote:

> Hi Udara,
>
> The repo is closed. You can access the repo via [1].
> Please verify.
>
> [1]
> http://maven.wso2.org/nexus/content/repositories/orgwso2carbondashboards-1002/
>
> Thanks,
> Jayanga.
>
> *Jayanga Dissanayake*
> Senior Software Engineer
> WSO2 Inc. - http://wso2.com/
> lean . enterprise . middleware
> email: jaya...@wso2.com
> mobile: +94772207259
>
> On Tue, Apr 26, 2016 at 8:37 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi Build team,
>>
>> Please close this and provide the repo.
>>
>> Thanks!
>>
>> --
>> Regards,
>> UdaraR
>>
>
>


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


[Dev] carbon-dashboard 1.0.16 released to staging

2016-04-26 Thread Udara Rathnayake
Hi Build team,

Please close this and provide the repo.

Thanks!

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


[Dev] Jaggery 0.12.4 released to staging

2016-04-25 Thread Udara Rathnayake
Hi build team,

Please close this and provide the repo URL

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


Re: [Dev] US Election Analytics - Data won't persist in DAS

2016-04-02 Thread Udara Rathnayake
https://wso2.org/jira/browse/DAS-388 created.

On Sat, Apr 2, 2016 at 12:34 PM, Mohanadarshan Vivekanandalingam <
mo...@wso2.com> wrote:

>
>
> On Sat, Apr 2, 2016 at 9:56 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Sure Niranda, Let me know whether I have to report this in CEP or DAS?
>>
>> It should be DAS :)
>
>
>> On Sat, Apr 2, 2016 at 12:21 PM, Niranda Perera <nira...@wso2.com> wrote:
>>
>>> Hi Udara,
>>>
>>> Ah. Never came across it but yes, you are correct. This seems to be a UI
>>> bug.
>>>
>>> Can you report a JIRA in this?
>>>
>>> Rgds
>>> On Apr 2, 2016 21:45, "Udara Rathnayake" <uda...@wso2.com> wrote:
>>>
>>>> Hi Niranda,
>>>>
>>>> ​If we edit and save an existing stream definition (without going to
>>>> the persistence UI)​ this can happen right? I have faced similar thing but
>>>> never tried reproducing.
>>>>
>>>> However we should bring tooling support(dev studio) ASAP to DAS
>>>> artifacts, so we can create and deploy via car apps easily.
>>>>
>>>>
>>>> On Fri, Apr 1, 2016 at 11:32 AM, Niranda Perera <nira...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi Chehara,
>>>>>
>>>>> It's highly unlikely that a stream persistence configuration to get
>>>>> disabled automatically. Looks like someone have mistakenly disabled it 
>>>>> from
>>>>> the UI. As per the current persistence UI, there is a possibility that 
>>>>> such
>>>>> an incident may occur.
>>>>>
>>>>>
>>>>> On Fri, Apr 1, 2016 at 8:43 PM, Chehara Pathmabandu <cheh...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> Solved. event persistent had been disabled automatically.
>>>>>>
>>>>>> On Fri, Apr 1, 2016 at 8:16 PM, Niranda Perera <nira...@wso2.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Hi Yasara,
>>>>>>>
>>>>>>> We need to find where exactly the data stopped persisting. can you
>>>>>>> find the final entry? Are there any error in the logs?
>>>>>>>
>>>>>>> also, we need to check the mysql connections. Check if it has grown
>>>>>>> out of proportion as previously.
>>>>>>> And the CPU and memory usage of the node.
>>>>>>>
>>>>>>> On Fri, Apr 1, 2016 at 7:37 PM, Mohanadarshan Vivekanandalingam <
>>>>>>> mo...@wso2.com> wrote:
>>>>>>>
>>>>>>>> [Adding Dev mail thread]
>>>>>>>>
>>>>>>>> @Niranda, can you please dig on this issue and find the root
>>>>>>>> cause..
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Fri, Apr 1, 2016 at 7:26 PM, Yasara Dissanayake <yas...@wso2.com
>>>>>>>> > wrote:
>>>>>>>>
>>>>>>>>> Hi,
>>>>>>>>>
>>>>>>>>> As you can see from the image attached here[1]:
>>>>>>>>> Current status is growing as the data receive and we use this same
>>>>>>>>> stream to persist. But from a particular date data had not been 
>>>>>>>>> persisted.
>>>>>>>>>
>>>>>>>>> regards,
>>>>>>>>> yasara
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> *V. Mohanadarshan*
>>>>>>>> *Senior Software Engineer,*
>>>>>>>> *Data Technologies Team,*
>>>>>>>> *WSO2, Inc. http://wso2.com <http://wso2.com> *
>>>>>>>> *lean.enterprise.middleware.*
>>>>>>>>
>>>>>>>> email: mo...@wso2.com
>>>>>>>> phone:(+94) 771117673
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> *Niranda Perera*
>>>>>>> Software Engineer, WSO2 Inc.
>>>>>>> Mobile: +94-71-554-8430
>>>>>>> Twitter: @n1r44 <https://twitter.com/N1R44>
>>>>>>> https://pythagoreanscript.wordpress.com/
>>>>>>>
>>>>>>> ___
>>>>>>> Dev mailing list
>>>>>>> Dev@wso2.org
>>>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Chehara Pathmabandu
>>>>>> *Software Engineer - Intern*
>>>>>> Mobile : +94711976407
>>>>>> cheh...@wso2.com
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> *Niranda Perera*
>>>>> Software Engineer, WSO2 Inc.
>>>>> Mobile: +94-71-554-8430
>>>>> Twitter: @n1r44 <https://twitter.com/N1R44>
>>>>> https://pythagoreanscript.wordpress.com/
>>>>>
>>>>> ___
>>>>> Dev mailing list
>>>>> Dev@wso2.org
>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>>
>>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> *V. Mohanadarshan*
> *Senior Software Engineer,*
> *Data Technologies Team,*
> *WSO2, Inc. http://wso2.com <http://wso2.com> *
> *lean.enterprise.middleware.*
>
> email: mo...@wso2.com
> phone:(+94) 771117673
>



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


Re: [Dev] US Election Analytics - Data won't persist in DAS

2016-04-02 Thread Udara Rathnayake
Sure Niranda, Let me know whether I have to report this in CEP or DAS?

On Sat, Apr 2, 2016 at 12:21 PM, Niranda Perera <nira...@wso2.com> wrote:

> Hi Udara,
>
> Ah. Never came across it but yes, you are correct. This seems to be a UI
> bug.
>
> Can you report a JIRA in this?
>
> Rgds
> On Apr 2, 2016 21:45, "Udara Rathnayake" <uda...@wso2.com> wrote:
>
>> Hi Niranda,
>>
>> ​If we edit and save an existing stream definition (without going to the
>> persistence UI)​ this can happen right? I have faced similar thing but
>> never tried reproducing.
>>
>> However we should bring tooling support(dev studio) ASAP to DAS
>> artifacts, so we can create and deploy via car apps easily.
>>
>>
>> On Fri, Apr 1, 2016 at 11:32 AM, Niranda Perera <nira...@wso2.com> wrote:
>>
>>> Hi Chehara,
>>>
>>> It's highly unlikely that a stream persistence configuration to get
>>> disabled automatically. Looks like someone have mistakenly disabled it from
>>> the UI. As per the current persistence UI, there is a possibility that such
>>> an incident may occur.
>>>
>>>
>>> On Fri, Apr 1, 2016 at 8:43 PM, Chehara Pathmabandu <cheh...@wso2.com>
>>> wrote:
>>>
>>>> Hi,
>>>>
>>>> Solved. event persistent had been disabled automatically.
>>>>
>>>> On Fri, Apr 1, 2016 at 8:16 PM, Niranda Perera <nira...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi Yasara,
>>>>>
>>>>> We need to find where exactly the data stopped persisting. can you
>>>>> find the final entry? Are there any error in the logs?
>>>>>
>>>>> also, we need to check the mysql connections. Check if it has grown
>>>>> out of proportion as previously.
>>>>> And the CPU and memory usage of the node.
>>>>>
>>>>> On Fri, Apr 1, 2016 at 7:37 PM, Mohanadarshan Vivekanandalingam <
>>>>> mo...@wso2.com> wrote:
>>>>>
>>>>>> [Adding Dev mail thread]
>>>>>>
>>>>>> @Niranda, can you please dig on this issue and find the root cause..
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Fri, Apr 1, 2016 at 7:26 PM, Yasara Dissanayake <yas...@wso2.com>
>>>>>> wrote:
>>>>>>
>>>>>>> Hi,
>>>>>>>
>>>>>>> As you can see from the image attached here[1]:
>>>>>>> Current status is growing as the data receive and we use this same
>>>>>>> stream to persist. But from a particular date data had not been 
>>>>>>> persisted.
>>>>>>>
>>>>>>> regards,
>>>>>>> yasara
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> *V. Mohanadarshan*
>>>>>> *Senior Software Engineer,*
>>>>>> *Data Technologies Team,*
>>>>>> *WSO2, Inc. http://wso2.com <http://wso2.com> *
>>>>>> *lean.enterprise.middleware.*
>>>>>>
>>>>>> email: mo...@wso2.com
>>>>>> phone:(+94) 771117673
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> *Niranda Perera*
>>>>> Software Engineer, WSO2 Inc.
>>>>> Mobile: +94-71-554-8430
>>>>> Twitter: @n1r44 <https://twitter.com/N1R44>
>>>>> https://pythagoreanscript.wordpress.com/
>>>>>
>>>>> ___
>>>>> Dev mailing list
>>>>> Dev@wso2.org
>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Chehara Pathmabandu
>>>> *Software Engineer - Intern*
>>>> Mobile : +94711976407
>>>> cheh...@wso2.com
>>>>
>>>
>>>
>>>
>>> --
>>> *Niranda Perera*
>>> Software Engineer, WSO2 Inc.
>>> Mobile: +94-71-554-8430
>>> Twitter: @n1r44 <https://twitter.com/N1R44>
>>> https://pythagoreanscript.wordpress.com/
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>


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


Re: [Dev] US Election Analytics - Data won't persist in DAS

2016-04-02 Thread Udara Rathnayake
Hi Niranda,

​If we edit and save an existing stream definition (without going to the
persistence UI)​ this can happen right? I have faced similar thing but
never tried reproducing.

However we should bring tooling support(dev studio) ASAP to DAS artifacts,
so we can create and deploy via car apps easily.


On Fri, Apr 1, 2016 at 11:32 AM, Niranda Perera  wrote:

> Hi Chehara,
>
> It's highly unlikely that a stream persistence configuration to get
> disabled automatically. Looks like someone have mistakenly disabled it from
> the UI. As per the current persistence UI, there is a possibility that such
> an incident may occur.
>
>
> On Fri, Apr 1, 2016 at 8:43 PM, Chehara Pathmabandu 
> wrote:
>
>> Hi,
>>
>> Solved. event persistent had been disabled automatically.
>>
>> On Fri, Apr 1, 2016 at 8:16 PM, Niranda Perera  wrote:
>>
>>> Hi Yasara,
>>>
>>> We need to find where exactly the data stopped persisting. can you find
>>> the final entry? Are there any error in the logs?
>>>
>>> also, we need to check the mysql connections. Check if it has grown out
>>> of proportion as previously.
>>> And the CPU and memory usage of the node.
>>>
>>> On Fri, Apr 1, 2016 at 7:37 PM, Mohanadarshan Vivekanandalingam <
>>> mo...@wso2.com> wrote:
>>>
 [Adding Dev mail thread]

 @Niranda, can you please dig on this issue and find the root cause..



 On Fri, Apr 1, 2016 at 7:26 PM, Yasara Dissanayake 
 wrote:

> Hi,
>
> As you can see from the image attached here[1]:
> Current status is growing as the data receive and we use this same
> stream to persist. But from a particular date data had not been persisted.
>
> regards,
> yasara
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>


 --
 *V. Mohanadarshan*
 *Senior Software Engineer,*
 *Data Technologies Team,*
 *WSO2, Inc. http://wso2.com  *
 *lean.enterprise.middleware.*

 email: mo...@wso2.com
 phone:(+94) 771117673

>>>
>>>
>>>
>>> --
>>> *Niranda Perera*
>>> Software Engineer, WSO2 Inc.
>>> Mobile: +94-71-554-8430
>>> Twitter: @n1r44 
>>> https://pythagoreanscript.wordpress.com/
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Chehara Pathmabandu
>> *Software Engineer - Intern*
>> Mobile : +94711976407
>> cheh...@wso2.com
>>
>
>
>
> --
> *Niranda Perera*
> Software Engineer, WSO2 Inc.
> Mobile: +94-71-554-8430
> Twitter: @n1r44 
> https://pythagoreanscript.wordpress.com/
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] [VizGrammar] Making multi-line chart x axis a timeline

2016-03-19 Thread Udara Rathnayake
attaching sample chart again


​

On Sun, Mar 20, 2016 at 12:34 AM, Udara Rathnayake <uda...@wso2.com> wrote:

> Hi All,
>
> I'm trying to create a multi-line chart using VizGrammar. I need to make
> my x-axis a timeline.
>
> But when I try to provide the date(2016-03-20) as the first argument to
> lineChart.insert() noticed following error.
>
> Uncaught Error: Pulse already has a non-zero stamp.
>>
> ​Then provided date in 20160320 format. This works, but while rendering
> the gadget this appears in 20,160,320 format.​
>
> My goal is to create something similar to the following line chat.
>
>
> ​
> Assume I have a data-set similar to the following,
>
>
> ​
>
> Appreciate any help.​
>
>
> --
> Regards,
> UdaraR
>



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


[Dev] Create a new API version in ESB

2016-03-19 Thread Udara Rathnayake
Hi,

I tried creating a new version of an existing API, just by updating the
context as explained here[1]. API name untouched. Seems this is not
possible[2].

Is there any other way to overcome this while preserving the previous
version?

[1]  https://docs.wso2.com/display/ESB481/Creating+APIs
[2]
*​TID: [0] [ESB] [2016-03-16 15:01:01,309] ERROR
{org.wso2.carbon.rest.api.service.RestApiAdmin} -  Error trying to add the
API to the ESB configuration : notificationAPI:: Duplicate resource
definition by the name: *











*notificationAPI{org.wso2.carbon.rest.api.service.RestApiAdmin}org.apache.synapse.SynapseException:
Duplicate resource definition by the name: CNEADHOCESB2QAPI2at
org.apache.synapse.config.SynapseConfiguration.handleException(SynapseConfiguration.java:1515)
at
org.apache.synapse.config.SynapseConfiguration.addAPI(SynapseConfiguration.java:351)
at
org.wso2.carbon.rest.api.service.RestApiAdmin.addApi(RestApiAdmin.java:640)
at
org.wso2.carbon.rest.api.service.RestApiAdmin.addApiFromString(RestApiAdmin.java:77)
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)​

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


Re: [Dev] Create a new API version in ESB

2016-03-19 Thread Udara Rathnayake
Hi Chanaka,

Thanks for the response.

So we need to have different names right(API1 and API2)?
I'm trying to create an API with the same name but with a different version.


On Wed, Mar 16, 2016 at 9:48 PM, Chanaka Fernando <chana...@wso2.com> wrote:

> Hi Udara,
>
> You need to append the version to your API context as mentioned below.
>
> API1 context - /test/1.0.0
>
> API2 context - /test/1.0.1
>
> Here is a sample configuration.
>
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
>     
> 
> 
>
>
>
> On Thu, Mar 17, 2016 at 12:47 AM, Udara Rathnayake <uda...@wso2.com>
> wrote:
>
>> Hi,
>>
>> I tried creating a new version of an existing API, just by updating the
>> context as explained here[1]. API name untouched. Seems this is not
>> possible[2].
>>
>> Is there any other way to overcome this while preserving the previous
>> version?
>>
>> [1]  https://docs.wso2.com/display/ESB481/Creating+APIs
>> [2]
>> *​TID: [0] [ESB] [2016-03-16 15:01:01,309] ERROR
>> {org.wso2.carbon.rest.api.service.RestApiAdmin} -  Error trying to add the
>> API to the ESB configuration : notificationAPI:: Duplicate resource
>> definition by the name: *
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> *notificationAPI{org.wso2.carbon.rest.api.service.RestApiAdmin}org.apache.synapse.SynapseException:
>> Duplicate resource definition by the name: CNEADHOCESB2QAPI2at
>> org.apache.synapse.config.SynapseConfiguration.handleException(SynapseConfiguration.java:1515)
>> at
>> org.apache.synapse.config.SynapseConfiguration.addAPI(SynapseConfiguration.java:351)
>> at
>> org.wso2.carbon.rest.api.service.RestApiAdmin.addApi(RestApiAdmin.java:640)
>> at
>> org.wso2.carbon.rest.api.service.RestApiAdmin.addApiFromString(RestApiAdmin.java:77)
>> 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)​
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
> Thank you and Best Regards,
> Chanaka Fernando
> Senior Technical Lead
> WSO2, Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: +94 773337238
> Blog : http://soatutorials.blogspot.com
> LinkedIn:http://www.linkedin.com/pub/chanaka-fernando/19/a20/5b0
> Twitter:https://twitter.com/chanakaudaya
>
>
>
>
>


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


Re: [Dev] DS server cannot publish data on gadget loads using PubSub functionality

2016-03-08 Thread Udara Rathnayake
On Tue, Mar 8, 2016 at 7:33 PM, Dilan Udara Ariyaratne <dil...@wso2.com>
wrote:

> Hi Damith,
>
> How about using the jquery ready() function, so that you can make sure the
> function runs
> just after DOM (document object model) has been fully loaded?
>
> For ex: see the following code snippet.
>
> var TOPIC = "publisher";
> var count = 1;
>
> function cb(start, end) {
> if (count != 0) {
> var message = {
> timeFrom: new Date(start).getTime(),
> timeTo: new Date(end).getTime()
> };
> console.log(message);
> gadgets.Hub.publish(TOPIC, message);
> }
> count++;
> }
>
>
> ​​
> ​​
> $(document).ready(function () {
> cb(moment().subtract(29, 'days'), moment());
> });
>
​*$(function() { })* this is the shorthand version of​

​​
*$(document).ready*, So I don't see any difference here.

>
>
> Cheers,
> Dilan.
>
>
>
> *Dilan U. Ariyaratne*
> Software Engineer
> WSO2 Inc. <http://wso2.com/>
> Mobile: +94725197942
> lean . enterprise . middleware
>
> On Tue, Mar 8, 2016 at 10:03 PM, Damith Wickramasinghe <dami...@wso2.com>
> wrote:
>
>> HI Udara,
>>
>> Thanks for the response. Set time out works but is it a good approach
>> since the time can be vary.
>>
>> Regards,
>> Damith.
>>
>> On Tue, Mar 8, 2016 at 8:12 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>>
>>> cay you try,
>>>
>>> setTimeout(function (){
>>> cb(moment().subtract(29, 'days'), moment());
>>>  }, 3000);
>>>
>>>
>>> On Tue, Mar 8, 2016 at 9:32 AM, Damith Wickramasinghe <dami...@wso2.com>
>>> wrote:
>>>
>>>> Hi,
>>>>
>>>> I have a requirement of  publishing data on load of publisher gadget. I
>>>> have following script
>>>>
>>>> $(function () {
>>>>
>>>> var TOPIC = "publisher";
>>>>
>>>> var count = 1;
>>>>
>>>> cb(moment().subtract(29, 'days'), moment());
>>>>
>>>> function cb(start, end) {
>>>> if (count != 0) {
>>>> var message = {
>>>> timeFrom: new Date(start).getTime(),
>>>> timeTo: new Date(end).getTime()
>>>> };
>>>> console.log(message);
>>>> gadgets.Hub.publish(TOPIC, message);
>>>> }
>>>> count++;
>>>> }
>>>>
>>>> });
>>>>
>>>>
>>>> As you can see I'm calling cb(moment().subtract(29, 'days'), moment());
>>>> which will publish that data. If I comment above line and call the function
>>>> when a button click then publisher works. It seems publisher functionality
>>>> is not available or gadget is not properly loaded if we call as above. Am I
>>>> missing something here ? or is there a better way to achieve this ?
>>>>
>>>> Thanks,
>>>> Damith.
>>>>
>>>>
>>>> --
>>>> Software Engineer
>>>> WSO2 Inc.; http://wso2.com
>>>> <http://www.google.com/url?q=http%3A%2F%2Fwso2.com=D=1=AFQjCNEZvyc0uMD1HhBaEGCBxs6e9fBObg>
>>>> lean.enterprise.middleware
>>>>
>>>> mobile: *+94728671315 <%2B94728671315>*
>>>>
>>>>
>>>> ___
>>>> Dev mailing list
>>>> Dev@wso2.org
>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>
>>>>
>>>
>>>
>>> --
>>> Regards,
>>> UdaraR
>>>
>>
>>
>>
>> --
>> Software Engineer
>> WSO2 Inc.; http://wso2.com
>> <http://www.google.com/url?q=http%3A%2F%2Fwso2.com=D=1=AFQjCNEZvyc0uMD1HhBaEGCBxs6e9fBObg>
>> lean.enterprise.middleware
>>
>> mobile: *+94728671315 <%2B94728671315>*
>>
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>


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


Re: [Dev] DS server cannot publish data on gadget loads using PubSub functionality

2016-03-08 Thread Udara Rathnayake
cay you try,

setTimeout(function (){
cb(moment().subtract(29, 'days'), moment());
 }, 3000);


On Tue, Mar 8, 2016 at 9:32 AM, Damith Wickramasinghe 
wrote:

> Hi,
>
> I have a requirement of  publishing data on load of publisher gadget. I
> have following script
>
> $(function () {
>
> var TOPIC = "publisher";
>
> var count = 1;
>
> cb(moment().subtract(29, 'days'), moment());
>
> function cb(start, end) {
> if (count != 0) {
> var message = {
> timeFrom: new Date(start).getTime(),
> timeTo: new Date(end).getTime()
> };
> console.log(message);
> gadgets.Hub.publish(TOPIC, message);
> }
> count++;
> }
>
> });
>
>
> As you can see I'm calling cb(moment().subtract(29, 'days'), moment());
> which will publish that data. If I comment above line and call the function
> when a button click then publisher works. It seems publisher functionality
> is not available or gadget is not properly loaded if we call as above. Am I
> missing something here ? or is there a better way to achieve this ?
>
> Thanks,
> Damith.
>
>
> --
> Software Engineer
> WSO2 Inc.; http://wso2.com
> 
> lean.enterprise.middleware
>
> mobile: *+94728671315 <%2B94728671315>*
>
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] [DAS] Error in clearing index data: Unable to delete directory

2016-03-08 Thread Udara Rathnayake
Hi Niranda,

Untouched, using default H2.

Thanks!

On Tue, Mar 8, 2016 at 1:39 AM, Niranda Perera <nira...@wso2.com> wrote:

> Hi Udara,
>
> what are the datasources you are using here? RDBMS?
>
> best
>
> On Tue, Mar 8, 2016 at 1:56 AM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> noticed same after ~20 mins..
>>
>> On Mon, Mar 7, 2016 at 3:10 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>>
>>> Hi,
>>>
>>> Noticed following error[1] while running DAS 3.0.1 on a windows
>>> environment.
>>> After a server restart, I don't see this now. What can be the cause?
>>>
>>> [1].
>>>
>>> [2016-03-07 14:48:01,456] ERROR
>>> {org.wso2.carbon.analytics.spark.core.sources.A
>>> alyticsRelation} -  Error while inserting data into table daily_sessions
>>> : Error
>>>  in clearing index data: Unable to delete directory
>>> C:\Users\URATHN~1\WORKSP~1\
>>>
>>> AS\dev\WSO2DA~1.1\WSO2DA~1.1\bin\..\repository\data\index_data\5\_data\taxonomy
>>> -1234_daily_sessions.
>>>
>>> org.wso2.carbon.analytics.dataservice.commons.exception.AnalyticsIndexException
>>>  Error in clearing index data: Unable to delete directory
>>> C:\Users\URATHN~1\WOR
>>>
>>> SP~1\DAS\dev\WSO2DA~1.1\WSO2DA~1.1\bin\..\repository\data\index_data\5\_data\ta
>>> onomy\-1234_daily_sessions.
>>> at
>>> org.wso2.carbon.analytics.dataservice.core.indexing.AnalyticsDataInd
>>> xer.clearIndexDataLocal(AnalyticsDataIndexer.java:1461)
>>> at
>>> org.wso2.carbon.analytics.dataservice.core.indexing.IndexNodeCoordin
>>> tor.clearIndexData(IndexNodeCoordinator.java:681)
>>> at
>>> org.wso2.carbon.analytics.dataservice.core.indexing.AnalyticsDataInd
>>> xer.clearIndexData(AnalyticsDataIndexer.java:1440)
>>> at
>>> org.wso2.carbon.analytics.dataservice.core.AnalyticsDataServiceImpl.
>>> learIndices(AnalyticsDataServiceImpl.java:889)
>>> at
>>> org.wso2.carbon.analytics.dataservice.core.AnalyticsDataServiceImpl.
>>> eleteTable(AnalyticsDataServiceImpl.java:541)
>>> at
>>> org.wso2.carbon.analytics.spark.core.sources.AnalyticsRelation.inser
>>> (AnalyticsRelation.java:157)
>>> at
>>> org.apache.spark.sql.sources.InsertIntoDataSource.run(commands.scala
>>> 53)
>>> at
>>> org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult$lzyc
>>> mpute(commands.scala:57)
>>> at
>>> org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult(comm
>>> nds.scala:57)
>>> at org.apache.spark.sql.execution.ExecutedCommand.doExecute(
>>> commands.sc
>>> la:68)
>>> at
>>> org.apache.spark.sql.execution.SparkPlan$$anonfun$execute$1.apply(Sp
>>> rkPlan.scala:88)
>>> at
>>> org.apache.spark.sql.execution.SparkPlan$$anonfun$execute$1.apply(Sp
>>> rkPlan.scala:88)
>>> at
>>> org.apache.spark.rdd.RDDOperationScope$.withScope(RDDOperationScope.
>>> cala:147)
>>> at
>>> org.apache.spark.sql.execution.SparkPlan.execute(SparkPlan.scala:87)
>>> at
>>> org.apache.spark.sql.SQLContext$QueryExecution.toRdd$lzycompute(SQLC
>>> ntext.scala:950)
>>> at
>>> org.apache.spark.sql.SQLContext$QueryExecution.toRdd(SQLContext.scal
>>> :950)
>>> at org.apache.spark.sql.DataFrame.(DataFrame.scala:144)
>>> at org.apache.spark.sql.DataFrame.(DataFrame.scala:128)
>>> at org.apache.spark.sql.DataFrame$.apply(DataFrame.scala:51)
>>> at org.apache.spark.sql.SQLContext.sql(SQLContext.scala:755)
>>> at
>>> org.wso2.carbon.analytics.spark.core.internal.SparkAnalyticsExecutor
>>> executeQueryLocal(SparkAnalyticsExecutor.java:731)
>>> at
>>> org.wso2.carbon.analytics.spark.core.internal.SparkAnalyticsExecutor
>>> executeQuery(SparkAnalyticsExecutor.java:709)
>>> at
>>> org.wso2.carbon.analytics.spark.core.CarbonAnalyticsProcessorService
>>> executeQuery(CarbonAnalyticsProcessorService.java:201)
>>> at
>>> org.wso2.carbon.analytics.spark.core.CarbonAnalyticsProcessorService
>>> executeScript(CarbonAnalyticsProcessorService.java:151)
>>> at
>>> org.wso2.carbon.analytics.spark.core.AnalyticsTask.execute(Analytics
>>> ask.java:59)
>>> at
>

Re: [Dev] [DAS] Error in clearing index data: Unable to delete directory

2016-03-07 Thread Udara Rathnayake
noticed same after ~20 mins..

On Mon, Mar 7, 2016 at 3:10 PM, Udara Rathnayake <uda...@wso2.com> wrote:

> Hi,
>
> Noticed following error[1] while running DAS 3.0.1 on a windows
> environment.
> After a server restart, I don't see this now. What can be the cause?
>
> [1].
>
> [2016-03-07 14:48:01,456] ERROR
> {org.wso2.carbon.analytics.spark.core.sources.A
> alyticsRelation} -  Error while inserting data into table daily_sessions :
> Error
>  in clearing index data: Unable to delete directory
> C:\Users\URATHN~1\WORKSP~1\
>
> AS\dev\WSO2DA~1.1\WSO2DA~1.1\bin\..\repository\data\index_data\5\_data\taxonomy
> -1234_daily_sessions.
>
> org.wso2.carbon.analytics.dataservice.commons.exception.AnalyticsIndexException
>  Error in clearing index data: Unable to delete directory
> C:\Users\URATHN~1\WOR
>
> SP~1\DAS\dev\WSO2DA~1.1\WSO2DA~1.1\bin\..\repository\data\index_data\5\_data\ta
> onomy\-1234_daily_sessions.
> at
> org.wso2.carbon.analytics.dataservice.core.indexing.AnalyticsDataInd
> xer.clearIndexDataLocal(AnalyticsDataIndexer.java:1461)
> at
> org.wso2.carbon.analytics.dataservice.core.indexing.IndexNodeCoordin
> tor.clearIndexData(IndexNodeCoordinator.java:681)
> at
> org.wso2.carbon.analytics.dataservice.core.indexing.AnalyticsDataInd
> xer.clearIndexData(AnalyticsDataIndexer.java:1440)
> at
> org.wso2.carbon.analytics.dataservice.core.AnalyticsDataServiceImpl.
> learIndices(AnalyticsDataServiceImpl.java:889)
> at
> org.wso2.carbon.analytics.dataservice.core.AnalyticsDataServiceImpl.
> eleteTable(AnalyticsDataServiceImpl.java:541)
> at
> org.wso2.carbon.analytics.spark.core.sources.AnalyticsRelation.inser
> (AnalyticsRelation.java:157)
> at
> org.apache.spark.sql.sources.InsertIntoDataSource.run(commands.scala
> 53)
> at
> org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult$lzyc
> mpute(commands.scala:57)
> at
> org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult(comm
> nds.scala:57)
> at org.apache.spark.sql.execution.ExecutedCommand.doExecute(
> commands.sc
> la:68)
> at
> org.apache.spark.sql.execution.SparkPlan$$anonfun$execute$1.apply(Sp
> rkPlan.scala:88)
> at
> org.apache.spark.sql.execution.SparkPlan$$anonfun$execute$1.apply(Sp
> rkPlan.scala:88)
> at
> org.apache.spark.rdd.RDDOperationScope$.withScope(RDDOperationScope.
> cala:147)
> at
> org.apache.spark.sql.execution.SparkPlan.execute(SparkPlan.scala:87)
> at
> org.apache.spark.sql.SQLContext$QueryExecution.toRdd$lzycompute(SQLC
> ntext.scala:950)
> at
> org.apache.spark.sql.SQLContext$QueryExecution.toRdd(SQLContext.scal
> :950)
> at org.apache.spark.sql.DataFrame.(DataFrame.scala:144)
> at org.apache.spark.sql.DataFrame.(DataFrame.scala:128)
> at org.apache.spark.sql.DataFrame$.apply(DataFrame.scala:51)
> at org.apache.spark.sql.SQLContext.sql(SQLContext.scala:755)
> at
> org.wso2.carbon.analytics.spark.core.internal.SparkAnalyticsExecutor
> executeQueryLocal(SparkAnalyticsExecutor.java:731)
> at
> org.wso2.carbon.analytics.spark.core.internal.SparkAnalyticsExecutor
> executeQuery(SparkAnalyticsExecutor.java:709)
> at
> org.wso2.carbon.analytics.spark.core.CarbonAnalyticsProcessorService
> executeQuery(CarbonAnalyticsProcessorService.java:201)
> at
> org.wso2.carbon.analytics.spark.core.CarbonAnalyticsProcessorService
> executeScript(CarbonAnalyticsProcessorService.java:151)
> at
> org.wso2.carbon.analytics.spark.core.AnalyticsTask.execute(Analytics
> ask.java:59)
> at
> org.wso2.carbon.ntask.core.impl.TaskQuartzJobAdapter.execute(TaskQua
> tzJobAdapter.java:67)
> at org.quartz.core.JobRunShell.run(JobRunShell.java:213)
> at
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:4
> 1)
> at java.util.concurrent.FutureTask.run(FutureTask.java:262)
> at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor
> java:1145)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecuto
> .java:615)
> at java.lang.Thread.run(Thread.java:745)
> Caused by: java.io.IOException: Unable to delete directory
> C:\Users\URATHN~1\WO
>
> KSP~1\DAS\dev\WSO2DA~1.1\WSO2DA~1.1\bin\..\repository\data\index_data\5\_data\t
> xonomy\-1234_daily_sessions.
> at
> org.apache.commons.io.FileUtils.deleteDirectory(FileUtils.java:1541)
> at
> org.wso2.carbon.analytics.dataservice.core.indexing.AnalyticsDataInd
> xer.clearIndexDataLocal(AnalyticsDataIndexer.java:1457)
> ... 31 more
>
>


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


[Dev] [DAS] Error in clearing index data: Unable to delete directory

2016-03-07 Thread Udara Rathnayake
Hi,

Noticed following error[1] while running DAS 3.0.1 on a windows environment.
After a server restart, I don't see this now. What can be the cause?

[1].

[2016-03-07 14:48:01,456] ERROR
{org.wso2.carbon.analytics.spark.core.sources.A
alyticsRelation} -  Error while inserting data into table daily_sessions :
Error
 in clearing index data: Unable to delete directory
C:\Users\URATHN~1\WORKSP~1\
AS\dev\WSO2DA~1.1\WSO2DA~1.1\bin\..\repository\data\index_data\5\_data\taxonomy
-1234_daily_sessions.
org.wso2.carbon.analytics.dataservice.commons.exception.AnalyticsIndexException
 Error in clearing index data: Unable to delete directory
C:\Users\URATHN~1\WOR
SP~1\DAS\dev\WSO2DA~1.1\WSO2DA~1.1\bin\..\repository\data\index_data\5\_data\ta
onomy\-1234_daily_sessions.
at
org.wso2.carbon.analytics.dataservice.core.indexing.AnalyticsDataInd
xer.clearIndexDataLocal(AnalyticsDataIndexer.java:1461)
at
org.wso2.carbon.analytics.dataservice.core.indexing.IndexNodeCoordin
tor.clearIndexData(IndexNodeCoordinator.java:681)
at
org.wso2.carbon.analytics.dataservice.core.indexing.AnalyticsDataInd
xer.clearIndexData(AnalyticsDataIndexer.java:1440)
at
org.wso2.carbon.analytics.dataservice.core.AnalyticsDataServiceImpl.
learIndices(AnalyticsDataServiceImpl.java:889)
at
org.wso2.carbon.analytics.dataservice.core.AnalyticsDataServiceImpl.
eleteTable(AnalyticsDataServiceImpl.java:541)
at
org.wso2.carbon.analytics.spark.core.sources.AnalyticsRelation.inser
(AnalyticsRelation.java:157)
at
org.apache.spark.sql.sources.InsertIntoDataSource.run(commands.scala
53)
at
org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult$lzyc
mpute(commands.scala:57)
at
org.apache.spark.sql.execution.ExecutedCommand.sideEffectResult(comm
nds.scala:57)
at org.apache.spark.sql.execution.ExecutedCommand.doExecute(
commands.sc
la:68)
at
org.apache.spark.sql.execution.SparkPlan$$anonfun$execute$1.apply(Sp
rkPlan.scala:88)
at
org.apache.spark.sql.execution.SparkPlan$$anonfun$execute$1.apply(Sp
rkPlan.scala:88)
at
org.apache.spark.rdd.RDDOperationScope$.withScope(RDDOperationScope.
cala:147)
at
org.apache.spark.sql.execution.SparkPlan.execute(SparkPlan.scala:87)
at
org.apache.spark.sql.SQLContext$QueryExecution.toRdd$lzycompute(SQLC
ntext.scala:950)
at
org.apache.spark.sql.SQLContext$QueryExecution.toRdd(SQLContext.scal
:950)
at org.apache.spark.sql.DataFrame.(DataFrame.scala:144)
at org.apache.spark.sql.DataFrame.(DataFrame.scala:128)
at org.apache.spark.sql.DataFrame$.apply(DataFrame.scala:51)
at org.apache.spark.sql.SQLContext.sql(SQLContext.scala:755)
at
org.wso2.carbon.analytics.spark.core.internal.SparkAnalyticsExecutor
executeQueryLocal(SparkAnalyticsExecutor.java:731)
at
org.wso2.carbon.analytics.spark.core.internal.SparkAnalyticsExecutor
executeQuery(SparkAnalyticsExecutor.java:709)
at
org.wso2.carbon.analytics.spark.core.CarbonAnalyticsProcessorService
executeQuery(CarbonAnalyticsProcessorService.java:201)
at
org.wso2.carbon.analytics.spark.core.CarbonAnalyticsProcessorService
executeScript(CarbonAnalyticsProcessorService.java:151)
at
org.wso2.carbon.analytics.spark.core.AnalyticsTask.execute(Analytics
ask.java:59)
at
org.wso2.carbon.ntask.core.impl.TaskQuartzJobAdapter.execute(TaskQua
tzJobAdapter.java:67)
at org.quartz.core.JobRunShell.run(JobRunShell.java:213)
at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:4
1)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor
java:1145)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecuto
.java:615)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.io.IOException: Unable to delete directory
C:\Users\URATHN~1\WO
KSP~1\DAS\dev\WSO2DA~1.1\WSO2DA~1.1\bin\..\repository\data\index_data\5\_data\t
xonomy\-1234_daily_sessions.
at
org.apache.commons.io.FileUtils.deleteDirectory(FileUtils.java:1541)
at
org.wso2.carbon.analytics.dataservice.core.indexing.AnalyticsDataInd
xer.clearIndexDataLocal(AnalyticsDataIndexer.java:1457)
... 31 more
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DAS-3.0.1] Getting Table "METRIC_GAUGE" not found periodically

2016-03-04 Thread Udara Rathnayake
> org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:620)
> at
> org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:197)
> at
> org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:343)
> at
> org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222)
> at
> org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
> at
> org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
> at
> org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
> at
> org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
> at
> org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
> at
> org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
> at
> org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
> at
> org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
> at
> org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
> at
> org.eclipse.equinox.http.servlet.internal.Activator.registerHttpService(Activator.java:81)
> at
> org.eclipse.equinox.http.servlet.internal.Activator.addProxyServlet(Activator.java:60)
> at
> org.eclipse.equinox.http.servlet.internal.ProxyServlet.init(ProxyServlet.java:40)
> at
> org.wso2.carbon.tomcat.ext.servlet.DelegationServlet.init(DelegationServlet.java:38)
> at
> org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1284)
> at
> org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1197)
> at
> org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1087)
> at
> org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5262)
> at
> org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5550)
> at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
> at
> org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1575)
> at
> org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1565)
> at java.util.concurrent.FutureTask.run(FutureTask.java:266)
> at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> at java.lang.Thread.run(Thread.java:745)
> Caused by: java.io.FileNotFoundException:
> /home/isuru/temp/metrics-test/wso2das-3.0.1/dbscripts/identity/h2.sql (No
> such file or directory)
> at java.io.FileInputStream.open0(Native Method)
> at java.io.FileInputStream.open(FileInputStream.java:195)
> at java.io.FileInputStream.(FileInputStream.java:138)
> at java.io.FileInputStream.(FileInputStream.java:93)
> at
> org.wso2.carbon.identity.core.persistence.IdentityDBInitializer.executeSQLScript(IdentityDBInitializer.java:235)
> ... 63 more
>
>
>
>
> On Fri, Mar 4, 2016 at 2:21 AM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi,
>>
>> Noticed following[1](DAS-3.0.1 with default H2 DB). As I noticed same
>> getting printed time to time even without any user interaction with DAS. Is
>> this something to do with the -Dsetup start after removing
>> wso2das-3.0.1/repository/database/*.
>>
>> WSO2METRICS_DB.h2.db exists within the database directory, but I don't
>> see any tables inside, when I browse it using H2 console.
>>
>> I have manually executed metrics h2 db script to get rid of this.
>> Any idea?
>>
>> [1]
>> [2016-03-03 14:40:45,058] ERROR
>> {org.wso2.carbon.metrics.jdbc.reporter.JDBCRepor
>> ter} -  Error when reporting gauges
>> org.h2.jdbc.JdbcSQLException: Table "METRIC_GAUGE" not found; SQL
>> statement:
>> INSERT INTO METRIC_GAUGE (SOURCE, TIMESTAMP, NAME, VALUE) VALUES
>> (?,?,?,?) [4210
>> 2-140]
>> at
>> org.h2.message.DbException.getJdbcSQLException(DbException.java:327)
>> at org.h2.message.DbException.get(DbException.java:167)
>> at org.h2.message.DbException.get(DbException.java:144)
>> at org.h2.command.Parser.readTableOrView(Parser.java:4498)
>> at org.h2.command.Parser.readTableOrView(Parser.java:4478)
>> at org.h2.command.Parser.p

[Dev] [DAS-3.0.1] Getting Table "METRIC_GAUGE" not found periodically

2016-03-03 Thread Udara Rathnayake
Hi,

Noticed following[1](DAS-3.0.1 with default H2 DB). As I noticed same
getting printed time to time even without any user interaction with DAS. Is
this something to do with the -Dsetup start after removing
wso2das-3.0.1/repository/database/*.

WSO2METRICS_DB.h2.db exists within the database directory, but I don't see
any tables inside, when I browse it using H2 console.

I have manually executed metrics h2 db script to get rid of this.
Any idea?

[1]
[2016-03-03 14:40:45,058] ERROR
{org.wso2.carbon.metrics.jdbc.reporter.JDBCRepor
ter} -  Error when reporting gauges
org.h2.jdbc.JdbcSQLException: Table "METRIC_GAUGE" not found; SQL statement:
INSERT INTO METRIC_GAUGE (SOURCE, TIMESTAMP, NAME, VALUE) VALUES (?,?,?,?)
[4210
2-140]
at
org.h2.message.DbException.getJdbcSQLException(DbException.java:327)
at org.h2.message.DbException.get(DbException.java:167)
at org.h2.message.DbException.get(DbException.java:144)
at org.h2.command.Parser.readTableOrView(Parser.java:4498)
at org.h2.command.Parser.readTableOrView(Parser.java:4478)
at org.h2.command.Parser.parseInsert(Parser.java:910)
at org.h2.command.Parser.parsePrepared(Parser.java:362)
at org.h2.command.Parser.parse(Parser.java:275)
at org.h2.command.Parser.parse(Parser.java:247)
at org.h2.command.Parser.prepare(Parser.java:201)
at org.h2.command.Parser.prepareCommand(Parser.java:214)
at org.h2.engine.Session.prepareLocal(Session.java:434)
at org.h2.engine.Session.prepareCommand(Session.java:384)
at
org.h2.jdbc.JdbcConnection.prepareCommand(JdbcConnection.java:1071)
at
org.h2.jdbc.JdbcPreparedStatement.(JdbcPreparedStatement.java:7
1)
at
org.h2.jdbc.JdbcConnection.prepareStatement(JdbcConnection.java:234)
at sun.reflect.GeneratedMethodAccessor30.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at
org.apache.tomcat.jdbc.pool.ProxyConnection.invoke(ProxyConnection.ja
va:126)
at
org.apache.tomcat.jdbc.pool.JdbcInterceptor.invoke(JdbcInterceptor.ja
va:109)
at
org.wso2.carbon.ndatasource.rdbms.ConnectionRollbackOnReturnIntercept
or.invoke(ConnectionRollbackOnReturnInterceptor.java:51)
at
org.apache.tomcat.jdbc.pool.JdbcInterceptor.invoke(JdbcInterceptor.ja
va:109)
at
org.apache.tomcat.jdbc.pool.interceptor.AbstractCreateStatementInterc
eptor.invoke(AbstractCreateStatementInterceptor.java:67)
at
org.apache.tomcat.jdbc.pool.JdbcInterceptor.invoke(JdbcInterceptor.ja
va:109)
at
org.apache.tomcat.jdbc.pool.interceptor.ConnectionState.invoke(Connec
tionState.java:153)
at
org.apache.tomcat.jdbc.pool.JdbcInterceptor.invoke(JdbcInterceptor.ja
va:109)
at
org.apache.tomcat.jdbc.pool.TrapException.invoke(TrapException.java:4
1)
at
org.apache.tomcat.jdbc.pool.JdbcInterceptor.invoke(JdbcInterceptor.ja
va:109)
at
org.apache.tomcat.jdbc.pool.DisposableConnectionFacade.invoke(Disposa
bleConnectionFacade.java:80)
at com.sun.proxy.$Proxy16.prepareStatement(Unknown Source)
at
org.wso2.carbon.metrics.jdbc.reporter.JDBCReporter.reportGauges(JDBCR
eporter.java:212)
at
org.wso2.carbon.metrics.jdbc.reporter.JDBCReporter.report(JDBCReporte
r.java:188)
at
com.codahale.metrics.ScheduledReporter.report(ScheduledReporter.java:
162)
at
com.codahale.metrics.ScheduledReporter$1.run(ScheduledReporter.java:1
17)
at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:47
1)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304)
at
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
access$301(ScheduledThreadPoolExecutor.java:178)
at
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.
run(ScheduledThreadPoolExecutor.java:293)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.
java:1145)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
.java:615)
at java.lang.Thread.run(Thread.java:745)


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


Re: [Dev] Jaggery how to redirect the page with data(json)

2016-03-03 Thread Udara Rathnayake
On Thu, Mar 3, 2016 at 1:28 PM, SajithAR Ariyarathna 
wrote:

> Hi Iqbal,
>
> As RuwanA mentioned this is not a Jaggery or Java limitation. Simply you
> cannot do this with HTTP. However there is a hack/workaround that you can
> try.
>
> You can stringify your JSON object and send it as a query param.
>
> var payload = {name: "sajith", age: 10};
> var url = "http://example.com?payload=; + encodeURIComponent(stringify
> (payload));
> response.sendRedirect(url);
>
>
> *Disclaimer: Didn't tested.*
>
>
> Nonetheless I must say that sending payloads in redirects is not a good
> programming practice.
>
​yes.. If the payload is huge in size GET will not work.
Try to change the design. first do the POST and ​do what ever processing.
then do the redirect within a callback etc..

> Thanks.
>
> On Thu, Mar 3, 2016 at 8:31 PM, Ruwan Abeykoon  wrote:
>
>> Hi Iqbal,
>> If I understand the question correctly, this can not be done. It will be
>> in violation of HTTP spec. [1]
>>
>> [1]
>> http://programmers.stackexchange.com/questions/99894/why-doesnt-http-have-post-redirect
>>
>> Cheers,
>> Ruwan
>>
>> On Thu, Mar 3, 2016 at 6:04 PM, Nipuna Chandradasa 
>> wrote:
>>
>>> Hi,
>>>
>>> Did you try setting the content to the response as follow?
>>>
>>> response.content = { products : ["Jaggery", "ESB"] };
>>>
>>> I did not try this but this will possibly work.
>>> Please refer the jaggery doc response section for more details.
>>> Regards.
>>>
>>> On Thu, Mar 3, 2016 at 3:45 PM, Irham Iqbal  wrote:
>>>
 Hi All,

 Is there any way to redirect the page + post the data(json) from a
 plain jaggery file to another jaggery file. I tried with post and
 response.sendRedirect. with post i couldn't redirect the page i only can
 pass the data to that page.  With response.sendRedirect i can redirect the
 page couldn't send the json. Is the a way i can do this ?

 Thanks,
 Iqbal

 --
 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


>>>
>>>
>>> --
>>> Nipuna Marcus
>>> *Software Engineer*
>>> WSO2 Inc.
>>> http://wso2.com/ - "lean . enterprise . middleware"
>>> Mobile : +94 (0) 713 667906
>>> nipu...@wso2.com
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>>
>> *Ruwan Abeykoon*
>> *Architect,*
>> *WSO2, Inc. http://wso2.com  *
>> *lean.enterprise.middleware.*
>>
>> email: ruw...@wso2.com
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Sajith Ariyarathna
> Software Engineer; WSO2, Inc.;  http://wso2.com/
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] [DAS] Retrieving sorted data from queries to DAS

2016-03-01 Thread Udara Rathnayake
If it's a temporary table, you should be able to do the sorting within the
spark query.
So no need to worry about sorting at the client side.

On Mon, Feb 29, 2016 at 11:45 PM, Shabir Mohamed  wrote:

> Hi All,
>
> In the process of creating analytics gadgets for the IoT/EMM Server, I
> have a need to fetch data from DAS filtered by some query parameters (ex:
> deviceId, owner).
>
> In addition, I also have a need to sort the retrieved data based on a
> specific attribute of the event-stream. As of what I had tried so far I
> could not find any APIs provided at the DAS end to directly allow this
> capability. Hence, I have taken to doing the sorting of the retrieved data
> at my end.
>
> Is there any mechanism to achieve this from DAS itself, which I might have
> missed?
>
> Regards
> -
> *Shabir Mohamed*
> *Software Engineer*
> WSO2 Inc.; http://wso2.com
> Email: sha...@wso2.com 
> Mobile: +94 77 3516019 | +94 71 6583393
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] [VOTE] Release WSO2 Dashboard Server 2.0.0 RC2

2016-02-25 Thread Udara Rathnayake
tested dashboard creation/view flow in IE11 on win7 and Firefox/Chromium on
Linux (super tenant/tenant).
ran zap tool pointing portal app.

[+] Stable - go ahead and release.

On Wed, Feb 24, 2016 at 11:31 AM, Tanya Madurapperuma 
wrote:

> Hi Devs,
>
> This is the RC2 release candidate of WSO2 Dashboard Server 2.0.0
>
> Please download DS 2.0.0 RC2 and test the functionality and vote. Vote
> will be open for 72 hours or as needed.
>
> Source & binary distribution files:
> https://github.com/wso2/product-ds/releases/tag/v2.0.0-RC2
>
> Maven staging repo:
> http://maven.wso2.org/nexus/content/repositories/orgwso2ds-374/
>
> The tag to be voted upon:
> https://github.com/wso2/product-ds/tree/v2.0.0-RC2
>
>
> [+] Stable - go ahead and release
> [-]  Broken - do not release (explain why)
>
> Thanks and Regards,
> ~ WSO2 DS Team ~
>
> --
> Tanya Madurapperuma
>
> Senior Software Engineer,
> WSO2 Inc. : wso2.com
> Mobile : +94718184439
> Blog : http://tanyamadurapperuma.blogspot.com
>
>
>
> --
> Tanya Madurapperuma
>
> Senior Software Engineer,
> WSO2 Inc. : wso2.com
> Mobile : +94718184439
> Blog : http://tanyamadurapperuma.blogspot.com
>



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


Re: [Dev] [EMM][APPM]How to call from emm jaggery apps to publisher jaggery apps

2016-02-24 Thread Udara Rathnayake
Out of $subject, but try not to hardcode application name(eg:- publisher).
Users tend to rename applications etc.. read it from a config at least, so
we have only one place to update.

On Wed, Feb 24, 2016 at 11:04 AM, Lakshman Udayakantha 
wrote:

> Hi,
>
> I have called using below code snippet a store rest API.
>
> var serviceURL = 
> "/publisher/api/asset/get/uuid/mobileapp"+provider+"/"+name+"/"+version;
> invokerUtil.get(
> serviceURL,
> function (data) {
> console.log("call succeeded...!");
> },
> function (data) {
> console.log("error occured.!!!");
> }
> );
>
>
> This call is done in a javascript method from emm to publisher jaggery
> app. But this call will fail with 401 unauthorised error. How do I get
> authenticate this call?
>
> Thanks
> --
> Lakshman Udayakantha
> WSO2 Inc. www.wso2.com
> lean.enterprise.middleware
> Mobile: *0714388124*
>
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] [VOTE] Release WSO2 Dashboard Server 2.0.0 RC1

2016-02-22 Thread Udara Rathnayake
Hi Rajeenthini,

On Tue, Feb 23, 2016 at 12:35 AM, Rajeenthini Satkunam <rajeenth...@wso2.com
> wrote:

> Hi,
>
> I have tested following features related to  "Gadget/Wdiget Maximization"
> and "Enable gadget/widget userPref settings in view mode"
>
>- Verify an editor can maximize gadgets/widgets in the Edit mode
>- Verify an editor can maximize gadgets/widgets in the View mode
>- Verify a viewer can maximize gadgets/widgets in the dashboard
>- Verify a viewer can maximize gadgets/widgets in the dashboard in
>personalize mode
>- Verify an external viewer can maximize gadgets/widgets in the
>dashboard
>- Verify an editor can change the settings of gadgets/widgets in the
>Edit mode
>- Verify an editor can change the settings of gadgets/widgets in the
>View mode
>- Verify a viewer can change the settings of gadgets/widgets in the
>View mode
>- Verify a viewer can change the settings of gadgets/widgets in the
>"Personalize" mode
>- Verify an external viewer cannot change the settings of
>gadgets/widgets in the dashboard
>
> And also I have tested the basic features with browsers Chrome version 
> 48.0.2564.116
> (64-bit) , Firefox version 42.0 and IE 10,9,8.
> There is an issue with Browser IE version 10 and less than 10
> versions(9,8).I have created a jira[1] for that.You can find it for more
> details.
>
> [1] - https://wso2.org/jira/browse/UES-882
>

​have you tried using browser compatibility mode or on exact version?​

​At the same time can you post the browser console error

@Dakshika,
​What are the IE versions we are going to support platform wide?

>
> [+] Stable - Go ahead and release
>
>
> On Tue, Feb 23, 2016 at 9:19 AM, Lalanke Athauda <lala...@wso2.com> wrote:
>
>> Hi,
>> I have tested the following features related to "Per user dashboard
>> theming - Banners"
>>
>>- Verify the banner image can be cropped appropriately
>>- Verify a user can remove the banner once uploaded
>>- Verify an editor can view the uploaded banner
>>- Verify an uploaded banner is loaded into the anonymous view
>>- Verify the same banner is uploaded to a new page added with banner
>>layout
>>- Verify the banner is displayed in both pages when toggle between
>>the anon and default views
>>- Verify changing the banner in one page will change all the banners
>>in other pages
>>- Verify removing a banner in one page will remove all the banners in
>>other pages
>>- Verify a viewer can view a dashboard with banner
>>- Verify a viewer can personalize a dashboard with banner
>>- Verify a viewer can remove the banner after personalizing a
>>dashboard with a banner
>>- Verify an anonymous view with a banner layout can be viewed by
>>outsiders
>>- Verify an anonymous view with a banner layout can be viewed by
>>tenants in other domains
>>- Verify the view is displayed correctly when there is no banner
>>uploaded for a banner layout
>>
>> And also tested authentication with SSO and Oauth token retrieval
>> features.
>>
>> [+] Stable - Go ahead and release.
>>
>>
>> On Tue, Feb 23, 2016 at 8:04 AM, Udara Rathnayake <uda...@wso2.com>
>> wrote:
>>
>>>
>>>
>>> On Mon, Feb 22, 2016 at 7:57 AM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> tested dashboard creation flow in Firefox/Chromium on Linux (super
>>>> tenant/tenant)
>>>> ran zap tool pointing portal app
>>>>
>>> ​I have also tested SSO scenarios(portal app, dashboard) using an
>>> external IS.​
>>>
>>>
>>>>
>>>> [+] Stable- go ahead and release
>>>>
>>>> On Sat, Feb 20, 2016 at 7:51 AM, Tanya Madurapperuma <ta...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi Devs,
>>>>>
>>>>> This is the RC release candidate of WSO2 Dashboard Server 2.0.0
>>>>>
>>>>> Please download DS 2.0.0 RC1 and test the functionality and vote. Vote
>>>>> will be open for 72 hours or as needed.
>>>>>
>>>>> Source & binary distribution files:
>>>>> https://github.com/wso2/product-ds/releases/tag/v2.0.0-RC1
>>>>>
>>>>> Maven staging repo:
>>>>> http://maven.wso2.org/nexus/content/repositories/orgwso2ds-358/
>>>>>
>>>>> The tag to be voted upon:
&

Re: [Dev] [VOTE] Release WSO2 Dashboard Server 2.0.0 RC1

2016-02-22 Thread Udara Rathnayake
On Mon, Feb 22, 2016 at 7:57 AM, Udara Rathnayake <uda...@wso2.com> wrote:

> tested dashboard creation flow in Firefox/Chromium on Linux (super
> tenant/tenant)
> ran zap tool pointing portal app
>
​I have also tested SSO scenarios(portal app, dashboard) using an external
IS.​


>
> [+] Stable- go ahead and release
>
> On Sat, Feb 20, 2016 at 7:51 AM, Tanya Madurapperuma <ta...@wso2.com>
> wrote:
>
>> Hi Devs,
>>
>> This is the RC release candidate of WSO2 Dashboard Server 2.0.0
>>
>> Please download DS 2.0.0 RC1 and test the functionality and vote. Vote
>> will be open for 72 hours or as needed.
>>
>> Source & binary distribution files:
>> https://github.com/wso2/product-ds/releases/tag/v2.0.0-RC1
>>
>> Maven staging repo:
>> http://maven.wso2.org/nexus/content/repositories/orgwso2ds-358/
>>
>> The tag to be voted upon:
>> https://github.com/wso2/product-ds/tree/v2.0.0-RC1
>>
>>
>> [+] Stable - go ahead and release
>> [-]  Broken - do not release (explain why)
>>
>> Thanks and Regards,
>> ~ WSO2 DS Team ~
>>
>> --
>> Tanya Madurapperuma
>>
>> Senior Software Engineer,
>> WSO2 Inc. : wso2.com
>> Mobile : +94718184439
>> Blog : http://tanyamadurapperuma.blogspot.com
>>
>
>
>
> --
> Regards,
> UdaraR
>



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


Re: [Dev] Unable to add a spark UDF without any parameter

2016-02-22 Thread Udara Rathnayake
Hi Niranda,

Noticed same issue in DAS 3.0.1. Is this fixed now?

Thanks!

On Tue, Jan 5, 2016 at 11:12 AM, Niranda Perera <nira...@wso2.com> wrote:

> Hi Udara,
>
> Yes, this is a known issue / limitation in the current implementation. You
> would have to pass a dummy param because udf0 implementation was not
> available by the time we released.
>
> Best
> On Jan 5, 2016 21:37, "Udara Rathnayake" <uda...@wso2.com> wrote:
>
>> Hi,
>>
>> When I try to call a UDF without any parameter, getting following
>> error[1]. Let's assume my UDF is convertDate(). But if I try the same with
>> a parameter like convertDate(null) it works.
>>
>> Any Idea? Noticed that we have TimeNowUDF[2] sample, do we need to use "
>> now(null)" within a spark query?
>>
>>
>> [1]
>>
>> TID: [-1] [] [2016-01-05 10:45:51,744] ERROR
>> {org.wso2.carbon.ntask.core.impl.TaskQuartzJobAdapter} -  Error in
>> executing task:
>> org.apache.spark.sql.UDFRegistration$$anonfun$register$24$$anonfun$apply$1
>> cannot be cast to scala.Function0
>> {org.wso2.carbon.ntask.core.impl.TaskQuartzJobAdapter}
>> java.lang.ClassCastException:
>> org.apache.spark.sql.UDFRegistration$$anonfun$register$24$$anonfun$apply$1
>> cannot be cast to scala.Function0
>> at
>> org.apache.spark.sql.catalyst.expressions.ScalaUdf.(ScalaUdf.scala:61)
>> at
>> org.apache.spark.sql.UDFRegistration$$anonfun$register$24.apply(UDFRegistration.scala:408)
>> at
>> org.apache.spark.sql.UDFRegistration$$anonfun$register$24.apply(UDFRegistration.scala:408)
>> at
>> org.apache.spark.sql.catalyst.analysis.SimpleFunctionRegistry.lookupFunction(FunctionRegistry.scala:57)
>> at
>> org.apache.spark.sql.catalyst.analysis.Analyzer$ResolveFunctions$$anonfun$apply$13$$anonfun$applyOrElse$5.applyOrElse(Analyzer.scala:465)
>> at
>> org.apache.spark.sql.catalyst.analysis.Analyzer$ResolveFunctions$$anonfun$apply$13$$anonfun$applyOrElse$5.applyOrElse(Analyzer.scala:463)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$3.apply(TreeNode.scala:222)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$3.apply(TreeNode.scala:222)
>> at
>> org.apache.spark.sql.catalyst.trees.CurrentOrigin$.withOrigin(TreeNode.scala:51)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode.transformDown(TreeNode.scala:221)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$4.apply(TreeNode.scala:242)
>> at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
>> at scala.collection.Iterator$class.foreach(Iterator.scala:727)
>> at scala.collection.AbstractIterator.foreach(Iterator.scala:1157)
>> at
>> scala.collection.generic.Growable$class.$plus$plus$eq(Growable.scala:48)
>> at
>> scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:103)
>> at
>> scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:47)
>> at scala.collection.TraversableOnce$class.to
>> (TraversableOnce.scala:273)
>> at scala.collection.AbstractIterator.to(Iterator.scala:1157)
>> at
>> scala.collection.TraversableOnce$class.toBuffer(TraversableOnce.scala:265)
>> at scala.collection.AbstractIterator.toBuffer(Iterator.scala:1157)
>> at
>> scala.collection.TraversableOnce$class.toArray(TraversableOnce.scala:252)
>> at scala.collection.AbstractIterator.toArray(Iterator.scala:1157)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode.transformChildrenDown(TreeNode.scala:272)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode.transformDown(TreeNode.scala:227)
>> at org.apache.spark.sql.catalyst.plans.QueryPlan.org
>> $apache$spark$sql$catalyst$plans$QueryPlan$$transformExpressionDown$1(QueryPlan.scala:75)
>> at
>> org.apache.spark.sql.catalyst.plans.QueryPlan$$anonfun$1.apply(QueryPlan.scala:85)
>> at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
>> at scala.collection.Iterator$class.foreach(Iterator.scala:727)
>> at scala.collection.AbstractIterator.foreach(Iterator.scala:1157)
>> at
>> scala.collection.generic.Growable$class.$plus$plus$eq(Growable.scala:48)
>> at
>> scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:103)
>> at
>> scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:47)
>> at scala.collection.TraversableOnce$class.to
>> (Trav

Re: [Dev] [VOTE] Release WSO2 Dashboard Server 2.0.0 RC1

2016-02-22 Thread Udara Rathnayake
tested dashboard creation flow in Firefox/Chromium on Linux (super
tenant/tenant)
ran zap tool pointing portal app

[+] Stable- go ahead and release

On Sat, Feb 20, 2016 at 7:51 AM, Tanya Madurapperuma  wrote:

> Hi Devs,
>
> This is the RC release candidate of WSO2 Dashboard Server 2.0.0
>
> Please download DS 2.0.0 RC1 and test the functionality and vote. Vote
> will be open for 72 hours or as needed.
>
> Source & binary distribution files:
> https://github.com/wso2/product-ds/releases/tag/v2.0.0-RC1
>
> Maven staging repo:
> http://maven.wso2.org/nexus/content/repositories/orgwso2ds-358/
>
> The tag to be voted upon:
> https://github.com/wso2/product-ds/tree/v2.0.0-RC1
>
>
> [+] Stable - go ahead and release
> [-]  Broken - do not release (explain why)
>
> Thanks and Regards,
> ~ WSO2 DS Team ~
>
> --
> Tanya Madurapperuma
>
> Senior Software Engineer,
> WSO2 Inc. : wso2.com
> Mobile : +94718184439
> Blog : http://tanyamadurapperuma.blogspot.com
>



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


Re: [Dev] [IS] Failed to create database tables for registry resource store.

2016-02-16 Thread Udara Rathnayake
You should be able to update the table schema.

At the same time you don't need to get a fresh pack and start if you are
working with H2 DB.
just update relevant db script() and remove content
within /repository/database and start the pack with -Dsetup

On Tue, Feb 16, 2016 at 6:23 AM, Rajjaz Mohammed  wrote:

> Hi Godwin,
> Can't we edit the database in the middle of working? it's mean while we
> working if we need some modification.
>
> On Tue, Feb 16, 2016 at 3:51 PM, Rajjaz Mohammed  wrote:
>
>> Hi Godwin,
>> Thanks its works fine if i add the table in the fresh pack DB and start
>> the IS.
>>
>> On Tue, Feb 16, 2016 at 3:38 PM, Godwin Shrimal  wrote:
>>
>>> Hi Rajjaz,
>>>
>>> It looks H2 database is corrupted. You may need to try it with fresh
>>> pack again (If data doesn't matters) or use a recovery tool to recover the
>>> database.
>>>
>>>
>>> Thanks
>>> Godwin
>>>
>>> On Tue, Feb 16, 2016 at 3:20 PM, Rajjaz Mohammed 
>>> wrote:
>>>
 Hi All,
 i'm trying to create new table in WSO2 IS. but after create new table
 using H2 console i'm getiing below error[1]. any suggestion?.

 [1]
 [2016-02-16 15:13:25,086] FATAL
 {org.wso2.carbon.utils.dbcreator.DatabaseCreator} -  Failed to create
 database tables for registry resource store. File corrupted while reading
 record: "1037 of 805". Possible solution: use the recovery tool [90030-140]
 org.h2.jdbc.JdbcSQLException: File corrupted while reading record:
 "1037 of 805". Possible solution: use the recovery tool [90030-140]
 at
 org.h2.message.DbException.getJdbcSQLException(DbException.java:327)
 at org.h2.message.DbException.get(DbException.java:167)
 at org.h2.message.DbException.get(DbException.java:144)
 at org.h2.store.PageStore.readPage(PageStore.java:1094)
 at org.h2.store.PageStore.getPage(PageStore.java:561)
 at org.h2.index.PageDataIndex.getPage(PageDataIndex.java:218)
 at org.h2.index.PageDataIndex.(PageDataIndex.java:73)
 at org.h2.table.RegularTable.(RegularTable.java:75)
 at org.h2.store.PageStore.addMeta(PageStore.java:1443)
 at org.h2.store.PageStore.readMetaData(PageStore.java:1380)
 at org.h2.store.PageStore.recover(PageStore.java:1178)
 at org.h2.store.PageStore.openExisting(PageStore.java:317)
 at org.h2.store.PageStore.open(PageStore.java:271)
 at org.h2.engine.Database.getPageStore(Database.java:2059)
 at org.h2.engine.Database.open(Database.java:534)
 at org.h2.engine.Database.openDatabase(Database.java:207)
 at org.h2.engine.Database.(Database.java:202)
 at org.h2.engine.Engine.openSession(Engine.java:56)
 at org.h2.engine.Engine.openSession(Engine.java:146)
 at org.h2.engine.Engine.getSession(Engine.java:125)
 at org.h2.engine.Session.createSession(Session.java:122)
 at
 org.h2.engine.SessionRemote.connectEmbeddedOrServer(SessionRemote.java:241)
 at org.h2.engine.SessionRemote.createSession(SessionRemote.java:219)
 at org.h2.jdbc.JdbcConnection.(JdbcConnection.java:111)
 at org.h2.jdbc.JdbcConnection.(JdbcConnection.java:95)
 at org.h2.Driver.connect(Driver.java:73)
 at
 org.apache.tomcat.jdbc.pool.PooledConnection.connectUsingDriver(PooledConnection.java:278)
 at
 org.apache.tomcat.jdbc.pool.PooledConnection.connect(PooledConnection.java:182)
 at
 org.apache.tomcat.jdbc.pool.ConnectionPool.createConnection(ConnectionPool.java:701)
 at
 org.apache.tomcat.jdbc.pool.ConnectionPool.borrowConnection(ConnectionPool.java:635)
 at
 org.apache.tomcat.jdbc.pool.ConnectionPool.getConnection(ConnectionPool.java:188)
 at
 org.apache.tomcat.jdbc.pool.DataSourceProxy.getConnection(DataSourceProxy.java:128)
 at
 org.wso2.carbon.utils.dbcreator.DatabaseCreator.createRegistryDatabase(DatabaseCreator.java:58)
 at
 org.wso2.carbon.user.core.common.DefaultRealmService.initializeDatabase(DefaultRealmService.java:328)
 at
 org.wso2.carbon.user.core.common.DefaultRealmService.(DefaultRealmService.java:88)
 at
 org.wso2.carbon.user.core.common.DefaultRealmService.(DefaultRealmService.java:112)
 at
 org.wso2.carbon.user.core.internal.Activator.startDeploy(Activator.java:68)
 at
 org.wso2.carbon.user.core.internal.BundleCheckActivator.start(BundleCheckActivator.java:61)
 at
 org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:711)
 at java.security.AccessController.doPrivileged(Native Method)
 at
 org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:702)
 at
 org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:683)
 at
 

Re: [Dev] [DAS-3.0.0] Unable to retrieve matching records via JS API

2016-02-11 Thread Udara Rathnayake
Hi,

Another small update, We have start and count parameters within
following[1]. I think these two parameters are misleading as we are
retrieving total count(number of matching records)

curl -X POST -H "Content-Type: application/json" -H "Authorization: Basic
YWRtaW46YWRtaW4=" -v https://localhost:9443/analytics/search_count -d
'{"tableName":"ORG_WSO2_DAS_SAMPLE_SMART_HOME_DATA",
"query":"state:Texas", "start":0,
"count":3}' -k


[1]
https://docs.wso2.com/display/DAS301/Retrieving+the+Number+of+Records+Matching+the+Given+Search+Query+via+REST+API

On Sun, Dec 27, 2015 at 4:31 PM, Udara Rathnayake <uda...@wso2.com> wrote:

> Hi Team,
>
> One more thing, within the example code snippet we are not using proper
> quotation mark(U+0022). For me it looks we are using double prime
> character(U+02BA). Check the highlighted portion.
> If someone try to copy and paste the exact same, this can cause issues.
> Better if we can update this also.
>
> var queryInfo = {
> tableName : “TEST”, //table being queried
> query : "column1:value1", //lucene query to search the records
> start : 0, //starting index of the matching record set
> count : 100 //page size for pagination
> };
> client.search(queryInfo, function(data) {
>   console.log (data[“message”]);
> }, function(error) {
>   console.log(“error occured: ” + error[“message”]);
> });
> “error occured: ” + error[“message”]
>
> This anomaly exists on most of the analytic JS API docs. Sorry for the
> trouble guys.
>
> On Sun, Dec 27, 2015 at 12:17 PM, Anjana Fernando <anj...@wso2.com> wrote:
>
>> Hi Gimantha,
>>
>> I think you've access to the docs wiki. Please change it directly.
>>
>> Cheers,
>> Anjana.
>>
>> On Sun, Dec 27, 2015 at 9:47 PM, Gimantha Bandara <giman...@wso2.com>
>> wrote:
>>
>>> Hi Udara,
>>>
>>> Yes, your way of calling search API is the correct way. Documentation
>>> needs to be updated. Thank you for pointing it out.
>>>
>>> @Rukshani, can you please replace the example with the following content?
>>>
>>> var queryInfo = {
>>>
>>> tableName : “TEST”, //table being queried
>>>
>>> searchParams : {
>>>
>>> query : "column1:value1", //lucene query to search the records
>>>
>>> start : 0, //starting index of the matching record set
>>>
>>> count : 100 //page size for pagination
>>>
>>>  }
>>>
>>> };
>>>
>>>
>>> client.search(queryInfo, function(data) {
>>>
>>> console.log (data[“message”]);
>>>
>>> }, function(error) {
>>>
>>> console.log(“error occured: ” + error[“message”]);
>>>
>>> });
>>>
>>>
>>> Highlighted text is missing in the current Docs.
>>>
>>> Thanks,
>>>
>>>
>>> On Sunday, December 27, 2015, Anjana Fernando <anj...@wso2.com> wrote:
>>>
>>>> @Gimantha, please check.
>>>>
>>>> Cheers,
>>>> Anjana.
>>>>
>>>> On Sat, Dec 26, 2015 at 8:52 PM, Udara Rathnayake <uda...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> I tried following doc[1] to retrieve records using a simple lucene
>>>>> query(userId:udarakr) via JS API.But noticed an error, when I use the same
>>>>> query within data explorer it works perfectly.
>>>>>
>>>>> Then did some debugging on portal/controllers/apis/analytics.jag &
>>>>> portal/js/carbon-analytics.js,  found we are expecting queryInfo object in
>>>>> a different format than in the doc[1].
>>>>>
>>>>> portal/js/carbon-analytics.js - LINE 473
>>>>>
>>>>> this.search = function (queryInfo, callback, error) {
>>>>> jQuery.ajax({
>>>>> url: this.serverUrl + "?type=" + TYPE_SEARCH +
>>>>> "=" + queryInfo["tableName"],
>>>>> data:
>>>>> JSON.stringify(queryInfo["searchParams"]),
>>>>> type: HTTP_POST,
>>>>> success: function (data) {
>>>>> callback(data);
>>>>> },
>>>>> 

[Dev] [DAS][3.0.1] -Dsetup startup error

2016-02-11 Thread Udara Rathnayake
Hi,

I have configured a DAS 3.0.1 instance with mssql. Added registry and
usermgt datasource configurations to the master-datasources.xml and default
carbon datasource is untouched(pointing to the default h2).

Then configured analytics-datasources.xml by pointing to MSSQL DBs.

While starting DAS node with -Dsetup noticed following[1].

Then just to verify, I have started(-Dsetup) a fresh DAS pack after
clearing wso2das-3.0.1/repository/database directory. Noticed the same
error and we don't have a sql script under the highlighted directory.

Do we need to configure a separate identity DB and modify identity.xml
datasource config?


> 
> jdbc/WSO2CarbonDB
> 
>


[1]

[2016-02-11 15:40:51,306] ERROR
> {org.wso2.carbon.identity.core.internal.IdentityCoreServiceComponent} -
> Error occurred while populating identity configuration properties
> org.wso2.carbon.identity.base.IdentityRuntimeException: Error occurred
> while executing SQL script for creating identity database
> at
> org.wso2.carbon.identity.base.IdentityRuntimeException.error(IdentityRuntimeException.java:162)
> at
> org.wso2.carbon.identity.core.persistence.IdentityDBInitializer.executeSQLScript(IdentityDBInitializer.java:273)
> at
> org.wso2.carbon.identity.core.persistence.IdentityDBInitializer.createIdentityDatabase(IdentityDBInitializer.java:141)
> at
> org.wso2.carbon.identity.core.persistence.JDBCPersistenceManager.initializeDatabase(JDBCPersistenceManager.java:112)
> at
> org.wso2.carbon.identity.core.internal.IdentityCoreServiceComponent.activate(IdentityCoreServiceComponent.java:101)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:497)
> at
> org.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:260)
> at
> org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:146)
> at
> org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:345)
> at
> org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:620)
> at
> org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:197)
> at
> org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:343)
> at
> org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222)
> at
> org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107)
> at
> org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861)
> at
> org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
> at
> org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
> at
> org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819)
> at
> org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771)
> at
> org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130)
> at
> org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214)
> at
> org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433)
> at
> org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:451)
> at
> org.wso2.carbon.core.init.CarbonServerManager.initializeCarbon(CarbonServerManager.java:514)
> at
> org.wso2.carbon.core.init.CarbonServerManager.removePendingItem(CarbonServerManager.java:290)
> at
> org.wso2.carbon.core.init.PreAxis2ConfigItemListener.bundleChanged(PreAxis2ConfigItemListener.java:118)
> at
> org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:847)
> at
> org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
> at
> org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
> *Caused by: java.io.FileNotFoundException:
> /carbon/wso2/das/wso2das-3.0.1/dbscripts/identity/h2.sql* (No such file
> or directory)
> at java.io.FileInputStream.open0(Native Method)
> at java.io.FileInputStream.open(FileInputStream.java:195)
> at java.io.FileInputStream.(FileInputStream.java:138)
> at java.io.FileInputStream.(FileInputStream.java:93)
> at
> 

Re: [Dev] [DEV][DAS] How to sort data in DAS?

2016-01-08 Thread Udara Rathnayake
On Fri, Jan 8, 2016 at 7:30 PM, Udara Rathnayake <uda...@wso2.com> wrote:

> Hi Roshan,
>
> You can give - i within your schema while creating the temporary table to
> make it an indexed column.
>
> Eg:- schema "user_name INT -i, .. "
>
​This Eg is a bit confusing... so following is something which I have tried,
CREATE TEMPORARY TABLE lasthour_login_info_001 using CarbonAnalytics
options (tableName "LASTHOUR_LOGIN_INFO_001", schema "*username STRING -i*,
timestamp STRING");​


>
> https://docs.wso2.com/display/DAS300/Spark+Query+Language
>
> On Fri, Jan 8, 2016 at 7:24 PM, Roshan Wijesena <ros...@wso2.com> wrote:
>
>> Hi,
>>
>> The problem is I can not *search* sorted tempory tables because there
>> are no indexes. Is there any way to create indexes in tempory tables?
>>
>> -Roshan
>>
>> On Fri, Jan 1, 2016 at 12:12 PM, Gimantha Bandara <giman...@wso2.com>
>> wrote:
>>
>>> Hi Roshan,
>>>
>>> REST APIs do not provide a way to sort data in DAS. The only option is
>>> to use spark queries to create sorted temporary tables.
>>>
>>> On Wed, Dec 30, 2015 at 9:25 AM, Roshan Wijesena <ros...@wso2.com>
>>> wrote:
>>>
>>>> Hi Udara,
>>>>
>>>> Yes I also thought about this, the only problem is let's say we have 10
>>>> column table, and if I want to sort  columns of this table, I need to
>>>> create 20 tempory tables two temp tables per one column (ASC/DESC). BTW, I
>>>> think this is the only solution we got so far. :)
>>>>
>>>> -Roshan
>>>>
>>>>
>>>>
>>>> On Tue, Dec 29, 2015 at 9:44 PM, Udara Rathnayake <uda...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi Roshan,
>>>>>
>>>>> If you are querying a temporary table, you can initially store data
>>>>> within temporary table in the particular order. Then you don't need to
>>>>> worry about the order while querying.
>>>>> Eg:- You can have ORDER BY, DESC/ASC within your SELECT (INSERT
>>>>> INTO/OVERWRITE TABLE  **)[1]
>>>>>
>>>>> BTW I haven't tried this method, May be someone from DAS team can
>>>>> point a better solution.
>>>>>
>>>>> [1] https://docs.wso2.com/display/DAS300/Spark+Query+Language
>>>>>
>>>>> On Tue, Dec 29, 2015 at 10:22 PM, Roshan Wijesena <ros...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> Do we have a REST API for this? How could I sort a data set by
>>>>>> ascending or descending order when retrieving from the data source?
>>>>>>
>>>>>> -Roshan
>>>>>>
>>>>>> --
>>>>>> Roshan Wijesena.
>>>>>> Senior Software Engineer-WSO2 Inc.
>>>>>> Mobile: *+94719154640 <%2B94719154640>*
>>>>>> Email: ros...@wso2.com
>>>>>> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
>>>>>> lean.enterprise.middleware.
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Regards,
>>>>> UdaraR
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Roshan Wijesena.
>>>> Senior Software Engineer-WSO2 Inc.
>>>> Mobile: *+94719154640 <%2B94719154640>*
>>>> Email: ros...@wso2.com
>>>> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
>>>> lean.enterprise.middleware.
>>>>
>>>
>>>
>>>
>>> --
>>> Gimantha Bandara
>>> Software Engineer
>>> WSO2. Inc : http://wso2.com
>>> Mobile : +94714961919
>>>
>>
>>
>>
>> --
>> Roshan Wijesena.
>> Senior Software Engineer-WSO2 Inc.
>> Mobile: *+94719154640 <%2B94719154640>*
>> Email: ros...@wso2.com
>> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
>> lean.enterprise.middleware.
>>
>
>
>
> --
> Regards,
> UdaraR
>



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


Re: [Dev] [DEV][DAS] How to sort data in DAS?

2016-01-08 Thread Udara Rathnayake
Hi Roshan,

You can give - i within your schema while creating the temporary table to
make it an indexed column.

Eg:- schema "user_name INT -i, .. "

https://docs.wso2.com/display/DAS300/Spark+Query+Language

On Fri, Jan 8, 2016 at 7:24 PM, Roshan Wijesena <ros...@wso2.com> wrote:

> Hi,
>
> The problem is I can not *search* sorted tempory tables because there are
> no indexes. Is there any way to create indexes in tempory tables?
>
> -Roshan
>
> On Fri, Jan 1, 2016 at 12:12 PM, Gimantha Bandara <giman...@wso2.com>
> wrote:
>
>> Hi Roshan,
>>
>> REST APIs do not provide a way to sort data in DAS. The only option is to
>> use spark queries to create sorted temporary tables.
>>
>> On Wed, Dec 30, 2015 at 9:25 AM, Roshan Wijesena <ros...@wso2.com> wrote:
>>
>>> Hi Udara,
>>>
>>> Yes I also thought about this, the only problem is let's say we have 10
>>> column table, and if I want to sort  columns of this table, I need to
>>> create 20 tempory tables two temp tables per one column (ASC/DESC). BTW, I
>>> think this is the only solution we got so far. :)
>>>
>>> -Roshan
>>>
>>>
>>>
>>> On Tue, Dec 29, 2015 at 9:44 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Hi Roshan,
>>>>
>>>> If you are querying a temporary table, you can initially store data
>>>> within temporary table in the particular order. Then you don't need to
>>>> worry about the order while querying.
>>>> Eg:- You can have ORDER BY, DESC/ASC within your SELECT (INSERT
>>>> INTO/OVERWRITE TABLE  **)[1]
>>>>
>>>> BTW I haven't tried this method, May be someone from DAS team can point
>>>> a better solution.
>>>>
>>>> [1] https://docs.wso2.com/display/DAS300/Spark+Query+Language
>>>>
>>>> On Tue, Dec 29, 2015 at 10:22 PM, Roshan Wijesena <ros...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> Do we have a REST API for this? How could I sort a data set by
>>>>> ascending or descending order when retrieving from the data source?
>>>>>
>>>>> -Roshan
>>>>>
>>>>> --
>>>>> Roshan Wijesena.
>>>>> Senior Software Engineer-WSO2 Inc.
>>>>> Mobile: *+94719154640 <%2B94719154640>*
>>>>> Email: ros...@wso2.com
>>>>> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
>>>>> lean.enterprise.middleware.
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>>
>>>
>>>
>>>
>>> --
>>> Roshan Wijesena.
>>> Senior Software Engineer-WSO2 Inc.
>>> Mobile: *+94719154640 <%2B94719154640>*
>>> Email: ros...@wso2.com
>>> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
>>> lean.enterprise.middleware.
>>>
>>
>>
>>
>> --
>> Gimantha Bandara
>> Software Engineer
>> WSO2. Inc : http://wso2.com
>> Mobile : +94714961919
>>
>
>
>
> --
> Roshan Wijesena.
> Senior Software Engineer-WSO2 Inc.
> Mobile: *+94719154640 <%2B94719154640>*
> Email: ros...@wso2.com
> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
> lean.enterprise.middleware.
>



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


[Dev] [DAS] Able to update spark scripts published through a capp

2016-01-06 Thread Udara Rathnayake
Hi,

As per the doc[1], we are restricting users to edit/delete artifacts
published through capp.
But it seems we can update spark scripts(published through a capp) though
management console.

If this is the expected behavior let's update the doc.

[1]
https://docs.wso2.com/display/DAS300/Packaging+Artifacts+as+a+C-App+Archive

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


Re: [Dev] [DAS] Able to update spark scripts published through a capp

2016-01-06 Thread Udara Rathnayake
Thanks Inosh.

On Wed, Jan 6, 2016 at 3:53 PM, Inosh Goonewardena <in...@wso2.com> wrote:

> No it is not the expected behavior. I think you are experiencing the
> similar issue reported here [1]. Please use the capp name as Capp artifact
> name [2].
>
> [1] - https://wso2.org/jira/browse/DAS-284
> [2] -
> https://github.com/wso2/product-das/commit/10bba4cd28623fc3fe7b4caec17874ee1bc6c991
>
> On Wed, Jan 6, 2016 at 2:35 PM, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi,
>>
>> As per the doc[1], we are restricting users to edit/delete artifacts
>> published through capp.
>> But it seems we can update spark scripts(published through a capp) though
>> management console.
>>
>> If this is the expected behavior let's update the doc.
>>
>> [1]
>> https://docs.wso2.com/display/DAS300/Packaging+Artifacts+as+a+C-App+Archive
>>
>> --
>> Regards,
>> UdaraR
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Thanks & Regards,
>
> Inosh Goonewardena
> Associate Technical Lead- WSO2 Inc.
> Mobile: +94779966317
>



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


[Dev] Unable to add a spark UDF without any parameter

2016-01-05 Thread Udara Rathnayake
Hi,

When I try to call a UDF without any parameter, getting following error[1].
Let's assume my UDF is convertDate(). But if I try the same with a
parameter like convertDate(null) it works.

Any Idea? Noticed that we have TimeNowUDF[2] sample, do we need to use
"now(null)"
within a spark query?


[1]

TID: [-1] [] [2016-01-05 10:45:51,744] ERROR
{org.wso2.carbon.ntask.core.impl.TaskQuartzJobAdapter} -  Error in
executing task:
org.apache.spark.sql.UDFRegistration$$anonfun$register$24$$anonfun$apply$1
cannot be cast to scala.Function0
{org.wso2.carbon.ntask.core.impl.TaskQuartzJobAdapter}
java.lang.ClassCastException:
org.apache.spark.sql.UDFRegistration$$anonfun$register$24$$anonfun$apply$1
cannot be cast to scala.Function0
at
org.apache.spark.sql.catalyst.expressions.ScalaUdf.(ScalaUdf.scala:61)
at
org.apache.spark.sql.UDFRegistration$$anonfun$register$24.apply(UDFRegistration.scala:408)
at
org.apache.spark.sql.UDFRegistration$$anonfun$register$24.apply(UDFRegistration.scala:408)
at
org.apache.spark.sql.catalyst.analysis.SimpleFunctionRegistry.lookupFunction(FunctionRegistry.scala:57)
at
org.apache.spark.sql.catalyst.analysis.Analyzer$ResolveFunctions$$anonfun$apply$13$$anonfun$applyOrElse$5.applyOrElse(Analyzer.scala:465)
at
org.apache.spark.sql.catalyst.analysis.Analyzer$ResolveFunctions$$anonfun$apply$13$$anonfun$applyOrElse$5.applyOrElse(Analyzer.scala:463)
at
org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$3.apply(TreeNode.scala:222)
at
org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$3.apply(TreeNode.scala:222)
at
org.apache.spark.sql.catalyst.trees.CurrentOrigin$.withOrigin(TreeNode.scala:51)
at
org.apache.spark.sql.catalyst.trees.TreeNode.transformDown(TreeNode.scala:221)
at
org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$4.apply(TreeNode.scala:242)
at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
at scala.collection.Iterator$class.foreach(Iterator.scala:727)
at scala.collection.AbstractIterator.foreach(Iterator.scala:1157)
at
scala.collection.generic.Growable$class.$plus$plus$eq(Growable.scala:48)
at
scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:103)
at
scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:47)
at scala.collection.TraversableOnce$class.to
(TraversableOnce.scala:273)
at scala.collection.AbstractIterator.to(Iterator.scala:1157)
at
scala.collection.TraversableOnce$class.toBuffer(TraversableOnce.scala:265)
at scala.collection.AbstractIterator.toBuffer(Iterator.scala:1157)
at
scala.collection.TraversableOnce$class.toArray(TraversableOnce.scala:252)
at scala.collection.AbstractIterator.toArray(Iterator.scala:1157)
at
org.apache.spark.sql.catalyst.trees.TreeNode.transformChildrenDown(TreeNode.scala:272)
at
org.apache.spark.sql.catalyst.trees.TreeNode.transformDown(TreeNode.scala:227)
at org.apache.spark.sql.catalyst.plans.QueryPlan.org
$apache$spark$sql$catalyst$plans$QueryPlan$$transformExpressionDown$1(QueryPlan.scala:75)
at
org.apache.spark.sql.catalyst.plans.QueryPlan$$anonfun$1.apply(QueryPlan.scala:85)
at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
at scala.collection.Iterator$class.foreach(Iterator.scala:727)
at scala.collection.AbstractIterator.foreach(Iterator.scala:1157)
at
scala.collection.generic.Growable$class.$plus$plus$eq(Growable.scala:48)
at
scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:103)
at
scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:47)
at scala.collection.TraversableOnce$class.to
(TraversableOnce.scala:273)
at scala.collection.AbstractIterator.to(Iterator.scala:1157)
at
scala.collection.TraversableOnce$class.toBuffer(TraversableOnce.scala:265)
at scala.collection.AbstractIterator.toBuffer(Iterator.scala:1157)
at
scala.collection.TraversableOnce$class.toArray(TraversableOnce.scala:252)
at scala.collection.AbstractIterator.toArray(Iterator.scala:1157)
at
org.apache.spark.sql.catalyst.plans.QueryPlan.transformExpressionsDown(QueryPlan.scala:94)
at
org.apache.spark.sql.catalyst.plans.QueryPlan.transformExpressions(QueryPlan.scala:64)
at
org.apache.spark.sql.catalyst.analysis.Analyzer$ResolveFunctions$$anonfun$apply$13.applyOrElse(Analyzer.scala:463)
at
org.apache.spark.sql.catalyst.analysis.Analyzer$ResolveFunctions$$anonfun$apply$13.applyOrElse(Analyzer.scala:461)
at
org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$3.apply(TreeNode.scala:222)
at
org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$3.apply(TreeNode.scala:222)
at
org.apache.spark.sql.catalyst.trees.CurrentOrigin$.withOrigin(TreeNode.scala:51)
at

Re: [Dev] Unable to add a spark UDF without any parameter

2016-01-05 Thread Udara Rathnayake
Thanks Niranda

On Tue, Jan 5, 2016 at 11:12 AM, Niranda Perera <nira...@wso2.com> wrote:

> Hi Udara,
>
> Yes, this is a known issue / limitation in the current implementation. You
> would have to pass a dummy param because udf0 implementation was not
> available by the time we released.
>
> Best
> On Jan 5, 2016 21:37, "Udara Rathnayake" <uda...@wso2.com> wrote:
>
>> Hi,
>>
>> When I try to call a UDF without any parameter, getting following
>> error[1]. Let's assume my UDF is convertDate(). But if I try the same with
>> a parameter like convertDate(null) it works.
>>
>> Any Idea? Noticed that we have TimeNowUDF[2] sample, do we need to use "
>> now(null)" within a spark query?
>>
>>
>> [1]
>>
>> TID: [-1] [] [2016-01-05 10:45:51,744] ERROR
>> {org.wso2.carbon.ntask.core.impl.TaskQuartzJobAdapter} -  Error in
>> executing task:
>> org.apache.spark.sql.UDFRegistration$$anonfun$register$24$$anonfun$apply$1
>> cannot be cast to scala.Function0
>> {org.wso2.carbon.ntask.core.impl.TaskQuartzJobAdapter}
>> java.lang.ClassCastException:
>> org.apache.spark.sql.UDFRegistration$$anonfun$register$24$$anonfun$apply$1
>> cannot be cast to scala.Function0
>> at
>> org.apache.spark.sql.catalyst.expressions.ScalaUdf.(ScalaUdf.scala:61)
>> at
>> org.apache.spark.sql.UDFRegistration$$anonfun$register$24.apply(UDFRegistration.scala:408)
>> at
>> org.apache.spark.sql.UDFRegistration$$anonfun$register$24.apply(UDFRegistration.scala:408)
>> at
>> org.apache.spark.sql.catalyst.analysis.SimpleFunctionRegistry.lookupFunction(FunctionRegistry.scala:57)
>> at
>> org.apache.spark.sql.catalyst.analysis.Analyzer$ResolveFunctions$$anonfun$apply$13$$anonfun$applyOrElse$5.applyOrElse(Analyzer.scala:465)
>> at
>> org.apache.spark.sql.catalyst.analysis.Analyzer$ResolveFunctions$$anonfun$apply$13$$anonfun$applyOrElse$5.applyOrElse(Analyzer.scala:463)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$3.apply(TreeNode.scala:222)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$3.apply(TreeNode.scala:222)
>> at
>> org.apache.spark.sql.catalyst.trees.CurrentOrigin$.withOrigin(TreeNode.scala:51)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode.transformDown(TreeNode.scala:221)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode$$anonfun$4.apply(TreeNode.scala:242)
>> at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
>> at scala.collection.Iterator$class.foreach(Iterator.scala:727)
>> at scala.collection.AbstractIterator.foreach(Iterator.scala:1157)
>> at
>> scala.collection.generic.Growable$class.$plus$plus$eq(Growable.scala:48)
>> at
>> scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:103)
>> at
>> scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:47)
>> at scala.collection.TraversableOnce$class.to
>> (TraversableOnce.scala:273)
>> at scala.collection.AbstractIterator.to(Iterator.scala:1157)
>> at
>> scala.collection.TraversableOnce$class.toBuffer(TraversableOnce.scala:265)
>> at scala.collection.AbstractIterator.toBuffer(Iterator.scala:1157)
>> at
>> scala.collection.TraversableOnce$class.toArray(TraversableOnce.scala:252)
>> at scala.collection.AbstractIterator.toArray(Iterator.scala:1157)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode.transformChildrenDown(TreeNode.scala:272)
>> at
>> org.apache.spark.sql.catalyst.trees.TreeNode.transformDown(TreeNode.scala:227)
>> at org.apache.spark.sql.catalyst.plans.QueryPlan.org
>> $apache$spark$sql$catalyst$plans$QueryPlan$$transformExpressionDown$1(QueryPlan.scala:75)
>> at
>> org.apache.spark.sql.catalyst.plans.QueryPlan$$anonfun$1.apply(QueryPlan.scala:85)
>> at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
>> at scala.collection.Iterator$class.foreach(Iterator.scala:727)
>> at scala.collection.AbstractIterator.foreach(Iterator.scala:1157)
>> at
>> scala.collection.generic.Growable$class.$plus$plus$eq(Growable.scala:48)
>> at
>> scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:103)
>> at
>> scala.collection.mutable.ArrayBuffer.$plus$plus$eq(ArrayBuffer.scala:47)
>> at scala.collection.TraversableOnce$class.to
>> (Trav

[Dev] [DS] Get number of dashboards created

2015-12-29 Thread Udara Rathnayake
Hi All,

Do we have a better way to $subject, other than following?

<%
var carbon = require('carbon');
var url = 'https://localhost:9443/admin/services/';
var server = new carbon.server.Server(url);
var options = {username: 'admin',  domain: 'carbon.super' , tenantId:
-1234};
var registry = new carbon.registry.Registry(server, options);

var resource = registry.get('/_system/config/ues/dashboards');
print(resource.content.length);
%>

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


Re: [Dev] [DEV][DAS] How to add pagination into dashboard data table?

2015-12-29 Thread Udara Rathnayake
Hi Roshan,

Populating gadget data using JS API's search with start and count[1] and
render as per your requirement is also an option I think.

[1]
https://docs.wso2.com/display/DAS300/Retrieving+All+Records+Matching+the+Given+Search+Query+via+JS+API

On Tue, Dec 29, 2015 at 12:43 PM, Roshan Wijesena <ros...@wso2.com> wrote:

> probably we have to make  main.js's  "start" and "count" params into
> dynamics to get this done.
>
>  var request = {
> type: 8,
> tableName: datasource,
> filter:filter,
> timeFrom: timeFrom,
> timeTo: timeTo,
> start: 10,
> count: 10
> };
>
​If this works, you can just go and edit existing gadget to cater your
requirement rather ​
creating new one using JS API.​


>
> On Tue, Dec 29, 2015 at 11:25 AM, Roshan Wijesena <ros...@wso2.com> wrote:
>
>> Hi Udara,
>>
>> Yes, I have a table like below within a gadget, currently it shows all
>> records available in the database table. Looking for a pagination solution
>> for this like 10 by 10 records.
>>
>>
>> ​
>>
>> On Tue, Dec 29, 2015 at 11:08 AM, Udara Rathnayake <uda...@wso2.com>
>> wrote:
>>
>>> Hi Roshan,
>>>
>>> Are we talking about displaying paginated content within a gadget?
>>>
>>> On Tue, Dec 29, 2015 at 11:58 AM, Maninda Edirisooriya <mani...@wso2.com
>>> > wrote:
>>>
>>>> [+Dunith]
>>>>
>>>> AFAIK you have to edit files to customize DAS dashboards.
>>>> Thanks.
>>>>
>>>>
>>>> *Maninda Edirisooriya*
>>>> Senior Software Engineer
>>>>
>>>> *WSO2, Inc.*lean.enterprise.middleware.
>>>>
>>>> *Blog* : http://maninda.blogspot.com/
>>>> *E-mail* : mani...@wso2.com
>>>> *Skype* : @manindae
>>>> *Twitter* : @maninda
>>>>
>>>> On Tue, Dec 29, 2015 at 10:23 PM, Roshan Wijesena <ros...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> Is there any  way to add paginations into DAS dashboard data table
>>>>> rather customize its d3.js files?
>>>>>
>>>>> -Roshan
>>>>>
>>>>> --
>>>>> Roshan Wijesena.
>>>>> Senior Software Engineer-WSO2 Inc.
>>>>> Mobile: *+94719154640 <%2B94719154640>*
>>>>> Email: ros...@wso2.com
>>>>> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
>>>>> lean.enterprise.middleware.
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Regards,
>>> UdaraR
>>>
>>
>>
>>
>> --
>> Roshan Wijesena.
>> Senior Software Engineer-WSO2 Inc.
>> Mobile: *+94719154640 <%2B94719154640>*
>> Email: ros...@wso2.com
>> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
>> lean.enterprise.middleware.
>>
>
>
>
> --
> Roshan Wijesena.
> Senior Software Engineer-WSO2 Inc.
> Mobile: *+94719154640 <%2B94719154640>*
> Email: ros...@wso2.com
> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
> lean.enterprise.middleware.
>



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


Re: [Dev] [DEV][DAS] How to add pagination into dashboard data table?

2015-12-29 Thread Udara Rathnayake
Hi Roshan,

Are we talking about displaying paginated content within a gadget?

On Tue, Dec 29, 2015 at 11:58 AM, Maninda Edirisooriya 
wrote:

> [+Dunith]
>
> AFAIK you have to edit files to customize DAS dashboards.
> Thanks.
>
>
> *Maninda Edirisooriya*
> Senior Software Engineer
>
> *WSO2, Inc.*lean.enterprise.middleware.
>
> *Blog* : http://maninda.blogspot.com/
> *E-mail* : mani...@wso2.com
> *Skype* : @manindae
> *Twitter* : @maninda
>
> On Tue, Dec 29, 2015 at 10:23 PM, Roshan Wijesena  wrote:
>
>> Hi,
>>
>> Is there any  way to add paginations into DAS dashboard data table rather
>> customize its d3.js files?
>>
>> -Roshan
>>
>> --
>> Roshan Wijesena.
>> Senior Software Engineer-WSO2 Inc.
>> Mobile: *+94719154640 <%2B94719154640>*
>> Email: ros...@wso2.com
>> *WSO2, Inc. :** wso2.com *
>> lean.enterprise.middleware.
>>
>
>


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


Re: [Dev] [DEV][DAS] How to sort data in DAS?

2015-12-29 Thread Udara Rathnayake
Hi Roshan,

If you are querying a temporary table, you can initially store data within
temporary table in the particular order. Then you don't need to worry about
the order while querying.
Eg:- You can have ORDER BY, DESC/ASC within your SELECT (INSERT
INTO/OVERWRITE TABLE  **)[1]

BTW I haven't tried this method, May be someone from DAS team can point a
better solution.

[1] https://docs.wso2.com/display/DAS300/Spark+Query+Language

On Tue, Dec 29, 2015 at 10:22 PM, Roshan Wijesena  wrote:

> Hi,
>
> Do we have a REST API for this? How could I sort a data set by ascending
> or descending order when retrieving from the data source?
>
> -Roshan
>
> --
> Roshan Wijesena.
> Senior Software Engineer-WSO2 Inc.
> Mobile: *+94719154640 <%2B94719154640>*
> Email: ros...@wso2.com
> *WSO2, Inc. :** wso2.com *
> lean.enterprise.middleware.
>



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


Re: [Dev] [DAS ]How to delete/edit created gadget from DAS.

2015-12-28 Thread Udara Rathnayake
Hi Roshan,

Creating a new gadget via gadget designer UI is the easiest way at the
moment. Yes even with this approach we have to delete existing gadget from
file system manually.

On Mon, Dec 28, 2015 at 6:53 PM, Roshan Wijesena  wrote:

> Hi,
>
> I think it has not implemented yet [1]. Any workaround for this?
>
> [1] https://wso2.org/jira/browse/DAS-336
>
> --
> Roshan Wijesena.
> Senior Software Engineer-WSO2 Inc.
> Mobile: *+94719154640 <%2B94719154640>*
> Email: ros...@wso2.com
> *WSO2, Inc. :** wso2.com *
> lean.enterprise.middleware.
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] [DAS-3.0.0] Unable to retrieve matching records via JS API

2015-12-27 Thread Udara Rathnayake
Hi Team,

One more thing, within the example code snippet we are not using proper
quotation mark(U+0022). For me it looks we are using double prime character(
U+02BA). Check the highlighted portion.
If someone try to copy and paste the exact same, this can cause issues.
Better if we can update this also.

var queryInfo = {
tableName : “TEST”, //table being queried
query : "column1:value1", //lucene query to search the records
start : 0, //starting index of the matching record set
count : 100 //page size for pagination
};
client.search(queryInfo, function(data) {
  console.log (data[“message”]);
}, function(error) {
  console.log(“error occured: ” + error[“message”]);
});
“error occured: ” + error[“message”]

This anomaly exists on most of the analytic JS API docs. Sorry for the
trouble guys.

On Sun, Dec 27, 2015 at 12:17 PM, Anjana Fernando <anj...@wso2.com> wrote:

> Hi Gimantha,
>
> I think you've access to the docs wiki. Please change it directly.
>
> Cheers,
> Anjana.
>
> On Sun, Dec 27, 2015 at 9:47 PM, Gimantha Bandara <giman...@wso2.com>
> wrote:
>
>> Hi Udara,
>>
>> Yes, your way of calling search API is the correct way. Documentation
>> needs to be updated. Thank you for pointing it out.
>>
>> @Rukshani, can you please replace the example with the following content?
>>
>> var queryInfo = {
>>
>> tableName : “TEST”, //table being queried
>>
>> searchParams : {
>>
>> query : "column1:value1", //lucene query to search the records
>>
>> start : 0, //starting index of the matching record set
>>
>> count : 100 //page size for pagination
>>
>>  }
>>
>> };
>>
>>
>> client.search(queryInfo, function(data) {
>>
>> console.log (data[“message”]);
>>
>> }, function(error) {
>>
>> console.log(“error occured: ” + error[“message”]);
>>
>> });
>>
>>
>> Highlighted text is missing in the current Docs.
>>
>> Thanks,
>>
>>
>> On Sunday, December 27, 2015, Anjana Fernando <anj...@wso2.com> wrote:
>>
>>> @Gimantha, please check.
>>>
>>> Cheers,
>>> Anjana.
>>>
>>> On Sat, Dec 26, 2015 at 8:52 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Hi,
>>>>
>>>> I tried following doc[1] to retrieve records using a simple lucene
>>>> query(userId:udarakr) via JS API.But noticed an error, when I use the same
>>>> query within data explorer it works perfectly.
>>>>
>>>> Then did some debugging on portal/controllers/apis/analytics.jag &
>>>> portal/js/carbon-analytics.js,  found we are expecting queryInfo object in
>>>> a different format than in the doc[1].
>>>>
>>>> portal/js/carbon-analytics.js - LINE 473
>>>>
>>>> this.search = function (queryInfo, callback, error) {
>>>> jQuery.ajax({
>>>> url: this.serverUrl + "?type=" + TYPE_SEARCH +
>>>> "=" + queryInfo["tableName"],
>>>> data: JSON.stringify(queryInfo["searchParams"])
>>>> ,
>>>> type: HTTP_POST,
>>>> success: function (data) {
>>>> callback(data);
>>>> },
>>>> error: function (msg) {
>>>> error(msg[RESPONSE_ELEMENT]);
>>>> }
>>>> });
>>>> };
>>>>
>>>>
>>>> As per above we need to provide queryInfo Object like,
>>>>
>>>> Eg:-
>>>> var queryInfo={
>>>> tableName:"LOCATION",
>>>> searchParams : {
>>>> query:"userId:udarakr",
>>>> start:0,
>>>> count:100
>>>> }
>>>> };
>>>>
>>>> If this is the correct way, Shall we update the docs?
>>>>
>>>> [1]
>>>> https://docs.wso2.com/display/DAS300/Retrieving+All+Records+Matching+the+Given+Search+Query+via+JS+API
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>> ​​
>>>>
>>>>
>>>
>>>
>>> --
>>> *Anjana Fernando*
>>> Senior Technical Lead
>>> WSO2 Inc. | http://wso2.com
>>> lean . enterprise . middleware
>>>
>>
>
>
> --
> *Anjana Fernando*
> Senior Technical Lead
> WSO2 Inc. | http://wso2.com
> lean . enterprise . middleware
>



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


[Dev] [DAS-3.0.0] Unable to retrieve matching records via JS API

2015-12-26 Thread Udara Rathnayake
Hi,

I tried following doc[1] to retrieve records using a simple lucene
query(userId:udarakr) via JS API.But noticed an error, when I use the same
query within data explorer it works perfectly.

Then did some debugging on portal/controllers/apis/analytics.jag &
portal/js/carbon-analytics.js,  found we are expecting queryInfo object in
a different format than in the doc[1].

portal/js/carbon-analytics.js - LINE 473

this.search = function (queryInfo, callback, error) {
jQuery.ajax({
url: this.serverUrl + "?type=" + TYPE_SEARCH +
"=" + queryInfo["tableName"],
data: JSON.stringify(queryInfo["searchParams"]),
type: HTTP_POST,
success: function (data) {
callback(data);
},
error: function (msg) {
error(msg[RESPONSE_ELEMENT]);
}
});
};


As per above we need to provide queryInfo Object like,

Eg:-
var queryInfo={
tableName:"LOCATION",
searchParams : {
query:"userId:udarakr",
start:0,
count:100
}
};

If this is the correct way, Shall we update the docs?

[1]
https://docs.wso2.com/display/DAS300/Retrieving+All+Records+Matching+the+Given+Search+Query+via+JS+API

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


Re: [Dev] HTTP event receiver to accept batch of same type events

2015-12-16 Thread Udara Rathnayake
I'm able to publish array of objects[1] with your help. Thanks Lasantha.

[1]

[{

  "event": {

"payloadData": {



}

  }

},

{

  "event": {

"payloadData": {



}

  }

}]


On Wed, Dec 16, 2015 at 3:12 AM, Lasantha Fernando <lasan...@wso2.com>
wrote:

> Hi Udara,
>
> You can do this using an HTTP receiver as well. For this, you can use XML
> input mapping and provide a parent selector xpath and if there are multiple
> child elements within that larger XML element, they will be taken as
> multiple events.
>
> Alternatively, if you are using JSON input mapping, if you send it as a
> json array, the objects in the array will be taken as individual events.
>
> Thanks,
> Lasantha
>
> On 16 December 2015 at 02:59, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> Hi,
>>
>> My requirement is to receive a set of events in a single request at DAS
>> side.
>> eg:- array of events
>>
>> is $subject possible else what is the recommended approach other than a
>> http event receiver?
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
>
> --
> *Lasantha Fernando*
> Senior Software Engineer - Data Technologies Team
> WSO2 Inc. http://wso2.com
>
> email: lasan...@wso2.com
> mobile: (+94) 71 5247551
>



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


[Dev] HTTP event receiver to accept batch of same type events

2015-12-15 Thread Udara Rathnayake
Hi,

My requirement is to receive a set of events in a single request at DAS
side.
eg:- array of events

is $subject possible else what is the recommended approach other than a
http event receiver?

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


Re: [Dev] [DEV][DAS] Publishing data through JAVA client REST or THRIFT?

2015-12-14 Thread Udara Rathnayake
Hi Gimantha,

What if we register a http event receiver and expose?

sent from my nexus4, ignore any typos
On Dec 14, 2015 6:47 PM, "Gimantha Bandara" <giman...@wso2.com> wrote:

> Hi Roshan,
>
> REST API cannot be used for publishing the data to DAS. You will have to
> use THRIFT.
>
> On Monday, December 14, 2015, Udara Rathnayake <uda...@wso2.com> wrote:
>
>> As far as I understood those EP's are for analytic purpose.
>> DAS team please correct me if I'm wrong.
>>
>> On Mon, Dec 14, 2015 at 4:08 PM, Roshan Wijesena <ros...@wso2.com> wrote:
>>
>>> Hi Udara,
>>>
>>> Yes, it is. But could not find data publisher end point (POST or PUT)
>>> from the endpoint list. Further, I am just wondering what are the
>>> advantages and disadvantages of REST vs Thrift publishers.
>>>
>>> -Roshan
>>>
>>> On Mon, Dec 14, 2015 at 3:04 PM, Udara Rathnayake <uda...@wso2.com>
>>> wrote:
>>>
>>>> Hi Roshan,
>>>>
>>>> On Mon, Dec 14, 2015 at 3:40 PM, Roshan Wijesena <ros...@wso2.com>
>>>> wrote:
>>>>
>>>>> Hi DAS team,
>>>>>
>>>>> 1. I could not find the data publisher endpoint  from the list [1].
>>>>> Which endpoint is used for save the data?
>>>>>
>>>> ​I think you are looking at the analytics REST API.​ Refer
>>>> https://docs.wso2.com/display/DAS300/Collecting+Data to
>>>> publish/persist data.
>>>>
>>>>>
>>>>> 2. I am just wondering which method to be used for data publishing for
>>>>> DAS. Can someone please explain few advantage and disadvantage of both?
>>>>>
>>>>> [1] https://docs.wso2.com/display/DAS300/Analytics+REST+API+Guide
>>>>>
>>>>> --
>>>>> Roshan Wijesena.
>>>>> Senior Software Engineer-WSO2 Inc.
>>>>> Mobile: *+94719154640 <%2B94719154640>*
>>>>> Email: ros...@wso2.com
>>>>> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
>>>>> lean.enterprise.middleware.
>>>>>
>>>>> ___
>>>>> Dev mailing list
>>>>> Dev@wso2.org
>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Regards,
>>>> UdaraR
>>>>
>>>
>>>
>>>
>>> --
>>> Roshan Wijesena.
>>> Senior Software Engineer-WSO2 Inc.
>>> Mobile: *+94719154640 <%2B94719154640>*
>>> Email: ros...@wso2.com
>>> *WSO2, Inc. :** wso2.com <http://wso2.com/>*
>>> lean.enterprise.middleware.
>>>
>>
>>
>>
>> --
>> Regards,
>> UdaraR
>>
>
>
> --
> Gimantha Bandara
> Software Engineer
> WSO2. Inc : http://wso2.com
> Mobile : +94714961919
>
>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DEV][DAS] Publishing data through JAVA client REST or THRIFT?

2015-12-14 Thread Udara Rathnayake
Hi Roshan,

On Mon, Dec 14, 2015 at 3:40 PM, Roshan Wijesena  wrote:

> Hi DAS team,
>
> 1. I could not find the data publisher endpoint  from the list [1]. Which
> endpoint is used for save the data?
>
​I think you are looking at the analytics REST API.​ Refer
https://docs.wso2.com/display/DAS300/Collecting+Data to publish/persist
data.

>
> 2. I am just wondering which method to be used for data publishing for
> DAS. Can someone please explain few advantage and disadvantage of both?
>
> [1] https://docs.wso2.com/display/DAS300/Analytics+REST+API+Guide
>
> --
> Roshan Wijesena.
> Senior Software Engineer-WSO2 Inc.
> Mobile: *+94719154640 <%2B94719154640>*
> Email: ros...@wso2.com
> *WSO2, Inc. :** wso2.com *
> lean.enterprise.middleware.
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


  1   2   3   4   >