Re: [Dev] [Registry][Carbon] An exception occurred processing JSP page

2015-06-26 Thread Harsha Kumara
Hi Ruwan,

I think you will need to add the following property to wso2server.sh and
the wso2server.bat appropriately.. It was discuss in [1].

-Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false \


[1] - http://mail.wso2.org/mailarchive/dev/2014-April/029523.html

Thanks,
Harsha

On Fri, Jun 26, 2015 at 12:24 PM, Ruwan Abeykoon  wrote:

> Hi Registry/Governance team,
>
> The issue I am getting is due to couple of places in carbon-registry and
> carbon-governance e.g. in [1]
>
>   label="<%=request.getParameter("breadcrumb")%>"
> topPage="true"
> request="<%=request%>"/>
>
> I think having quote in the "label" attribute is wrong.
> can we change them to something like
>
>  label="${param[\"breadcrumb\"]}"
> topPage="true"
> request="<%=request%>"/>
>
>
> [1]
> https://github.com/wso2/carbon-governance/blob/065e7ee6511d5608694b93abab8b340c87a666d0/components/governance/org.wso2.carbon.governance.generic.ui/src/main/resources/web/generic/list.jsp
>
> On Thu, Jun 25, 2015 at 11:39 AM, Ruwan Abeykoon  wrote:
>
>> Hi Carbon team,
>> I am getting an exception in all the registry ui pages along the line of
>> $subject.  It could be a missing or incompatible jar related to jasper
>> compiler.
>>
>> Running Carbon 4.4.0
>> JDK : 1.7.0_79
>>
>> What could be the cause?
>>
>> Part of the stack trace, hope this is sufficient --
>> ---
>>
>> Caused by: org.apache.jasper.JasperException: An exception occurred
>> processing JSP page /relations/relations.jsp at line 28
>>
>>
>> 25: 
>>
>> 26: > src="../relations/js/relations.js">
>>
>> 27:
>>
>> 28: 
>>
>> 29:
>>
>> 30: 
>>
>> 31:
>>
>>
>>
>> Stacktrace:
>>
>> at
>> org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:568)
>>
>> at
>> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:455)
>>
>> at
>> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)
>>
>> at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)
>>
>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
>>
>> 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:727)
>>
>> 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:727)
>>
>> at
>> org.wso2.carbon.tomcat.ext.servlet.DelegationServlet.service(DelegationServlet.java:68)
>>
>> 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.doInclude(ApplicationDispatcher.java:604)
>>
>> at
>> org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:543)
>>
>> 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:954)
>>
>> at
>> org.apache.jsp.resources.resource_jsp._jspService(resource_jsp.java:456)
>>
>> at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
>>
>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
>>
>> at
>> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
>>
>> ... 102 more
>>
>> Caused by: org.apache.jasper.JasperException: An exception occurred
>> processing JSP page /relations/dependencies.jsp at line 131
>>
>>
>> 128: <% String url =
>> "../relations/association-list-ajaxprocessor.jsp?type=depends&path=" +
>> request.getParameter("path").replaceAll("&","%26"); %>
>>
>> 129: 
>>
>> 130:
>>
>> 131: 
>>
>> 132: 
>>
>> 133: 
>>
>> 134: 
>>
>>
>>
>> Stacktrace:
>>
>> at
>> org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:568)
>>
>> at
>> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:455)
>>
>> at
>> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)
>>
>> at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)
>>
>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
>>
>> at org.w

Re: [Dev] [Registry][Carbon] An exception occurred processing JSP page

2015-06-26 Thread Ruwan Abeykoon
Hi Harsha,
Thanks, setting "STRICT_QUOTE_ESCAPING=false" worked.

Cheers,

On Fri, Jun 26, 2015 at 12:32 PM, Harsha Kumara  wrote:

> Hi Ruwan,
>
> I think you will need to add the following property to wso2server.sh and
> the wso2server.bat appropriately.. It was discuss in [1].
>
> -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false \
>
>
> [1] - http://mail.wso2.org/mailarchive/dev/2014-April/029523.html
>
> Thanks,
> Harsha
>
> On Fri, Jun 26, 2015 at 12:24 PM, Ruwan Abeykoon  wrote:
>
>> Hi Registry/Governance team,
>>
>> The issue I am getting is due to couple of places in carbon-registry and
>> carbon-governance e.g. in [1]
>>
>> >  label="<%=request.getParameter("breadcrumb")%>"
>> topPage="true"
>> request="<%=request%>"/>
>>
>> I think having quote in the "label" attribute is wrong.
>> can we change them to something like
>>
>> > label="${param[\"breadcrumb\"]}"
>> topPage="true"
>> request="<%=request%>"/>
>>
>>
>> [1]
>> https://github.com/wso2/carbon-governance/blob/065e7ee6511d5608694b93abab8b340c87a666d0/components/governance/org.wso2.carbon.governance.generic.ui/src/main/resources/web/generic/list.jsp
>>
>> On Thu, Jun 25, 2015 at 11:39 AM, Ruwan Abeykoon  wrote:
>>
>>> Hi Carbon team,
>>> I am getting an exception in all the registry ui pages along the line of
>>> $subject.  It could be a missing or incompatible jar related to jasper
>>> compiler.
>>>
>>> Running Carbon 4.4.0
>>> JDK : 1.7.0_79
>>>
>>> What could be the cause?
>>>
>>> Part of the stack trace, hope this is sufficient --
>>> ---
>>>
>>> Caused by: org.apache.jasper.JasperException: An exception occurred
>>> processing JSP page /relations/relations.jsp at line 28
>>>
>>>
>>> 25: 
>>>
>>> 26: >> src="../relations/js/relations.js">
>>>
>>> 27:
>>>
>>> 28: 
>>>
>>> 29:
>>>
>>> 30: 
>>>
>>> 31:
>>>
>>>
>>>
>>> Stacktrace:
>>>
>>> at
>>> org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:568)
>>>
>>> at
>>> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:455)
>>>
>>> at
>>> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)
>>>
>>> at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)
>>>
>>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
>>>
>>> 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:727)
>>>
>>> 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:727)
>>>
>>> at
>>> org.wso2.carbon.tomcat.ext.servlet.DelegationServlet.service(DelegationServlet.java:68)
>>>
>>> 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.doInclude(ApplicationDispatcher.java:604)
>>>
>>> at
>>> org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:543)
>>>
>>> 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:954)
>>>
>>> at
>>> org.apache.jsp.resources.resource_jsp._jspService(resource_jsp.java:456)
>>>
>>> at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
>>>
>>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
>>>
>>> at
>>> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
>>>
>>> ... 102 more
>>>
>>> Caused by: org.apache.jasper.JasperException: An exception occurred
>>> processing JSP page /relations/dependencies.jsp at line 131
>>>
>>>
>>> 128: <% String url =
>>> "../relations/association-list-ajaxprocessor.jsp?type=depends&path=" +
>>> request.getParameter("path").replaceAll("&","%26"); %>
>>>
>>> 129: 
>>>
>>> 130:
>>>
>>> 131: 
>>>
>>> 132: 
>>>
>>> 133: 
>>>
>>> 134: 
>>>
>>>
>>>
>>> Stacktrace:
>>>
>>> at
>>> org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:568)
>>>
>>> at
>>> org.apac

[Dev] Please merge the carbon4-kernel integration test commit#252

2015-06-26 Thread Nuwan Wimalasekara
Hi Carbon Team,

Please merge the pull request
https://github.com/wso2/carbon4-kernel/pull/252

Thanks,
Nuwanw

-- 
Nuwan Wimalasekara
Senior Software Engineer - Test Automation
WSO2, Inc.: http://wso2.com
lean. enterprise. middleware

phone: +94 71 668 4620
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] WSO2 Application Server 5.2.1 Docker Image

2015-06-26 Thread Kishanthan Thangarajah
Thanks Imesh and Akila. I will try this out for ESB image.

On Thu, Jun 25, 2015 at 1:54 PM, Imesh Gunaratne  wrote:

> Hi Kishanthan,
>
> On Wed, Jun 24, 2015 at 11:29 PM, Kishanthan Thangarajah <
> kishant...@wso2.com> wrote:
>
>> Hi Imesh,
>>
>> Good stuff. I could get this working by installing and starting the
>> container on my local machine (using boot2docker). Is there a way to start
>> a AS cluster (mgt+worker) with this image?
>>
>
> Yes we can, we have written a script for this in ESB:
>
> https://github.com/wso2/product-private-paas/blob/master/cartridges/docker/wso2esb-4.8.1/run.sh
>
> On Wed, Jun 24, 2015 at 11:29 PM, Kishanthan Thangarajah <
> kishant...@wso2.com> wrote:
>
>> Hi Imesh,
>>
>> Good stuff. I could get this working by installing and starting the
>> container on my local machine (using boot2docker). Is there a way to start
>> a AS cluster (mgt+worker) with this image?
>>
>>
>>
>> On Wed, Jun 24, 2015 at 10:57 AM, Imesh Gunaratne  wrote:
>>
>>> Hi Devs,
>>>
>>> WSO2 Application Server 5.2.1 Docker image is now available in Docker
>>> Hub:
>>> https://registry.hub.docker.com/u/wso2/as/
>>>
>>> Thanks
>>>
>>> --
>>> *Imesh Gunaratne*
>>> Senior Technical Lead
>>> WSO2 Inc: http://wso2.com
>>> T: +94 11 214 5345 M: +94 77 374 2057
>>> W: http://imesh.gunaratne.org
>>> Lean . Enterprise . Middleware
>>>
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> *Kishanthan Thangarajah*
>> Associate Technical Lead,
>> Platform Technologies Team,
>> WSO2, Inc.
>> lean.enterprise.middleware
>>
>> Mobile - +94773426635
>> Blog - *http://kishanthan.wordpress.com
>> *
>> Twitter - *http://twitter.com/kishanthan *
>>
>
>
>
> --
> *Imesh Gunaratne*
> Senior Technical Lead
> WSO2 Inc: http://wso2.com
> T: +94 11 214 5345 M: +94 77 374 2057
> W: http://imesh.gunaratne.org
> Lean . Enterprise . Middleware
>
>


-- 
*Kishanthan Thangarajah*
Associate Technical Lead,
Platform Technologies Team,
WSO2, Inc.
lean.enterprise.middleware

Mobile - +94773426635
Blog - *http://kishanthan.wordpress.com *
Twitter - *http://twitter.com/kishanthan *
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [User-core][Authentication] Multiple requests to LDAP/AD when authentication fails

2015-06-26 Thread Asela Pathberiya
This has been done to support multiple DN pattern  which is fixed for
ticket [1]. If we just return the false,  there can be some problem
with it.  Therefore we need to check whether multiple DN has been
configured or not and then return the "false"

[1] https://wso2.org/jira/browse/CARBON-13631

Thanks,
Asela.

On Thu, Jun 25, 2015 at 6:14 PM, Damith Senanayake  wrote:
> Sorry, in the above code the section
> if (name != null) {
> try {
> if (debug) {
> log.debug("Cache hit. Using DN " + name);
> }
> bValue = this.bindAsUser(userName,name, (String)
> credential);
> } catch (NamingException e) {
> // do nothing if bind fails since we check for other DN
> // patterns as well.
> if (log.isDebugEnabled()) {
> log.debug("Checking authentication with UserDN " + name
> + "failed " +
> e.getMessage(), e);
> }
> }
>
> return bValue;
>
> }
>  should be changed as
>
> if (name != null) {
> try {
> if (debug) {
> log.debug("Cache hit. Using DN " + name);
> }
> bValue = this.bindAsUser(userName,name, (String)
> credential);
> } catch (NamingException e) {
> // do nothing if bind fails since we check for other DN
> // patterns as well.
> if (log.isDebugEnabled()) {
> log.debug("Checking authentication with UserDN " + name
> + "failed " +
> e.getMessage(), e);
> }
> }
>
>  if(bValue){
>   return bValue;
>  }
> }
>
>
>
> On Thu, Jun 25, 2015 at 6:11 PM, Damith Senanayake  wrote:
>>
>> in org.wso2.carbon.user.core.ldap.ReadOnlyLDAPUserStoreManager.java, the
>> following section follows a logic as
>>
>> 1. Check cache for user RDN
>> -a) if RDN in cache, try authentication with User Store, and return true
>> if successful,
>> -b) if RDN in cache and authentication fails, continue,
>>
>> 2.  Try creating user RDN from UserDN Patterns, and attempt authentication
>> 3. If UserDN patterns are null,  try authentication from UserBase, and
>> attempt authentication.
>>
>> The code is as below
>>
>>  boolean debug = log.isDebugEnabled();
>>
>> if (userName == null || credential == null) {
>> return false;
>> }
>>
>> userName = userName.trim();
>>
>> String password = (String) credential;
>> password = password.trim();
>>
>> if (userName.equals("") || password.equals("")) {
>> return false;
>> }
>>
>> if (debug) {
>> log.debug("Authenticating user " + userName);
>> }
>>
>> boolean bValue = false;
>> // check cached user DN first.
>> String name = userCache.get(userName);
>> if (name != null) {
>> try {
>> if (debug) {
>> log.debug("Cache hit. Using DN " + name);
>> }
>> bValue = this.bindAsUser(userName,name, (String)
>> credential);
>> } catch (NamingException e) {
>> // do nothing if bind fails since we check for other DN
>> // patterns as well.
>> if (log.isDebugEnabled()) {
>> log.debug("Checking authentication with UserDN " +
>> name + "failed " +
>> e.getMessage(), e);
>> }
>> }
>>
>> return bValue;
>>
>> }
>>
>> // read list of patterns from user-mgt.xml
>> String patterns =
>> realmConfig.getUserStoreProperty(LDAPConstants.USER_DN_PATTERN);
>>
>> if (patterns != null && !patterns.isEmpty()) {
>>
>> if (debug) {
>> log.debug("Using UserDNPatterns " + patterns);
>> }
>>
>> // if the property is present, split it using # to see if
>> there are
>> // multiple patterns specified.
>> String[] userDNPatternList = patterns.split("#");
>> if (userDNPatternList.length > 0) {
>> for (String userDNPattern : userDNPatternList) {
>> name = MessageFormat.format(userDNPattern,
>>
>> escapeUsernameSpecialCharacters(userName,true));
>> if (debug) {
>> log.debug("Authenticating with " + name);
>> }
>> try {
>> if (name != null) {
>> bValue = this.bindAsUser(userName, name,
>> (String) credential);
>> if (bValue) {
>> userCache.put(userName, name);
>> break;
>> }
>> }
>>  

Re: [Dev] [ESBJAVA-3836] - JSP compilation error on JDK 8

2015-06-26 Thread Prabath Ariyarathna
Hi Kasun G.

Reason seems to be exposed same ECJ packages from
the jasper-jdt_6.0.18.wso2v1 bundle and it has exposed from the
carbon-commons (org.wso2.carbon.reporting.ui.feature). After removing this
bundle JSP exceptions has not occurred.


Thanks.

On Fri, Jun 26, 2015 at 6:27 AM, Prabath Ariyarathna 
wrote:

> Hi KasunG.
>
> I tested scenario with the set carbon-kernel  ECJ version to
> 4.4.2 but same  exceptions can see in the console however if we place the
> ECJ jar into the lib directory, it is working perfectly even for the old
> ECJ 4.3.1.
>
>
> Thanks.
>
> On Thu, Jun 25, 2015 at 6:39 PM, KasunG Gajasinghe 
> wrote:
>
>> Raised a jira - https://wso2.org/jira/browse/WSAS-1993
>>
>> On Thu, Jun 25, 2015 at 6:38 PM, KasunG Gajasinghe 
>> wrote:
>>
>>>
>>> The ECJ bundle is not packed into the Tomcat orbit. Rather, it is
>>> included in kernel o.w.c.core.common feature. We have tested with ECJ
>>> 4.4.2, and it worked.
>>>
>>> PrabathAR is testing this further.
>>>
>>> On Thu, Jun 25, 2015 at 6:28 AM, Prabath Ariyarathna >> > wrote:
>>>
 Hi KasunG.

 I tried with change ECJ version to 4.4.2 but same error has occurred.
 Do I need to change anything other than the ECJ version?


 Thanks.

 On Wed, Jun 24, 2015 at 5:28 PM, KasunG Gajasinghe 
 wrote:

> Hi,
>
> We are using Eclipse ECJ for JSP compilation which is packed into the
> Tomcat orbit bundle. We are currently using ECJ 4.3.1. To support JDK 8, 
> we
> will need to update it to ECJ 4.4.x as per this Tomcat bug [1].
>
> To verify, can you guys try your scenario by updating the ecj version
> of tomcat orbit [2] to 4.4.2?
>
>
> [1] https://bz.apache.org/bugzilla/show_bug.cgi?id=56283
> [2]
> https://github.com/wso2/orbit/blob/master/tomcat/7.0.59.wso2v3/pom.xml
>
> Regards,
> KasunG
>
> --
>
> *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
> email: kasung AT spamfree wso2.com
> linked-in: http://lk.linkedin.com/in/gajasinghe
> blog: http://kasunbg.org
>
>
>



 --

 *Prabath Ariyarathna*

 *Associate Technical Lead*

 *WSO2, Inc. *

 *lean . enterprise . middleware *


 *Email: prabat...@wso2.com *

 *Blog: http://prabu-lk.blogspot.com *

 *Flicker : https://www.flickr.com/photos/47759189@N08
 *

 *Mobile: +94 77 699 4730 *






>>>
>>>
>>> --
>>>
>>> *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
>>> email: kasung AT spamfree wso2.com
>>> linked-in: http://lk.linkedin.com/in/gajasinghe
>>> blog: http://kasunbg.org
>>>
>>>
>>>
>>
>>
>>
>> --
>>
>> *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
>> email: kasung AT spamfree wso2.com
>> linked-in: http://lk.linkedin.com/in/gajasinghe
>> blog: http://kasunbg.org
>>
>>
>>
>
>
>
> --
>
> *Prabath Ariyarathna*
>
> *Associate Technical Lead*
>
> *WSO2, Inc. *
>
> *lean . enterprise . middleware *
>
>
> *Email: prabat...@wso2.com *
>
> *Blog: http://prabu-lk.blogspot.com *
>
> *Flicker : https://www.flickr.com/photos/47759189@N08
> *
>
> *Mobile: +94 77 699 4730 *
>
>
>
>
>
>


-- 

*Prabath Ariyarathna*

*Associate Technical Lead*

*WSO2, Inc. *

*lean . enterprise . middleware *


*Email: prabat...@wso2.com *

*Blog: http://prabu-lk.blogspot.com *

*Flicker : https://www.flickr.com/photos/47759189@N08
*

*Mobile: +94 77 699 4730 *
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [BAM] Sorted view of the Cassandra data in the BAM Console

2015-06-26 Thread Shabir Mohamed
Hi,

Is there a way I could *"sort"* & view the data written to Cassandra in
WSO2 BAM via the Explore Cluster window under Cassandra Explorer???

Thanks
-
*Shabir Mohamed*
*Software Engineer*
WSO2 Inc.; http://wso2.com
Email: sha...@wso2.com 
Mobile: +94 77 3516019 | +94 71 6583393
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Metrics UI: Show we restrict to super-tenant only?

2015-06-26 Thread Isuru Perera
Hi,

Do we need to show Metrics UIs for tenant users? I think we should restrict
Metrics UIs to super-tenant and allow only if there is some admin
permission.

WDYT?

Thanks!

-- 
Isuru Perera
Associate Technical Lead | WSO2, Inc. | http://wso2.com/
Lean . Enterprise . Middleware

about.me/chrishantha
Contact: +IsuruPereraWSO2 
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Metrics UI: Show we restrict to super-tenant only?

2015-06-26 Thread Srinath Perera
+1

On Fri, Jun 26, 2015 at 2:35 PM, Isuru Perera  wrote:

> Hi,
>
> Do we need to show Metrics UIs for tenant users? I think we should
> restrict Metrics UIs to super-tenant and allow only if there is some admin
> permission.
>
> WDYT?
>
> Thanks!
>
> --
> Isuru Perera
> Associate Technical Lead | WSO2, Inc. | http://wso2.com/
> Lean . Enterprise . Middleware
>
> about.me/chrishantha
> Contact: +IsuruPereraWSO2 
>



-- 

Blog: http://srinathsview.blogspot.com twitter:@srinath_perera
Site: http://people.apache.org/~hemapani/
Photos: http://www.flickr.com/photos/hemapani/
Phone: 0772360902
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [BAM] Sorted view of the Cassandra data in the BAM Console

2015-06-26 Thread Anjana Fernando
Hi Shabir,

I'm afraid, we cannot do that. The data is shown in the same order we get
from Cassandra.

Cheers,
Anjana.

On Fri, Jun 26, 2015 at 2:31 PM, Shabir Mohamed  wrote:

> Hi,
>
> Is there a way I could *"sort"* & view the data written to Cassandra in
> WSO2 BAM via the Explore Cluster window under Cassandra Explorer???
>
> Thanks
> -
> *Shabir Mohamed*
> *Software Engineer*
> WSO2 Inc.; http://wso2.com
> Email: sha...@wso2.com 
> Mobile: +94 77 3516019 | +94 71 6583393
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Anjana Fernando*
Senior Technical Lead
WSO2 Inc. | http://wso2.com
lean . enterprise . middleware
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Supporting referential integrity in the database of WSO2MB

2015-06-26 Thread Sasikala Kottegoda
Hi all,

Currently our database schema does not support referential integrity
between the tables MB_CONTENT (which stores message contet) and MB_METADATA
(which store message metadata). But message content with no related
metadata is meaningless.

To address this problem, what we have done is deleting message content
along with metadata.

But if we have have a foreign key relationship between the two tables, we
will be able to ensure that no message content will be left without
metadata associated. Also, it will reduce the number of database calls that
are made thus speeding up the process.

Any comments?

Thank you.
-- 
Sasikala Kottegoda
*Software Engineer*
WSO2 Inc., http://wso2.com/
lean. enterprise. middleware
Mobile: +94 774835928/712792401
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Metrics UI: Show we restrict to super-tenant only?

2015-06-26 Thread Isuru Perera
Thanks Srinath!

I will show Metrics UI only in super-tenant.

PS: Subject of this mail thread should be: "Metrics UI: *Should* we
restrict to super-tenant only?". Sorry about the mistake!

On Fri, Jun 26, 2015 at 2:39 PM, Srinath Perera  wrote:

> +1
>
> On Fri, Jun 26, 2015 at 2:35 PM, Isuru Perera  wrote:
>
>> Hi,
>>
>> Do we need to show Metrics UIs for tenant users? I think we should
>> restrict Metrics UIs to super-tenant and allow only if there is some admin
>> permission.
>>
>> WDYT?
>>
>> Thanks!
>>
>> --
>> Isuru Perera
>> Associate Technical Lead | WSO2, Inc. | http://wso2.com/
>> Lean . Enterprise . Middleware
>>
>> about.me/chrishantha
>> Contact: +IsuruPereraWSO2 
>>
>
>
>
> --
> 
> Blog: http://srinathsview.blogspot.com twitter:@srinath_perera
> Site: http://people.apache.org/~hemapani/
> Photos: http://www.flickr.com/photos/hemapani/
> Phone: 0772360902
>



-- 
Isuru Perera
Associate Technical Lead | WSO2, Inc. | http://wso2.com/
Lean . Enterprise . Middleware

about.me/chrishantha
Contact: +IsuruPereraWSO2 
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Supporting referential integrity in the database of WSO2MB

2015-06-26 Thread Anuja Herath
Hi Sasikala,

Since we dropped cassandra, this will enable us to use full power of RDBMS.
But make sure that mentioned operations will work on MySQL, MS SQL and
oracle in the same way.

Thanks,
Anuja

On Fri, Jun 26, 2015 at 2:56 PM, Sasikala Kottegoda 
wrote:

> Hi all,
>
> Currently our database schema does not support referential integrity
> between the tables MB_CONTENT (which stores message contet) and MB_METADATA
> (which store message metadata). But message content with no related
> metadata is meaningless.
>
> To address this problem, what we have done is deleting message content
> along with metadata.
>
> But if we have have a foreign key relationship between the two tables, we
> will be able to ensure that no message content will be left without
> metadata associated. Also, it will reduce the number of database calls that
> are made thus speeding up the process.
>
> Any comments?
>
> Thank you.
> --
> Sasikala Kottegoda
> *Software Engineer*
> WSO2 Inc., http://wso2.com/
> lean. enterprise. middleware
> Mobile: +94 774835928/712792401
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Anuja Herath
*Software Engineer*
*WSO2, Inc.*
Mobile : +94 (0)71 429 8861
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Please review and merge PR for IDENTITY-3371

2015-06-26 Thread Nuwandi Wickramasinghe
Hi,
Fix for [1] is found in [2]

[1] https://wso2.org/jira/browse/IDENTITY-3371
[2] https://github.com/wso2/carbon-identity/pull/492

thanks




-- 

Best Regards,

Nuwandi Wickramasinghe

Software Engineer

WSO2 Inc.

Web : http://wso2.com

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


Re: [Dev] [ESBJAVA-3836] - JSP compilation error on JDK 8

2015-06-26 Thread KasunG Gajasinghe
It is wrong to package ECJ bundles inside reporting ui feature. This bundle
is already coming from kernel.

The jasper-jdt is a wso2 orbit of ECJ, but there was no need to create an
orbit in the first place since the original jar itself is an osgi bundle.

I believe we can remove this from the reporting ui feature. But can you
verify that with the maintainers of the reporting component?


On Fri, Jun 26, 2015 at 2:16 PM, Prabath Ariyarathna 
wrote:

> Hi Kasun G.
>
> Reason seems to be exposed same ECJ packages from
> the jasper-jdt_6.0.18.wso2v1 bundle and it has exposed from the
> carbon-commons (org.wso2.carbon.reporting.ui.feature). After removing
> this bundle JSP exceptions has not occurred.
>
>
> Thanks.
>
> On Fri, Jun 26, 2015 at 6:27 AM, Prabath Ariyarathna 
> wrote:
>
>> Hi KasunG.
>>
>> I tested scenario with the set carbon-kernel  ECJ version to
>> 4.4.2 but same  exceptions can see in the console however if we place the
>> ECJ jar into the lib directory, it is working perfectly even for the old
>> ECJ 4.3.1.
>>
>>
>> Thanks.
>>
>> On Thu, Jun 25, 2015 at 6:39 PM, KasunG Gajasinghe 
>> wrote:
>>
>>> Raised a jira - https://wso2.org/jira/browse/WSAS-1993
>>>
>>> On Thu, Jun 25, 2015 at 6:38 PM, KasunG Gajasinghe 
>>> wrote:
>>>

 The ECJ bundle is not packed into the Tomcat orbit. Rather, it is
 included in kernel o.w.c.core.common feature. We have tested with ECJ
 4.4.2, and it worked.

 PrabathAR is testing this further.

 On Thu, Jun 25, 2015 at 6:28 AM, Prabath Ariyarathna <
 prabat...@wso2.com> wrote:

> Hi KasunG.
>
> I tried with change ECJ version to 4.4.2 but same error has occurred.
> Do I need to change anything other than the ECJ version?
>
>
> Thanks.
>
> On Wed, Jun 24, 2015 at 5:28 PM, KasunG Gajasinghe 
> wrote:
>
>> Hi,
>>
>> We are using Eclipse ECJ for JSP compilation which is packed into the
>> Tomcat orbit bundle. We are currently using ECJ 4.3.1. To support JDK 8, 
>> we
>> will need to update it to ECJ 4.4.x as per this Tomcat bug [1].
>>
>> To verify, can you guys try your scenario by updating the ecj version
>> of tomcat orbit [2] to 4.4.2?
>>
>>
>> [1] https://bz.apache.org/bugzilla/show_bug.cgi?id=56283
>> [2]
>> https://github.com/wso2/orbit/blob/master/tomcat/7.0.59.wso2v3/pom.xml
>>
>> Regards,
>> KasunG
>>
>> --
>>
>> *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
>> email: kasung AT spamfree wso2.com
>> linked-in: http://lk.linkedin.com/in/gajasinghe
>> blog: http://kasunbg.org
>>
>>
>>
>
>
>
> --
>
> *Prabath Ariyarathna*
>
> *Associate Technical Lead*
>
> *WSO2, Inc. *
>
> *lean . enterprise . middleware *
>
>
> *Email: prabat...@wso2.com *
>
> *Blog: http://prabu-lk.blogspot.com *
>
> *Flicker : https://www.flickr.com/photos/47759189@N08
> *
>
> *Mobile: +94 77 699 4730 *
>
>
>
>
>
>


 --

 *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
 email: kasung AT spamfree wso2.com
 linked-in: http://lk.linkedin.com/in/gajasinghe
 blog: http://kasunbg.org



>>>
>>>
>>>
>>> --
>>>
>>> *Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
>>> email: kasung AT spamfree wso2.com
>>> linked-in: http://lk.linkedin.com/in/gajasinghe
>>> blog: http://kasunbg.org
>>>
>>>
>>>
>>
>>
>>
>> --
>>
>> *Prabath Ariyarathna*
>>
>> *Associate Technical Lead*
>>
>> *WSO2, Inc. *
>>
>> *lean . enterprise . middleware *
>>
>>
>> *Email: prabat...@wso2.com *
>>
>> *Blog: http://prabu-lk.blogspot.com *
>>
>> *Flicker : https://www.flickr.com/photos/47759189@N08
>> *
>>
>> *Mobile: +94 77 699 4730 *
>>
>>
>>
>>
>>
>>
>
>
> --
>
> *Prabath Ariyarathna*
>
> *Associate Technical Lead*
>
> *WSO2, Inc. *
>
> *lean . enterprise . middleware *
>
>
> *Email: prabat...@wso2.com *
>
> *Blog: http://prabu-lk.blogspot.com *
>
> *Flicker : https://www.flickr.com/photos/47759189@N08
> *
>
> *Mobile: +94 77 699 4730 *
>
>
>
>
>
>


-- 

*Kasun Gajasinghe*Senior Software Engineer, WSO2 Inc.
email: kasung AT spamfree wso2.com
linked-in: http://lk.linkedin.com/in/gajasinghe
blog: http://kasunbg.org
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [ESB] JMS Inbound Endpoint Topic Consumer Configuration

2015-06-26 Thread Malaka Silva
Note added to esb 490 documentation.

On Wed, May 27, 2015 at 9:48 PM, eranda rajapaksha 
wrote:

> Hi,
>
> I think it will be really helpful to have a note on this and about the
> cache level.
>
> Thank you!
>
> On Wed, May 27, 2015 at 8:40 PM, Hasitha Hiranya 
> wrote:
>
>> Hi,
>>
>> Is this something we need to document?
>>
>> Thanks
>>
>> On Wed, May 27, 2015 at 10:07 AM, eranda rajapaksha 
>> wrote:
>>
>>> Hi,
>>>
>>> It works fine after changing the cache level.
>>>
>>> Thanks a lot!
>>>
>>> On Wed, May 27, 2015 at 12:13 PM, Malaka Silva  wrote:
>>>
 Hi Eranda,

 Increase the transport.jms.CacheLevel to maximum and check.

 You should see registered consumers in activemq topic ui view.

 On Tue, May 26, 2015 at 10:20 PM, eranda rajapaksha >>> > wrote:

> Hi,
>
> I am trying to configure WSO2 ESB JMS inbound endpoint as a Topic
> Listener with ActiveMQ broker.
> I used following configuration on wso2esb-4.9.0-M8-SNAPSHOT and it
> worked fine, but when I use the same configuration with 
> wso2esb-4.9.0-ALPHA
> it doesn't work. (it doesn't consume messages from the given ActiveMQ 
> topic)
> Is there any change that I have to do in the configuration with
> wso2esb-4.9.0-ALPHA?
>
> 
>> http://ws.apache.org/ns/synapse";>
>>> provider="org.wso2.carbon.mediation.registry.WSO2Registry">
>>   15000
>>
>>> provider="org.wso2.carbon.mediation.ntask.NTaskTaskManager">
>>   15000
>>
>>
>>   
>>  
>> http://localhost:9000/services/SimpleStockQuoteService";
>>  format="soap12"/>
>>  
>>   
>>   
>>
>>
>>   
>>  
>>  > expression="get-property('ERROR_CODE')"/>
>>  > expression="get-property('ERROR_MESSAGE')"/>
>>   
>>   
>>
>>
>>   
>>   
>>
>>> sequence="request"
>> onError="fault"
>> protocol="jms"
>> suspend="false">
>>   
>>  1000
>>  > name="transport.jms.Destination">exampleTopic
>>  1
>>  > name="transport.jms.ConnectionFactoryJNDIName">TopicConnectionFactory
>>  true
>>  > name="java.naming.factory.initial">org.apache.activemq.jndi.ActiveMQInitialContextFactory
>>  > name="java.naming.provider.url">tcp://localhost:61616
>>  > name="transport.jms.SessionAcknowledgement">AUTO_ACKNOWLEDGE
>>  > name="transport.jms.SessionTransacted">false
>>  > name="transport.jms.ConnectionFactoryType">topic
>>   
>>
>> 
>
>
> Thank you!
>
> --
> *Eranda Rajapakshe*
> Computer Science and Engineering Undergraduate,
> University of Moratuwa.
> Tel : +94784822608
> Email : erand...@gmail.com 
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


 --

 Best Regards,

 Malaka Silva
 Senior Tech Lead
 M: +94 777 219 791
 Tel : 94 11 214 5345
 Fax :94 11 2145300
 Skype : malaka.sampath.silva
 LinkedIn : http://www.linkedin.com/pub/malaka-silva/6/33/77
 Blog : http://mrmalakasilva.blogspot.com/

 WSO2, Inc.
 lean . enterprise . middleware
 http://www.wso2.com/
 http://www.wso2.com/about/team/malaka-silva/
 

 Save a tree -Conserve nature & Save the world for your future. Print
 this email only if it is absolutely necessary.

>>>
>>>
>>>
>>> --
>>> *Eranda Rajapakshe*
>>> Computer Science and Engineering Undergraduate,
>>> University of Moratuwa.
>>> Tel : +94784822608
>>> Email : erand...@gmail.com 
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> *Hasitha Abeykoon*
>> Senior Software Engineer; WSO2, Inc.; http://wso2.com
>> *cell:* *+94 719363063*
>> *blog: **abeykoon.blogspot.com* 
>>
>>
>
>
> --
> *Eranda Rajapakshe*
> Computer Science and Engineering Undergraduate,
> University of Moratuwa.
> Tel : +94784822608
> Email : erand...@gmail.com 
>



-- 

Best Regards,

Malaka Silva
Senior Tech Lead
M: +94 777 219 791
Tel : 94 11 214 5345
Fax :94 11 2145300
Skype : malaka.sampath.silva
LinkedIn : http://www.linkedin.com/pub/malaka-silva/6/33/77
Blog : http://mrmalakasilva.blogspot.com/

WSO2, Inc.
lean . enterprise . middleware
http://www.wso2.com/
http://www.wso2.com/about/team/malaka-silva/


Save a tree -Conserve nature & Save t

Re: [Dev] [AS]

2015-06-26 Thread Sabra Ossen
Hi,

@Thusitha , there are no extra jars in the web app and also is there is
method to check out the actual web socket that gets deployed in the AS.

@Kasun, the name of the web app is the same "TestWebApp" and I checked the
behavior in chrome which displays the following error in the console


*Failed to load resource: the server responded with a status of 405 (Method
Not Allowed)WebSocket connection to 'ws://10.224.29.52:9763/TestWebApp/echo
' failed: Error during WebSocket
handshake: Unexpected response code: 404*

Regards.

On Thu, Jun 25, 2015 at 6:55 PM, KasunG Gajasinghe  wrote:

> Hi,
>
> What's the war name of your webapp? AS do not process the path parameter
> in context.xml currently. Rather, it uses the war name as the context.
>
> Also, you might want to run the same in Chome and verify the behavior. In
> some of the Firefox versions, you need to use MozWebSocket object instead
> of WebSocket object. See [1].
>
> [1]
> https://github.com/wso2/product-as/blob/master/modules/samples/example/src/main/resources/websocket/chat.xhtml#L55
>
> On Thu, Jun 25, 2015 at 5:38 PM, Thusitha Thilina Dayaratne <
> thusit...@wso2.com> wrote:
>
>> Hi Sabra,
>>
>> AFAIK you don't have to do any extra configurations to make websocket
>> works with AS. This kind of issues may pop out when webapp contains
>> websoket jars inside the webapp itself (WEB-INF/lib).
>> IF not most probably there is some mismatch in the actual websocket that
>> get deployed and what you are trying to connect.
>>
>> Thanks
>>
>> On Thu, Jun 25, 2015 at 5:08 PM, Sabra Ossen  wrote:
>>
>>> Hi Thusitha,
>>>
>>> The context path is as follows (present in context.xml),  *>> antiJARLocking="true" path="/TestWebApp"/>*
>>>
>>> and the error code is 404 stating that the html file "echo" was not
>>> found.
>>>
>>> Thanks.
>>>
>>> On Thu, Jun 25, 2015 at 4:43 PM, Thusitha Thilina Dayaratne <
>>> thusit...@wso2.com> wrote:
>>>
 Hi Sabra,

 Did you check the Context path is correct? Also can you check what is
 the error code that you get?
 Thanks

 On Thu, Jun 25, 2015 at 4:28 PM, Sabra Ossen 
 wrote:

> Hi,
>
> I am following the blog mentioned in [1] and I can successfully run
> the Web App in the local tomcat server, when I run the following code in
> the WSO2 AS 5.3.0 alpha the browser returns the following error in the
> browser console.
>
> *Firefox can't establish a connection to the server at
> ws://10.225.125.91:9763/TestWebApp/echo
> .*
>
> Server code;
>
> import java.io.IOException;
>  import javax.websocket.OnClose;import javax.websocket.OnMessage;import 
> javax.websocket.OnOpen;import javax.websocket.Session;import 
> javax.websocket.server.ServerEndpoint;
>
> @ServerEndpoint("/echo") public class EchoServer {
>
> @OnOpen
> public void onOpen(Session session){
> System.out.println(session.getId() + " has opened a connection");
> try {
> session.getBasicRemote().sendText("Connection Established");
> } catch (IOException ex) {
> ex.printStackTrace();
> }
> }
>
> @OnMessage
> public void onMessage(String message, Session session){
> System.out.println("Message from " + session.getId() + ": " + 
> message);
> try {
> session.getBasicRemote().sendText(message);
> } catch (IOException ex) {
> ex.printStackTrace();
> }
> }
>
> @OnClose
> public void onClose(Session session){
> System.out.println("Session " +session.getId()+" has ended");
> }}
>
>
> index.html;
>
> 
>
> 
> 
> Echo Chamber
> 
> 
> 
> 
>
> 
> 
> 
> 
> Open button>
> Send
> Close button>
> 
> 
> 
>
> 
> 
>
> var webSocket;
> var messages = document.getElementById("messages");
>
> function openSocket(){
>
> if(webSocket !== undefined && webSocket.readyState
> !== WebSocket.CLOSED){
>writeResponse("WebSocket is already opened.");
> return;
> }
>
> *webSocket = new WebSocket("ws://" +
> window.location.host + "/TestWebApp/echo");*
>
> webSocket.onopen = function(event){
> if(event.data === undefined)
> return;
>
> writeResponse(event.data);
> };
>
> 

[Dev] Visibility of Internal Roles for the tenant admins

2015-06-26 Thread Tanya Madurapperuma
Hi,

In products like ES, APIM we have set of internal roles such as
internal/publisher, internal/store, internal/reviewer etc that comes by
default.

These roles are visible when we log into the super tenant.

But if we create a tenant and login to that tenant from management console
as the tenant admin, those internal roles are not visible to the tenant
admin.

Is this the desired behaviour ?
If so, is it the responsibility of the tenant admin to create those roles
manually and assign the appropriate permission to that role?

Appreciate any insight.

Thanks,
Tanya


-- 
Tanya Madurapperuma

Senior Software Engineer,
WSO2 Inc. : wso2.com
Mobile : +94718184439
Blog : http://tanyamadurapperuma.blogspot.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [AS]

2015-06-26 Thread Chathura Priyankara
Hi Sabra,

I was able to run the same sample successfully in AS 5.3.0 running on
Ubuntu machine. I'm using JDK 7.
Could you please mention the JDK version and OS that you are using ?

Regards,
Chathura.

On Fri, Jun 26, 2015 at 3:55 PM, Sabra Ossen  wrote:

> Hi,
>
> @Thusitha , there are no extra jars in the web app and also is there is
> method to check out the actual web socket that gets deployed in the AS.
>
> @Kasun, the name of the web app is the same "TestWebApp" and I checked the
> behavior in chrome which displays the following error in the console
>
>
> *Failed to load resource: the server responded with a status of 405
> (Method Not Allowed)WebSocket connection to
> 'ws://10.224.29.52:9763/TestWebApp/echo
> ' failed: Error during WebSocket
> handshake: Unexpected response code: 404*
>
> Regards.
>
> On Thu, Jun 25, 2015 at 6:55 PM, KasunG Gajasinghe 
> wrote:
>
>> Hi,
>>
>> What's the war name of your webapp? AS do not process the path parameter
>> in context.xml currently. Rather, it uses the war name as the context.
>>
>> Also, you might want to run the same in Chome and verify the behavior. In
>> some of the Firefox versions, you need to use MozWebSocket object instead
>> of WebSocket object. See [1].
>>
>> [1]
>> https://github.com/wso2/product-as/blob/master/modules/samples/example/src/main/resources/websocket/chat.xhtml#L55
>>
>> On Thu, Jun 25, 2015 at 5:38 PM, Thusitha Thilina Dayaratne <
>> thusit...@wso2.com> wrote:
>>
>>> Hi Sabra,
>>>
>>> AFAIK you don't have to do any extra configurations to make websocket
>>> works with AS. This kind of issues may pop out when webapp contains
>>> websoket jars inside the webapp itself (WEB-INF/lib).
>>> IF not most probably there is some mismatch in the actual websocket that
>>> get deployed and what you are trying to connect.
>>>
>>> Thanks
>>>
>>> On Thu, Jun 25, 2015 at 5:08 PM, Sabra Ossen  wrote:
>>>
 Hi Thusitha,

 The context path is as follows (present in context.xml),  *>>> antiJARLocking="true" path="/TestWebApp"/>*

 and the error code is 404 stating that the html file "echo" was not
 found.

 Thanks.

 On Thu, Jun 25, 2015 at 4:43 PM, Thusitha Thilina Dayaratne <
 thusit...@wso2.com> wrote:

> Hi Sabra,
>
> Did you check the Context path is correct? Also can you check what is
> the error code that you get?
> Thanks
>
> On Thu, Jun 25, 2015 at 4:28 PM, Sabra Ossen 
> wrote:
>
>> Hi,
>>
>> I am following the blog mentioned in [1] and I can successfully run
>> the Web App in the local tomcat server, when I run the following code in
>> the WSO2 AS 5.3.0 alpha the browser returns the following error in the
>> browser console.
>>
>> *Firefox can't establish a connection to the server at
>> ws://10.225.125.91:9763/TestWebApp/echo
>> .*
>>
>> Server code;
>>
>> import java.io.IOException;
>>  import javax.websocket.OnClose;import javax.websocket.OnMessage;import 
>> javax.websocket.OnOpen;import javax.websocket.Session;import 
>> javax.websocket.server.ServerEndpoint;
>>
>> @ServerEndpoint("/echo") public class EchoServer {
>>
>> @OnOpen
>> public void onOpen(Session session){
>> System.out.println(session.getId() + " has opened a connection");
>> try {
>> session.getBasicRemote().sendText("Connection Established");
>> } catch (IOException ex) {
>> ex.printStackTrace();
>> }
>> }
>>
>> @OnMessage
>> public void onMessage(String message, Session session){
>> System.out.println("Message from " + session.getId() + ": " + 
>> message);
>> try {
>> session.getBasicRemote().sendText(message);
>> } catch (IOException ex) {
>> ex.printStackTrace();
>> }
>> }
>>
>> @OnClose
>> public void onClose(Session session){
>> System.out.println("Session " +session.getId()+" has ended");
>> }}
>>
>>
>> index.html;
>>
>> 
>>
>> 
>> 
>> Echo Chamber
>> 
>> 
>> 
>> 
>>
>> 
>> 
>> 
>> 
>> Open> button>
>> Send
>> Close> button>
>> 
>> 
>> 
>>
>> 
>> 
>>
>> var webSocket;
>> var messages = document.getElementById("messages");
>>
>> function openSocket(){
>>
>> if(webSocket !== undefined && webSocket.readyState
>> !== WebSocket.CLOSED){
>>writeResponse("WebSocket is already opened.");
>>  

[Dev] How OSGi Bundle Activation Policy Works in Runtime

2015-06-26 Thread Nuwan Pallewela
If a plug-in's Bundle Activation Policy is configured as "lazy", will
another plug-in which depends on it can use it if the current state of the
first plug-in is in RESOLVED state? Will it come to ACTIVE state because of
the second plug-In's invocation?

-- 
--

*Nuwan Chamara Pallewela*


*Software Engineer*

*WSO2, Inc. *
*lean . enterprise . middleware*

Email   *nuw...@wso2.com *
Mobile  *+94719079739*
*+94767100087*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Visibility of Internal Roles for the tenant admins

2015-06-26 Thread Bhathiya Jayasekara
Hi Tanya,

On Fri, Jun 26, 2015 at 4:44 PM, Tanya Madurapperuma  wrote:

> Hi,
>
> In products like ES, APIM we have set of internal roles such as
> internal/publisher, internal/store, internal/reviewer etc that comes by
> default.
>
> These roles are visible when we log into the super tenant.
>
> But if we create a tenant and login to that tenant from management console
> as the tenant admin, those internal roles are not visible to the tenant
> admin.
>
> Is this the desired behaviour ?
>

Yes, roles belong to a particular tenant.


> If so, is it the responsibility of the tenant admin to create those roles
> manually and assign the appropriate permission to that role?
>

You can automate that by writing a tenant loading listener by extending
AbstractAxis2ConfigurationContextObserver.

Thanks,
Bhathiya


>
> Appreciate any insight.
>
> Thanks,
> Tanya
>
>
> --
> Tanya Madurapperuma
>
> Senior Software Engineer,
> WSO2 Inc. : wso2.com
> Mobile : +94718184439
> Blog : http://tanyamadurapperuma.blogspot.com
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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

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


Re: [Dev] Visibility of Internal Roles for the tenant admins

2015-06-26 Thread Ishara Karunarathna
Hi,

On Fri, Jun 26, 2015 at 5:01 PM, Bhathiya Jayasekara 
wrote:

> Hi Tanya,
>
> On Fri, Jun 26, 2015 at 4:44 PM, Tanya Madurapperuma 
> wrote:
>
>> Hi,
>>
>> In products like ES, APIM we have set of internal roles such as
>> internal/publisher, internal/store, internal/reviewer etc that comes by
>> default.
>>
>> These roles are visible when we log into the super tenant.
>>
>> But if we create a tenant and login to that tenant from management
>> console as the tenant admin, those internal roles are not visible to the
>> tenant admin.
>>
>> Is this the desired behaviour ?
>>
>
> Yes, roles belong to a particular tenant.
>
>
>> If so, is it the responsibility of the tenant admin to create those roles
>> manually and assign the appropriate permission to that role?
>>
>
> You can automate that by writing a tenant loading listener by extending
> AbstractAxis2ConfigurationContextObserver.
>
I think its better to use TenantMgtListener to  do this.

Thanks,
Ishara

>
> Thanks,
> Bhathiya
>
>
>>
>> Appreciate any insight.
>>
>> Thanks,
>> Tanya
>>
>>
>> --
>> Tanya Madurapperuma
>>
>> Senior Software Engineer,
>> WSO2 Inc. : wso2.com
>> Mobile : +94718184439
>> Blog : http://tanyamadurapperuma.blogspot.com
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> *Bhathiya Jayasekara*
> *Senior Software Engineer,*
> *WSO2 inc., http://wso2.com *
>
> *Phone: +94715478185 <%2B94715478185>*
> *LinkedIn: http://www.linkedin.com/in/bhathiyaj
> *
> *Twitter: https://twitter.com/bhathiyax *
> *Blog: http://movingaheadblog.blogspot.com
> *
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Ishara Karunarathna
Senior Software Engineer
WSO2 Inc. - lean . enterprise . middleware |  wso2.com

email: isha...@wso2.com,   blog: isharaaruna.blogspot.com,   mobile:
+94717996791
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Maven.wso2.org will be unavailable during 2015-06-26 1700- 1800 IST

2015-06-26 Thread Chamara Thilina
HI,

Due to unavoidable circumstances we have postponed the maintenance.

Thank You,
ChamaraT

On Fri, Jun 26, 2015 at 9:53 AM, Chamara Thilina  wrote:

> HI All,
>
>
> For the maintenance purpose maven.wso2.org will be unavailable during
> above mentioned time.
>
> Sorry for the inconvenience causing.
>
> Thank You,
> ChamaraT
>
> --
> Chamara Thilina Samarakoon
> Senior Systems Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: +94772929487
> blog: http://mageconfig.blogspot.com/
> linkedin: https://www.linkedin.com/pub/chamara-samarakoon
>
>


-- 
Chamara Thilina Samarakoon
Senior Systems Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

mobile: +94772929487
blog: http://mageconfig.blogspot.com/
linkedin: https://www.linkedin.com/pub/chamara-samarakoon
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Please review and merge PR for IDENTITY-3372

2015-06-26 Thread Nuwandi Wickramasinghe
Hi,
Please find fix for [1] in [2]

[1] https://wso2.org/jira/browse/IDENTITY-3372
[2] https://github.com/wso2/carbon-identity/pull/499
-- 

Best Regards,

Nuwandi Wickramasinghe

Software Engineer

WSO2 Inc.

Web : http://wso2.com

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


[Dev] Please review and merge

2015-06-26 Thread Kathees Rajendram
Hi Malaka,

Please review and merge the PR[1] for Disqus.Some methods are failing
because of *"This method is currently under development*" in API [2].

[1] - https://github.com/wso2/esb-connectors/pull/208
[2] - https://disqus.com/api/docs/threads/create/

Thanks,
Kathees

-- 
Kathees
Software Engineer,
email: kath...@wso2.com
mobile: +94772596173
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Please review and merge

2015-06-26 Thread Malaka Silva
How many methods are there in the connector and how many are failing?

On Fri, Jun 26, 2015 at 6:14 PM, Kathees Rajendram  wrote:

> Hi Malaka,
>
> Please review and merge the PR[1] for Disqus.Some methods are failing
> because of *"This method is currently under development*" in API [2].
>
> [1] - https://github.com/wso2/esb-connectors/pull/208
> [2] - https://disqus.com/api/docs/threads/create/
>
> Thanks,
> Kathees
>
> --
> Kathees
> Software Engineer,
> email: kath...@wso2.com
> mobile: +94772596173
>



-- 

Best Regards,

Malaka Silva
Senior Tech Lead
M: +94 777 219 791
Tel : 94 11 214 5345
Fax :94 11 2145300
Skype : malaka.sampath.silva
LinkedIn : http://www.linkedin.com/pub/malaka-silva/6/33/77
Blog : http://mrmalakasilva.blogspot.com/

WSO2, Inc.
lean . enterprise . middleware
http://www.wso2.com/
http://www.wso2.com/about/team/malaka-silva/


Save a tree -Conserve nature & Save the world for your future. Print this
email only if it is absolutely necessary.
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [APPM]Please review and merge PR for APPM-482

2015-06-26 Thread Sajith Abeywardhana
Hi Team,

Please review and merge PR[1] for APPM-482[2]

[1]. https://github.com/wso2/carbon-appmgt/pull/85
[2]. https://wso2.org/jira/browse/APPM-482

*Sajith Abeywardhana* | Software Engineer
WSO2, Inc | lean. enterprise. middleware.
#20, Palm Grove, Colombo 03, Sri Lanka.
Mobile: +94772260485
Email: saji...@wso2.com  | Web: www.wso2.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] make MB bind to 0.0.0.0 by default

2015-06-26 Thread Manuranga Perera
done https://wso2.org/jira/browse/MB-1124

On Fri, Jun 26, 2015 at 1:07 AM, Ramith Jayasinghe  wrote:

> could you create a public jira.?
>
> On Fri, Jun 26, 2015 at 11:34 AM, Manuranga Perera  wrote:
>
>> MB by default bind to 127.0.0.1 . This is not sometime visible through
>> other interfaces such were Wi-Fi and has to be manually changed to IP form
>> broker.xml.
>>
>> It's better if we can bind it to 0.0.0.0 or to :: .Please test this and
>> make it the default.
>> --
>> With regards,
>> *Manu*ranga Perera.
>>
>> phone : 071 7 70 20 50
>> mail : manu@wso2.comint
>>
>
>
>
> --
> Ramith Jayasinghe
> Technical Lead
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> E: ram...@wso2.com
> P: +94 777542851
>
>


-- 
With regards,
*Manu*ranga Perera.

phone : 071 7 70 20 50
mail : m...@wso2.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Please review and merge

2015-06-26 Thread Kathees Rajendram
4 methods are failing and 6 methods are skipped out of 25.

On Fri, Jun 26, 2015 at 6:21 PM, Malaka Silva  wrote:

> How many methods are there in the connector and how many are failing?
>
> On Fri, Jun 26, 2015 at 6:14 PM, Kathees Rajendram 
> wrote:
>
>> Hi Malaka,
>>
>> Please review and merge the PR[1] for Disqus.Some methods are failing
>> because of *"This method is currently under development*" in API [2].
>>
>> [1] - https://github.com/wso2/esb-connectors/pull/208
>> [2] - https://disqus.com/api/docs/threads/create/
>>
>> Thanks,
>> Kathees
>>
>> --
>> Kathees
>> Software Engineer,
>> email: kath...@wso2.com
>> mobile: +94772596173
>>
>
>
>
> --
>
> Best Regards,
>
> Malaka Silva
> Senior Tech Lead
> M: +94 777 219 791
> Tel : 94 11 214 5345
> Fax :94 11 2145300
> Skype : malaka.sampath.silva
> LinkedIn : http://www.linkedin.com/pub/malaka-silva/6/33/77
> Blog : http://mrmalakasilva.blogspot.com/
>
> WSO2, Inc.
> lean . enterprise . middleware
> http://www.wso2.com/
> http://www.wso2.com/about/team/malaka-silva/
> 
>
> Save a tree -Conserve nature & Save the world for your future. Print this
> email only if it is absolutely necessary.
>



-- 
Kathees
Software Engineer,
email: kath...@wso2.com
mobile: +94772596173
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [AS]

2015-06-26 Thread Sabra Ossen
Hi,

@Chathura, I am using oracle JDK 7 in Ubuntu 14.04.

@Manoj, Thank you for the samples. But this particular example does not
work in the AS 5.3.0 as well as 5.2.1. The built in samples work well in
both versions of the AS.

Regards.

On Fri, Jun 26, 2015 at 4:57 PM, Chathura Priyankara 
wrote:

> Hi Sabra,
>
> I was able to run the same sample successfully in AS 5.3.0 running on
> Ubuntu machine. I'm using JDK 7.
> Could you please mention the JDK version and OS that you are using ?
>
> Regards,
> Chathura.
>
> On Fri, Jun 26, 2015 at 3:55 PM, Sabra Ossen  wrote:
>
>> Hi,
>>
>> @Thusitha , there are no extra jars in the web app and also is there is
>> method to check out the actual web socket that gets deployed in the AS.
>>
>> @Kasun, the name of the web app is the same "TestWebApp" and I checked
>> the behavior in chrome which displays the following error in the console
>>
>>
>> *Failed to load resource: the server responded with a status of 405
>> (Method Not Allowed)WebSocket connection to
>> 'ws://10.224.29.52:9763/TestWebApp/echo
>> ' failed: Error during WebSocket
>> handshake: Unexpected response code: 404*
>>
>> Regards.
>>
>> On Thu, Jun 25, 2015 at 6:55 PM, KasunG Gajasinghe 
>> wrote:
>>
>>> Hi,
>>>
>>> What's the war name of your webapp? AS do not process the path parameter
>>> in context.xml currently. Rather, it uses the war name as the context.
>>>
>>> Also, you might want to run the same in Chome and verify the behavior.
>>> In some of the Firefox versions, you need to use MozWebSocket object
>>> instead of WebSocket object. See [1].
>>>
>>> [1]
>>> https://github.com/wso2/product-as/blob/master/modules/samples/example/src/main/resources/websocket/chat.xhtml#L55
>>>
>>> On Thu, Jun 25, 2015 at 5:38 PM, Thusitha Thilina Dayaratne <
>>> thusit...@wso2.com> wrote:
>>>
 Hi Sabra,

 AFAIK you don't have to do any extra configurations to make websocket
 works with AS. This kind of issues may pop out when webapp contains
 websoket jars inside the webapp itself (WEB-INF/lib).
 IF not most probably there is some mismatch in the actual websocket
 that get deployed and what you are trying to connect.

 Thanks

 On Thu, Jun 25, 2015 at 5:08 PM, Sabra Ossen 
 wrote:

> Hi Thusitha,
>
> The context path is as follows (present in context.xml),  * antiJARLocking="true" path="/TestWebApp"/>*
>
> and the error code is 404 stating that the html file "echo" was not
> found.
>
> Thanks.
>
> On Thu, Jun 25, 2015 at 4:43 PM, Thusitha Thilina Dayaratne <
> thusit...@wso2.com> wrote:
>
>> Hi Sabra,
>>
>> Did you check the Context path is correct? Also can you check what is
>> the error code that you get?
>> Thanks
>>
>> On Thu, Jun 25, 2015 at 4:28 PM, Sabra Ossen 
>> wrote:
>>
>>> Hi,
>>>
>>> I am following the blog mentioned in [1] and I can successfully run
>>> the Web App in the local tomcat server, when I run the following code in
>>> the WSO2 AS 5.3.0 alpha the browser returns the following error in the
>>> browser console.
>>>
>>> *Firefox can't establish a connection to the server at
>>> ws://10.225.125.91:9763/TestWebApp/echo
>>> .*
>>>
>>> Server code;
>>>
>>> import java.io.IOException;
>>>  import javax.websocket.OnClose;import javax.websocket.OnMessage;import 
>>> javax.websocket.OnOpen;import javax.websocket.Session;import 
>>> javax.websocket.server.ServerEndpoint;
>>>
>>> @ServerEndpoint("/echo") public class EchoServer {
>>>
>>> @OnOpen
>>> public void onOpen(Session session){
>>> System.out.println(session.getId() + " has opened a 
>>> connection");
>>> try {
>>> session.getBasicRemote().sendText("Connection Established");
>>> } catch (IOException ex) {
>>> ex.printStackTrace();
>>> }
>>> }
>>>
>>> @OnMessage
>>> public void onMessage(String message, Session session){
>>> System.out.println("Message from " + session.getId() + ": " + 
>>> message);
>>> try {
>>> session.getBasicRemote().sendText(message);
>>> } catch (IOException ex) {
>>> ex.printStackTrace();
>>> }
>>> }
>>>
>>> @OnClose
>>> public void onClose(Session session){
>>> System.out.println("Session " +session.getId()+" has ended");
>>> }}
>>>
>>>
>>> index.html;
>>>
>>> 
>>>
>>> 
>>> 
>>> Echo Chamber
>>> 
>>> 
>>> 
>>> 
>>>
>>> 
>>> 
>>> 
>>> 
>>> Open>> button>
>>> Send
>>> Close>

Re: [Dev] Please review and merge

2015-06-26 Thread Malaka Silva
We need to note this down and mark the status as working with esb latest
version.

On Fri, Jun 26, 2015 at 7:53 PM, Kathees Rajendram  wrote:

> 4 methods are failing and 6 methods are skipped out of 25.
>
> On Fri, Jun 26, 2015 at 6:21 PM, Malaka Silva  wrote:
>
>> How many methods are there in the connector and how many are failing?
>>
>> On Fri, Jun 26, 2015 at 6:14 PM, Kathees Rajendram 
>> wrote:
>>
>>> Hi Malaka,
>>>
>>> Please review and merge the PR[1] for Disqus.Some methods are failing
>>> because of *"This method is currently under development*" in API [2].
>>>
>>> [1] - https://github.com/wso2/esb-connectors/pull/208
>>> [2] - https://disqus.com/api/docs/threads/create/
>>>
>>> Thanks,
>>> Kathees
>>>
>>> --
>>> Kathees
>>> Software Engineer,
>>> email: kath...@wso2.com
>>> mobile: +94772596173
>>>
>>
>>
>>
>> --
>>
>> Best Regards,
>>
>> Malaka Silva
>> Senior Tech Lead
>> M: +94 777 219 791
>> Tel : 94 11 214 5345
>> Fax :94 11 2145300
>> Skype : malaka.sampath.silva
>> LinkedIn : http://www.linkedin.com/pub/malaka-silva/6/33/77
>> Blog : http://mrmalakasilva.blogspot.com/
>>
>> WSO2, Inc.
>> lean . enterprise . middleware
>> http://www.wso2.com/
>> http://www.wso2.com/about/team/malaka-silva/
>> 
>>
>> Save a tree -Conserve nature & Save the world for your future. Print this
>> email only if it is absolutely necessary.
>>
>
>
>
> --
> Kathees
> Software Engineer,
> email: kath...@wso2.com
> mobile: +94772596173
>



-- 

Best Regards,

Malaka Silva
Senior Tech Lead
M: +94 777 219 791
Tel : 94 11 214 5345
Fax :94 11 2145300
Skype : malaka.sampath.silva
LinkedIn : http://www.linkedin.com/pub/malaka-silva/6/33/77
Blog : http://mrmalakasilva.blogspot.com/

WSO2, Inc.
lean . enterprise . middleware
http://www.wso2.com/
http://www.wso2.com/about/team/malaka-silva/


Save a tree -Conserve nature & Save the world for your future. Print this
email only if it is absolutely necessary.
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [AS]

2015-06-26 Thread Thusitha Thilina Dayaratne
Hi Sabra,

Since you are using JSR 356 based implementation it is not working on the
AS 5.2.1. Because AS 5.2.1 only supports tomcat based websocket
implementation. But sample should be worked on AS 5.3.0-Alpha. Are you
building this using a maven project? If so share the pom.

Thanks

On Fri, Jun 26, 2015 at 8:32 PM, Sabra Ossen  wrote:

> Hi,
>
> @Chathura, I am using oracle JDK 7 in Ubuntu 14.04.
>
> @Manoj, Thank you for the samples. But this particular example does not
> work in the AS 5.3.0 as well as 5.2.1. The built in samples work well in
> both versions of the AS.
>
> Regards.
>
> On Fri, Jun 26, 2015 at 4:57 PM, Chathura Priyankara 
> wrote:
>
>> Hi Sabra,
>>
>> I was able to run the same sample successfully in AS 5.3.0 running on
>> Ubuntu machine. I'm using JDK 7.
>> Could you please mention the JDK version and OS that you are using ?
>>
>> Regards,
>> Chathura.
>>
>> On Fri, Jun 26, 2015 at 3:55 PM, Sabra Ossen  wrote:
>>
>>> Hi,
>>>
>>> @Thusitha , there are no extra jars in the web app and also is there is
>>> method to check out the actual web socket that gets deployed in the AS.
>>>
>>> @Kasun, the name of the web app is the same "TestWebApp" and I checked
>>> the behavior in chrome which displays the following error in the console
>>>
>>>
>>> *Failed to load resource: the server responded with a status of 405
>>> (Method Not Allowed)WebSocket connection to
>>> 'ws://10.224.29.52:9763/TestWebApp/echo
>>> ' failed: Error during WebSocket
>>> handshake: Unexpected response code: 404*
>>>
>>> Regards.
>>>
>>> On Thu, Jun 25, 2015 at 6:55 PM, KasunG Gajasinghe 
>>> wrote:
>>>
 Hi,

 What's the war name of your webapp? AS do not process the path
 parameter in context.xml currently. Rather, it uses the war name as the
 context.

 Also, you might want to run the same in Chome and verify the behavior.
 In some of the Firefox versions, you need to use MozWebSocket object
 instead of WebSocket object. See [1].

 [1]
 https://github.com/wso2/product-as/blob/master/modules/samples/example/src/main/resources/websocket/chat.xhtml#L55

 On Thu, Jun 25, 2015 at 5:38 PM, Thusitha Thilina Dayaratne <
 thusit...@wso2.com> wrote:

> Hi Sabra,
>
> AFAIK you don't have to do any extra configurations to make websocket
> works with AS. This kind of issues may pop out when webapp contains
> websoket jars inside the webapp itself (WEB-INF/lib).
> IF not most probably there is some mismatch in the actual websocket
> that get deployed and what you are trying to connect.
>
> Thanks
>
> On Thu, Jun 25, 2015 at 5:08 PM, Sabra Ossen 
> wrote:
>
>> Hi Thusitha,
>>
>> The context path is as follows (present in context.xml),  *> antiJARLocking="true" path="/TestWebApp"/>*
>>
>> and the error code is 404 stating that the html file "echo" was not
>> found.
>>
>> Thanks.
>>
>> On Thu, Jun 25, 2015 at 4:43 PM, Thusitha Thilina Dayaratne <
>> thusit...@wso2.com> wrote:
>>
>>> Hi Sabra,
>>>
>>> Did you check the Context path is correct? Also can you check what
>>> is the error code that you get?
>>> Thanks
>>>
>>> On Thu, Jun 25, 2015 at 4:28 PM, Sabra Ossen 
>>> wrote:
>>>
 Hi,

 I am following the blog mentioned in [1] and I can successfully run
 the Web App in the local tomcat server, when I run the following code 
 in
 the WSO2 AS 5.3.0 alpha the browser returns the following error in the
 browser console.

 *Firefox can't establish a connection to the server at
 ws://10.225.125.91:9763/TestWebApp/echo
 .*

 Server code;

 import java.io.IOException;
  import javax.websocket.OnClose;import 
 javax.websocket.OnMessage;import javax.websocket.OnOpen;import 
 javax.websocket.Session;import javax.websocket.server.ServerEndpoint;

 @ServerEndpoint("/echo") public class EchoServer {

 @OnOpen
 public void onOpen(Session session){
 System.out.println(session.getId() + " has opened a 
 connection");
 try {
 session.getBasicRemote().sendText("Connection 
 Established");
 } catch (IOException ex) {
 ex.printStackTrace();
 }
 }

 @OnMessage
 public void onMessage(String message, Session session){
 System.out.println("Message from " + session.getId() + ": " + 
 message);
 try {
 session.getBasicRemote().sendText(message);
 } catch (IOException ex) {
 ex.printStackTrace();
 }
 }
>

[Dev] WSO2 ML 1.0.0 Beta-2 Released

2015-06-26 Thread CD Athuraliya
WSO2 ML 1.0.0 Beta-2 Released!

WSO2 ML team is pleased to announce the Beta-2 release of WSO2 ML 1.0.0.
The distribution is available at [1] and ML P2 repository at [2]. This
release includes following bug fixes and improvements.

Bug

   - [ML-77 ] - Generated model's
   weight vector should be verified for not null and not infinite
   - [ML-78 ] - Canceling a new model
   created by existing analysis deletes the analysis
   - [ML-80 ] - New feature indices
   should be available via the built model
   - [ML-82 ] - Feature Importance
   graph doesn't show all features sometimes
   - [ML-85 ] - rename BAM option ->
   DAS in dataset upload feature
   - [ML-89 ] - Predict Mediator 'Help'
   page is missing
   - [ML-90 ] - [Mediator] Namespaces
   doesn't get appear in namespace editor
   - [ML-91 ] - [Mediator] WARN -
   MLIOFactory Failed to load/instantiate the class: null getting printed due
   to improper usage of MLIOFactory
   - [ML-92 ] - [Mediator] Updated
   feature xpath expressions are not getting updated
   - [ML-96 ] - Bundle predict mediator
   feature to p2-repo
   - [ML-97 ] - Cluster diagram doesn't
   work in DAS case.

Improvement

   - [ML-75 ] - Add favicon to ML UI
   - [ML-76 ] - Models of an analysis
   page should be in reverse chronological order
   - [ML-79 ] - [UI] Upload data points
   for prediction using a file
   - [ML-81 ] - [UI] Sanitize
   dynamically generated content using an encoding function
   - [ML-83 ] - In DAS case, we have to
   extract feature names from the table schema
   - [ML-84 ] - Refactor input and
   output adapters to work with String paths instead of URIs
   - [ML-86 ] - Styles for ML Carbon
   console
   - [ML-87 ] - Make default folder
   configurations OS independent
   - [ML-88 ] - Create a Spark Commons
   feature and use it from ML and DAS
   - [ML-93 ] - [DAS] API to retrieve
   all table names of a tenant
   - [ML-94 ] - Confusion matrix for
   multiclass classification models
   - [ML-99 ] - List DAS tables to
   select a particular table when creating dataset from DAS

Task

   - [ML-95 ] - Get all carbon kernel
   patches to ML
   - [ML-98 ] - Enable UI tests for
   Jenkins



The documentation for ML 1.0.0 Beta-2 can be found at [3]. Please report
any issues you may find in our JIRA [4].

[1]
https://github.com/wso2/product-ml/releases/download/1.0.0-beta2/wso2ml-1.0.0-SNAPSHOT.zip
[2]
https://github.com/wso2/product-ml/releases/download/1.0.0-beta2/p2-repo.zip
[3] https://docs.wso2.com/display/ML100/WSO2+Machine+Learner+Documentation
[4] https://wso2.org/jira/browse/ML

- WSO2 ML Team -

-- 
*CD Athuraliya*
Software Engineer
WSO2, Inc.
lean . enterprise . middleware
Mobile: +94 716288847 <94716288847>
LinkedIn  | Twitter
 | Blog 
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Please review and merge

2015-06-26 Thread Kathees Rajendram
Ok Malaka, I marked the status as working with ESB latest version.

On Fri, Jun 26, 2015 at 9:07 PM, Malaka Silva  wrote:

> We need to note this down and mark the status as working with esb latest
> version.
>
> On Fri, Jun 26, 2015 at 7:53 PM, Kathees Rajendram 
> wrote:
>
>> 4 methods are failing and 6 methods are skipped out of 25.
>>
>> On Fri, Jun 26, 2015 at 6:21 PM, Malaka Silva  wrote:
>>
>>> How many methods are there in the connector and how many are failing?
>>>
>>> On Fri, Jun 26, 2015 at 6:14 PM, Kathees Rajendram 
>>> wrote:
>>>
 Hi Malaka,

 Please review and merge the PR[1] for Disqus.Some methods are failing
 because of *"This method is currently under development*" in API [2].

 [1] - https://github.com/wso2/esb-connectors/pull/208
 [2] - https://disqus.com/api/docs/threads/create/

 Thanks,
 Kathees

 --
 Kathees
 Software Engineer,
 email: kath...@wso2.com
 mobile: +94772596173

>>>
>>>
>>>
>>> --
>>>
>>> Best Regards,
>>>
>>> Malaka Silva
>>> Senior Tech Lead
>>> M: +94 777 219 791
>>> Tel : 94 11 214 5345
>>> Fax :94 11 2145300
>>> Skype : malaka.sampath.silva
>>> LinkedIn : http://www.linkedin.com/pub/malaka-silva/6/33/77
>>> Blog : http://mrmalakasilva.blogspot.com/
>>>
>>> WSO2, Inc.
>>> lean . enterprise . middleware
>>> http://www.wso2.com/
>>> http://www.wso2.com/about/team/malaka-silva/
>>> 
>>>
>>> Save a tree -Conserve nature & Save the world for your future. Print
>>> this email only if it is absolutely necessary.
>>>
>>
>>
>>
>> --
>> Kathees
>> Software Engineer,
>> email: kath...@wso2.com
>> mobile: +94772596173
>>
>
>
>
> --
>
> Best Regards,
>
> Malaka Silva
> Senior Tech Lead
> M: +94 777 219 791
> Tel : 94 11 214 5345
> Fax :94 11 2145300
> Skype : malaka.sampath.silva
> LinkedIn : http://www.linkedin.com/pub/malaka-silva/6/33/77
> Blog : http://mrmalakasilva.blogspot.com/
>
> WSO2, Inc.
> lean . enterprise . middleware
> http://www.wso2.com/
> http://www.wso2.com/about/team/malaka-silva/
> 
>
> Save a tree -Conserve nature & Save the world for your future. Print this
> email only if it is absolutely necessary.
>



-- 
Kathees
Software Engineer,
email: kath...@wso2.com
mobile: +94772596173
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How OSGi Bundle Activation Policy Works in Runtime

2015-06-26 Thread Kishanthan Thangarajah
Hi Nuwan,

According to the spec, If the bundle activation policy is lazy, then its
state will be in "STARTING" once it passed the "RESOLVED" stage without
encountering any issues. The state remains as "STARTING" until there is an
event to load class from the this bundle space. Then only the state changes
to "ACTIVE" once it has properly finished calling the bundle activator.
This is known as the "On-Demand" activation.

So to answer your question, the first bundle's state will remain in
"STARTING", until the second bundle calls/uses a class from it. This call
will trigger the even to start the BundleActivator. Then the state will
change to "ACTIVE" once BundleActivator's start method returns without any
issues.

BTW, we do not have this policy set for carbon related bundles (mostly).
Are you working on dev-studio/eclipse project related bundles to observe
this behaviour?

Thanks,

On Fri, Jun 26, 2015 at 4:59 PM, Nuwan Pallewela  wrote:

> If a plug-in's Bundle Activation Policy is configured as "lazy", will
> another plug-in which depends on it can use it if the current state of the
> first plug-in is in RESOLVED state? Will it come to ACTIVE state because of
> the second plug-In's invocation?
>
> --
> --
>
> *Nuwan Chamara Pallewela*
>
>
> *Software Engineer*
>
> *WSO2, Inc. *
> *lean . enterprise . middleware*
>
> Email   *nuw...@wso2.com *
> Mobile  *+94719079739 <%2B94719079739>*
> *+94767100087 <%2B94767100087>*
>
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Kishanthan Thangarajah*
Associate Technical Lead,
Platform Technologies Team,
WSO2, Inc.
lean.enterprise.middleware

Mobile - +94773426635
Blog - *http://kishanthan.wordpress.com *
Twitter - *http://twitter.com/kishanthan *
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev