[Dev] Error while tenant admin login to EMM

2014-08-21 Thread Chathura Dilan
We are getting the following error when a tenant admin try to login to EMM
server in a  cloud environment. This error is not getting when super
admin login to server. any ideas?

TID: [0] [EMM] [2014-08-20 21:15:07,513] ERROR
{org.jaggeryjs.jaggery.core.manager.WebAppManager}
-  org.mozilla.javascript.EcmaError: TypeError: Cannot read property
prodConsumerKey from undefined (/emm/modules/cloudstartup.js#66)
{org.jaggeryjs.jaggery.core.manager.WebAppManager}
org.jaggeryjs.scriptengine.exceptions.ScriptException:
org.mozilla.javascript.EcmaError: TypeError: Cannot read property
prodConsumerKey from undefined (/emm/modules/cloudstartup.js#66)
at org.jaggeryjs.scriptengine.engine.RhinoEngine.execScript(
RhinoEngine.java:571)
at org.jaggeryjs.scriptengine.engine.RhinoEngine.exec(
RhinoEngine.java:273)
at org.jaggeryjs.jaggery.core.manager.WebAppManager.execute(
WebAppManager.java:447)
at org.jaggeryjs.jaggery.core.JaggeryServlet.doPost(
JaggeryServlet.java:29)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:755)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
ApplicationFilterChain.java:305)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
ApplicationFilterChain.java:210)
at org.apache.catalina.core.ApplicationDispatcher.invoke(
ApplicationDispatcher.java:749)
at org.apache.catalina.core.ApplicationDispatcher.processRequest(
ApplicationDispatcher.java:487)
at org.apache.catalina.core.ApplicationDispatcher.doForward(
ApplicationDispatcher.java:379)
at org.apache.catalina.core.ApplicationDispatcher.forward(
ApplicationDispatcher.java:339)
at org.jaggeryjs.jaggery.core.JaggeryFilter.doFilter(
JaggeryFilter.java:21)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
ApplicationFilterChain.java:243)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(
ApplicationFilterChain.java:210)
at org.apache.catalina.core.StandardWrapperValve.invoke(
StandardWrapperValve.java:222)
at org.apache.catalina.core.StandardContextValve.invoke(
StandardContextValve.java:123)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(
AuthenticatorBase.java:472)
at org.apache.catalina.core.StandardHostValve.invoke(
StandardHostValve.java:171)
at org.apache.catalina.valves.ErrorReportValve.invoke(
ErrorReportValve.java:99)
at org.wso2.carbon.tomcat.ext.valves.CompositeValve.continueInvocation(
CompositeValve.java:178)
at org.wso2.carbon.tomcat.ext.valves.CarbonTomcatValve$1.
invoke(CarbonTomcatValve.java:47)
at org.wso2.carbon.webapp.mgt.TenantLazyLoaderValve.invoke(
TenantLazyLoaderValve.java:56)
at org.wso2.carbon.tomcat.ext.valves.TomcatValveContainer.invokeValves(
TomcatValveContainer.java:47)
at org.wso2.carbon.tomcat.ext.valves.CompositeValve.invoke(
CompositeValve.java:141)
at org.wso2.carbon.tomcat.ext.valves.CarbonStuckThreadDetectionValv
e.invoke(CarbonStuckThreadDetectionValve.java:156)
at org.apache.catalina.valves.AccessLogValve.invoke(
AccessLogValve.java:936)
at org.wso2.carbon.tomcat.ext.valves.CarbonContextCreatorValve.invoke(
CarbonContextCreatorValve.java:52)
at org.apache.catalina.core.StandardEngineValve.invoke(
StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(
CoyoteAdapter.java:407)
at org.apache.coyote.http11.AbstractHttp11Processor.process(
AbstractHttp11Processor.java:1004)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.
process(AbstractProtocol.java:589)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.
run(NioEndpoint.java:1653)
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:744)
Caused by: org.mozilla.javascript.EcmaError: TypeError: Cannot read
property prodConsumerKey from undefined (/emm/modules/cloudstartup.js#66)
at org.mozilla.javascript.ScriptRuntime.constructError(
ScriptRuntime.java:3687)
at org.mozilla.javascript.ScriptRuntime.constructError(
ScriptRuntime.java:3665)
at org.mozilla.javascript.ScriptRuntime.typeError(
ScriptRuntime.java:3693)
at org.mozilla.javascript.ScriptRuntime.typeError2(
ScriptRuntime.java:3712)
at org.mozilla.javascript.ScriptRuntime.undefReadError(
ScriptRuntime.java:3725)
at org.mozilla.javascript.ScriptRuntime.getObjectProp(
ScriptRuntime.java:1483)
at org.jaggeryjs.rhino.emm.modules.c20._c_anonymous_3(/
emm/modules/cloudstartup.js:66)
at org.jaggeryjs.rhino.emm.modules.c20.call(/emm/modules/
cloudstartup.js)
at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
at org.jaggeryjs.rhino.emm.controller.c2._c_anonymous_1(/
emm/controller/acs.jag:54)
at org.jaggeryjs.rhino.emm.controller.c2.call(/emm/controller/acs.jag)

[Dev] Error getting while installing an iOS Enterprise app

2014-09-29 Thread Chathura Dilan
I'm getting following error while installing an iOS application from Mobile
store.

EMM and Mobile store are  in separate servers and both share same
client-truststore.jks wso2carbon.jks

Error
[{ErrorCode:12024,ErrorDomain:MCMDMErrorDomain,LocalizedDescription:The
manifest for the app at
https://10.10.10.148:9444/emm/api/apps/install/ios/5422cc9f-7fae-42af-8682-7b81a8778c8d?tenantDomain=carbon.super
could not be validated.,USEnglishDescription:The manifest for the app
at
https://10.10.10.148:9444/emm/api/apps/install/ios/5422cc9f-7fae-42af-8682-7b81a8778c8d?tenantDomain=carbon.super
could not be validated.}]



-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Error getting while installing an iOS Enterprise app

2014-09-30 Thread Chathura Dilan
Hi,

I had internal chat with Dulitha, and found this issue is happening due to
paths mismatch. It has to be fixed it in both mobile store/publisher and emm

Thanks,

On Tue, Sep 30, 2014 at 11:43 PM, Dilshan Edirisuriya dils...@wso2.com
wrote:

 Hi Dilan,

 What is the application name you entered? Does it have spaces or any
 special characters?

 Regards,

 Dilshan

 On Sun, Sep 28, 2014 at 11:39 PM, Chathura Dilan chathu...@wso2.com
 wrote:

 I'm getting following error while installing an iOS application from
 Mobile store.

 EMM and Mobile store are  in separate servers and both share same
 client-truststore.jks wso2carbon.jks

 Error
 [{ErrorCode:12024,ErrorDomain:MCMDMErrorDomain,LocalizedDescription:The
 manifest for the app at
 https://10.10.10.148:9444/emm/api/apps/install/ios/5422cc9f-7fae-42af-8682-7b81a8778c8d?tenantDomain=carbon.super
 could not be validated.,USEnglishDescription:The manifest for the app
 at
 https://10.10.10.148:9444/emm/api/apps/install/ios/5422cc9f-7fae-42af-8682-7b81a8778c8d?tenantDomain=carbon.super
 could not be validated.}]



 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
 www.dilan.me




 --
 Dilshan Edirisuriya
 Senior Software Engineer - WSO2
 Mob: + 94 777878905
 http://wso2.com/




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Permission issue when changing the life cycle state in ES publisher

2014-10-22 Thread Chathura Dilan
Hi,

I'm getting the following exception when changing the life-cycle state ( to
Approve or Reject) in mobile publisher with reviewer role.

 JaggeryTravellingPermissionLifeCycle
org.wso2.carbon.registry.core.secure.AuthorizationFailedException: Resource
update failed. User rev is not authorized to update the resource
/_system/governance/mobileapps/pub/android/WSO2 App/1.0.
[2014-10-22 15:33:27,966] ERROR - GovernanceArtifactImpl Invoking lifecycle
action Approve failed
org.wso2.carbon.registry.core.exceptions.RegistryException: Resource update
failed. User rev is not authorized to update the resource
/_system/governance/mobileapps/pub/android/WSO2 App/1.0.
at
org.wso2.jaggery.scxml.aspects.JaggeryTravellingPermissionLifeCycle.invoke(JaggeryTravellingPermissionLifeCycle.java:510)
at
org.wso2.carbon.governance.registry.eventing.handlers.GovernanceEventingHandler.invokeAspect(GovernanceEventingHandler.java:243)
at
org.wso2.carbon.registry.core.jdbc.handlers.HandlerManager.invokeAspect(HandlerManager.java:2792)
at
org.wso2.carbon.registry.core.jdbc.handlers.HandlerLifecycleManager.invokeAspect(HandlerLifecycleManager.java:531)
at
org.wso2.carbon.registry.core.jdbc.EmbeddedRegistry.invokeAspect(EmbeddedRegistry.java:2550)
at
org.wso2.carbon.registry.core.caching.CacheBackedRegistry.invokeAspect(CacheBackedRegistry.java:427)
at
org.wso2.carbon.registry.core.session.UserRegistry.invokeAspect(UserRegistry.java:1930)
at
org.wso2.carbon.governance.api.common.dataobjects.GovernanceArtifactImpl.invokeAction(GovernanceArtifactImpl.java:625)
at
org.wso2.carbon.governance.api.common.dataobjects.GovernanceArtifactImpl.invokeAction(GovernanceArtifactImpl.java:605)
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.call1(OptRuntime.java:32)
at org.mozilla.javascript.gen.artifacts_17._c_anonymous_21(artifacts:283)
at org.mozilla.javascript.gen.artifacts_17.call(artifacts)
at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4._c_mobileAppsLifeCycleChange_24(/publisher/apis/v1/lifecycle_api_router.jag:473)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4.call(/publisher/apis/v1/lifecycle_api_router.jag)
at org.mozilla.javascript.optimizer.OptRuntime.callName(OptRuntime.java:63)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4._c_anonymous_9(/publisher/apis/v1/lifecycle_api_router.jag:138)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4.call(/publisher/apis/v1/lifecycle_api_router.jag)
at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
at
org.jaggeryjs.rhino.publisher.modules.c4._c_anonymous_12(/publisher/modules/router-g.js:183)
at
org.jaggeryjs.rhino.publisher.modules.c4.call(/publisher/modules/router-g.js)
at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4._c_anonymous_1(/publisher/apis/v1/lifecycle_api_router.jag:438)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4.call(/publisher/apis/v1/lifecycle_api_router.jag)
at org.mozilla.javascript.ScriptRuntime.applyOrCall(ScriptRuntime.java:2430)
at org.mozilla.javascript.BaseFunction.execIdCall(BaseFunction.java:269)
at org.mozilla.javascript.IdFunctionObject.call(IdFunctionObject.java:97)
at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
at
org.jaggeryjs.rhino.publisher.modules.c6._c_anonymous_17(/publisher/modules/publisher.js:438)
at
org.jaggeryjs.rhino.publisher.modules.c6.call(/publisher/modules/publisher.js)
at org.mozilla.javascript.optimizer.OptRuntime.call0(OptRuntime.java:23)
at
org.mozilla.javascript.gen._store__server_js_8._c_anonymous_17([store]/server.js:271)
at org.mozilla.javascript.gen._store__server_js_8.call([store]/server.js)
at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
at
org.jaggeryjs.rhino.publisher.modules.c6._c_anonymous_16(/publisher/modules/publisher.js:433)
at
org.jaggeryjs.rhino.publisher.modules.c6.call(/publisher/modules/publisher.js)
at org.mozilla.javascript.optimizer.OptRuntime.callN(OptRuntime.java:52)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4._c_script_0(/publisher/apis/v1/lifecycle_api_router.jag:24)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4.call(/publisher/apis/v1/lifecycle_api_router.jag)
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:394)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3091)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4.call(/publisher/apis/v1/lifecycle_api_router.jag)
at
org.jaggeryjs.rhino.publisher.apis.v_1.c4.exec(/publisher/apis/v1/lifecycle_api_router.jag)
at

Re: [Dev] Permission issue when changing the life cycle state in ES publisher

2014-10-22 Thread Chathura Dilan
Hi Sameera,

It is In-Review to Approved

On Wed, Oct 22, 2014 at 5:36 PM, Sameera Medagammaddegedara 
samee...@wso2.com wrote:

 Hi DIlan,

 Could you provide the states involved in the transition?

 Thank You,
 Sameera

 On Wed, Oct 22, 2014 at 4:27 PM, Chathura Dilan chathu...@wso2.com
 wrote:

 Hi,

 I'm getting the following exception when changing the life-cycle state (
 to Approve or Reject) in mobile publisher with reviewer role.

  JaggeryTravellingPermissionLifeCycle
 org.wso2.carbon.registry.core.secure.AuthorizationFailedException: Resource
 update failed. User rev is not authorized to update the resource
 /_system/governance/mobileapps/pub/android/WSO2 App/1.0.
 [2014-10-22 15:33:27,966] ERROR - GovernanceArtifactImpl Invoking
 lifecycle action Approve failed
 org.wso2.carbon.registry.core.exceptions.RegistryException: Resource
 update failed. User rev is not authorized to update the resource
 /_system/governance/mobileapps/pub/android/WSO2 App/1.0.
 at
 org.wso2.jaggery.scxml.aspects.JaggeryTravellingPermissionLifeCycle.invoke(JaggeryTravellingPermissionLifeCycle.java:510)
 at
 org.wso2.carbon.governance.registry.eventing.handlers.GovernanceEventingHandler.invokeAspect(GovernanceEventingHandler.java:243)
 at
 org.wso2.carbon.registry.core.jdbc.handlers.HandlerManager.invokeAspect(HandlerManager.java:2792)
 at
 org.wso2.carbon.registry.core.jdbc.handlers.HandlerLifecycleManager.invokeAspect(HandlerLifecycleManager.java:531)
 at
 org.wso2.carbon.registry.core.jdbc.EmbeddedRegistry.invokeAspect(EmbeddedRegistry.java:2550)
 at
 org.wso2.carbon.registry.core.caching.CacheBackedRegistry.invokeAspect(CacheBackedRegistry.java:427)
 at
 org.wso2.carbon.registry.core.session.UserRegistry.invokeAspect(UserRegistry.java:1930)
 at
 org.wso2.carbon.governance.api.common.dataobjects.GovernanceArtifactImpl.invokeAction(GovernanceArtifactImpl.java:625)
 at
 org.wso2.carbon.governance.api.common.dataobjects.GovernanceArtifactImpl.invokeAction(GovernanceArtifactImpl.java:605)
 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.call1(OptRuntime.java:32)
 at org.mozilla.javascript.gen.artifacts_17._c_anonymous_21(artifacts:283)
 at org.mozilla.javascript.gen.artifacts_17.call(artifacts)
 at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
 at
 org.jaggeryjs.rhino.publisher.apis.v_1.c4._c_mobileAppsLifeCycleChange_24(/publisher/apis/v1/lifecycle_api_router.jag:473)
 at
 org.jaggeryjs.rhino.publisher.apis.v_1.c4.call(/publisher/apis/v1/lifecycle_api_router.jag)
 at
 org.mozilla.javascript.optimizer.OptRuntime.callName(OptRuntime.java:63)
 at
 org.jaggeryjs.rhino.publisher.apis.v_1.c4._c_anonymous_9(/publisher/apis/v1/lifecycle_api_router.jag:138)
 at
 org.jaggeryjs.rhino.publisher.apis.v_1.c4.call(/publisher/apis/v1/lifecycle_api_router.jag)
 at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.c4._c_anonymous_12(/publisher/modules/router-g.js:183)
 at
 org.jaggeryjs.rhino.publisher.modules.c4.call(/publisher/modules/router-g.js)
 at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
 at
 org.jaggeryjs.rhino.publisher.apis.v_1.c4._c_anonymous_1(/publisher/apis/v1/lifecycle_api_router.jag:438)
 at
 org.jaggeryjs.rhino.publisher.apis.v_1.c4.call(/publisher/apis/v1/lifecycle_api_router.jag)
 at
 org.mozilla.javascript.ScriptRuntime.applyOrCall(ScriptRuntime.java:2430)
 at org.mozilla.javascript.BaseFunction.execIdCall(BaseFunction.java:269)
 at org.mozilla.javascript.IdFunctionObject.call(IdFunctionObject.java:97)
 at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
 at
 org.jaggeryjs.rhino.publisher.modules.c6._c_anonymous_17(/publisher/modules/publisher.js:438)
 at
 org.jaggeryjs.rhino.publisher.modules.c6.call(/publisher/modules/publisher.js)
 at org.mozilla.javascript.optimizer.OptRuntime.call0(OptRuntime.java:23)
 at
 org.mozilla.javascript.gen._store__server_js_8._c_anonymous_17([store]/server.js:271)
 at org.mozilla.javascript.gen._store__server_js_8.call([store]/server.js)
 at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
 at
 org.jaggeryjs.rhino.publisher.modules.c6._c_anonymous_16(/publisher/modules/publisher.js:433)
 at
 org.jaggeryjs.rhino.publisher.modules.c6.call(/publisher/modules/publisher.js)
 at org.mozilla.javascript.optimizer.OptRuntime.callN(OptRuntime.java:52)
 at
 org.jaggeryjs.rhino.publisher.apis.v_1.c4._c_script_0(/publisher/apis/v1/lifecycle_api_router.jag:24)
 at
 org.jaggeryjs.rhino.publisher.apis.v_1.c4.call(/publisher/apis

Re: [Dev] A doubt in one of the field names in Add Policy of EMM

2014-10-31 Thread Chathura Dilan
I think documentation need to be updated

On Tue, Oct 28, 2014 at 5:43 PM, Pasanthi Amarasekera pasan...@wso2.com
wrote:

 Hi,

 In Operation Restrictions of Add Policy in EMM, what is meant by Change
 Screen Lock Passcode field ?

 In documentation (https://docs.wso2.com/display/EMM110/EMM+Policy+Settings)
 it says  The end-user's device passcode lock will be automatically
 cleared. But this doesn't give a clear idea on what to enter there when
 creating the policy.

 Thank you.

 Regards,
 Pasanthi.

 --
 Pasanthi Amarasekera
 WSO2 Inc: http://wso2.com
 lean.enterprise.middleware

 Mobile: +94 77 9541735

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




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] EMM 1.1.0 - A doubt in passcode policy compliance

2014-11-02 Thread Chathura Dilan
Hi Pasanthi,

Admin can disable this operation form the configurations for users. So the
users will not be allowed to perform that operation.
​​
​
​
​
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [EMM] What is meant by Pass-code History ?

2014-11-09 Thread Chathura Dilan
I'm not sure. General term could be 'Passcode History'[1]

[1] -
https://www.google.lk/search?q=passcode+history#q=%22passcode+history%22

On Mon, Nov 10, 2014 at 10:43 AM, Dilan Udara Ariyaratne dil...@wso2.com
wrote:

 +1, Thanks for creating the JIRA.


 *Dilan U. Ariyaratne*
 Software Engineer
 WSO2 Inc. http://wso2.com/
 Mobile: +94775149066
 lean . enterprise . middleware

 On Mon, Nov 10, 2014 at 10:32 AM, Pasanthi Amarasekera pasan...@wso2.com
 wrote:

 Hi,

 I also had the same problem when I was trying to give a passcode policy
 to my Android device for testing purposes. Thus created this JIRA [1]. We
 need to fix this in CDM 2.0 (if it has the same functionality as this).
 WDYT ?

 [1]https://wso2.org/jira/browse/EMM-756

 Thank you.

 Regards,
 Pasanthi.



 On Mon, Nov 10, 2014 at 9:17 AM, Inosh Perera ino...@wso2.com wrote:

 Hi Dilan,
 As you can see in the doc Lakshman mentioned, Passcode has an expiration
 time, after the expiration, user will have to change the password. In order
 to stop user from using the same passwords, he recently used, pass-code
 history has to be set.

 Regards,
 inosh

 On Mon, Nov 10, 2014 at 8:55 AM, Lakshman Udayakantha 
 lakshm...@wso2.com wrote:

 Hi Dilan,

 documentation[1] says. is that helpful?

 The end-user will not be allowed to reuse a passcode that he/she
 previously entered until he/she exceeds the set password history
 length (e.g., if the passcode history length is 3 and your passcode
 currently is 21345, you can not enter 21345 as the passcode in the
 next three consecutive passcode rotation cycles).

 [1] https://docs.wso2.com/display/EMM110/EMM+Policy+Settings

 On Mon, Nov 10, 2014 at 7:00 AM, Dilan Udara Ariyaratne 
 dil...@wso2.com wrote:

 Hi All,

 I was going through a check of the list of operations supported by
 wso2 emm
 on Android devices.

 Under pass-code policy, when the corresponding policy setting form
 prompts up,
 It asks for a required field called Pass-code History. (See the
 screen-shot)

 What is the kind of input that we are supposed to give for this?

 Appreciate any feedback on this.

 Thanks.


 *Dilan U. Ariyaratne*
 Software Engineer
 WSO2 Inc. http://wso2.com/
 Mobile: +94775149066
 lean . enterprise . middleware

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




 --
 Lakshman Udayakantha
 WSO2 Inc. www.wso2.com
 lean.enterprise.middleware
 Mobile: *0711241005*


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




 --
 Inosh Perera
 Software Engineer, WSO2 Inc.
 Tel: 0785293686

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




 --
 Pasanthi Amarasekera
 WSO2 Inc: http://wso2.com
 lean.enterprise.middleware

 Mobile: +94 77 9541735



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




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] What does sh -DworkerNode=true really mean?

2014-04-18 Thread Chathura Dilan
Hi All,

We can start a worker node in a clustering environment according to the
clustering doc[1] using following command

sh ./wso2server.sh -DworkerNode=true

It also says

The additional -DworkerNode=true argument indicates that this is a worker
node.

But is there any effect on the server if we enable that parameter, even
though we configure it as the worker node in axis2.xml?

[1]. https://docs.wso2.org/display/Cluster/Creating+a+Cluster

---
Regards,

Chatura Dilan Perera
*(Senior Software Engineer - WSO2 Inc.)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] What does sh -DworkerNode=true really mean?

2014-04-18 Thread Chathura Dilan
Thank you


On Fri, Apr 18, 2014 at 2:25 PM, Kishanthan Thangarajah kishant...@wso2.com
 wrote:

 This parameter basically makes a server read only. A node with this
 parameter, will not do any changes such as writing/modifying to deployment
 repo etc. This parameter also enables the worker profile, where the UI
 bundles will not be activated and only the BE bundles will be activated
 with the server start-up.

 What you configure in axis2.xml (under clustering) is the cluster
 sub-domain informing that this node belongs to worker sub domain in the
 cluster.


 On Fri, Apr 18, 2014 at 12:16 PM, Chathura Dilan chathu...@wso2.comwrote:

 Hi All,

 We can start a worker node in a clustering environment according to the
 clustering doc[1] using following command

 sh ./wso2server.sh -DworkerNode=true

 It also says

 The additional -DworkerNode=true argument indicates that this is a
 worker node.

 But is there any effect on the server if we enable that parameter, even
 though we configure it as the worker node in axis2.xml?

 [1]. https://docs.wso2.org/display/Cluster/Creating+a+Cluster

 ---
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer - WSO2 Inc.)*
 www.dilan.me




 --
 *Kishanthan Thangarajah*
 Senior Software Engineer,
 Platform Technologies Team,
 WSO2, Inc.
 lean.enterprise.middleware

 Mobile - +94773426635
 Blog - *http://kishanthan.wordpress.com http://kishanthan.wordpress.com*
 Twitter - *http://twitter.com/kishanthan http://twitter.com/kishanthan*




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer - WSO2 Inc.)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Loadbalancer configuration for API Manager

2014-04-20 Thread Chathura Dilan
Hi All,

When configuring the loadbalancer to cluster API Manager according to [1],
is there any specific configuration to use in the loadbalancer.conf for API
Manager like appserver for application server and esb for ESB. It is not
mentioned in the docs.

[1].  https://docs.wso2.org/display/CLUSTER420/Clustering+API+Manager
-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer - WSO2 Inc.)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Loadbalancer configuration for API Manager

2014-04-21 Thread Chathura Dilan
Hi Sanjeewa,

Thank you


On Mon, Apr 21, 2014 at 11:14 AM, Sanjeewa Malalgoda sanje...@wso2.comwrote:

 Normally we used term *apim* for API Manager. So hope you can use same
 here as well. But if its distributed deployment cluster names should
 contain gateway, store, publisher and keymanager in addition to apim.

 Thanks,
 sanjeewa.


 On Mon, Apr 21, 2014 at 11:02 AM, Chathura Dilan chathu...@wso2.comwrote:

 Hi All,

 When configuring the loadbalancer to cluster API Manager according to
 [1], is there any specific configuration to use in the loadbalancer.conf
 for API Manager like appserver for application server and esb for ESB. It
 is not mentioned in the docs.

 [1].  https://docs.wso2.org/display/CLUSTER420/Clustering+API+Manager
 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer - WSO2 Inc.)*
 www.dilan.me

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




 --

 *Sanjeewa Malalgoda*
 WSO2 Inc.
 Mobile : +94713068779

  http://sanjeewamalalgoda.blogspot.com/blog
 :http://sanjeewamalalgoda.blogspot.com/http://sanjeewamalalgoda.blogspot.com/





-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer - WSO2 Inc.)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] ESB DBRepot mediator configuration UI is not available after adding a Data-source

2014-04-25 Thread Chathura Dilan
Hi All,

I added a new MYSQL DataSource to the WSO2 ESB 4.8.1 and it was success.
After adding that I tried to create an API which has DBReport mediator and
DBReport mediator configuration UI failed to load when I try to add it to
the API.

I'm also getting following error message in the terminal. Is it a bug? WDYT?

ApplicationDispatcher Servlet.service() for servlet bridgeservlet threw
exception
java.lang.IllegalArgumentException: [=] is not a hexadecimal digit
at
org.apache.catalina.util.RequestUtil.convertHexDigit(RequestUtil.java:316)
at
org.apache.catalina.util.RequestUtil.parseParameters(RequestUtil.java:400)
at
org.apache.catalina.util.RequestUtil.parseParameters(RequestUtil.java:153)
at
org.apache.catalina.core.ApplicationHttpRequest.mergeParameters(ApplicationHttpRequest.java:894)
at
org.apache.catalina.core.ApplicationHttpRequest.parseParameters(ApplicationHttpRequest.java:756)
at
org.apache.catalina.core.ApplicationHttpRequest.getParameter(ApplicationHttpRequest.java:367)
at
javax.servlet.ServletRequestWrapper.getParameter(ServletRequestWrapper.java:184)
at
org.wso2.carbon.ui.CarbonUILoginUtil.getCustomIndexPage(CarbonUILoginUtil.java:153)
at
org.wso2.carbon.ui.CarbonSecuredHttpContext.handleSecurity(CarbonSecuredHttpContext.java:190)
at
org.eclipse.equinox.http.servlet.internal.ServletRegistration.service(ServletRegistration.java:60)
at
org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:128)
at
org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:68)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at
org.wso2.carbon.tomcat.ext.servlet.DelegationServlet.service(DelegationServlet.java:68)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:749)
at
org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:605)
at
org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:544)
at
org.eclipse.equinox.http.servlet.internal.RequestDispatcherAdaptor.include(RequestDispatcherAdaptor.java:37)
at
org.eclipse.equinox.http.helper.ContextPathServletAdaptor$RequestDispatcherAdaptor.include(ContextPathServletAdaptor.java:369)
at
org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:1015)
at
org.apache.jsp.dbreport_002dmediator.edit_002dmediator_jsp._jspService(org.apache.jsp.dbreport_002dmediator.edit_002dmediator_jsp:172)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:111)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:403)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:492)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:378)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at org.wso2.carbon.ui.JspServlet.service(JspServlet.java:155)
at org.wso2.carbon.ui.TilesJspServlet.service(TilesJspServlet.java:80)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at
org.eclipse.equinox.http.helper.ContextPathServletAdaptor.service(ContextPathServletAdaptor.java:37)
at
org.eclipse.equinox.http.servlet.internal.ServletRegistration.service(ServletRegistration.java:61)
at
org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:128)
at
org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:68)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at
org.wso2.carbon.tomcat.ext.servlet.DelegationServlet.service(DelegationServlet.java:68)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:749)
at
org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:605)
at
org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:544)
at
org.eclipse.equinox.http.servlet.internal.RequestDispatcherAdaptor.include(RequestDispatcherAdaptor.java:37)
at
org.eclipse.equinox.http.helper.ContextPathServletAdaptor$RequestDispatcherAdaptor.include(ContextPathServletAdaptor.java:369)
at
org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:1015)
at
org.apache.jsp.sequences.mediator_002dedit_002dajaxprocessor_jsp._jspService(org.apache.jsp.sequences.mediator_002dedit_002dajaxprocessor_jsp:154)
at 

Re: [Dev] Change password for users in EMM

2014-05-05 Thread Chathura Dilan
Yes we can add that feature, depending on read and write access of the user
store. And we have to also list what the operations can be performed on
user store if it is read only and if it has full read/write access.

I will add it to github once we finalize the design after today meeting.


On Tue, May 6, 2014 at 7:22 AM, Chan duli...@wso2.com wrote:

 Hi Dilan,
 For the new UI that you are building -can we have change password feature
 as well. This is something necessary since our password is randomly
 generated. Since you are currently building the UI separately - can you
 also put it in a separate Git repo. Then everyone can contribute to it.

 Cheers~

 --
 Chan (Dulitha Wijewantha)
 Software Engineer - Mobile Development
 WSO2Mobile
 Lean.Enterprise.Mobileware
  * ~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,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] org.apache.felix:maven-bundle-plugin:2.3.5 mvn error

2014-05-08 Thread Chathura Dilan
Hi,

I'm getting following  error when I try to build our latest EMM source
which is in development branch.

The POM for org.apache.felix:maven-bundle-plugin:jar:2.3.5 is invalid,
transitive dependencies (if any) will not be available

Mvn is unable to download the 2.3.5 plugins. However when I change it to
2.3.4 it works.

Anyone know what  is the reason for the above error?



-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Tenant UI Page

2014-05-21 Thread Chathura Dilan
Hi Dilshan,

UI Theme contains lot of files including images and css files and they
should directly consumed by the UI. Lot of process involve in getting the
binary from the registry write them into files and loading them and we have
to think about caching also.


On Wed, May 21, 2014 at 11:57 AM, Dilshan Edirisuriya dils...@wso2.comwrote:

 Hi Dilan,

 Why don't you store this in registry?

 Regards,

 Dilshan


 On Wed, May 21, 2014 at 11:44 AM, Chathura Dilan chathu...@wso2.comwrote:

 Hi Niranjan, Can you raise this in a public list. I think this kind of
 situation still not handled by any team yet. So we can come to a solution.


 On Wed, May 21, 2014 at 11:33 AM, Niranjan Karunanandham 
 niran...@wso2.com wrote:

 Hi Dilan,

 In case we are uploading zip files then the user needs to the format of
 the file in hand. I agree that we will have to store this files in the file
 system but you are forgetting an important thing that is in this version,
 the admin page will be there in the work nodes also. In this case, the
 worker nodes should also have commit rights so that it can be synchronized
 with the other nodes.

 Regards,
 Nira



 On Wed, May 21, 2014 at 11:29 AM, Chathura Dilan chathu...@wso2.comwrote:

 Hi Niranjan,

 That field represent the theme folder of the tenant. So let's fix the
 tenant configuration first to change the theme. Then I'll looking in to
 that separately regarding the best way to handle it.
 Uploading a zip file from the UI is the only option what we can do from
 UI, otherwise admin have to manually copy the theme to the file system.
 IMO storing the theme files in the registry is not a good option.

 I'm adding Ruchira and SameeraM and Manu also for their opinions also.


 On Wed, May 21, 2014 at 11:05 AM, Niranjan Karunanandham 
 niran...@wso2.com wrote:

 Hi Dilan,

 In the Tenant configuration, there is a field called UI Theme. If I am
 not mistaken there are quite a lot of files (images, css, etc...) that 
 need
 to be uploaded. How is this being implemented from the UI? I do not
 recommend sending zip files since there are different formats in zip and
 the pack can running in ubuntu, windows, mac, etc...

 Regards,
 Nira



 On Wed, May 21, 2014 at 9:08 AM, Niranjan Karunanandham 
 niran...@wso2.com wrote:

 Yes i had two more fields for ios but we need to have a separate one
 for email configs. Can u add it to the the tenant branch??
  On 21 May 2014 08:50, Chathura Dilan chathu...@wso2.com wrote:

 Hi Niranjan,

 That's good. If you need more fields, what you have to do is add it
 to .hbs file and that's all. other JS logic be will automatically 
 handled.


 On Wed, May 21, 2014 at 2:46 AM, Niranjan Karunanandham 
 niran...@wso2.com wrote:

 Hi Dilan,

 I have added some fields to the tenant configuration hbs files and
 committed it only to the feature/tenant-configurate file.

 Regards,
 Nira



 On Wed, May 21, 2014 at 12:56 AM, Niranjan Karunanandham 
 niran...@wso2.com wrote:

 Its fixed. Had a chat with chan and he told me that files need to
 be retrieved from request.getfile() and not from the ctx.


 On Tue, May 20, 2014 at 11:56 PM, Niranjan Karunanandham 
 niran...@wso2.com wrote:

 Hi Dilan,

 The file upload stream is not passed when the form is submitted.
 I am getting all the other values except the files. The two input 
 with type
 file is undefined.

 Regards,
 Nira

 --

 *Niranjan Karunanandham*
 Senior Software Engineer - WSO2 Inc.
 WSO2 Inc.: http://www.wso2.com
 M: +94 777 749 661 http:///




 --

 *Niranjan Karunanandham*
 Senior Software Engineer - WSO2 Inc.
 WSO2 Inc.: http://www.wso2.com
 M: +94 777 749 661 http:///




 --

 *Niranjan Karunanandham*
 Senior Software Engineer - WSO2 Inc.
 WSO2 Inc.: http://www.wso2.com
 M: +94 777 749 661 http:///




 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
 www.dilan.me




 --

 *Niranjan Karunanandham*
 Senior Software Engineer - WSO2 Inc.
 WSO2 Inc.: http://www.wso2.com
 M: +94 777 749 661 http:///




 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
 www.dilan.me




 --

 *Niranjan Karunanandham*
 Senior Software Engineer - WSO2 Inc.
 WSO2 Inc.: http://www.wso2.com
 M: +94 777 749 661 http:///




 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
 www.dilan.me




 --
 Dilshan Edirisuriya

 Senior Software Engineer - WSO2
 Mob: + 94 777878905
 http://wso2.com/




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] API Store list all the tenant domains publicly.

2014-05-22 Thread Chathura Dilan
Hi All,

We are using API Manager with our EMM 1.1.0 release to publish some of our
APIs which are consumed by Android devices.

We have API Store Jaggery app in our EMM

The API Store publicly list down all the tenants publicly in the front
page. So this could lead to a privacy issue.

Is there any workaround for this.

Thank you,



-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] API Store list all the tenant domains publicly.

2014-05-22 Thread Chathura Dilan
Adding Sumedha and Nuwan


On Thu, May 22, 2014 at 5:07 PM, Chathura Dilan chathu...@wso2.com wrote:

 Hi All,

 We are using API Manager with our EMM 1.1.0 release to publish some of our
 APIs which are consumed by Android devices.

 We have API Store Jaggery app in our EMM

 The API Store publicly list down all the tenants publicly in the front
 page. So this could lead to a privacy issue.

 Is there any workaround for this.

 Thank you,



 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
 www.dilan.me




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Error gets when executing sql query in UES data-api.jag

2014-06-18 Thread Chathura Dilan
Hi Sajini,

Yes it should be a valid JSON string to get JSON.parse method to work, you
can get more info about JSON.parse from [1][2]

[1] - http://www.w3schools.com/json/json_eval.asp
[2] - http://msdn.microsoft.com/en-us/library/ie/cc836466(v=vs.94).aspx


On Thu, Jun 19, 2014 at 9:04 AM, Sajini De Silva saj...@wso2.com wrote:

 Hi,

 It worked after changing the statement like below.

 var queryData = JSON.parse({\SQL Statement\ : \SELECT * FROM
 multiGraphTable2 where hostName = '
 41304041432.dmz.mgt.platformelb1.wso2.com' limit 10\});

 Thank you.
 Sajini.


 On Wed, Jun 18, 2014 at 11:48 PM, Tanya Madurapperuma ta...@wso2.com
 wrote:

 Hi Sajini,

 Did you also change the mappings as well?  Because the generated jag file
 has the mappings as for your initial query. So processing of the data in to
 the format that flot accepts happens according to that mapping.

 Thanks,
 Tanya


 On Wed, Jun 18, 2014 at 9:48 AM, Sajini De Silva saj...@wso2.com wrote:

 HI Kalpa,

 Yp it works fine with that query, but again there is an error with this
 query,

 var queryData = JSON.parse('{SQL Statement : SELECT * FROM
 `multiGraphTable2` where `hostName` = 'nameOftheHost' limit 10}');

 In the backend i get the following error.

 js:
 /monitoring-tool/gadgets/_9c7f9a50-f167-46bc-9e60-2fedd19e6b6f/data-api.jag,
 line 6: missing ) after argument list
 js:var queryData = JSON.parse('{SQL Statement : SELECT * FROM
 `multiGraphTable2` where `hostName` = 'nameOftheHost}');
 js:
 ^
 [2014-06-18 22:11:16,998] ERROR
 {org.jaggeryjs.jaggery.core.manager.WebAppManager} -
 org.jaggeryjs.scriptengine.exceptions.ScriptException:
 org.mozilla.javascript.EvaluatorException: Compilation produced 1 syntax
 errors.
 (/monitoring-tool/gadgets/_9c7f9a50-f167-46bc-9e60-2fedd19e6b6f/data-api.jag#1)
 org.jaggeryjs.scriptengine.exceptions.ScriptException:
 org.jaggeryjs.scriptengine.exceptions.ScriptException:
 org.mozilla.javascript.EvaluatorException: Compilation produced 1 syntax
 errors.
 (/monitoring-tool/gadgets/_9c7f9a50-f167-46bc-9e60-2fedd19e6b6f/data-api.jag#1)



 On Wed, Jun 18, 2014 at 10:07 PM, Kalpa Welivitigoda kal...@wso2.com
 wrote:

 Hi Sajini,

 Try,

 var queryData = JSON.parse('{SQL Statement : SELECT * FROM
 `multiGraphTable2` limit 10}');


 On Wed, Jun 18, 2014 at 9:25 PM, Sajini De Silva saj...@wso2.com
 wrote:

 Hi Udara,

 I copied mysql connector lib and this is the error I got.

 NetworkError: 500 Internal Server Error -
 https://localhost:9443/monitoring-tool/gadgets/_9c7f9a50-f167-46bc-9e60-2fedd19e6b6f/data-api.jag
 

 Thank you.


 On Wed, Jun 18, 2014 at 9:21 PM, Udara Rathnayake uda...@wso2.com
 wrote:

 Hi,

 Can you copy that error here?
 Hope you have relevant connector lib in Jaggery runtime.


 On Wed, Jun 18, 2014 at 8:57 PM, Sajini De Silva saj...@wso2.com
 wrote:

 Hi,

 I created a new gadget using a data source which worked fine. After
 creating the gadget I edited the sql query in data-api.jag like below.

 var queryData = JSON.parse('{SELECT * FROM `multiGraphTable2` limit
 10}');

 I run this query in mysql database and it gave me the correct
 results, but when I edited the data-api.jag with this query the gadget
 doesn't load and it gives an error in firebug.

 Any idea why this is happening?

 Thank you,
 Sajini.

 --
 Sajini De SIlva
 Software Engineer; WSO2 Inc.; http://wso2.com ,
 Email: saj...@wso2.com
 Blog: http://sajinid.blogspot.com/
 Git hub profile: https://github.com/sajinidesilva


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




 --
 *Udara Rathnayake*
 Software Engineer
 WSO2 Inc. : http://wso2.com

 Mobile : +94 772207239
 Twitter : http://twitter.com/udarakr
 Blog: http://udarakr.blogspot.com




 --
 Sajini De SIlva
 Software Engineer; WSO2 Inc.; http://wso2.com ,
 Email: saj...@wso2.com
 Blog: http://sajinid.blogspot.com/
 Git hub profile: https://github.com/sajinidesilva


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




 --
 Best Regards,

 Kalpa Welivitigoda
 Software Engineer, WSO2 Inc. http://wso2.com
 Email: kal...@wso2.com
 Mobile: +94776509215




 --
 Sajini De SIlva
 Software Engineer; WSO2 Inc.; http://wso2.com ,
 Email: saj...@wso2.com
 Blog: http://sajinid.blogspot.com/
 Git hub profile: https://github.com/sajinidesilva


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




 --
 Tanya Madurapperuma

 Software Engineer,
 WSO2 Inc. : wso2.com
 Mobile : +94718184439
 Blog : http://tanyamadurapperuma.blogspot.com




 --
 Sajini De SIlva
 Software Engineer; WSO2 Inc.; http://wso2.com ,
 Email: saj...@wso2.com
 Blog: http://sajinid.blogspot.com/
 Git hub profile: https://github.com/sajinidesilva


 

Re: [Dev] Can we use libs with MIT license, in WSO2 ?

2014-07-04 Thread Chathura Dilan
Bootstrap Select2 is also a good plugin which is released under MIT

https://fk.github.io/select2-bootstrap-css/3.4.5.html


On Fri, Jul 4, 2014 at 12:40 PM, Ruchira Wageesha ruch...@wso2.com wrote:

 It seems to be a good and well maintained plugin. So, I think you should
 be good to go.

 @Chanaka, Joe, Dilan,

 If you guys have a better alternative, please suggest.


 On Fri, Jul 4, 2014 at 8:47 AM, Sameera Perera samee...@wso2.com wrote:

 Hi Ruchira,
 Can someone from your team review this library? Also, in case there's an
 alternative that is already in use or is a better fit to other UI
 components we use; please suggest.

 On a cursory glance, it's only dependencies seem to be jQuery and
 Bootstrap; so relative safe unless we have an alternative already being
 used.

 Rushmin,
 Can you explain the your use case as to why we need this library? Just so
 that we can validate that the additional dependency is not for superfluous
 functionality :)


  On Thu, Jul 3, 2014 at 2:06 PM, Rushmin Fernando rush...@wso2.com
 wrote:

 Its just a Bootstrap extension which I'm planning to use in App Manager
 front end. Thought of using it rather than writing it from the scratch.

 [1] or [2] are the candidate components.

 [1] - http://montrezorro.github.io/bootstrap-checkbox/
 [2] - http://silviomoreto.github.io/bootstrap-select/




 On Thu, Jul 3, 2014 at 1:58 PM, Paul Fremantle p...@wso2.com wrote:

 You can use it from a legal perspective. However, you still need to get
 it reviewed and agreed for whether it fits into the architecture!
 What is the library?

 Paul


 On 3 July 2014 09:20, Rushmin Fernando rush...@wso2.com wrote:


 There is a UI component which I need. Its under MIT license. $subject
 please.


 --
 *Rushmin Fernando*
 *Technical Lead*

 WSO2 Inc. http://wso2.com/ - Lean . Enterprise . Middleware

 email : rush...@wso2.com
 mobile : +94772310855



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




 --
 Paul Fremantle
 CTO and Co-Founder, WSO2
 OASIS WS-RX TC Co-chair, Apache Member

 UK: +44 207 096 0336
 US: +1 646 595 7614

 blog: http://pzf.fremantle.org
 twitter.com/pzfreo
 p...@wso2.com

 wso2.com Lean Enterprise Middleware

 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.




 --
 *Rushmin Fernando*
 *Technical Lead*

 WSO2 Inc. http://wso2.com/ - Lean . Enterprise . Middleware

 email : rush...@wso2.com
 mobile : +94772310855



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




 --

 --

 *Sameera Perera*
 Director of Engineering
 gtalk: samee...@wso2.com
 Tel : 94 11 214 5345
 Fax :94 11 2145300
 *WSO2, Inc.* http://wso2.com/
 lean.enterprise.middleware





 --

 *Ruchira Wageesha**Associate Technical Lead*
 *WSO2 Inc. - lean . enterprise . middleware |  wso2.com http://wso2.com*

 *email: ruch...@wso2.com ruch...@wso2.com,   blog:
 ruchirawageesha.blogspot.com http://ruchirawageesha.blogspot.com,
 mobile: +94 77 5493444 %2B94%2077%205493444*




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [EMM] Devices Pending Operations APIs are different in APIM and Android

2014-08-12 Thread Chathura Dilan
Hi,

I have found that the pending operation APIs are different in APIM and
Android Agent in EMM

EMM creates and subscribes to a API called

GET /api/emm/devices/pendingOperations


but in Android agent  it calls an API called

POST /api/emm/notifications/pendingOperations/1.0.0


But in EMM there is no API called /devices/pendingOperations and it has
only notifications/pendingOperations/1.0.0


This might not going through APIM, seems android directly calls the API


-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [EMM] Devices Pending Operations APIs are different in APIM and Android

2014-08-12 Thread Chathura Dilan
Added a JIRA

https://wso2.org/jira/browse/EMM-719


On Tue, Aug 12, 2014 at 2:06 PM, Niranjan Karunanandham niran...@wso2.com
wrote:

 Hi Dilan,

 You are correct. We do not have an api as devices/pendingOperations in the
 Server. The valid one is notifications/pendingOperations. I believe the
 issue is at the startup.js which auto creates the apis and publishes it.
 Please create a public JIRA.

 Regards,
 Nira


 On Tue, Aug 12, 2014 at 1:57 PM, Chathura Dilan chathu...@wso2.com
 wrote:

 Hi,

 I have found that the pending operation APIs are different in APIM and
 Android Agent in EMM

 EMM creates and subscribes to a API called

 GET /api/emm/devices/pendingOperations


 but in Android agent  it calls an API called

 POST /api/emm/notifications/pendingOperations/1.0.0


 But in EMM there is no API called /devices/pendingOperations and it has
 only notifications/pendingOperations/1.0.0


 This might not going through APIM, seems android directly calls the API


 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
 www.dilan.me




 --

 *Niranjan Karunanandham*
 Senior Software Engineer - WSO2 Inc.
 WSO2 Inc.: http://www.wso2.com
 M: +94 777 749 661 http:///




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.* * [Mobile])*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Node is not joining with the cluster when using the hostname

2014-04-04 Thread Chathura Dilan
Hi,

$subject when refer to

https://docs.wso2.org/display/CLUSTER420/Configuring+the+Manager+Node

below configuration not working ( node does not join with the cluster)
elb.wso2.com is assigned to an IP address in  /etc/hosts

members
member
  hostNameelb.wso2.com/hostName
  port4500/port
/member
/members


It only works when IP address is used instead of the host name

Eg:
members
member
  hostNamexx.xx.xx.xx/hostName
  port4500/port
/member
/members





-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer - WSO2 Mobile)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Bug in APPM ES branch GenricExecuter.java class

2014-12-04 Thread Chathura Dilan
Hi All,

There is a bug in APPM ES branch[1] which does not allow mobileapps to
attach permissions which is defined in the LifeCycle. This bug is inherited
from ES 1.0.0 and it is fixed in ES 2.0.0.
However webapps are working fine with a workaround in web app extension
while the mobile apps breaks. But the workaround is not the best way to
handle it.


In APPM ES branch GenricExecuter.java class[1] following code (Line
102 -110)


String
stringTenantId=Integer.toString(PrivilegedCarbonContext.getThreadLocalCarbonContext().getTenantId());

try{

this.tenantId=RealmContext.getRealmService().getTenantManager().getTenantId(stringTenantId);
}
catch(Exception e){
log.debug(Failed to obtain Tenant id);
}



   Should be replace with following code as in ES 2.0[2]



   String
stringTenantId=Integer.toString(PrivilegedCarbonContext.getThreadLocalCarbonContext().getTenantId());

try{

this.tenantId=RealmContext.getRealmService().getTenantManager().getTenantId(stringTenantId);
}
catch(Exception e){
log.debug(Failed to obtain Tenant id);
}


I tested the fix for both webapp and mobileapp and they worked.


[1] -
https://github.com/wso2/product-es/blob/es-1.0.1-apm-reg/modules/components/jaggery-scxml-executors/src/main/java/org/wso2/jaggery/scxml/generic/GenericExecutor.java
[2] -
https://github.com/wso2/product-es/blob/master/modules/components/jaggery-scxml-executors/src/main/java/org/wso2/jaggery/scxml/generic/GenericExecutor.java



-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Bug in APPM ES branch GenricExecuter.java class

2014-12-04 Thread Chathura Dilan
Hi Ruwan,

Yes, Tenant name should be passed instead of tenant ID. That is a bug in ES
1.0 which makes that java code to malfunction. It is confirmed by SameeraM.

On Fri, Dec 5, 2014 at 8:57 AM, Ruwan Yatawara ruw...@wso2.com wrote:

 Hi Chathura,

 The two code blocks you have listed seem to be exactly the same. But i
 believe the fix you are referring to is passing the teantDomain instead of
 the tenantId to the 
 RealmContext.getRealmService().getTenantManager().getTenantId
 method, is it?


 Thanks and Regards,

 Ruwan


 On 4 Dec 2014 15:01, Chathura Dilan chathu...@wso2.com wrote:

 Hi All,

 There is a bug in APPM ES branch[1] which does not allow mobileapps to
 attach permissions which is defined in the LifeCycle. This bug is inherited
 from ES 1.0.0 and it is fixed in ES 2.0.0.
 However webapps are working fine with a workaround in web app extension
 while the mobile apps breaks. But the workaround is not the best way to
 handle it.


 In APPM ES branch GenricExecuter.java class[1] following code
 (Line 102 -110)


 String
 stringTenantId=Integer.toString(PrivilegedCarbonContext.getThreadLocalCarbonContext().getTenantId());

 try{

 this.tenantId=RealmContext.getRealmService().getTenantManager().getTenantId(stringTenantId);
 }
 catch(Exception e){
 log.debug(Failed to obtain Tenant id);
 }



Should be replace with following code as in ES 2.0[2]



String
 stringTenantId=Integer.toString(PrivilegedCarbonContext.getThreadLocalCarbonContext().getTenantId());

 try{

 this.tenantId=RealmContext.getRealmService().getTenantManager().getTenantId(stringTenantId);
 }
 catch(Exception e){
 log.debug(Failed to obtain Tenant id);
 }


 I tested the fix for both webapp and mobileapp and they worked.


 [1] -
 https://github.com/wso2/product-es/blob/es-1.0.1-apm-reg/modules/components/jaggery-scxml-executors/src/main/java/org/wso2/jaggery/scxml/generic/GenericExecutor.java
 [2] -
 https://github.com/wso2/product-es/blob/master/modules/components/jaggery-scxml-executors/src/main/java/org/wso2/jaggery/scxml/generic/GenericExecutor.java



 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.**)*
 www.dilan.me




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Permissions issues with some default roles in WSO2 App Manager

2015-02-06 Thread Chathura Dilan
​Hi,

FYI, Here is how Mobile Apps works.

Roles

1. Intermal/Publisher
2. Internal/Reviewer
3. admin (admin has ability to perform all operations below)

-
*Main Flow*

*Publisher*
1. Publisher *create* the app
2. App goes to *Created* state
3. Publisher *submit* the app
4. App goes to *In-review *state

*Reviewer*
5. Reviewer *approve* the app
6.  App goes to* Approved* state

*Publisher*
7. Publisher *publish* the app
8. App goes to *Published* state.

---
*Alternative flow 1*

*Reviewer*
4.1. Reviewer* reject* the App
4.2 App goes to *Rejected* state

*Publisher*
4.3 Publisher *resubmit* the App
4.4 App Goes to *In-review* state


---
*Alternative flow 2*

*Publisher*
8.1 Publisher *un-publish* the app
8.2 App goes to  *Un-published* state
8. Publisher *publish* the app
8.4. App goes to *Published *state

8.2.1 Publisher *retire* the app
8.2.2 App goes to *Retired* state​

On Fri, Feb 6, 2015 at 2:25 PM, Dinusha Senanayaka dinu...@wso2.com wrote:

 Hi Thilini,



 On Fri, Feb 6, 2015 at 2:07 PM, Thilini Shanika thili...@wso2.com wrote:

 Hi,
 Need some clarification regarding the issue - [1].

 In super tenant mode all the default roles can be seen once we login to
 carbon console(Internal/everyone, Internal/publisher, Internal/reviewer, 
 Internal/subscriber,
 admin roles) . But in tenant mode, when we initially log in to admin
 console, we can only see admin, Internal/everyone, Internal/subscriber
 roles only and some roles are missing. But once we login to publisher, the
 missing roles - Internal/publisher and Internal/reviewer are generated.

 Is this the expected behavior or do we need to make those missing roles
 available in tenant mode also?


 This is a bug. Internal/publisher and Internal/reviewer roles also need to
 be created at the tenant loading time. i.e even when you login to the
 carbon-mgt console for the first time this role need to be get created in
 the same way we do for internal/subscriber role.

 Regards,
 Dinusha.


 [1] - https://wso2.org/jira/browse/APPM-332

 On Mon, Feb 2, 2015 at 12:35 PM, Ruwan Yatawara ruw...@wso2.com wrote:

 Hi Thilini,

 The internal/store role is pretty much obsolete AFAIK. However there are
 specific validations on the roles i've listed below .

 intermal/publisher - Can create Apps but cannot publish
 internal/reviewer - Ones, publisher submits for an app to be published,
 reviewer permission is needed to approve said request.
 internal/subscriber - This role needs to be available for anyone to be
 able to login to the store.

 However, IMHO i believe this is wrong and we should change it (Had a
 chat with Manu and I think this is the same way things are implemented in
 ES).

 *What we should do is basically go for a permission check rather than
 check for a role*. For an instance for creating of apps we should check
 if a particular user has api/create *permission *(can be of any role) and
 to publish api/publish, permission etc. For the store however, its ok to
 have a role based check as there is no specific reference to store access
 in the permission tree.


 Thanks and Regards,

 Ruwan Yatawara

 Senior Software Engineer,
 WSO2 Inc.

 email : ruw...@wso2.com
 mobile : +94 77 9110413
 blog : http://thoughts.ruwan-ace.com/
 www: :http://wso2.com


 On Sun, Feb 1, 2015 at 11:31 AM, Thilini Shanika thili...@wso2.com
 wrote:

 Hi all,

 There are several bugs reported regarding the permission issues of
 default roles in App Manager. In order to fix and resolve them, we need to
 clarify what are the exact usage  and permissions which should assigned
 with those roles.

 The roles which were subjected to permission issues are listed below
 with the current permissions assigned.

- Internal/store-admin   - Login
- Internal/store  - Login
- Internal/reviewer-  Login

 Can you please specify what are the usage, and whether the current
 permissions assigned are correct? If not correct what are the exact
 permissions that these roles should be assigned with?

 --
 Thilini Shanika
 Software Engineer
 WSO2, Inc.; http://wso2.com
 20, Palmgrove Avenue, Colombo 3

 E-mail: tgtshan...@gmail.com





 --
 Thilini Shanika
 Software Engineer
 WSO2, Inc.; http://wso2.com
 20, Palmgrove Avenue, Colombo 3

 E-mail: tgtshan...@gmail.com




 --
 Dinusha Dilrukshi
 Senior Software Engineer
 WSO2 Inc.: http://wso2.com/
 Mobile: +94725255071
 Blog: http://dinushasblog.blogspot.com/




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Permissions issues with some default roles in WSO2 App Manager

2015-02-06 Thread Chathura Dilan
Hi Thilini,

I think it is coming form ES. In publisher those roles are created when the
admin user first login to the publisher. +1 for Dinusha's suggestion

On Fri, Feb 6, 2015 at 2:25 PM, Dinusha Senanayaka dinu...@wso2.com wrote:

 Hi Thilini,



 On Fri, Feb 6, 2015 at 2:07 PM, Thilini Shanika thili...@wso2.com wrote:

 Hi,
 Need some clarification regarding the issue - [1].

 In super tenant mode all the default roles can be seen once we login to
 carbon console(Internal/everyone, Internal/publisher, Internal/reviewer, 
 Internal/subscriber,
 admin roles) . But in tenant mode, when we initially log in to admin
 console, we can only see admin, Internal/everyone, Internal/subscriber
 roles only and some roles are missing. But once we login to publisher, the
 missing roles - Internal/publisher and Internal/reviewer are generated.

 Is this the expected behavior or do we need to make those missing roles
 available in tenant mode also?


 This is a bug. Internal/publisher and Internal/reviewer roles also need to
 be created at the tenant loading time. i.e even when you login to the
 carbon-mgt console for the first time this role need to be get created in
 the same way we do for internal/subscriber role.

 Regards,
 Dinusha.


 [1] - https://wso2.org/jira/browse/APPM-332

 On Mon, Feb 2, 2015 at 12:35 PM, Ruwan Yatawara ruw...@wso2.com wrote:

 Hi Thilini,

 The internal/store role is pretty much obsolete AFAIK. However there are
 specific validations on the roles i've listed below .

 intermal/publisher - Can create Apps but cannot publish
 internal/reviewer - Ones, publisher submits for an app to be published,
 reviewer permission is needed to approve said request.
 internal/subscriber - This role needs to be available for anyone to be
 able to login to the store.

 However, IMHO i believe this is wrong and we should change it (Had a
 chat with Manu and I think this is the same way things are implemented in
 ES).

 *What we should do is basically go for a permission check rather than
 check for a role*. For an instance for creating of apps we should check
 if a particular user has api/create *permission *(can be of any role) and
 to publish api/publish, permission etc. For the store however, its ok to
 have a role based check as there is no specific reference to store access
 in the permission tree.


 Thanks and Regards,

 Ruwan Yatawara

 Senior Software Engineer,
 WSO2 Inc.

 email : ruw...@wso2.com
 mobile : +94 77 9110413
 blog : http://thoughts.ruwan-ace.com/
 www: :http://wso2.com


 On Sun, Feb 1, 2015 at 11:31 AM, Thilini Shanika thili...@wso2.com
 wrote:

 Hi all,

 There are several bugs reported regarding the permission issues of
 default roles in App Manager. In order to fix and resolve them, we need to
 clarify what are the exact usage  and permissions which should assigned
 with those roles.

 The roles which were subjected to permission issues are listed below
 with the current permissions assigned.

- Internal/store-admin   - Login
- Internal/store  - Login
- Internal/reviewer-  Login

 Can you please specify what are the usage, and whether the current
 permissions assigned are correct? If not correct what are the exact
 permissions that these roles should be assigned with?

 --
 Thilini Shanika
 Software Engineer
 WSO2, Inc.; http://wso2.com
 20, Palmgrove Avenue, Colombo 3

 E-mail: tgtshan...@gmail.com





 --
 Thilini Shanika
 Software Engineer
 WSO2, Inc.; http://wso2.com
 20, Palmgrove Avenue, Colombo 3

 E-mail: tgtshan...@gmail.com




 --
 Dinusha Dilrukshi
 Senior Software Engineer
 WSO2 Inc.: http://wso2.com/
 Mobile: +94725255071
 Blog: http://dinushasblog.blogspot.com/




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [ES] [APPM] Creating a duplicate assets exception is shown

2015-01-15 Thread Chathura Dilan
Hi,

Regarding the issue[1], IMO this is a user error and this should not be
shown to the backend as a exception. Exception should be thrown to the UI
layer to handle. WDYT?


[1]- https://wso2.org/jira/browse/APPM-310

-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [Carbon] Getting tenant domain and tenant admin username from the tenant id

2015-03-09 Thread Chathura Dilan
Hi All,

Is there a way to get the tenant domain name and the tenant admin username
when tenantId is provided to
PrivilegedCarbonContext.getThreadLocalCarbonContext()?


Thanks

-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [Carbon] Getting tenant domain and tenant admin username from the tenant id

2015-03-09 Thread Chathura Dilan
Thanks, it worked

On Mon, Mar 9, 2015 at 4:58 PM, Shashika Karunatilaka shashi...@wso2.com
wrote:

 HI Chathura,

 If you start a tenant flow you can set the tenant Id and from that you can
 get the tenant domain from below code
 PrivilegedCarbonContext.getThreadLocalCarbonContext().setTenantId(tenantId,
 true);
 setTenantId with boolean argument it will resolve the tenant domain. or
 else you can get from
 PrivilegedCarbonContext.getThreadLocalCarbonContext().getTenantDomain();

 To get the admin user name you can use realmConfig

 PrivilegedCarbonContext.getThreadLocalCarbonContext().getUserRealm().getRealmConfiguration().getAdminUserName()

 Thank you.

 On Mon, Mar 9, 2015 at 4:48 PM, Chathura Dilan chathu...@wso2.com wrote:

 Hi All,

 Is there a way to get the tenant domain name and the tenant admin
 username when tenantId is provided to
 PrivilegedCarbonContext.getThreadLocalCarbonContext()?


 Thanks

 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.**)*
 www.dilan.me

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




 --
 Shashika Prabath Karunatilaka,
 Software Engineer,
 WSO2, Inc: http://wso2.com/
 mobile : +94 77 7487792




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [AppM] [EMM] Patch for EMM to work with AppM 1.0.0

2015-04-01 Thread Chathura Dilan
Hi All,

I have created patch for EMM 1.1.0 to work it with AppM 1.0.0. You can find
the patch from this JIRA[1]


[1] - https://wso2.org/jira/browse/APPM-692


-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [AppM] [EMM] Patch for EMM to work with AppM 1.0.0

2015-04-02 Thread Chathura Dilan
Hi Yasassri,

I attached the README with the task

On Thu, Apr 2, 2015 at 11:23 AM, Yasassri Ratnayake yasas...@wso2.com
wrote:

 Hi Chathura,

 I'm unable to find a READ-ME file in the patch. Can you kindly point me to
 the correct location if I have missed it. If its not there can we add a
 Read-Me with the instructions?

 With Regards,

 On Thu, Apr 2, 2015 at 11:18 AM, Chathura Dilan chathu...@wso2.com
 wrote:

 Hi All,

 I have created patch for EMM 1.1.0 to work it with AppM 1.0.0. You can
 find the patch from this JIRA[1]


 [1] - https://wso2.org/jira/browse/APPM-692


 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.**)*
 www.dilan.me




 --
 Yasassri Ratnayake
 Software Engineer - QA
 WSO2 Inc ; http://wso2.com
 lean.enterprise.middleware
 *Mobile : +94715933168 %2B94715933168*
 *Blog : http://yasassriratnayake.blogspot.com/
 http://yasassriratnayake.blogspot.com/*




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [AppM] [EMM] Patch for EMM to work with AppM 1.0.0

2015-04-30 Thread Chathura Dilan
you can follow this[1] documentation for EMM integration.

[1] -
https://docs.wso2.com/display/APPM100/Integrating+a+Mobile+Device+Manager

On Thu, Apr 2, 2015 at 11:59 AM, Chathura Dilan chathu...@wso2.com wrote:

 Hi Yasassri,

 I attached the README with the task

 On Thu, Apr 2, 2015 at 11:23 AM, Yasassri Ratnayake yasas...@wso2.com
 wrote:

 Hi Chathura,

 I'm unable to find a READ-ME file in the patch. Can you kindly point me
 to the correct location if I have missed it. If its not there can we add a
 Read-Me with the instructions?

 With Regards,

 On Thu, Apr 2, 2015 at 11:18 AM, Chathura Dilan chathu...@wso2.com
 wrote:

 Hi All,

 I have created patch for EMM 1.1.0 to work it with AppM 1.0.0. You can
 find the patch from this JIRA[1]


 [1] - https://wso2.org/jira/browse/APPM-692


 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.**)*
 www.dilan.me




 --
 Yasassri Ratnayake
 Software Engineer - QA
 WSO2 Inc ; http://wso2.com
 lean.enterprise.middleware
 *Mobile : +94715933168 %2B94715933168*
 *Blog : http://yasassriratnayake.blogspot.com/
 http://yasassriratnayake.blogspot.com/*




 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.**)*
 www.dilan.me




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [MDM] Is it possible to get device language, country and carrier?

2015-04-29 Thread Chathura Dilan
Hi All,

Is it possible to get the language, country and carrier form a device from
WSO2 MDM? It will be useful for stats.

-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [GReg] Exception thrown when adding a duplicate artifacts with same title and version

2015-04-27 Thread Chathura Dilan
Hi All,

This is regarding the JIRA issue [1]. When user try to create a new
artifact with same name and title, an exception is printed in logs with
whole stack trace. as follows


ERROR - GovernanceArtifactManager Failed to add artifact: artifact id:
33b672f3-5d65-4678-b1d1-c7fc5680d974. Governance artifact Title
already exists at /mobileapps/creator2/android/Title/1.0
org.wso2.carbon.governance.api.exception.GovernanceException:
Governance artifact Title already exists at
/mobileapps/creator2/android/Title/1.0
at 
org.wso2.carbon.governance.api.common.GovernanceArtifactManager.addGovernanceArtifact(GovernanceArtifactManager.java:189)
at 
org.wso2.carbon.governance.api.generic.GenericArtifactManager.addGenericArtifact(GenericArtifactManager.java:170)
at sun.reflect.GeneratedMethodAccessor345.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)


 IMO this is not necessary since it is a user error. What's your idea on
this?

[1] - https://wso2.org/jira/browse/APPM-572

-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [MDM] Device List properties are getting as objects in an array

2015-05-11 Thread Chathura Dilan
Hi All,

Currently in WSO2 MDM device list API (mdm-admin/devices/{userId})

 Properties are getting as a objects in an array like following

properties: [
{
name: imei,
value: 310260043444000
},
{
name: imsi,
value: 310264430
},
{
name: model,
value: Google Nexus 5
},
{
name: osVersion,
value: 5.0
},
{
name: vendor,
value: Genymotion
}
]


This is cumbersome when searching for a value of a property, because it
needs be to looped through the whole array. Would be easy if  it can be
presented  as a whole object with key value pairs like follows

properties : {
  imie : 434243242432434,
  imsi  : 643534242424243,
  model : Google Nexus 5

}



-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] GenericArtifacts Pagination

2015-04-11 Thread Chathura Dilan
Hi Shazni,

Thank you, I will try it

On Sun, Apr 12, 2015 at 8:44 AM, Shazni Nazeer sha...@wso2.com wrote:

 Hi Chathura,

 You may try using get(path, int, int) in Registry class. This is a method
 defined in the CoreRegistry interface in the org.wso2.carbon.registry.core
 package. Registry class implements this interface. This method returns the
 collection you need.

 Shazni Nazeer

 Senior Software Engineer

 Mob : +94 37331
 LinkedIn : http://lk.linkedin.com/in/shazninazeer
 Blog : http://shazninazeer.blogspot.com

 On Mon, Apr 6, 2015 at 4:51 PM, Chathura Dilan chathu...@wso2.com wrote:

 Hi All,

 I want to get artifact set by giving  offset and limit. I tried with
 PaginationContext but I'm not getting the expected output.

 Can anyone explain how PaginationContext.init() is working and how to set
 offset and limit to get a specific artifact set.

 Eg. If I have 1000 artifacts and I want to get the artifacts between 20
 and 50, how offset (which is 20) and limit (which is 30) can be used in
 PaginationContext.init().

 ​Thanks​

 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.**)*
 www.dilan.me

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





-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] GenericArtifacts Pagination

2015-04-06 Thread Chathura Dilan
Hi All,

I want to get artifact set by giving  offset and limit. I tried with
PaginationContext but I'm not getting the expected output.

Can anyone explain how PaginationContext.init() is working and how to set
offset and limit to get a specific artifact set.

Eg. If I have 1000 artifacts and I want to get the artifacts between 20 and
50, how offset (which is 20) and limit (which is 30) can be used in
PaginationContext.init().

​Thanks​

-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [AppM] Issue with clustering AppM with large mobile apps

2015-05-20 Thread Chathura Dilan
Hi All,

In App Manager users can upload mobile applications though publisher
Jaggery app and others can download them from that app.

Uploaded mobile applications are currently saved in
/repository/resources/mobileapps folder in the server home.

We have a issue in clustering AppM, since /repository/resources/mobileapps
not synced in all nodes of the cluster.

Mobile apps can be large files and we can neither store them in the
registry nor move it to  /repository/deployment folder for dep sync. If we
take uploaded mobile apps all together sometimes it could exceed 10GB.

Only way is to store them in a central location. Do we have any solution to
address it? or is there any better approach to save those binaries to a
central location.


Thank you,

-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [AppM] Issue with clustering AppM with large mobile apps

2015-05-21 Thread Chathura Dilan
Thanks Ruwan and Sajith.

NuwanS and I tested it with mounting a common location for all nodes of the
cluster and pointing that location as the file repository and it worked.
Since mobile apps are stored in the file system, it is the only and
effective option we have now.

for more information refer to this[1] JIRA

[1] - https://wso2.org/jira/browse/APPM-943


Thank you,


On Wed, May 20, 2015 at 6:02 PM, Sajith Ariyarathna sajit...@wso2.com
wrote:

 Hi Chathura,

 My suggestion is to give the capability of specifying a location (path) to
 the admin user.

 Admin user can specify a location in the configuration file
 (app-manager.xml). Then he can mount that location to all nodes in the
 cluster. So, in Java we can access that location.

 This approach have several advantages:

- High fault tolerance. Because we can safely assume that admin user
will choose a secured location with a low downtime.
- No extra effort to read/write data, because location will be mounted
to every node.
- Less implementation burden as we don't have to use any extra
libraries.


 Cheers.

 On Wed, May 20, 2015 at 5:07 PM, Chathura Dilan chathu...@wso2.com
 wrote:

 Hi All,

 In App Manager users can upload mobile applications though publisher
 Jaggery app and others can download them from that app.

 Uploaded mobile applications are currently saved in
 /repository/resources/mobileapps folder in the server home.

 We have a issue in clustering AppM, since
 /repository/resources/mobileapps not synced in all nodes of the cluster.

 Mobile apps can be large files and we can neither store them in the
 registry nor move it to  /repository/deployment folder for dep sync. If we
 take uploaded mobile apps all together sometimes it could exceed 10GB.

 Only way is to store them in a central location. Do we have any solution
 to address it? or is there any better approach to save those binaries to a
 central location.


 Thank you,

 --
 Regards,

 Chatura Dilan Perera
 *(Senior Software Engineer** - WSO2 Inc.**)*
 www.dilan.me




 --
 Sajith Ariyarathna
 Software Engineer; WSO2, Inc.;  http://wso2.com/
 mobile: +94 77 6602284, +94 71 3951048




-- 
Regards,

Chatura Dilan Perera
*(Senior Software Engineer** - WSO2 Inc.**)*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [AppM] Merging new UI changes to AppM master branch

2015-08-24 Thread Chathura Dilan
Hi All,

I merged new store and login page UI changes  to app manager master branch.
Main changes are follows.

1. Upgrade Bootstrap version 3 from 2.
2. Adopt the new UI layout which is built by WSO2.
3. Change partials and js files for bootstrap 3.
4. Added responsive styles for mobile, tablets and desktops.

Following tasks are pending and we can fix them while progressing.

1. Commenting and Ratings.
2. Enterprise subscription for web apps.
3. Pagination and sorting.
4. Fix small UI and UX issues.

Please contribute your UI and UX improvements and suggestions to the new
changes.

Thanks.

-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] App Manager integration with MDM(EMM)

2015-11-16 Thread Chathura Dilan
Hi Dinusha,

I think they are doing it with dynamic client key/sec generating API. So we
will have to go with that approach if we use their REST API. They didn't
have it earlier and and they used API manager inside MDM server to generate
it.

As we discussed we can do all the operations via OSGI for OOTB solution.

On Mon, Nov 16, 2015 at 11:59 AM, Dinusha Senanayaka 
wrote:

> Hi Ruwan,
>
> Need some help to figure out, OSGi based MDM integration.
>
> Found this commit relate to this "[carbon-appmgt] Added OSGI based MDM
> integration. (#103)"
>
> But not sure EMM has merged this to their repo. Do you have any idea ?
>
> @Chathura:  How do we get consumer/secret key from MDM with JAX-RS
> integration ? (EMM doesn't have provided UI for this).
>
> Regards,
> Dinusha
>
>
>
> --
> Dinusha Dilrukshi
> Associate Technical Lead
> WSO2 Inc.: http://wso2.com/
> Mobile: +94725255071
> Blog: http://dinushasblog.blogspot.com/
>



-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Content repository for App Manager

2015-08-30 Thread Chathura Dilan
+1 for Amazon EFS. IMO that kind of a solution exactly what we need.

On Sun, Aug 30, 2015 at 6:15 PM, Ruwan Abeykoon ruw...@wso2.com wrote:

 Hi Dinusha,
 For AWS customer can use EFS[1]. Most major cloud providers support
 similar services. IMO we should not do much on storage side because storage
 is best managed by file systems and OS drivers.

 However we need to optimize our front end (HTTP) to get Zero-copy based
 serving, may be using netty transports.
 One other concern is that whether we server content using HTTPS. We will
 not be able to use much of Zero copy optimizations if we use HTTPS. So I
 think we should use HTTP for serving user uploaded image files and signed
 mobile archives.

 Cheers,
 Ruwan

 [1] https://aws.amazon.com/efs/

 On Sun, Aug 30, 2015 at 5:41 PM, Dinusha Senanayaka dinu...@wso2.com
 wrote:

 Hi,

 For the mobile apps we need to store the .apk files. Currently we use the
 file system based storage which has used in EMM-1.0.0 (Stored in
 repository/resources/).  In a cluster environment we need to have a shared
 file system. This become difficult in a could deployment like AWS.

 Also in future we might need to have a content repository with the other
 types of app support like desktop application etc. One option is to extend
 and use the DepSync. Do we have any other suggestions here ?

 Regards,
 Dinusha.


 --
 Dinusha Dilrukshi
 Associate Technical Lead
 WSO2 Inc.: http://wso2.com/
 Mobile: +94725255071
 Blog: http://dinushasblog.blogspot.com/




 --

 *Ruwan Abeykoon*
 *Architect,*
 *WSO2, Inc. http://wso2.com http://wso2.com/ *
 *lean.enterprise.middleware.*

 email: ruw...@wso2.com




-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] App Manager Test Framework is upgraded to 4.4.2

2015-09-08 Thread Chathura Dilan
Hi all,

I have upgraded App Manager Test Framework to 4.4.2

Following tasks has been done

1. Upgraded App Manager Test Framework to 4.4.2 from 4.3
2. Changed the test port offset to 600
3. Create a custom CarbonServerExtension to change port values of the
configuration files app-manager.xml and sso-idp-conf.xml
4. Added a Test Case to AppM publisher Sign In

However previous test cases are not working due to API changes of the test
framework. We need to rewrite them to work with 4.4.2

-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] App Manager Test Framework is upgraded to 4.4.2

2015-09-10 Thread Chathura Dilan
Hi Krishantha,

Sorry, previous test cases use 4.2.7 for UI automation and we are no longer
using org.wso2.carbon.automation.core.utils,
 org.wso2.carbon.automation.utils.esb
and org.wso2.carbon.automation.utils.services packages . Previous test
cases are heavily depend on their classes, therefore, we will have to write
test cases from the scratch.

On Thu, Sep 10, 2015 at 10:47 AM, Krishantha Samaraweera <
krishan...@wso2.com> wrote:

>
>
> On Tue, Sep 8, 2015 at 12:00 PM, Chathura Dilan <chathu...@wso2.com>
> wrote:
>
>> Hi all,
>>
>> I have upgraded App Manager Test Framework to 4.4.2
>>
>> Following tasks has been done
>>
>> 1. Upgraded App Manager Test Framework to 4.4.2 from 4.3
>> 2. Changed the test port offset to 600
>> 3. Create a custom CarbonServerExtension to change port values of the
>> configuration files app-manager.xml and sso-idp-conf.xml
>> 4. Added a Test Case to AppM publisher Sign In
>>
>> However previous test cases are not working due to API changes of the
>> test framework. We need to rewrite them to work with 4.4.2
>>
>
> I don't think you need to rewrite all tests here. Just fixing the
> compilations failures wouldn't be enough ? TAF 4.3 already contain major
> api changes. Changes we have introduced in 4.4.2 is related to exception
> handling etc..
>
> Thanks,
> Krishantha.
>
>
>> --
>> Regards,
>>
>> Chatura Dilan Perera
>> *Senior Software Engineer** - WSO2 Inc.*
>> www.dilan.me
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Krishantha Samaraweera
> Senior Technical Lead - Test Automation
> Mobile: +94 77 7759918
> WSO2, Inc.; http://wso2.com/
> lean . enterprise . middleware.
>



-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] App Manager Test Framework is upgraded to 4.4.2

2015-09-10 Thread Chathura Dilan
Hi Krishantha,

Thanks, I will check that

On Thu, Sep 10, 2015 at 1:33 PM, Krishantha Samaraweera <krishan...@wso2.com
> wrote:

> Hi Dilan,
>
> On Thu, Sep 10, 2015 at 12:20 PM, Chathura Dilan <chathu...@wso2.com>
> wrote:
>
>> Hi Krishantha,
>>
>> Sorry, previous test cases use 4.2.7 for UI automation and we are no
>> longer using org.wso2.carbon.automation.core.utils,
>>  org.wso2.carbon.automation.utils.esb
>> and org.wso2.carbon.automation.utils.services packages . Previous test
>> cases are heavily depend on their classes, therefore, we will have to write
>> test cases from the scratch.
>>
>
> I can't understand why you need to write test cases from the scratch. You
> just need to modify the test initialisation logic.
>
> We did migrate 1000 tests in G-Reg and ESB but never rewrite the tests
> again.
>
> Thanks,
> Krishantha.
>
>
>> On Thu, Sep 10, 2015 at 10:47 AM, Krishantha Samaraweera <
>> krishan...@wso2.com> wrote:
>>
>>>
>>>
>>> On Tue, Sep 8, 2015 at 12:00 PM, Chathura Dilan <chathu...@wso2.com>
>>> wrote:
>>>
>>>> Hi all,
>>>>
>>>> I have upgraded App Manager Test Framework to 4.4.2
>>>>
>>>> Following tasks has been done
>>>>
>>>> 1. Upgraded App Manager Test Framework to 4.4.2 from 4.3
>>>> 2. Changed the test port offset to 600
>>>> 3. Create a custom CarbonServerExtension to change port values of the
>>>> configuration files app-manager.xml and sso-idp-conf.xml
>>>> 4. Added a Test Case to AppM publisher Sign In
>>>>
>>>> However previous test cases are not working due to API changes of the
>>>> test framework. We need to rewrite them to work with 4.4.2
>>>>
>>>
>>> I don't think you need to rewrite all tests here. Just fixing the
>>> compilations failures wouldn't be enough ? TAF 4.3 already contain major
>>> api changes. Changes we have introduced in 4.4.2 is related to exception
>>> handling etc..
>>>
>>> Thanks,
>>> Krishantha.
>>>
>>>
>>>> --
>>>> Regards,
>>>>
>>>> Chatura Dilan Perera
>>>> *Senior Software Engineer** - WSO2 Inc.*
>>>> www.dilan.me
>>>>
>>>> ___
>>>> Dev mailing list
>>>> Dev@wso2.org
>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>>
>>>>
>>>
>>>
>>> --
>>> Krishantha Samaraweera
>>> Senior Technical Lead - Test Automation
>>> Mobile: +94 77 7759918
>>> WSO2, Inc.; http://wso2.com/
>>> lean . enterprise . middleware.
>>>
>>
>>
>>
>> --
>> Regards,
>>
>> Chatura Dilan Perera
>> *Senior Software Engineer** - WSO2 Inc.*
>> www.dilan.me
>>
>
>
>
> --
> Krishantha Samaraweera
> Senior Technical Lead - Test Automation
> Mobile: +94 77 7759918
> WSO2, Inc.; http://wso2.com/
> lean . enterprise . middleware.
>



-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] App Manager Test Framework is upgraded to 4.4.2

2015-09-09 Thread Chathura Dilan
Hi all,

You can run App Manager UI Integration tests using following command

mvn clean install -DskipUiTests=false

however WSO2 Jenkins builds the product-appmanager without skipping the UI
tests by setting skipUiTests value to false

On Tue, Sep 8, 2015 at 12:00 PM, Chathura Dilan <chathu...@wso2.com> wrote:

> Hi all,
>
> I have upgraded App Manager Test Framework to 4.4.2
>
> Following tasks has been done
>
> 1. Upgraded App Manager Test Framework to 4.4.2 from 4.3
> 2. Changed the test port offset to 600
> 3. Create a custom CarbonServerExtension to change port values of the
> configuration files app-manager.xml and sso-idp-conf.xml
> 4. Added a Test Case to AppM publisher Sign In
>
> However previous test cases are not working due to API changes of the test
> framework. We need to rewrite them to work with 4.4.2
>
> --
> Regards,
>
> Chatura Dilan Perera
> *Senior Software Engineer** - WSO2 Inc.*
> www.dilan.me
>



-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [EMM] Why we are using 404 for "No Content" responses ?

2016-06-15 Thread Chathura Dilan
​Yes

Take an API like /devices and if there are no records in it, return an
empty array. In this case the collection there is empty but it does exist.
So we cannot return 404 and use 200 instead.
If it is an single resource like devices/{deviceId} and if it is not found
return 404, because it does not exist.


On Wed, Jun 15, 2016 at 11:42 AM, Ruwan Yatawara  wrote:

> However, as per the implementation, since what is drawn from '/devices' is
> a list of resources.. and not an individual device. I believe a 200 ok with
> an empty set is acceptable.
>
>
> Thanks and Regards,
>
> Ruwan Yatawara
>
> Associate Technical Lead,
> WSO2 Inc.
>
> email : ruw...@wso2.com
> mobile : +94 77 9110413
> blog : http://ruwansrants.blogspot.com/
>   https://500px.com/ruwan_ace
> www: :http://wso2.com
>
>
> On Wed, Jun 15, 2016 at 11:26 AM, Ruwan Yatawara  wrote:
>
>> In the devices example that's used, it is my opinion that the device that
>> you are trying to locate is the resource, "/devices" is merely the context.
>> Therefore if a resource cannot be located a 404 no content is acceptable.
>> However, when looking at things from a AJAX request perspective, this kind
>> of scenario become tricky to handle.
>>
>> Even when I started on working on the UI stabilisation effort, i thought
>> 204 was the way to go, however upon further reading and looking at things
>> from aforementioned perspective, IMHO 404 seems the right response to
>> return when a resource is not found.
>>
>> Thanks and Regards,
>>
>> Ruwan Yatawara
>>
>> Associate Technical Lead,
>> WSO2 Inc.
>>
>> email : ruw...@wso2.com
>> mobile : +94 77 9110413
>> blog : http://ruwansrants.blogspot.com/
>>   https://500px.com/ruwan_ace
>> www: :http://wso2.com
>>
>>
>> On Wed, Jun 15, 2016 at 11:15 AM, Rasika Perera  wrote:
>>
>>> ​Hi All,
>>> ​
>>>
>>>
 I think that even though it is a single resource or a collection it
 should not be handled differently. if there is no resource behind the URI
 then it should be 404.
>>>
>>> ​-1. "/devices" is your resource in this case. and it is a *collection*.​
>>> ​ Query components are for retrieval of non-hierarchical data
>>> .  You should not use the query string to identify a *single* resource.
>>> "?type={platform}" is not a part of your resources hierarchy.​ Hence
>>> returning 404 may convey that "/devices" is non-existant and client should
>>> not try "/devices" on proceeding requests.
>>>
>>> ​Thanks,
>>> Rasika​
>>>
>>>
>>>
>>> On Wed, Jun 15, 2016 at 10:51 AM, Geeth Munasinghe 
>>> wrote:
>>>


 On Wed, Jun 15, 2016 at 10:11 AM, Ayyoob Hamza  wrote:

> I think that even though it is a single resource or a collection it
> should not be handled differently. if there is no resource behind the URI
> then it should be 404.
>
 -1,
 AFAIK, it is an actual endpoint (URL) refers to a resource. (In case of
 "/devices?{query_params}",  "/devices" is the resource) It does not matter
 that resource returns an output or not. Because resource can return an
 empty body for a request which in my opinion a valid response. Furthermore
 returning a empty body does not mean that resource is not found (404) (in
 case of /devices, it is there) or client has made an error with the
 request. Empty body means that no records available in database matching
 the filtering criteria. 404 implies a wrong message to the client, which
 means that he has done something wrong with the request. If we send 404 for
 empty body (returns due to no records in the database), then later same
 request will behave differently when database has relevant data. In my
 opinion, it should return 200 for empty body.

 According to [1] 4XX is used for client side errors.

 [1] https://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html

 Thanks
 Geeth

>
> However this could be subjective so have to delve into our rest
> guidelines to make a decision on it.
>
> [Adding Frank and Joe]
>
> *Ayyoob Hamza*
> *Software Engineer*
> WSO2 Inc.; http://wso2.com
> email: ayy...@wso2.com cell: +94 77 1681010 <%2B94%2077%207779495>
>
> On Wed, Jun 15, 2016 at 8:47 AM, Rasika Perera 
> wrote:
>
>> For example, /devices/{device-id} is a URI. Hence, by the time client
>>> makes a request for a non-existing device id, that results in a URI that
>>> could not be found and returning a 404 for that is perfectly valid.
>>
>> ​+1
>>
>> But if we take an example like this, /devices?type={platform}, here
>>> the URI is /devices. If we return a 404 here at any instance, what it
>>> simply means is that the requested URI (/devices) could not be found in 
>>> the
>>> server and should not be used anymore which is wrong. It's a
>>> defined resource 

Re: [Dev] [DEV][APPM] Rest API support for Mobile App Installation/Download options

2016-06-23 Thread Chathura Dilan
Hi Thilini,

Seems good.

Is there any reason to use 'download' instead of 'install'? Since it
subscribes the user when accessing the API, I think 'install' is
appropriate term. and for uninstall it use the term 'uninstall'

We also have to come up with the mechanism to deliver multiple enterprise
apps download links in a single installation request. It would be useful
when the user install apps to many devices.

On Thu, Jun 23, 2016 at 9:20 AM, Thilini Shanika  wrote:

> Hi all,
>
> We have few concerns regarding mobile app installing REST API support in
> APPM.
>
> In the new JAX-RS Rest API model, we have provided following API to
> install a mobile application via MDM.
>
> /api/appm/store/v1.1/apps/download
>
> Apart from that, below app installation options have to be supported by
> new REST APIs.
>
>- In App Manager, there is an option to enabling app binary direct
>download ( config in app-manager.xml). Once direct
>download is enabled, authorized and subscribed users should be able to
>download the app binaries directly without having MDM integrated. This
>particular requirement is not satisfied by currently available REST APIs.
>- Subscribed users should be able to obtain one-time download link for
>enterprise andrioid app binaries and generated plist config link for
>enterprise ios apps, so that the link can be shared via email, SMS etc.
>
>
> As per the discussion we had with the team, below are the alterations and
> additions to current API model in order to fulfill above requirements.
>
>1. Adding new API to make mobile app subscriptions/download. This
>particular install won't have any interaction with MDM and it is dedicated
>to make subscription and return app url for users. This API will return
>generated one-time download link for enterprise android apps and one-time
>download link included plist config link for enterprise IOS apps. For
>mobile webapps and public android/IOS, this will return the app url.
>2. In 1.2.0 Beta release, we already have a mobile binary retrieving
>API. That API has to be deprecated or removed, since we have a one-time
>download API.
>3. Renaming the currently available API path (/api/appm
>/store/v1.1/apps/download) in order to indicate the actual purpose of
>it.
>
>
> Your suggestions and comments are highly appreciated.
>
> Thanks
> Thilini
>
> --
> Thilini Shanika
> Senior Software Engineer
> WSO2, Inc.; http://wso2.com
> 20, Palmgrove Avenue, Colombo 3
>
> E-mail: tgtshan...@gmail.com
>
>


-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] WSO2 Committers += Sajith Abeywardhana

2016-01-27 Thread Chathura Dilan
Congratz Sajith!

On Thu, Jan 28, 2016 at 12:25 PM, Rasika Perera  wrote:

> Congratulations Sajith !!!
>
> On Thu, Jan 28, 2016 at 10:05 AM, Yasassri Ratnayake 
> wrote:
>
>> Congtrats Sajith!!
>>
>> On Thu, Jan 28, 2016 at 9:50 AM, Dinusha Senanayaka 
>> wrote:
>>
>>> Hi All,
>>>
>>> It is my pleasure to welcome Sajith Abeywardhana as a WSO2 Committer.
>>> SajithA, congratulations and keep up the good work.
>>>
>>> Regards,
>>> Dinusha.
>>>
>>> --
>>> Dinusha Dilrukshi
>>> Associate Technical Lead
>>> WSO2 Inc.: http://wso2.com/
>>> Mobile: +94725255071
>>> Blog: http://dinushasblog.blogspot.com/
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Yasassri Ratnayake
>> Software Engineer - QA
>> WSO2 Inc ; http://wso2.com
>> lean.enterprise.middleware
>> *Mobile : +94715933168 <%2B94715933168>*
>> *Blogs : http://yasassriratnayake.blogspot.com
>> *
>> *http://wso2logs.blogspot.com *
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> With Regards,
>
> *Rasika Perera*
> Software Engineer
> M: +94 71 680 9060 E: rasi...@wso2.com
> LinkedIn: http://lk.linkedin.com/in/rasika90
>
> WSO2 Inc. www.wso2.com
> lean.enterprise.middleware
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Shall we use latest APPM in EMM?

2016-03-20 Thread Chathura Dilan
r if we can do this as
>>>>>>>> soon as possible.
>>>>>>>>
>>>>>>>> Regards,
>>>>>>>>
>>>>>>>> On Thu, Mar 17, 2016 at 2:31 PM, Dinusha Senanayaka <
>>>>>>>> dinu...@wso2.com> wrote:
>>>>>>>>
>>>>>>>>> Hi Milan,
>>>>>>>>>
>>>>>>>>> IMO, if we have version conflicts we should try to fix it. What we
>>>>>>>>> have done so far is not correct. We have created a separate branch of 
>>>>>>>>> AppM
>>>>>>>>> for EMM by manually removing the web app related UIs. We have done it 
>>>>>>>>> for
>>>>>>>>> the time being, but this won't scale when it comes to 
>>>>>>>>> support/maintenance
>>>>>>>>> and feature development. With the feature that Lakshman has done, we 
>>>>>>>>> could
>>>>>>>>> use the same code base for both AppM and EMM.
>>>>>>>>>
>>>>>>>>> Regards,
>>>>>>>>> Dinusha.
>>>>>>>>>
>>>>>>>>> On Thu, Mar 17, 2016 at 2:11 PM, Milan Perera <mi...@wso2.com>
>>>>>>>>> wrote:
>>>>>>>>>
>>>>>>>>>> Hi Lakshman,
>>>>>>>>>>
>>>>>>>>>> As I remember, we have tried it before and in the previous
>>>>>>>>>> attempt of migrating to the latest APPM feature was failed due to 
>>>>>>>>>> some
>>>>>>>>>> conflicts in dependencies that were unable to resolve at that time. 
>>>>>>>>>> If im
>>>>>>>>>> not mistaken, it had conflicts with the IS version which we use in 
>>>>>>>>>> the EMM
>>>>>>>>>> 200.
>>>>>>>>>>
>>>>>>>>>> Regards,
>>>>>>>>>>
>>>>>>>>>> On Thu, Mar 17, 2016 at 7:25 AM, Lakshman Udayakantha <
>>>>>>>>>> lakshm...@wso2.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> Hi Chathura,
>>>>>>>>>>>
>>>>>>>>>>> Yes. It is not because of asset turning off/on feature. I meant
>>>>>>>>>>> that UI has changed a lot in latest APP Manager recently and APPM 
>>>>>>>>>>> team
>>>>>>>>>>> didn't get much time to resolve all the bugs reported. As per the 
>>>>>>>>>>> offline
>>>>>>>>>>> discussion with LahiruC lot of mobile features has broken with new 
>>>>>>>>>>> UI and
>>>>>>>>>>> they are fixing it now. So IMO replacing new features may introduce 
>>>>>>>>>>> new
>>>>>>>>>>> bugs to existing APP UI in EMM. Anyway if new UI will go to a high 
>>>>>>>>>>> stable
>>>>>>>>>>> position and APPM release is not going to conflict with EMM release 
>>>>>>>>>>> this
>>>>>>>>>>> will be possible. right? WDYT?
>>>>>>>>>>>
>>>>>>>>>>> Thanks
>>>>>>>>>>>
>>>>>>>>>>> On Thu, Mar 17, 2016 at 12:21 AM, Chathura Dilan <
>>>>>>>>>>> chathu...@wso2.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Hi Lakshman,
>>>>>>>>>>>>
>>>>>>>>>>>> ​​This feature will not introduce any bugs in store or
>>>>>>>>>>>> publisher, since it only on/off assets types.  But we have to test 
>>>>>>>>>>>> all
>>>>>>>>>>>> scenarios of EMM and AppM integration.
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Mar 16, 2016 at 7:03 AM, Lakshman Udayakantha <
>>>>>>>>>>>> lakshm...@wso2.com> wrote:
>>>>>>>

[Dev] [EMM][AppM] Emm is sending all of its devices in a specific tenant when user's devices are needed.

2016-03-03 Thread Chathura Dilan
Hi All,

In AppM EMM integration from OSGI[1] (line 163). I can see EMM retrieve all
of its devices and send it to AppM when user's devices are needed. This
should be filtered to get only users devices by AppM, not all devices which
is in the tenant.



[1] -
https://github.com/wso2/product-mdm/blob/master/modules/components/app-mgt/org.wso2.mdm.appmgt/src/main/java/org/wso2/mdm/appmgt/service/MDMOperationsImpl.java

-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [EMM][AppM] Emm is sending all of its devices in a specific tenant when user's devices are needed.

2016-03-04 Thread Chathura Dilan
Hi Prabath,

Thank you. I created a JIRA[1] for that.

[1] - https://wso2.org/jira/browse/MDM-407

On Thu, Mar 3, 2016 at 6:53 PM, Prabath Abeysekera <praba...@wso2.com>
wrote:

> Thanks for reporting. Please file a JIRA for us to keep track of it and
> fix targeting the next immediate patch release of the product.
>
> Cheers,
> Prabath
>
>
> On Friday, March 4, 2016, Chathura Dilan <chathu...@wso2.com> wrote:
>
>> Hi All,
>>
>> In AppM EMM integration from OSGI[1] (line 163). I can see EMM retrieve
>> all of its devices and send it to AppM when user's devices are needed. This
>> should be filtered to get only users devices by AppM, not all devices which
>> is in the tenant.
>>
>>
>>
>> [1] -
>> https://github.com/wso2/product-mdm/blob/master/modules/components/app-mgt/org.wso2.mdm.appmgt/src/main/java/org/wso2/mdm/appmgt/service/MDMOperationsImpl.java
>>
>> --
>> Regards,
>>
>> Chatura Dilan Perera
>> *Senior Software Engineer** - WSO2 Inc.*
>> www.dilan.me
>>
>
>
> --
> Prabath Abeysekara
> Technical Lead
> WSO2 Inc.
> Email: praba...@wso2.com
> Mobile: +94774171471
>
>


-- 
Regards,

Chatura Dilan Perera
*Senior Software Engineer** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Releasing carbon-appmgt 1.1.3

2016-05-12 Thread Chathura Dilan
Hi Kishanthan / KasunG,

Could you please release this.

Thanks

On Thu, May 12, 2016 at 10:00 PM, KasunG Gajasinghe  wrote:

> Staged -
> https://maven.wso2.org/nexus/content/repositories/orgwso2carbonappmgt-1002/
> 
>
> On Thu, May 12, 2016 at 8:10 PM, Dinusha Senanayaka 
> wrote:
>
>> Thanks Kishanthan.
>>
>> Done the release perform again. Can you send the new staging URL too?
>>
>> Regards,
>> Disnuha.
>>
>> On Thu, May 12, 2016 at 7:57 PM, Kishanthan Thangarajah <
>> kishant...@wso2.com> wrote:
>>
>>> Done
>>>
>>> On Thu, May 12, 2016 at 7:54 PM, Dinusha Senanayaka 
>>> wrote:
>>>
 +Kishanthan

 On Thu, May 12, 2016 at 7:52 PM, Dinusha Senanayaka 
 wrote:

> Hi Maheshika,
>
> Can you please drop the  staging repo again.
>
>
> https://maven.wso2.org/nexus/content/repositories/orgwso2carbonappmgt-1001/
>
> Regards,
> Dinusha.
>
> On Wed, May 11, 2016 at 8:03 PM, Hasunie Adikari 
> wrote:
>
>> Hi Thilini,
>>
>> There was a issue in installing mobile apps from AppStore.I'm getting
>> following backend error and INSTALL_APPLICATION operation is also not 
>> added
>> to the operation table.
>>
>> [2016-05-11 19:51:35,641] ERROR
>> {org.jaggeryjs.jaggery.core.manager.WebAppManager} -
>> org.mozilla.javascript.EcmaError: TypeError: Cannot call method "split" 
>> of
>> undefined 
>> (/store/extensions/assets/mobileapp/modules/mod-ent-install.js#31)
>> org.jaggeryjs.scriptengine.exceptions.ScriptException:
>> org.mozilla.javascript.EcmaError: TypeError: Cannot call method "split" 
>> of
>> undefined 
>> (/store/extensions/assets/mobileapp/modules/mod-ent-install.js#31)
>> at
>> org.jaggeryjs.scriptengine.engine.RhinoEngine.execScript(RhinoEngine.java:571)
>> 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:646)
>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
>> 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:748)
>> at
>> org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:486)
>> at
>> org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:378)
>> at
>> org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:338)
>> 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:504)
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)
>> 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.webapp.authenticator.framework.WebappAuthenticationValve.invoke(WebappAuthenticationValve.java:44)
>> at
>> 

Re: [Dev] Releasing carbon-appmgt 1.1.3

2016-05-12 Thread Chathura Dilan
Thank you Jayanga

On Thu, May 12, 2016 at 11:23 PM, Jayanga Dissanayake <jaya...@wso2.com>
wrote:

> Hi Chatura,
>
> Repo is released.
>
> Thanks,
> Jayanga.
>
> *Jayanga Dissanayake*
> Senior Software Engineer
> WSO2 Inc. - http://wso2.com/
> lean . enterprise . middleware
> email: jaya...@wso2.com
> mobile: +94772207259
>
> On Fri, May 13, 2016 at 5:32 AM, Chathura Dilan <chathu...@wso2.com>
> wrote:
>
>> Hi Kishanthan / KasunG,
>>
>> Could you please release this.
>>
>> Thanks
>>
>> On Thu, May 12, 2016 at 10:00 PM, KasunG Gajasinghe <kas...@wso2.com>
>> wrote:
>>
>>> Staged -
>>> https://maven.wso2.org/nexus/content/repositories/orgwso2carbonappmgt-1002/
>>> <https://www.google.com/url?q=https%3A%2F%2Fmaven.wso2.org%2Fnexus%2Fcontent%2Frepositories%2Forgwso2carbonappmgt-1002%2F=D=1=AFQjCNGT2jJjhpzD1ARLCLpm5VHPYgo7lw>
>>>
>>> On Thu, May 12, 2016 at 8:10 PM, Dinusha Senanayaka <dinu...@wso2.com>
>>> wrote:
>>>
>>>> Thanks Kishanthan.
>>>>
>>>> Done the release perform again. Can you send the new staging URL too?
>>>>
>>>> Regards,
>>>> Disnuha.
>>>>
>>>> On Thu, May 12, 2016 at 7:57 PM, Kishanthan Thangarajah <
>>>> kishant...@wso2.com> wrote:
>>>>
>>>>> Done
>>>>>
>>>>> On Thu, May 12, 2016 at 7:54 PM, Dinusha Senanayaka <dinu...@wso2.com>
>>>>> wrote:
>>>>>
>>>>>> +Kishanthan
>>>>>>
>>>>>> On Thu, May 12, 2016 at 7:52 PM, Dinusha Senanayaka <dinu...@wso2.com
>>>>>> > wrote:
>>>>>>
>>>>>>> Hi Maheshika,
>>>>>>>
>>>>>>> Can you please drop the  staging repo again.
>>>>>>>
>>>>>>>
>>>>>>> https://maven.wso2.org/nexus/content/repositories/orgwso2carbonappmgt-1001/
>>>>>>>
>>>>>>> Regards,
>>>>>>> Dinusha.
>>>>>>>
>>>>>>> On Wed, May 11, 2016 at 8:03 PM, Hasunie Adikari <hasu...@wso2.com>
>>>>>>> wrote:
>>>>>>>
>>>>>>>> Hi Thilini,
>>>>>>>>
>>>>>>>> There was a issue in installing mobile apps from AppStore.I'm
>>>>>>>> getting following backend error and INSTALL_APPLICATION operation is 
>>>>>>>> also
>>>>>>>> not added to the operation table.
>>>>>>>>
>>>>>>>> [2016-05-11 19:51:35,641] ERROR
>>>>>>>> {org.jaggeryjs.jaggery.core.manager.WebAppManager} -
>>>>>>>> org.mozilla.javascript.EcmaError: TypeError: Cannot call method 
>>>>>>>> "split" of
>>>>>>>> undefined 
>>>>>>>> (/store/extensions/assets/mobileapp/modules/mod-ent-install.js#31)
>>>>>>>> org.jaggeryjs.scriptengine.exceptions.ScriptException:
>>>>>>>> org.mozilla.javascript.EcmaError: TypeError: Cannot call method 
>>>>>>>> "split" of
>>>>>>>> undefined 
>>>>>>>> (/store/extensions/assets/mobileapp/modules/mod-ent-install.js#31)
>>>>>>>> at
>>>>>>>> org.jaggeryjs.scriptengine.engine.RhinoEngine.execScript(RhinoEngine.java:571)
>>>>>>>> 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:646)
>>>>>>>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
>>>>>>>> at
>>>>>>>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
>>>>>>>> at
>>>>>>>> org.apache.catalina.core.Applic

[Dev] App manager REST API issue with MySQL

2016-08-01 Thread Chathura Dilan
Hi All,

We are getting following error in EMM after configure it with MySQL 5.5
when adding a mobile app with REST API.



TID: [-1234] [] [2016-08-01 10:20:21,492] ERROR
{org.wso2.carbon.appmgt.rest.api.publisher.AppsApiService} -  Error
occurred while creating mobile application : Anti Virus 3
org.wso2.carbon.appmgt.api.AppManagementException: Error occurred while
creating the mobile application : Anti Virus 3
at
org.wso2.carbon.appmgt.impl.AbstractAPIManager.handleException(AbstractAPIManager.java:692)
at
org.wso2.carbon.appmgt.impl.APIProviderImpl.createMobileApp(APIProviderImpl.java:470)
at
org.wso2.carbon.appmgt.impl.UserAwareAPIProvider.createMobileApp(UserAwareAPIProvider.java:36)
at
org.wso2.carbon.appmgt.rest.api.publisher.impl.AppsApiServiceImpl.appsAppTypePost(AppsApiServiceImpl.java:217)
at
org.wso2.carbon.appmgt.rest.api.publisher.AppsApi.appsAppTypePost(AppsApi.java:118)
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:498)
at
org.apache.cxf.service.invoker.AbstractInvoker.performInvocation(AbstractInvoker.java:180)
at
org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:96)
at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:200)
at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:99)
at
org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvokerInterceptor.java:59)
at
org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(ServiceInvokerInterceptor.java:96)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308)
at
org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121)
at
org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:251)
at
org.apache.cxf.transport.servlet.ServletController.invokeDestination(ServletController.java:234)
at
org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:208)
at
org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:160)
at
org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpringServlet.java:180)
at
org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(AbstractHTTPServlet.java:293)
at
org.apache.cxf.transport.servlet.AbstractHTTPServlet.doPost(AbstractHTTPServlet.java:212)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:646)
at
org.apache.cxf.transport.servlet.AbstractHTTPServlet.service(AbstractHTTPServlet.java:268)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
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:504)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)
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.webapp.authenticator.framework.WebappAuthenticationValve.invoke(WebappAuthenticationValve.java:45)
at
org.wso2.carbon.tomcat.ext.valves.TomcatValveContainer.invokeValves(TomcatValveContainer.java:47)
at
org.wso2.carbon.tomcat.ext.valves.CompositeValve.invoke(CompositeValve.java:62)
at
org.wso2.carbon.tomcat.ext.valves.CarbonStuckThreadDetectionValve.invoke(CarbonStuckThreadDetectionValve.java:159)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950)
at
org.wso2.carbon.tomcat.ext.valves.CarbonContextCreatorValve.invoke(CarbonContextCreatorValve.java:57)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:421)
at
org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1074)
at
org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)
at
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1739)
at
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1698)

[Dev] Getting Error while installing iOS features to EMM 2.1.0

2016-07-05 Thread Chathura Dilan
(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)
... 146 more




On Tue, Jul 5, 2016 at 2:21 PM, Chathura Dilan <chathu...@wso2.com> wrote:

> Hi All,
>
> I'm getting the following error while installing iOS features to EMM
> 2.1.0. Anyone know what's the reason for the issue?
>
>
> Error creating bean with name 'enrollmentServiceBean' defined in URL
> [jndi:/localhost/ios-enrollment/WEB-INF/cxf-servlet.xml]: Instantiation of
> bean failed; nested exception is java.lang.NoClassDefFoundError:
> org/wso2/carbon/device/mgt/ios/core/exception/IOSEnrollmentException
> at
> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:328)
> at
> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:106)
> at
> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveManagedList(BeanDefinitionValueResolver.java:353)
> at
> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:153)
> at
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1327)
> at
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1085)
> at
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:516)
> at
> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:455)
> at
> org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:293)
> at
> org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
> at
> org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:290)
> at
> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:192)
> at
> org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:585)
> at
> org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:895)
> at
> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:425)
> at
> org.apache.cxf.transport.servlet.CXFServlet.createSpringContext(CXFServlet.java:151)
> at org.apache.cxf.transport.servlet.CXFServlet.loadBus(CXFServlet.java:74)
> at
> org.apache.cxf.transport.servlet.CXFNonSpringServlet.init(CXFNonSpringServlet.java:76)
> 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.addChildInternal(ContainerBase.java:901)
> at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
> at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
> at
> org.wso2.carbon.tomcat.internal.CarbonTomcat.addWebApp(CarbonTomcat.java:290)
> at
> org.wso2.carbon.tomcat.internal.CarbonTomcat.addWebApp(CarbonTomcat.java:198)
> at
> org.wso2.carbon.webapp.mgt.TomcatGenericWebappsDeployer.handleWebappDeployment(TomcatGenericWebappsDeployer.java:258)
> at
> org.wso2.carbon.webapp.mgt.TomcatGenericWebappsDeployer.handleWarWebappDeployment(TomcatGenericWebappsDeployer.java:208)
> at
> org.wso2.carbon.webapp.mgt.TomcatGenericWebappsDeployer.handleHotDeployment(TomcatGenericWebappsDeployer.java:175)
> at
> org.wso2.carbon.webapp.mgt.TomcatGenericWebappsDeployer.deploy(TomcatGenericWebappsDeployer.java:140)
> at
> org.wso2.carbon.webapp.mgt.AbstractWebappDeployer.deployThisWebApp(AbstractWebappDeployer.java:224)
> at
> org.wso2.carbon.webapp.mgt.AbstractWebappDeployer.deploy(AbstractWebappDeployer.java:114)
> at
> org.wso2.carbon.webapp.deployer.WebappDeployer.deploy(WebappDeployer.java:42)
> at
> org.apache.axis2.deployment.repository.util.DeploymentFil

[Dev] Getting Error while installing iOS features to EMM 2.1.0

2016-07-05 Thread Chathura Dilan
Hi All,

I'm getting the following error while installing iOS features to EMM 2.1.0.
Anyone know what's the reason for the issue?


Error creating bean with name 'enrollmentServiceBean' defined in URL
[jndi:/localhost/ios-enrollment/WEB-INF/cxf-servlet.xml]: Instantiation of
bean failed; nested exception is java.lang.NoClassDefFoundError:
org/wso2/carbon/device/mgt/ios/core/exception/IOSEnrollmentException
at
org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:328)
at
org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:106)
at
org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveManagedList(BeanDefinitionValueResolver.java:353)
at
org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:153)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1327)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1085)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:516)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:455)
at
org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:293)
at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at
org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:290)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:192)
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:585)
at
org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:895)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:425)
at
org.apache.cxf.transport.servlet.CXFServlet.createSpringContext(CXFServlet.java:151)
at org.apache.cxf.transport.servlet.CXFServlet.loadBus(CXFServlet.java:74)
at
org.apache.cxf.transport.servlet.CXFNonSpringServlet.init(CXFNonSpringServlet.java:76)
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.addChildInternal(ContainerBase.java:901)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
at
org.wso2.carbon.tomcat.internal.CarbonTomcat.addWebApp(CarbonTomcat.java:290)
at
org.wso2.carbon.tomcat.internal.CarbonTomcat.addWebApp(CarbonTomcat.java:198)
at
org.wso2.carbon.webapp.mgt.TomcatGenericWebappsDeployer.handleWebappDeployment(TomcatGenericWebappsDeployer.java:258)
at
org.wso2.carbon.webapp.mgt.TomcatGenericWebappsDeployer.handleWarWebappDeployment(TomcatGenericWebappsDeployer.java:208)
at
org.wso2.carbon.webapp.mgt.TomcatGenericWebappsDeployer.handleHotDeployment(TomcatGenericWebappsDeployer.java:175)
at
org.wso2.carbon.webapp.mgt.TomcatGenericWebappsDeployer.deploy(TomcatGenericWebappsDeployer.java:140)
at
org.wso2.carbon.webapp.mgt.AbstractWebappDeployer.deployThisWebApp(AbstractWebappDeployer.java:224)
at
org.wso2.carbon.webapp.mgt.AbstractWebappDeployer.deploy(AbstractWebappDeployer.java:114)
at
org.wso2.carbon.webapp.deployer.WebappDeployer.deploy(WebappDeployer.java:42)
at
org.apache.axis2.deployment.repository.util.DeploymentFileData.deploy(DeploymentFileData.java:136)
at
org.apache.axis2.deployment.DeploymentEngine.doDeploy(DeploymentEngine.java:807)
at
org.apache.axis2.deployment.repository.util.WSInfoList.update(WSInfoList.java:144)
at
org.apache.axis2.deployment.RepositoryListener.update(RepositoryListener.java:377)
at
org.apache.axis2.deployment.RepositoryListener.checkServices(RepositoryListener.java:254)
at
org.apache.axis2.deployment.RepositoryListener.startListener(RepositoryListener.java:371)
at
org.apache.axis2.deployment.scheduler.SchedulerTask.checkRepository(SchedulerTask.java:59)
at
org.apache.axis2.deployment.scheduler.SchedulerTask.run(SchedulerTask.java:67)
at

Re: [Dev] Regarding APPM-1160

2016-07-05 Thread Chathura Dilan
Hi Dinusha,

EMM supports multi-tenancy it is designed to work with one instance of App
Manager via OSGI services. When they work together they function as one
product, hence EMM and App Manager share same tenants across the multi
tenanted environment.

This is a special scenario where AppM connects to EMM via  EMM REST
APIs. According to how we have developed the plugin tenant admin and
password needs to be stored in the plugin configuration. This is a
plugin specific configuration, therefore, the plugin developer has
flexibility to store those configurations in any way he prefers.

When it's comes to multi tenancy, +1 we have to store those
configurations in the registry for the rest connector plugin . But how we
store those values are plugin specific.


On Tue, Jul 5, 2016 at 10:51 AM, Dinusha Senanayaka 
wrote:

> Hi Chathura,
>
> Does multi-tenancy supports in EMM for device management ? If yes, we need
> to fix [1] as well, which means we cannot keep this configuration in the
> app-manager.xml. Need to take it to registry.
>
> [1] https://wso2.org/jira/browse/APPM-1160
>
> Regards,
> Dinsuha.
>
> --
> Dinusha Dilrukshi
> Associate Technical Lead
> WSO2 Inc.: http://wso2.com/
> Mobile: +94725255071
> Blog: http://dinushasblog.blogspot.com/
>



-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] WSO2 EMM 2.1.0-SNAPSHOT Nightly Build 08/08/2016

2016-08-08 Thread Chathura Dilan
Hi All,

You can get the latest EMM 2.1.0-SNAPSHOT build from here [1]. It is still
being building. once it is done you can download it from there.

[1] -
https://wso2.org/jenkins/job/product-emm/lastSuccessfulBuild/org.wso2.mdm$wso2emm/

-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [APIM] [EMM] Adding multiple scopes to a single API resource endpoint

2016-08-08 Thread Chathura Dilan
Hi Sam,

Sometimes based on the scopes we might need to authorize the APIs to get
different responses.

Eg: Facebook scopes [1]. At the login we can send multiple scopes, generate
the token and authorize an API based on scopes.

It is not possible if only one scope is assigned to one API (resource).

IMO scopes should be initially designed when the APIs are designed
regardless of the roles that they would be attached to.

[1] - https://developers.facebook.com/docs/facebook-login/permissions



On Thu, Aug 4, 2016 at 1:41 PM, Milan Perera  wrote:

> Hi Sam,
>
> Thanks for the clarification.
>
> On Thu, Aug 4, 2016 at 12:34 PM, Sam Sivayogam  wrote:
>
>> Hi Milan,
>>
>> In APIM scopes are there to give access controls based on user roles. A
>> scope can contain multiple user roles so if you want to block multiple
>> roles add those roles to a* single scope *and assign to the particular
>> resource. IMO there is no need to create multiple scopes with different
>> roles and assigning it to the same resource, when you can already create a
>> scope with multiple roles.
>>
>> Thanks,
>> Sam
>>
>> On Thu, Aug 4, 2016 at 12:25 PM, Milan Perera  wrote:
>>
>>> Hi all,
>>>
>>> While going through the code I found that URITemplate class has an
>>> attribute to store multiple scopes.
>>>
>>> package org.wso2.carbon.apimgt.api.model;
>>>
>>>
>>> public class URITemplate implements Serializable {
>>> *...*
>>> private Scope scope;
>>> private List scopes = new ArrayList();
>>>
>>> Can we use this scopes attribute to do the $subject?
>>>
>>>
>>> Regards,
>>>
>>>
>>> On Thu, Aug 4, 2016 at 12:09 PM, Milan Perera  wrote:
>>>
 Hi all,

 Is $subject possible?
 I noticed that $subject capability is limited in UI.

 Regards,

 --
 *Milan Perera *| Software Engineer
 WSO2, Inc | lean. enterprise. middleware.
 #20, Palm Grove, Colombo 03, Sri Lanka
 Mobile: +94 77 309 7088 | Work: +94 11 214 5345
 Email: mi...@wso2.com  | Web: www.wso2.com
 
 

>>>
>>>
>>>
>>> --
>>> *Milan Perera *| Software Engineer
>>> WSO2, Inc | lean. enterprise. middleware.
>>> #20, Palm Grove, Colombo 03, Sri Lanka
>>> Mobile: +94 77 309 7088 | Work: +94 11 214 5345
>>> Email: mi...@wso2.com  | Web: www.wso2.com
>>> 
>>> 
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> *Sam Sivayogam*
>>
>> Software Engineer
>> Mobile  : +94 772 906 439
>> Office   : +94 112 145 345
>> *WSO2, Inc. :** wso2.com *
>> lean.enterprise.middleware.
>>
>
>
>
> --
> *Milan Perera *| Software Engineer
> WSO2, Inc | lean. enterprise. middleware.
> #20, Palm Grove, Colombo 03, Sri Lanka
> Mobile: +94 77 309 7088 | Work: +94 11 214 5345
> Email: mi...@wso2.com  | Web: www.wso2.com
> 
> 
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Scope based authorization for CDMF

2016-07-04 Thread Chathura Dilan
+Dev

For the UI

IMO, UI should have their own permissions. and they should be associated
with scopes

Such as

*UI Permission scopes*
manage_user users:add, users:edit, users:delete, users:view, roles:view
view_user   users:view

These UI permissions can to be assigned from the permission tree to a role.
Once the permission is assigned to a role, the scopes associated with the
permission also assigned to that role automatically.

For that we can reduce the complexity of assigning the UI permission. WDYT?




On Mon, Jul 4, 2016 at 10:16 AM, Milan Perera  wrote:

> Sure, will schedule it in the morning.
>
> On Mon, Jul 4, 2016 at 6:27 AM, Prabath Abeysekera 
> wrote:
>
>> Awesome! Shall we review this in the morn and be done with it?
>>
>> Cheers,
>> Prabath
>>
>>
>> On Monday, July 4, 2016, Milan Perera  wrote:
>>
>>> Hi all,
>>>
>>> I've done the $subject and its still in my fork [1]. Let's have a review
>>> on that and then I will merge.
>>> I've tested this implementation with JDBC scope validator and it works
>>> fine.
>>>
>>> Currently I just only changed the devicemgt-api and have to do necessary
>>> changes to other apis as well.
>>>
>>> [1]
>>> https://github.com/milanperera/carbon-device-mgt/commit/49623a4693dcbd35f6b5305c3e29d31254fcb4ce
>>>
>>>
>>> Regards,
>>>
>>> --
>>> *Milan Perera *| Software Engineer
>>> WSO2, Inc | lean. enterprise. middleware.
>>> #20, Palm Grove, Colombo 03, Sri Lanka
>>> Mobile: +94 77 309 7088 | Work: +94 11 214 5345
>>> Email: mi...@wso2.com | Web: www.wso2.com
>>> 
>>>
>>
>>
>> --
>> Prabath Abeysekara
>> Technical Lead
>> WSO2 Inc.
>> Email: praba...@wso2.com
>> Mobile: +94774171471
>>
>>
>
>
> --
> *Milan Perera *| Software Engineer
> WSO2, Inc | lean. enterprise. middleware.
> #20, Palm Grove, Colombo 03, Sri Lanka
> Mobile: +94 77 309 7088 | Work: +94 11 214 5345
> Email: mi...@wso2.com  | Web: www.wso2.com
> 
>



-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Scope based authorization for CDMF

2016-07-04 Thread Chathura Dilan
+1 Instead of having users:add, users:edit, users:view and users:delete we
can have all of them under users:manage scope.

But when designing the scopes it not possible to consider all the business
functionalities so we can provide basic functionalities such as
users:manage, roles:view, roles:manage.

When it comes to UI, when managing users, viewing roles is also needed. In
that case we need to combine two or more scopes and create a special UI
permission like 'manage_users'

having separate UI permissions make them easy to authorize the UI pages as
well as focuses on the real business functionality rather than depending on
BE.


On Mon, Jul 4, 2016 at 12:20 PM, Prabath Abeysekera <praba...@wso2.com>
wrote:

> IMO, scopes for any application should be designed and implemented taking
> the end-to-end business functionalities into account, rather than focussing
> on different discrete pieces of small functional units such as UI, BE, etc.
> For instance, if some user is authorized to "manage users", the underlying
> scopes that make it possible to that particular user to perform the
> intended task, should be shared across the UI as well as the BE. In other
> words, the same scope that lets the user access the BE resources associated
> with managing users, can be re-used to render the associated UI elements as
> well. That way, not only it makes us avoid overly redundant scopes, which -
> if not managed properly - can be a headache, but also helps us make things
> much more simplified.
>
> Cheers,
> Prabath
>
> On Mon, Jul 4, 2016 at 12:00 PM, Chathura Dilan <chathu...@wso2.com>
> wrote:
>
>> +Dev
>>
>> For the UI
>>
>> IMO, UI should have their own permissions. and they should be associated
>> with scopes
>>
>> Such as
>>
>> *UI Permission scopes*
>> manage_user users:add, users:edit, users:delete, users:view,
>> roles:view
>> view_user   users:view
>>
>> These UI permissions can to be assigned from the permission tree to a
>> role. Once the permission is assigned to a role, the scopes associated with
>> the permission also assigned to that role automatically.
>>
>> For that we can reduce the complexity of assigning the UI permission.
>> WDYT?
>>
>>
>>
>>
>> On Mon, Jul 4, 2016 at 10:16 AM, Milan Perera <mi...@wso2.com> wrote:
>>
>>> Sure, will schedule it in the morning.
>>>
>>> On Mon, Jul 4, 2016 at 6:27 AM, Prabath Abeysekera <praba...@wso2.com>
>>> wrote:
>>>
>>>> Awesome! Shall we review this in the morn and be done with it?
>>>>
>>>> Cheers,
>>>> Prabath
>>>>
>>>>
>>>> On Monday, July 4, 2016, Milan Perera <mi...@wso2.com> wrote:
>>>>
>>>>> Hi all,
>>>>>
>>>>> I've done the $subject and its still in my fork [1]. Let's have a
>>>>> review on that and then I will merge.
>>>>> I've tested this implementation with JDBC scope validator and it works
>>>>> fine.
>>>>>
>>>>> Currently I just only changed the devicemgt-api and have to do
>>>>> necessary changes to other apis as well.
>>>>>
>>>>> [1]
>>>>> https://github.com/milanperera/carbon-device-mgt/commit/49623a4693dcbd35f6b5305c3e29d31254fcb4ce
>>>>>
>>>>>
>>>>> Regards,
>>>>>
>>>>> --
>>>>> *Milan Perera *| Software Engineer
>>>>> WSO2, Inc | lean. enterprise. middleware.
>>>>> #20, Palm Grove, Colombo 03, Sri Lanka
>>>>> Mobile: +94 77 309 7088 | Work: +94 11 214 5345
>>>>> Email: mi...@wso2.com | Web: www.wso2.com
>>>>> <http://lk.linkedin.com/in/milanharinduperera>
>>>>>
>>>>
>>>>
>>>> --
>>>> Prabath Abeysekara
>>>> Technical Lead
>>>> WSO2 Inc.
>>>> Email: praba...@wso2.com
>>>> Mobile: +94774171471
>>>>
>>>>
>>>
>>>
>>> --
>>> *Milan Perera *| Software Engineer
>>> WSO2, Inc | lean. enterprise. middleware.
>>> #20, Palm Grove, Colombo 03, Sri Lanka
>>> Mobile: +94 77 309 7088 | Work: +94 11 214 5345
>>> Email: mi...@wso2.com <ar...@wso2.com> | Web: www.wso2.com
>>> <http://lk.linkedin.com/in/milanharinduperera>
>>>
>>
>>
>>
>> --
>> Regards,
>>
>> Chatura Dilan Perera
>> *Associate Tech Lead** - WSO2 Inc.*
>> www.dilan.me
>>
>
>
>
> --
> Prabath Abeysekara
> Technical Lead
> WSO2 Inc.
> Email: praba...@wso2.com
> Mobile: +94774171471
>



-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [Architecture] [VOTE] Release WSO2 IoT Server 3.0.0 RC2

2017-01-20 Thread Chathura Dilan
Hi,

I've tested

   - Android app enrollment installation and un-installation, policies and
   operations
   - App Management


 [+] Stable - go ahead and release


On Sat, Jan 21, 2017 at 5:18 AM, Jasintha Dasanayake 
wrote:

> Hi All
>
> I have tested the following flows using the virtual firearm plugin :
>
>- Operation flows
>- Grouping devices
>- Applying and updating policy for individual & grouped devices
>- Realtime analytics
>
> [+] Stable-go ahead and release
>
> Regards
> /Jasintha
>
>
> On Sat, Jan 21, 2017 at 2:27 AM, Ayyoob Hamza  wrote:
>
>> Hi All,
>>
>> I have tested following:
>>
>>- Tested below flows using the reference device types
>>implementation(Virtual firealarm, Connected cup, Raspberry pi).
>>- Operation flow
>>   - Policy
>>   - Batch Analytics
>>   - Real time analytics
>>- Tested Android Device Management APIs
>>- Tested maven archtype for tooling
>>- Created a new device type by generating through the the maven arch
>>type.
>>- Tested Operation flow
>>   - Batch Analytics
>>   - Realtime analytics
>>- Tested the distributed setup (Mqtt Gateway, Http Gateway, Device
>>Type Publisher, Key Manager, Analytics, Mysql).
>>- Tested Android Apis in a distributed environment.
>>   - Virtual firealarm Enrollment and operation flow
>>- Role Management.
>>
>> [+] Stable-go ahead and release.
>>
>> Regards,
>> Ayyoob
>>
>> ___
>> Architecture mailing list
>> architect...@wso2.org
>> https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
>>
>>
>
>
> --
>
> *Jasintha Dasanayake**Associate Technical Lead*
>
> *WSO2 Inc. | http://wso2.com lean . enterprise .
> middleware*
>
>
> *mobile :- 0711-368-118*
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] WSO2 Committers += Saad Sahibjan

2016-10-31 Thread Chathura Dilan
​Hi Devs,

​It's my pleasure to announce Saad Sahibjan as a WSO2 Committer. Saad has
been a valuable contributor for WSO2 EMM product, and in recognition of his
contribution to WSO2, he has been voted as a WSO2 Committer.​

​Saad, Keep up the good work and wish you all the best for your future
endeavors!


-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Dynamic zip file download from Jaggery application

2016-10-17 Thread Chathura Dilan
Hi Godwin,

Yes there is a better approach than  save those files in the jaggery app
itself. This is mainly because jaggery app is getting bulky, difficult for
clustering, and less security.

What we have done for mobile app is store them in a secured place such as
/repository/resources/mobileapps (as the default location) with an
arbitrary name. It can be configurable to any location in the file system
or the network.

That file can be read from its physical location using Java and and get an
input stream via Jaggery for download or you can directly read it from
Jaggery.


On Mon, Oct 17, 2016 at 6:27 PM, Dinusha Senanayaka 
wrote:

> We have done something similar in AppM for mobile apps where publisher
> uploads binary (.apk etc) and users comes to store install these apps to
> device.  Download has handled as a byte stream and storage location is
> stored in property of app-manger.xml (${carbon.
> home}/repository/resources/mobileapps/) and HostObject
> method has been provided to get the location.
>
> @Chathura should be able to explain the logic more since he implemented
> this.
>
> Regards,
> Dinusha.
>
> On Mon, Oct 17, 2016 at 6:06 PM, Godwin Shrimal  wrote:
>
>> Hi All,
>>
>> We need to dynamically create zip file and allow download it from jaggery
>> application. For resolve the concurrent access of the system, we are going
>> to create a directory with the time-stamp and archive that directory and
>> allow user to download it. Then we need to create a separate cleanup task
>> to clean those directories and archive files.
>>
>> We can create above zip files in jaggery application level (ex.
>> jaggery/dashboard/resource/) and create a cleanup task in OSGI level to
>> delete the files/directories periodically. Here we need to keep a configure
>> to find the jaggery application context from OSGI level.
>>
>> Do we have a better approach for this or is it fine to use a
>> configuration for particular jaggery context ?
>>
>> Thanks
>> Godwin
>>
>> --
>> *Godwin Amila Shrimal*
>> Senior Software Engineer
>> WSO2 Inc.; http://wso2.com
>> lean.enterprise.middleware
>>
>> mobile: *+94772264165*
>> linkedin: *http://lnkd.in/KUum6D *
>> twitter: https://twitter.com/godwinamila
>> 
>>
>
>
>
> --
> Dinusha Dilrukshi
> Associate Technical Lead
> WSO2 Inc.: http://wso2.com/
> Mobile: +94725255071
> Blog: http://dinushasblog.blogspot.com/
>



-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Dynamic zip file download from Jaggery application

2016-10-17 Thread Chathura Dilan
Hi Godwin,

Yes, Jaggery File API is only working within Jaggery app context according
to documentation. so you will have to read it from Java and pass it to
jaggery. That's how we are doing with mobile apps.

On Mon, Oct 17, 2016 at 6:57 PM, Godwin Shrimal  wrote:

> Hi Chathura,
>
>
>
> Yes there is a better approach than  save those files in the jaggery app
>> itself. This is mainly because jaggery app is getting bulky, difficult for
>> clustering, and less security.
>>
>> What we have done for mobile app is store them in a secured place such as
>> /repository/resources/mobileapps (as the default location) with an
>> arbitrary name. It can be configurable to any location in the file system
>> or the network.
>>
>> That file can be read from its physical location using Java and and get
>> an input stream via Jaggery for download or you can directly read it from
>> Jaggery.
>>
>
> As per the offline discussion had with Senthuja and Nisal, we cannot
> access location such as /repository/resources/mobileapps from Jaggery.
>
>
> Thanks
> Godwin
>
>
>
>
>>
>> On Mon, Oct 17, 2016 at 6:27 PM, Dinusha Senanayaka 
>> wrote:
>>
>>> We have done something similar in AppM for mobile apps where publisher
>>> uploads binary (.apk etc) and users comes to store install these apps to
>>> device.  Download has handled as a byte stream and storage location is
>>> stored in property of app-manger.xml (${carbon.ho
>>> me}/repository/resources/mobileapps/) and HostObject
>>> method has been provided to get the location.
>>>
>>> @Chathura should be able to explain the logic more since he implemented
>>> this.
>>>
>>> Regards,
>>> Dinusha.
>>>
>>> On Mon, Oct 17, 2016 at 6:06 PM, Godwin Shrimal  wrote:
>>>
 Hi All,

 We need to dynamically create zip file and allow download it from
 jaggery application. For resolve the concurrent access of the system, we
 are going to create a directory with the time-stamp and archive that
 directory and allow user to download it. Then we need to create a separate
 cleanup task to clean those directories and archive files.

 We can create above zip files in jaggery application level (ex.
 jaggery/dashboard/resource/) and create a cleanup task in OSGI level to
 delete the files/directories periodically. Here we need to keep a configure
 to find the jaggery application context from OSGI level.

 Do we have a better approach for this or is it fine to use a
 configuration for particular jaggery context ?

 Thanks
 Godwin

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

 mobile: *+94772264165*
 linkedin: *http://lnkd.in/KUum6D *
 twitter: https://twitter.com/godwinamila
 

>>>
>>>
>>>
>>> --
>>> Dinusha Dilrukshi
>>> Associate Technical Lead
>>> WSO2 Inc.: http://wso2.com/
>>> Mobile: +94725255071
>>> Blog: http://dinushasblog.blogspot.com/
>>>
>>
>>
>>
>> --
>> Regards,
>>
>> Chatura Dilan Perera
>> *Associate Tech Lead** - WSO2 Inc.*
>> www.dilan.me
>>
>
>
>
> --
> *Godwin Amila Shrimal*
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: *+94772264165*
> linkedin: *http://lnkd.in/KUum6D *
> twitter: https://twitter.com/godwinamila
> 
>



-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [Architecture] [VOTE] Release WSO2 Enterprise Mobility Manager 2.2.0 RC2

2016-11-30 Thread Chathura Dilan
Hi all,

Tested Follows

Android and iOS application installation/uninstallation via app manager.

[+] Stable - go ahead and release


On Thu, Dec 1, 2016 at 10:41 AM, Geeth Munasinghe  wrote:

> Hi all,
>
> Tested following scenarios.
>
>
>1. Android device enrollment.
>2. User and role creation and assigning permission.
>3. Sending email with user invite.
>4. Create/Edit policy
>5. Applying policy to device.
>6. Reapplying changed policy.
>7. Add few operations.
>
> [+] - Stable - go ahead and release.
>
> Thanks
> Geeth
>
> On Thu, Dec 1, 2016 at 10:26 AM, Inosh Perera  wrote:
>
>> Hi all,
>>
>> I have tested FCM together with Android enrollment and operation sending,
>> functionality works well.
>>
>> [+] Stable - go ahead and release
>>
>> Regards,
>> Inosh
>>
>> On Wed, Nov 30, 2016 at 3:55 PM, Charitha Goonetilleke <
>> charit...@wso2.com> wrote:
>>
>>> Hi All,
>>>
>>> I have enrolled Android device and tested basic functionality.
>>>
>>> [+] Stable - go ahead and release
>>>
>>> Thanks & Regards,
>>> /charithag
>>>
>>> On Tue, Nov 29, 2016 at 9:50 PM, Harshan Liyanage 
>>> wrote:
>>>
 Hi Devs,

 This is the release candidate of WSO2 Enterprise Mobility Manager 2.2.
 0.

 Please download EMM 2.2.0 RC2 and test the functionality and vote.
 Vote will be open for 72 hours or as needed.
 Know issues: https://wso2.org/jira/issues/?filter=13384
 Fixes provided : https://wso2.org/jira/issues/?filter=13582
 

 Source & binary distribution files:
 https://github.com/wso2/product-emm/releases/tag/v2.2.0-RC2

 The tag to be voted upon:
 https://github.com/wso2/product-emm/tree/release-2.2.0-RC2


 [+] Stable - go ahead and release
 [-]  Broken - do not release (explain why)

 Thanks and Regards,


 Harshan Liyanage
 EMM/IoT TG
 Mobile: *+94765672894*
 Email: hars...@wso2.com
 Blog : http://harshanliyanage.blogspot.com/
 *WSO2, Inc. :** wso2.com *
 lean.enterprise.middleware.

 ___
 Architecture mailing list
 architect...@wso2.org
 https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture


>>>
>>>
>>> --
>>> *Charitha Goonetilleke*
>>> Software Engineer
>>> WSO2 Inc.; http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> mobile: +94 77 751 3669 <%2B94777513669>
>>> Twitter:@CharithaWs , fb: charithag
>>> , linkedin: charithag
>>> 
>>>
>>> 
>>>
>>> ___
>>> Architecture mailing list
>>> architect...@wso2.org
>>> https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
>>>
>>>
>>
>>
>> --
>> Inosh Perera
>> Senior Software Engineer, WSO2 Inc.
>> Tel: 077813 7285, 0785293686
>>
>> ___
>> Architecture mailing list
>> architect...@wso2.org
>> https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
>>
>>
>
>
> --
>
> *G. K. S. Munasinghe*
> *Senior Software Engineer,*
> *WSO2, Inc. http://wso2.com  *
> *lean.enterprise.middleware.*
>
> email: ge...@wso2.com
> phone:(+94) 777911226 <+94%2077%20791%201226>
>
> 
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [IOT]Concerns regarding saving the image and binary files in the File System

2017-08-16 Thread Chathura Dilan
Hi Megala,

If you go with the first approach, could you please mention what are the
parameters you use to get the image? It is always better to get the image
with a random parameters so it prevents hackers from guessing image names.

@Nuwan. Some binary files could be large as 500MB in size. So we cannot
store them in the  database. Also rsync consumes lot of bandwidth, but you
can go with that approach based on the scenario. But IMO NFS with high
availability would be best approach.

On Wed, Aug 16, 2017 at 5:41 PM, Megala Uthayakumar  wrote:

> Hi Nuwan,
>
> As mentioned by Harshan user needs to configure NFS when configuring this
> in HA setup. We do accept local file path or NFS url in the configuration
> file for the path.
>
> Thanks.
>
> On Wed, Aug 16, 2017 at 5:01 PM, Nuwan Dias  wrote:
>
>> When you have two nodes of the IoT server running for HA, and if a given
>> image/file is stored on the file system of one server, how do you make that
>> image/file available for a request that's served via the other server?
>>
>> On Wed, Aug 16, 2017 at 4:54 PM, Megala Uthayakumar 
>> wrote:
>>
>>> Hi All,
>>>
>>> Currently we are working on writing a mobile application store for IOT
>>> server. For that we have decided to save the images and binary files
>>> related with applications in the file system(This decision was taken
>>> considering the file size). File location will be derived from a
>>> configuration. While implementing this, we have come-up with the following
>>> suggestions for saving files as per the meeting we had internally.
>>>
>>> *Option 1*
>>> For each application we will have a folder with the name as the
>>> generated ID for the application from the database. Each will hold all the
>>> relevant artifacts such as icon, screen-shots and binary files.
>>> In this case, there were 2 suggestions
>>>
>>>1. For each app, the icon and screen-shots will be saved with the
>>>same name. Ex - For icons the image file name will be 'icon' and 
>>> like-wise
>>>for others as well. So in this case, we do not need to save image names 
>>> in
>>>the database.
>>>2. Need to dynamically generate some random names.
>>>
>>> If we consider first approach, if we use the same name for all the
>>> application, there is possible chance an attacker may get all the image
>>> files if the name is known to them.  AFAIU this can happen even if we do
>>> not use the 1st approach and use the second approach in which we use random
>>> names, as this can happen only if the root path for saving the artifacts
>>> are compromised and without the name also attacker can do a "listFiles"
>>> request  and get all the data.
>>>
>>> *Option 2*
>>> For binary files and image files we will have separate location and each
>>> respective files will be saved in these location separately by generating a
>>> unique name. This may be helpful if we can cache the images and improve the
>>> performance, but this may not be possible in real production scenarios
>>> depending on the size of the images.
>>>
>>> What would be the most preferable option? Comments and suggestions on
>>> this regard is highly appreciated.
>>>
>>> Thanks.
>>>
>>> Regards,
>>> Megala
>>>
>>> --
>>> Megala Uthayakumar
>>>
>>> Software Engineer
>>> Mobile : 0779967122
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "WSO2 IoT Team Group" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to iot-group+unsubscr...@wso2.com.
>>> For more options, visit https://groups.google.com/a/wso2.com/d/optout.
>>>
>>
>>
>>
>> --
>> Nuwan Dias
>>
>> Software Architect - WSO2, Inc. http://wso2.com
>> email : nuw...@wso2.com
>> Phone : +94 777 775 729 <+94%2077%20777%205729>
>>
>
>
>
> --
> Megala Uthayakumar
>
> Software Engineer
> Mobile : 0779967122
>



-- 
Thanks and Best Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
+94777266673
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [IOT]Concerns regarding saving the image and binary files in the File System

2017-08-16 Thread Chathura Dilan
I'm +1 with option 2 since we can have a big storage for binary files and
small storage for image files. The method of serving images and binary
files are for two different things. We can optimize image storage for
serving images because images are accessed frequently. Also in terms of
security storing binary files in a separate location provides additional
security for them.

On Wed, Aug 16, 2017 at 11:21 PM, Megala Uthayakumar 
wrote:

> Hi All,
>
> Please fine my responses below,
>
> *@Nuwan *
> Is there a problem is storing this file on the DB instead of the FS?
>
> As explained by Chathura and Charitha main reasoning behind not selecting
> the database is size of the binary file and yes we will consider other
> possible ways for supporting this as well, given that NFS may not be
> preferred by the customer.
>
> *@Chathura*
> If you go with the first approach, could you please mention what are the
> parameters you use to get the image? It is always better to get the image
> with a random parameters so it prevents hackers from guessing image names.
>
> As we know already we will be getting the files using an REST API and in
> that case, the URL will be something like follow,
>*https://localhost:8243/applications/getIcon/
> *
> So with this URL, nothing can be guessed as in the API level, what we
> expect to do is something like follow,
>
>1. From the UUID, get the auto-generated ID from the database
>2. We will derive the path for the particular application as follow,
>   - /ID
>3. In that path we will search for the file with the name "icon" and
>we will pass File with the response.
>
> In this case, I don't think there is possible security issue where we
> expose the path name or so. Please do correct me, if it is not the case.By
> having random names, we need to have additional database operations for
> saving icon/other image files name and retrieving them.
>
> *@Charitha*
> I'm not clear with the reason behind this statement in under option 2
>
> "but this may not be possible in real production scenarios depending on
> the size of the images.
>
> I meant that caching images will not work as in the real-production
> scenarios, we may have images with higher sizes, so in that case, we cannot
> efficiently cache and gain performance gain out of them by using option 2.
>
> *@Waruna *
> Storage Location - This should be written as extension where you can store
> in local directory, FTP, NFS or someone can customize based on requirement.
>
> For the storage location, if we are using NFS or local file system, I
> think om the implementation level it will be the same and we do not need to
> specially handle them. We have not thought about supporting FTP for the
> first cut implementation and wondering whether we need that level
> complexity (i.e. Having a server-server communication) for only saving
> image files and binary files.
>
> Do we need real requirement to search by image name,apk name or other
> content name. If we have that kind of requiremnt as well then option 1 will
> have some cons.
>
> AFAIK we will not get a requirement to search the apis with the apk name
> or image name as people are normally interested in searching by using
> application name, platform name etc.
>
> Thanks.
>
> Regards,
> Megala
>
> On Wed, Aug 16, 2017 at 6:31 PM, Waruna Jayaweera 
> wrote:
>
>> Hi Megala,
>>
>> AFAIU There are two problems as where we store the file
>> contents(supporting clustering cases) and file structure of application
>> content.
>>
>> Storage Location - This should be written as extension where you can
>> store in local directory, FTP, NFS or someone can customize based on
>> requirement.
>> Application store structure - I prefer option 1 as it will be more
>> manageable per application which makes separate storage space for
>> application contents(apk,icon etc).
>>
>> As an example we can store like //> plication_content_name>/content_data
>> I option 2 you will have less folders but you may need to concat file
>> names for support for multiple application versions and their contents. In
>> option 1 delete application operation also easy.
>>
>> Do we need real requirement to search by image name,apk name or other
>> content name. If we have that kind of requiremnt as well then option 1 will
>> have some cons.
>>
>> Thanks,
>> Waruna
>>
>> On Wed, Aug 16, 2017 at 6:02 PM, Charitha Goonetilleke <
>> charit...@wso2.com> wrote:
>>
>>> Hi Nuwan,
>>>
>>> As our previous experience with similar approach we have used to store
>>> binaries in DB, it cause for scallability issues in later when growing the
>>> size of the DB in GBs. So storing files as binaries in DB is highly
>>> depending on the DB engine used and the growth rate of the data. IMO, these
>>> concerns and issues might be critical and complex than the complexity we
>>> are going to introduce with FS based solution. So I think 

[Dev] WSO2 Committers += Madhawa Perera

2017-06-19 Thread Chathura Dilan
Hi All,

It's my pleasure to welcome Madhawa Perera as a WSO2 Committer.

Madhawa has been a valuable contributor to the IoT team. In recognition of
his contribution, dedication, and commitment he has been voted as a WSO2
 committer.

Madhawa, welcome aboard and keep up the good work!

-- 
Thanks and Best Regards,

Chatura Dilan Perera
*Associate Tech Lead** - WSO2 Inc.*
+94777266673
www.dilan.me
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev