Re: [Dev] [ESB 490] Create empty named json array inside an xslt
Hi Senduran, Thanks, That worked. We are generating it inside a xslt where we can not use payloadFactory. On Wed, Oct 5, 2016 at 12:24 PM, Rajith Vitharana <raji...@wso2.com> wrote: > Hi Udara, > > Try using the config senduran mentioned inside a payloadfactory mediator. > Sample would be as below. > > > > > > sample1 > test > sample2 > > > > > > Thanks, > > > > On 5 October 2016 at 12:18, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi Senduran, >> >> I need to create json array within synapse configs coz backend expects an >> array >> >> On Wed, Oct 5, 2016 at 8:11 AM, Senduran Balasubramaniyam < >> sendu...@wso2.com> wrote: >> >>> Hi Udara, >>> >>> I tried the following API and the request, (I am using ESB 500) >>> API: >>> >>> >>> http://ws.apache.org/ns/synapse; >>> name="XMLtoJSON" >>> context="/XMLtoJSON"> >>> >>> >>> >> scope="axis2"/> >>> >>> >>> >>> >>> >>> >>> Request: >>> >>> curl -v -d '' >>> http://localhost:8280/XMLtoJSON -H "Content-type: application/xml" >>> >>> Regards >>> Senduran >>> >>> >>> On Tue, Oct 4, 2016 at 6:36 PM, Udara Liyanage <ud...@wso2.com> wrote: >>> >>>> Hi Senduran, >>>> >>>> Below is xslt snippet I tried. >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> On Tue, Oct 4, 2016 at 6:26 PM, Udara Liyanage <ud...@wso2.com> wrote: >>>> >>>>> Hi Senduran, >>>>> >>>>> That I tried already. But it produced >>>>> >>>>> {"root":null} >>>>> >>>>> On Tue, Oct 4, 2016 at 5:37 PM, Senduran Balasubramaniyam < >>>>> sendu...@wso2.com> wrote: >>>>> >>>>>> Hi Udara, >>>>>> >>>>>> You can get an empty addresses array by following: >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> Regards >>>>>> Senduran >>>>>> >>>>>> On Tue, Oct 4, 2016 at 12:09 PM, Udara Liyanage <ud...@wso2.com> >>>>>> wrote: >>>>>> >>>>>>> Hi, >>>>>>> >>>>>>> I want to generate an empty json array ("addresses":[]) when >>>>>>> addresses count is zero. I tried below as [1] which resulted only in >>>>>>> null. >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> [1] https://docs.wso2.com/display/ESB500/JSON+Support >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> >>>>>>> Udara Liyanage >>>>>>> Software Engineer >>>>>>> WSO2, Inc.: http://wso2.com >>>>>>> lean. enterprise. middleware >>>>>>> >>>>>>> Blog: http://udaraliyanage.wordpress.com >>>>>>> >>>>>>> ___ >>>>>>> Dev mailing list >>>>>>> Dev@wso2.org >>>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>>>>> >>>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> *Senduran * >>>>>> Senior Software Engineer, >>>>>> WSO2, Inc.; http://wso2.com/ <http://wso2.com/> >>>>>> Mobile: +94 77 952 6548 >>>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> >>>>> Udara Liyanage >>>>> Software Engineer >>>>> WSO2, Inc.: http://wso2.com >>>>> lean. enterprise. middleware >>>>> >>>>> Blog: http://udaraliyanage.wordpress.com >>>>> >>>> >>>> >>>> >>>> -- >>>> >>>> Udara Liyanage >>>> Software Engineer >>>> WSO2, Inc.: http://wso2.com >>>> lean. enterprise. middleware >>>> >>>> Blog: http://udaraliyanage.wordpress.com >>>> >>> >>> >>> >>> -- >>> *Senduran * >>> Senior Software Engineer, >>> WSO2, Inc.; http://wso2.com/ <http://wso2.com/> >>> Mobile: +94 77 952 6548 >>> >> >> >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> Blog: http://udaraliyanage.wordpress.com >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > Rajith Vitharana > > Senior Software Engineer, > WSO2 Inc. : wso2.com > Mobile : +94715883223 > Blog : http://lankavitharana.blogspot.com/ > <http://wso2.com/signature> > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [ESB 490] Create empty named json array inside an xslt
Hi Senduran, I need to create json array within synapse configs coz backend expects an array On Wed, Oct 5, 2016 at 8:11 AM, Senduran Balasubramaniyam <sendu...@wso2.com > wrote: > Hi Udara, > > I tried the following API and the request, (I am using ESB 500) > API: > > > http://ws.apache.org/ns/synapse; > name="XMLtoJSON" > context="/XMLtoJSON"> > > > scope="axis2"/> > > > > > > > Request: > > curl -v -d '' > http://localhost:8280/XMLtoJSON -H "Content-type: application/xml" > > Regards > Senduran > > > On Tue, Oct 4, 2016 at 6:36 PM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi Senduran, >> >> Below is xslt snippet I tried. >> >> >> >> >> >> >> >> >> On Tue, Oct 4, 2016 at 6:26 PM, Udara Liyanage <ud...@wso2.com> wrote: >> >>> Hi Senduran, >>> >>> That I tried already. But it produced >>> >>> {"root":null} >>> >>> On Tue, Oct 4, 2016 at 5:37 PM, Senduran Balasubramaniyam < >>> sendu...@wso2.com> wrote: >>> >>>> Hi Udara, >>>> >>>> You can get an empty addresses array by following: >>>> >>>> >>>> >>>> >>>> >>>> Regards >>>> Senduran >>>> >>>> On Tue, Oct 4, 2016 at 12:09 PM, Udara Liyanage <ud...@wso2.com> wrote: >>>> >>>>> Hi, >>>>> >>>>> I want to generate an empty json array ("addresses":[]) when addresses >>>>> count is zero. I tried below as [1] which resulted only in null. >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> [1] https://docs.wso2.com/display/ESB500/JSON+Support >>>>> >>>>> >>>>> -- >>>>> >>>>> Udara Liyanage >>>>> Software Engineer >>>>> WSO2, Inc.: http://wso2.com >>>>> lean. enterprise. middleware >>>>> >>>>> Blog: http://udaraliyanage.wordpress.com >>>>> >>>>> ___ >>>>> Dev mailing list >>>>> Dev@wso2.org >>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>>> >>>>> >>>> >>>> >>>> -- >>>> *Senduran * >>>> Senior Software Engineer, >>>> WSO2, Inc.; http://wso2.com/ <http://wso2.com/> >>>> Mobile: +94 77 952 6548 >>>> >>> >>> >>> >>> -- >>> >>> Udara Liyanage >>> Software Engineer >>> WSO2, Inc.: http://wso2.com >>> lean. enterprise. middleware >>> >>> Blog: http://udaraliyanage.wordpress.com >>> >> >> >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> Blog: http://udaraliyanage.wordpress.com >> > > > > -- > *Senduran * > Senior Software Engineer, > WSO2, Inc.; http://wso2.com/ <http://wso2.com/> > Mobile: +94 77 952 6548 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [ESB 490] Create empty named json array inside an xslt
Hi Senduran, Below is xslt snippet I tried. On Tue, Oct 4, 2016 at 6:26 PM, Udara Liyanage <ud...@wso2.com> wrote: > Hi Senduran, > > That I tried already. But it produced > > {"root":null} > > On Tue, Oct 4, 2016 at 5:37 PM, Senduran Balasubramaniyam < > sendu...@wso2.com> wrote: > >> Hi Udara, >> >> You can get an empty addresses array by following: >> >> >> >> >> >> Regards >> Senduran >> >> On Tue, Oct 4, 2016 at 12:09 PM, Udara Liyanage <ud...@wso2.com> wrote: >> >>> Hi, >>> >>> I want to generate an empty json array ("addresses":[]) when addresses >>> count is zero. I tried below as [1] which resulted only in null. >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> [1] https://docs.wso2.com/display/ESB500/JSON+Support >>> >>> >>> -- >>> >>> Udara Liyanage >>> Software Engineer >>> WSO2, Inc.: http://wso2.com >>> lean. enterprise. middleware >>> >>> Blog: http://udaraliyanage.wordpress.com >>> >>> ___ >>> Dev mailing list >>> Dev@wso2.org >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> *Senduran * >> Senior Software Engineer, >> WSO2, Inc.; http://wso2.com/ <http://wso2.com/> >> Mobile: +94 77 952 6548 >> > > > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > Blog: http://udaraliyanage.wordpress.com > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [ESB 490] Create empty named json array inside an xslt
Hi Senduran, That I tried already. But it produced {"root":null} On Tue, Oct 4, 2016 at 5:37 PM, Senduran Balasubramaniyam <sendu...@wso2.com > wrote: > Hi Udara, > > You can get an empty addresses array by following: > > > > > > Regards > Senduran > > On Tue, Oct 4, 2016 at 12:09 PM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> I want to generate an empty json array ("addresses":[]) when addresses >> count is zero. I tried below as [1] which resulted only in null. >> >> >> >> >> >> >> >> >> >> [1] https://docs.wso2.com/display/ESB500/JSON+Support >> >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> Blog: http://udaraliyanage.wordpress.com >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > *Senduran * > Senior Software Engineer, > WSO2, Inc.; http://wso2.com/ <http://wso2.com/> > Mobile: +94 77 952 6548 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [ESB 490] Create empty named json array inside an xslt
Hi, I want to generate an empty json array ("addresses":[]) when addresses count is zero. I tried below as [1] which resulted only in null. [1] https://docs.wso2.com/display/ESB500/JSON+Support -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] Clarification on content aware logic in log mediator
Hi ESB team, Below is isContentAware() method for LogMediator. According to that any log which does not have log level custom becomes content aware. public boolean isContentAware() { if (logLevel == CUSTOM) { for (MediatorProperty property : properties) { if (property.getExpression() != null && property.getExpression().isContentAware()) { return true; } } return false; } return true; } If so below log will also become content aware. IMO this is not a content aware log, is it? -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [ESB] Invoke fault sequence for http fault scenarios
Hi, ESB invokes fault sequence when error occurred in mediation flow. In addition we can configure error codes on which an endpoint to be invoked fault sequence [1]. However can I configure ESB to invoke fault sequence for http error codes such as 403, 401 etc? I can have a filter for http_sc and check it after call mediator. However in a service chaining with multiple endpoints, we will have to do that check after every call. [1] https://docs.wso2.com/display/ESB481/Error+Handling -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [Mesos artifacts] Use Docker --dns and --dns-search for hostname DNS resolution
Hi, Container to contianer communication can be done by this as long as we run a dns server. However when users/browser wants to access a service running on a container (say ESB maagement console) don't they have to come via marathon lb? Or else do the they have to add our dns server to their resolve.conf ? How about load balancing features such as sticky sessions and round robbing load balancing. Round robbing load balancing can be done using DNS server itself, but not sure about sticky session. On Tue, Aug 23, 2016 at 10:07 AM, Akila Ravihansa Perera <raviha...@wso2.com > wrote: > Hi, > > Currently we are using Marathon-LB hostname and service ports in product > configuration when deploying on DC/OS (Apache Mesos). We can set the > --dns-search and --dns properties and set a DOMAIN and DNS server in > /etc/resolve.conf to resolve hostnames which are not found in /etc/hosts > [1]. > > This is a much cleaner approach than using Marathon-LB hostname and > service ports. WDYT? > > > [1] https://docs.docker.com/v1.7/articles/networking/#dns > > Thanks. > > -- > Akila Ravihansa Perera > WSO2 Inc.; http://wso2.com/ > > Blog: http://ravihansa3000.blogspot.com > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [ESB 490] RelayUtils Error while building Passthrough stream in call mediator
Hi Nadeeshan, Yes, charset was null when I debug. ESB does not even sends the request I guess. It may be previous call did not respond with charset. On Tue, Aug 16, 2016 at 2:14 PM, Nadeeshaan Gunasinghe <nadeesh...@wso2.com> wrote: > Hi Udara, > > According to the following snippet it seems like that the charsetEncoding > hasn't been set to the message context. This could be either the response > does not send the charset encoding or due to some configuration. > > extractParametersFromRequest(parameterMap, query, queryParameterSeparator, > (String) messageContext.getProperty( > > Constants.Configuration.CHARACTER_SET_ENCODING), > inputStream); > > Thanks, > > *Nadeeshaan Gunasinghe* > Software Engineer, WSO2 Inc. http://wso2.com > +94770596754 | nadeesh...@wso2.com | Skype: nadeeshaan.gunasinghe > <#m_191935483537751175_> > <http://www.facebook.com/nadeeshaan.gunasinghe> > <http://lk.linkedin.com/in/nadeeshaan> <http://twitter.com/Nadeeshaan> > <http://nadeeshaan.blogspot.com/> > Get a signature like this: Click here! > <http://ws-promos.appspot.com/r?rdata=eyJydXJsIjogImh0dHA6Ly93d3cud2lzZXN0YW1wLmNvbS9lbWFpbC1pbnN0YWxsP3dzX25jaWQ9NjcyMjk0MDA4JnV0bV9zb3VyY2U9ZXh0ZW5zaW9uJnV0bV9tZWRpdW09ZW1haWwmdXRtX2NhbXBhaWduPXByb21vXzU3MzI1Njg1NDg3Njk3OTIiLCAiZSI6ICI1NzMyNTY4NTQ4NzY5NzkyIn0==614103463781132> > > On Wed, Aug 3, 2016 at 5:37 PM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> I get the following exception in ESB for following call mediator. There >> are some other previous call mediators which are successful and we can see >> the request/responses in wire log. But for this there is no wire logs that >> shows weather ESB sends the requests out. Please note that this is >> intermittent. >> >> What could cause the following exception. >> >> >> >> >> >> [2016-08-03 16:57:30,597] ERROR - RelayUtils Error while building >> Passthrough stream >> java.lang.NullPointerException: charsetName >> at java.io.InputStreamReader.(InputStreamReader.java:99) >> at org.apache.synapse.commons.builders.XFormURLEncodedBuilder$ >> 1.run(XFormURLEncodedBuilder.java:206) >> at org.apache.axis2.java.security.AccessController.doPrivileged >> (AccessController.java:132) >> at org.apache.synapse.commons.builders.XFormURLEncodedBuilder.e >> xtractParametersFromRequest(XFormURLEncodedBuilder.java:203) >> at org.apache.synapse.commons.builders.XFormURLEncodedBuilder.p >> rocessDocumentWrapper(XFormURLEncodedBuilder.java:128) >> at org.apache.synapse.commons.builders.XFormURLEncodedBuilder.p >> rocessDocument(XFormURLEncodedBuilder.java:52) >> at org.apache.synapse.transport.passthru.util.DeferredMessageBu >> ilder.getDocument(DeferredMessageBuilder.java:138) >> at org.apache.synapse.transport.passthru.util.RelayUtils.builld >> Message(RelayUtils.java:133) >> at org.apache.synapse.transport.passthru.util.RelayUtils.buildM >> essage(RelayUtils.java:98) >> at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.buildM >> essage(Axis2SynapseEnvironment.java:716) >> at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.send(A >> xis2SynapseEnvironment.java:459) >> at org.apache.synapse.endpoints.AbstractEndpoint.send(AbstractE >> ndpoint.java:372) >> at org.apache.synapse.endpoints.HTTPEndpoint.send(HTTPEndpoint. >> java:89) >> at org.apache.synapse.endpoints.IndirectEndpoint.send(IndirectE >> ndpoint.java:55) >> at org.apache.synapse.mediators.builtin.CallMediator.handleNonB >> lockingCall(CallMediator.java:204) >> at org.apache.synapse.mediators.builtin.CallMediator.mediate(Ca >> llMediator.java:87) >> at org.apache.synapse.mediators.AbstractListMediator.mediate(Ab >> stractListMediator.java:81) >> at org.apache.synapse.mediators.AbstractListMediator.mediate(Ab >> stractListMediator.java:48) >> at org.apache.synapse.mediators.filters.FilterMediator.mediate( >> FilterMediator.java:160) >> at org.apache.synapse.mediators.AbstractListMediator.mediate(Ab >> stractListMediator.java:81) >> at org.apache.synapse.mediators.AbstractListMediator.mediate(Ab >> stractListMediator.java:48) >> at org.apache.synapse.mediators.base.SequenceMediator.mediate(S >> equenceMediator.java:149) >> at org.apache.synapse.mediators.base.SequenceMediator.mediate(S >> equenceMediator.java:214) >> at org.apache.synapse.me
Re: [Dev] [ESB] fn:sum is not working
Hi Godwin, As a workaround following worked for me. I had to use parseInt, just using + did not work for me. <![CDATA[ var sum = parseInt(mc.getProperty("num1")) +parseInt(mc.getProperty("num2")); var sum = mc.setProperty("testValue",sum.toString()); ]]> On Sat, Aug 6, 2016 at 12:44 AM, Godwin Shrimal <god...@wso2.com> wrote: > Hi All, > > I have following sample config to sum two values > > > > http://www.w3.org/2005/xpath-functions; xmlns:test=" > http://test; xmlns:ns="http://org.apache.synapse/xsd; name="testValue" > expression="fn:sum($ctx:num1,$ctx:num2)"/> > > > > > > > Total gives as 10 not 30, Is this a known bug or am I doing something > wrong ? > > > Thanks > Godwin > > > -- > *Godwin Amila Shrimal* > Senior Software Engineer > WSO2 Inc.; http://wso2.com > lean.enterprise.middleware > > mobile: *+94772264165* > linkedin: *http://lnkd.in/KUum6D <http://lnkd.in/KUum6D>* > twitter: https://twitter.com/godwinamila > <http://wso2.com/signature> > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [ESB 490] RelayUtils Error while building Passthrough stream in call mediator
(AbstractListMediator.java:81) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:48) at org.apache.synapse.mediators.filters.FilterMediator.mediate(FilterMediator.java:160) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:81) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:48) at org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:149) at org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:214) at org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:81) at org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:261) at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.mediateFromContinuationStateStack(Axis2SynapseEnvironment.java:679) at org.apache.synapse.core.axis2.Axis2SynapseEnvironment.injectMessage(Axis2SynapseEnvironment.java:244) at org.apache.synapse.core.axis2.SynapseCallbackReceiver.handleMessage(SynapseCallbackReceiver.java:529) at org.apache.synapse.core.axis2.SynapseCallbackReceiver.receive(SynapseCallbackReceiver.java:172) at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180) at org.apache.synapse.transport.passthru.ClientWorker.run(ClientWorker.java:247) at org.apache.axis2.transport.base.threads.NativeWorkerPool$1.run(NativeWorkerPool.java:172) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.NullPointerException: charsetName at java.io.InputStreamReader.(InputStreamReader.java:99) at org.apache.synapse.commons.builders.XFormURLEncodedBuilder$1.run(XFormURLEncodedBuilder.java:206) at org.apache.axis2.java.security.AccessController.doPrivileged(AccessController.java:132) at org.apache.synapse.commons.builders.XFormURLEncodedBuilder.extractParametersFromRequest(XFormURLEncodedBuilder.java:203) at org.apache.synapse.commons.builders.XFormURLEncodedBuilder.processDocumentWrapper(XFormURLEncodedBuilder.java:128) at org.apache.synapse.commons.builders.XFormURLEncodedBuilder.processDocument(XFormURLEncodedBuilder.java:52) at org.apache.synapse.transport.passthru.util.DeferredMessageBuilder.getDocument(DeferredMessageBuilder.java:138) at org.apache.synapse.transport.passthru.util.RelayUtils.builldMessage(RelayUtils.java:133) ... 27 more [2016-08-03 16:57:30,623] WARN - EndpointContext Endpoint : GetAuthTokenEndpoint will be marked SUSPENDED as it failed [2016-08-03 16:57:30,623] WARN - EndpointContext Suspending endpoint : GetAuthTokenEndpoint - current suspend duration is : 3ms - Next retry after : Wed Aug 03 16:58:00 IST 2016 [2016-08-03 16:57:30,624] INFO - LogMediator To: https://identity-ampdevalpst.amp.endeavourdemo.com/oauth/token, WSAction: , SOAPAction: , MessageID: urn:uuid:9b0217e2-b782-4aa1-90ec-42d3f1b24194, Direction: request, MESSAGE = Executing default 'fault' sequence, ERROR_CODE = 0, ERROR_MESSAGE = Error while building message, HTTP_SC = null, Envelope: http://schemas.xmlsoap.org/soap/envelope/;>http://ws.apache.org/ns/synapse;>notusednam...@gmail.com testSignupUserAIMIAWORLDurn:endeavour:oauth2:grant_type:member_tokenEMAIL [2016-08-03 16:57:30,625] DEBUG - wire << "HTTP/1.1 200 OK[\r][\n]" [2016-08-03 16:57:30,625] DEBUG - wire << "Authorization: Basic bWVtYmVyd2ViOm1lbWJlcndlYg==[\r][\n]" [2016-08-03 16:57:30,625] DEBUG - wire << "Content-Type: application/x-www-form-urlencoded; charset=UTF-8[\r][\n]" [2016-08-03 16:57:30,625] DEBUG - wire << "Date: Wed, 03 Aug 2016 11:27:30 GMT[\r][\n]" [2016-08-03 16:57:30,625] DEBUG - wire << "Content-Length: 168[\r][\n]" -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] When to use NO_ENTITY_BODY
Hi, According to [1], NO_ENTITY_BODY property is set if the client want to get response with entities for requests which does not have an entity body such as GET and DELETE. 1) My first question according to [1] by default ESB will not send a response for requests without body. That is OK for DELETE, but how about GET. GET are supposed to get a response. 2) I have below api definition. with a simple GET which generates a simple response. I get a response for GET even I do or don't remove NO_ENTITY_BODY property. Behavior is same for DELETE too. http://ws.apache.org/ns/synapse; name="GetTickets" context="/tickets"> {"fname":"udara","lname":liyanage""} *Request and response* curl -X GET -H "Authorization: Token" "http://localhost:8280/tickets/; {"name":"udara","age":"10"} [1] https://docs.wso2.com/display/ESB403/HTTP+Transport+Specific+Properties -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] When ESB add "xformValues" to outgoing http url
Hi, I don't set any of the properties to x-www-form-urlencoded in my configs. However when I set messageType to application/json correct url is seen in outgoing message from ESB [2016-07-28 12:04:23,049] DEBUG - wire << "GET* /abc?abc=123* HTTP/1.1[\r][\n]" [2016-07-28 12:04:23,049] DEBUG - wire << "Authorization: Token[\r][\n]" [2016-07-28 12:04:23,049] DEBUG - wire << "Accept: */*[\r][\n]" [2016-07-28 12:04:23,049] DEBUG - wire << "Content-Type: application/json[\r][\n]" [2016-07-28 12:04:23,050] DEBUG - wire << "Host: localhost:[\r][\n]" [2016-07-28 12:04:23,050] DEBUG - wire << "Connection: Keep-Alive[\r][\n]" [2016-07-28 12:04:23,050] DEBUG - wire << "User-Agent: Synapse-PT-HttpComponents-NIO[\r][\n]" [2016-07-28 12:04:23,050] DEBUG - wire << "[\r][\n]" [2016-07-28 12:04:23,050] WARN - TargetHandler Connecti -- Forwarded message -- From: Udara Liyanage <ud...@wso2.com> Date: Thu, Jul 28, 2016 at 12:00 PM Subject: Re: What is this xformValues To: Vijitha Ekanayake <vijit...@wso2.com> Hi, Did you mean in transport receiver or in our configs?. we did n't set it in our configs. However when I set messageType and Content-Type to application/json it works as expected On Thu, Jul 28, 2016 at 11:48 AM, Vijitha Ekanayake <vijit...@wso2.com> wrote: > It seems you are having x-www-form-urlencoded Data to the backend. Check > whether below to properties has set in the somewhere in the InFlow of the > message. > > scope="axis2" type="STRING"/> > scope="axis2" type="STRING"/> > > > On Thu, Jul 28, 2016 at 11:26 AM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> What is this GET */xformValues in *ESB outgoing message >> >> Request >> curl -X POST -H "Authorization: Token" " >> http://ampdevcmsst-wso2api.amp.endeavourdemo.com:8280/users/; -v >> >> >> http://ws.apache.org/ns/synapse; name="localendpoint"> >>http://localhost:/abc?abc=123; method="get"> >> >> 1.0 >> >> >> 0 >> 0 >> >> >> >> >> [2016-07-28 11:21:30,680] DEBUG - wire >> "POST /users/ HTTP/1.1[\r][\n]" >> [2016-07-28 11:21:30,681] DEBUG - wire >> "Host: >> ampdevcmsst-wso2api.amp.endeavourdemo.com:8280[\r][\n]" >> [2016-07-28 11:21:30,681] DEBUG - wire >> "User-Agent: >> curl/7.43.0[\r][\n]" >> [2016-07-28 11:21:30,681] DEBUG - wire >> "Accept: */*[\r][\n]" >> [2016-07-28 11:21:30,681] DEBUG - wire >> "Authorization: Token[\r][\n]" >> [2016-07-28 11:21:30,681] DEBUG - wire >> "[\r][\n]" >> [2016-07-28 11:21:30,740] INFO - LogMediator To: /users/, MessageID: >> urn:uuid:380a10da-a751-4f0b-8397-203e7079525b, Direction: request, auth >> header2 = Token >> [2016-07-28 11:21:30,748] INFO - TimeoutHandler This engine will expire >> all callbacks after : 120 seconds, irrespective of the timeout action, >> after the specified or optional timeout >> [2016-07-28 11:21:30,770] DEBUG - wire << "GET */xformValues* >> HTTP/1.1[\r][\n]" >> [2016-07-28 11:21:30,770] DEBUG - wire << "Authorization: Token[\r][\n]" >> [2016-07-28 11:21:30,770] DEBUG - wire << "Accept: */*[\r][\n]" >> [2016-07-28 11:21:30,770] DEBUG - wire << "Host: localhost:[\r][\n]" >> [2016-07-28 11:21:30,770] DEBUG - wire << "Connection: Keep-Alive[\r][\n]" >> [2016-07-28 11:21:30,770] DEBUG - wire << "User-Agent: >> Synapse-PT-HttpComponents-NIO[\r][\n]" >> [2016-07-28 11:21:30,770] DEBUG - wire << "[\r][\n]" >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> Blog: http://udaraliyanage.wordpress.com >> > > > > -- > Vijitha Ekanayake > Software Engineer*, *WSO2, Inc.; http://wso2.com/ > Mobile : +94 777 24 73 39 | +94 718 74 44 08 > lean.enterprise.middleware > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [ESB] Enable debug logs for proxies and apis
Hi Elilmatha, 1) I want to enable it for every proxy and api, otherwise we have to add log4j configs every time we add a proxy and api which is not practical where there are 10+ proxies 2) Below is my api config and log4j config. Still debug logs are not printed. http://ws.apache.org/ns/synapse; name="*getUsers*" context="/users"> # Configure the service logger at INFO level. Writes only run-time/mediation-time audit messages log4j.category.SERVICE_LOGGER.*getUsers*=DEBUG, SERVICE_APPENDER log4j.additivity.SERVICE_LOGGER=false log4j.appender.SERVICE_APPENDER=org.apache.log4j.RollingFileAppender #log4j.appender.SERVICE_APPENDER.File=${carbon.home}/repository/logs/${instance.log}/wso2-esb-service${instance.log}.log log4j.appender.SERVICE_APPENDER.File=${carbon.home}/repository/logs/${instance.log}/wso2-esb- *get-users*${instance.log}.log log4j.appender.SERVICE_APPENDER.MaxFileSize=1000KB log4j.appender.SERVICE_APPENDER.MaxBackupIndex=10 log4j.appender.SERVICE_APPENDER.layout=org.apache.log4j.PatternLayout log4j.appender.SERVICE_APPENDER.layout.ConversionPattern=%d{ISO8601} [%X{ip}-%X{host}] [%t] %5p %c{1} %m%n On Tue, Jul 26, 2016 at 10:17 AM, Elilmatha Sivanesan <elilma...@wso2.com> wrote: > Hi Udara, > > Can you try by adding the following entries into your log4j.properties > file ,In this way, you might need to add separate blocks of configuration > for all configured proxies.(assumes a proxy service named TestProxy): > > log4j.category.SERVICE_LOGGER.TestProxy= > DEBUG,PROXY_APPENDERlog4j.additivity.PROXY_APPENDER=falselog4j.appender.PROXY_APPENDER=org.apache.log4j.DailyRollingFileAppenderlog4j.appender.PROXY_APPENDER.File=${carbon.home}/repository/logs/${instance.log}/wso2-esb-test-proxy${instance.log}.loglog4j.appender.PROXY_APPENDER.Append=truelog4j.appender.PROXY_APPENDER.layout=org.apache.log4j.PatternLayoutlog4j.appender.PROXY_APPENDER.layout.ConversionPattern=%d{HH:mm:ss,SSS} > [%X{ip}-%X{host}] [%t] %5p %c{1} %m% > > > Thanks > > On Tue, Jul 26, 2016 at 9:33 AM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> I want to set some logs to debug in log mediator. When I set log category >> to DEBUG and enable DEBUG in SERVICE_LOGGER, I don't see any logs in any of >> the file inside logs folder. How do we enable debug logs for APIs and >> proxies? >> >> >> >> >> >> >> >> >> log4j.category.SERVICE_LOGGER=*DEBUG*, SERVICE_APPENDER >> log4j.additivity.SERVICE_LOGGER=false >> log4j.appender.SERVICE_APPENDER=org.apache.log4j.RollingFileAppender >> >> log4j.appender.SERVICE_APPENDER.File=${carbon.home}/repository/logs/${instance.log}/wso2-esb-service${instance.log}.log >> >> log4j.appender.SERVICE_APPENDER.File=${carbon.home}/repository/logs/${instance.log}/wso2-esb-get-users${instance.log}.log >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> Blog: http://udaraliyanage.wordpress.com >> >> _______ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > *S.Elilmatha* > Software Engineer, > > WSO2 Inc.; http://wso2.com > lean.enterprise.middleware > > Mobile 0779842221. > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [ESB] Enable debug logs for proxies and apis
Hi, I want to set some logs to debug in log mediator. When I set log category to DEBUG and enable DEBUG in SERVICE_LOGGER, I don't see any logs in any of the file inside logs folder. How do we enable debug logs for APIs and proxies? log4j.category.SERVICE_LOGGER=*DEBUG*, SERVICE_APPENDER log4j.additivity.SERVICE_LOGGER=false log4j.appender.SERVICE_APPENDER=org.apache.log4j.RollingFileAppender log4j.appender.SERVICE_APPENDER.File=${carbon.home}/repository/logs/${instance.log}/wso2-esb-service${instance.log}.log log4j.appender.SERVICE_APPENDER.File=${carbon.home}/repository/logs/${instance.log}/wso2-esb-get-users${instance.log}.log -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Is it best practice to return null or an empty object from a method in DAO layer?
Hi, It is not performance that matters, using exceptions for flow control is an anti pattern [1] [2]. [1] http://c2.com/cgi/wiki?DontUseExceptionsForFlowControl [2] http://programmers.stackexchange.com/questions/189222/are-exceptions-as-control-flow-considered-a-serious-antipattern-if-so-why On Sun, Jul 17, 2016 at 10:46 PM, Rasika Perera <rasi...@wso2.com> wrote: > Hi All, > > >> Considering a method returning a user object the client code should not >> be able to proceed further if there is no user. > > This is the use case we need to achieve. How do we enforce clients to > *not* to proceed if the user is not found? I really do promote Design by > Contract <https://en.wikipedia.org/wiki/Design_by_contract>. NULL will > give over-flexibility here and it is not what we asked for either. > Further, it might caused redundant NULL checks and NPEs for FREE. > > Exceptions are meant to be used for exceptional cases, using them for flow >> control is a bad practice. So I don't think it is a good practice to throw >> Exceptions instead of returning null. In addition using exceptions is >> costly for performance. > > Yes, Exceptions might be costly if you used it in bad way. Why not for flow > control? If your code running happy path most of the times, returning > exception on a trap would not be that harmfull. Exceptions are much > similar to other objects except the native call fillInStackTrace > <http://docs.oracle.com/javase/8/docs/api/java/lang/Throwable.html#fillInStackTrace-->. > Even > Throwable has a constructor without a stacktrace, if you worried on > performance. My rule of thumb is; If performance matters so much, you may > need to re-consider writing your application in Java instead try C or C++. > Java meant to be high-level and code should be self explanatory and > maintainable[1]. Please refer "Null References: The Billion Dollar > Mistake" by T. Hoare[2]. > > This is my two cents for NULLs ;) > > Choosing return NULL over Exceptions is a choice of writing *unreliable* > applications over bad-performance. > > Thanks, > Rasika > > [1] http://wolfie.github.io/2010/03/14/exceptional-heresy.html > [2] > https://www.infoq.com/presentations/Null-References-The-Billion-Dollar-Mistake-Tony-Hoare > > On Sun, Jul 17, 2016 at 5:58 PM, Udara Liyanage <ud...@wso2.com> wrote: > >> >> >> On Sun, Jul 17, 2016 at 2:53 PM, Nuwan Pallewela <nuw...@wso2.com> wrote: >> >>> Hi, >>> >>> On Wed, Jul 13, 2016 at 10:15 AM, Sabra Ossen <sa...@wso2.com> wrote: >>> >>>> Hi, >>>> >>>> Thank you all for your prompt responses :) >>>> >>>> So if it's an ArrayList/Map it's better to return an empty object >>>> rather than null. Got it. >>>> >>>> Regarding a POJO object IMO the usage of null, empty object or >>>> exception depends on the scenario being considered. >>>> >>>> Based on Rasikas' reply since the jaggery level code is using the DAO >>>> method (via manager interface) basically if no user is found then the >>>> exception thrown should be propagated and in the UI an appropriate message >>>> is rendered. Also since anyone else could be using the back end, when an >>>> exception is thrown they would not have to be aware of the internal >>>> implementation (if null or an empty object is returned, specifically he >>>> should be aware if an empty object is returned so that he should write his >>>> front end code accordingly). >>>> >>>> IMO returning an exception is clearer in terms of code but I guess the >>>> discussion could continue further until a guideline is specified. >>>> >>> +1 for throwing an exception in general. If we return a null or empty >>> object if data is unavailable, we may have to do a null check or empty >>> object check when trying to process it most probably. And that check may >>> tend to hide the original problem of unavailability of data and hard to >>> debug if we face an error in a different place because of that.IMO throwing >>> a custom exception which we could handle and log later or give an error >>> message to user will be more suitable. >>> What to use with ArrayList and Maps is also depends on how we are going >>> to manipulate the returned value. If we are going to access data in a >>> ArrayList by index calling index values individually, it is better to use >>> exception otherwise we may need to have a null check before that. Same >>> applies to Maps. If we are
Re: [Dev] Is it best practice to return null or an empty object from a method in DAO layer?
>>>>>>> think >>>>>>>> the returning null is not something we should do. >>>>>>>> >>>>>>>> Thank You! >>>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> *Sabra Ossen* >>>>>>> *Software Engineer* >>>>>>> Email: sa...@wso2.com >>>>>>> Mobile: +94 767 837356 >>>>>>> >>>>>>> ___ >>>>>>> Dev mailing list >>>>>>> Dev@wso2.org >>>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>>>>> >>>>>>> >>>>>> >>>>>> ___ >>>>>> Dev mailing list >>>>>> Dev@wso2.org >>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>>>> >>>>>> >>>>> >>>>> >>>>> -- >>>>> Thanks >>>>> Abimaran Kugathasan >>>>> Senior Software Engineer >>>>> >>>>> Email : abima...@wso2.com >>>>> Mobile : +94 773922820 >>>>> >>>>> <http://stackoverflow.com/users/515034> >>>>> <http://lk.linkedin.com/in/abimaran> >>>>> <http://www.lkabimaran.blogspot.com/> <https://github.com/abimarank> >>>>> <https://twitter.com/abimaran> >>>>> >>>>> >>>>> ___ >>>>> 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 >>>> >>>> >>> >>> ___ >>> Dev mailing list >>> Dev@wso2.org >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> *Sabra Ossen* >> *Software Engineer* >> Email: sa...@wso2.com >> Mobile: +94 767 837356 >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > Thanks, > Nuwan > > -- > -- > > *Nuwan Chamara Pallewela* > > > *Software Engineer* > > *WSO2, Inc. *http://wso2.com > *lean . enterprise . middleware* > > Email *nuw...@wso2.com <nuw...@wso2.com>* > Mobile *+94719079739 <%2B94719079739>@* > > > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [ES] Too many mysql connections when starting ES instances
ternal(UserRegistry.java:617) >>>>>>>> at >>>>>>>> org.wso2.carbon.registry.core.session.UserRegistry.access$400(UserRegistry.java:61) >>>>>>>> at >>>>>>>> org.wso2.carbon.registry.core.session.UserRegistry$5.run(UserRegistry.java:597) >>>>>>>> at >>>>>>>> org.wso2.carbon.registry.core.session.UserRegistry$5.run(UserRegistry.java:594) >>>>>>>> at java.security.AccessController.doPrivileged(Native Method) >>>>>>>> at >>>>>>>> org.wso2.carbon.registry.core.session.UserRegistry.get(UserRegistry.java:594) >>>>>>>> at >>>>>>>> org.wso2.carbon.registry.indexing.AsyncIndexer$IndexingTask.createIndexDocument(AsyncIndexer.java:242) >>>>>>>> at >>>>>>>> org.wso2.carbon.registry.indexing.AsyncIndexer$IndexingTask.run(AsyncIndexer.java:210) >>>>>>>> at >>>>>>>> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) >>>>>>>> at java.util.concurrent.FutureTask.run(FutureTask.java:266) >>>>>>>> at >>>>>>>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) >>>>>>>> at >>>>>>>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) >>>>>>>> at java.lang.Thread.run(Thread.java:745) >>>>>>>> Caused by: >>>>>>>> com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: >>>>>>>> Too >>>>>>>> many connections >>>>>>>> at sun.reflect.GeneratedConstructorAccessor107.newInstance(Unknown >>>>>>>> Source) >>>>>>>> at >>>>>>>> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) >>>>>>>> at java.lang.reflect.Constructor.newInstance(Constructor.java:422) >>>>>>>> at com.mysql.jdbc.Util.handleNewInstance(Util.java:404) >>>>>>>> at com.mysql.jdbc.Util.getInstance(Util.java:387) >>>>>>>> at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:917) >>>>>>>> at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3878) >>>>>>>> at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3814) >>>>>>>> at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:871) >>>>>>>> at >>>>>>>> com.mysql.jdbc.MysqlIO.proceedHandshakeWithPluggableAuthentication(MysqlIO.java:1694) >>>>>>>> at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1215) >>>>>>>> at >>>>>>>> com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2255) >>>>>>>> at >>>>>>>> com.mysql.jdbc.ConnectionImpl.connectWithRetries(ConnectionImpl.java:2106) >>>>>>>> ... 43 more >>>>>>>> [2016-07-13 07:50:40,077] ERROR >>>>>>>> {org.wso2.carbon.registry.indexing.AsyncIndexer} - Error while >>>>>>>> indexing. >>>>>>>> Resource at path >>>>>>>> "/_system/governance/store/asset_resources/gadget/8c3eda76-ec7f-43e3-bbe8-efa14f85d780/images_thumbnail"could >>>>>>>> not be >>>>>>>> indexedorg.wso2.carbon.registry.core.exceptions.ResourceNotFoundException: >>>>>>>> Resource does not exist at path >>>>>>>> /_system/governance/store/asset_resources/gadget/8c3eda76-ec7f-43e3-bbe8-efa14f85d780/images_thumbnail >>>>>>>> [2016-07-13 07:50:40,076] ERROR >>>>>>>> {org.wso2.carbon.registry.indexing.AsyncIndexer} - Error while >>>>>>>> indexing. >>>>>>>> Resource at path "/_system/governance/gadgets/admin/Stacked Line >>>>>>>> Chart/1.0.0"could not be >>>>>>>> indexedorg.wso2.carbon.registry.core.exceptions.ResourceNotFoundException: >>>>>>>> Resource does not exist at path >>>>>>>> /_system/governance/gadgets/admin/Stacked >>>>>>>> Line Chart/1.0.0 >>>>>>>> [2016-07-13 07:50:40,074] ERROR >>>>>>>> {org.wso2.carbon.registry.indexing.AsyncIndexer} - Error while >>>>>>>> indexing. >>>>>>>> Resource at path >>>>>>>> "/_system/governance/store/asset_resources/gadget/57235acc-ad87-41db-84e7-dadc0bcff8d5/images_banner"could >>>>>>>> not be >>>>>>>> indexedorg.wso2.carbon.registry.core.exceptions.ResourceNotFoundException: >>>>>>>> Resource does not exist at path >>>>>>>> /_system/governance/store/asset_resources/gadget/57235acc-ad87-41db-84e7-dadc0bcff8d5/images_banner >>>>>>>> [2016-07-13 07:50:40,067] ERROR >>>>>>>> {org.wso2.carbon.registry.indexing.AsyncIndexer} - Error while >>>>>>>> indexing. >>>>>>>> Resource at path >>>>>>>> "/_system/governance/store/asset_resources/gadget/8c3eda76-ec7f-43e3-bbe8-efa14f85d780/images_banner"could >>>>>>>> not be >>>>>>>> indexedorg.wso2.carbon.registry.core.exceptions.ResourceNotFoundException: >>>>>>>> Resource does not exist at path >>>>>>>> /_system/governance/store/asset_resources/gadget/8c3eda76-ec7f-43e3-bbe8-efa14f85d780/images_banner >>>>>>>> [2016-07-13 07:50:40,064] ERROR >>>>>>>> {org.wso2.carbon.registry.indexing.AsyncIndexer} - Error while >>>>>>>> indexing. >>>>>>>> Resource at path "/_system/governance/gadgets/admin/WSO2 Carbon Commits >>>>>>>> List Discussion/1.0.0"could not be >>>>>>>> indexedorg.wso2.carbon.registry.core.exceptions.ResourceNotFoundException: >>>>>>>> Resource does not exist at path /_system/governance/gadgets/admin/WSO2 >>>>>>>> Carbon Commits List Discussion/1.0.0 >>>>>>>> [2016-07-13 07:50:40,062] ERROR >>>>>>>> {org.wso2.carbon.registry.indexing.AsyncIndexer} - Error while >>>>>>>> indexing. >>>>>>>> Resource at path >>>>>>>> "/_system/governance/store/asset_resources/site/6b89dd21-0a98-4489-9f0d-fc327ff46bc0/images_thumbnail"could >>>>>>>> not be >>>>>>>> indexedorg.wso2.carbon.registry.core.exceptions.ResourceNotFoundException: >>>>>>>> Resource does not exist at path >>>>>>>> /_system/governance/store/asset_resources/site/6b89dd21-0a98-4489-9f0d-fc327ff46bc0/images_thumbnail >>>>>>>> [2016-07-13 07:50:40,056] ERROR >>>>>>>> {org.wso2.carbon.registry.indexing.AsyncIndexer} - Error while >>>>>>>> indexing. >>>>>>>> Resource at path >>>>>>>> "/_system/governance/store/asset_resources/gadget/4c4f7877-ff39-4379-9ee4-6c1827732ec6/images_thumbnail"could >>>>>>>> not be >>>>>>>> indexedorg.wso2.carbon.registry.core.exceptions.ResourceNotFoundException: >>>>>>>> Resource does not exist at path >>>>>>>> /_system/governance/store/asset_resources/gadget/4c4f7877-ff39-4379-9ee4-6c1827732ec6/images_thumbnail >>>>>>>> [2016-07-13 07:50:40,079] ERROR >>>>>>>> {org.wso2.carbon.registry.indexing.AsyncIndexer} - Error while >>>>>>>> indexing. >>>>>>>> Resource at path >>>>>>>> "/_system/governance/store/asset_resources/gadget/57235acc-ad87-41db-84e7-dadc0bcff8d5/images_thumbnail"could >>>>>>>> not be >>>>>>>> indexedorg.wso2.carbon.registry.core.exceptions.ResourceNotFoundException: >>>>>>>> Resource does not exist at path >>>>>>>> /_system/governance/store/asset_resources/gadget/57235acc-ad87-41db-84e7-dadc0bcff8d5/images_thumbnail >>>>>>>> >>>>>>>> >>>>>>>> Thank you. >>>>>>>> Regards, >>>>>>>> >>>>>>>> -- >>>>>>>> >>>>>>>> *Dilini GunatilakeSoftware Engineer - QA Team* >>>>>>>> Mobile : +94 (0) 771 162518 >>>>>>>> dili...@wso2.com >>>>>>>> >>>>>>>> ___ >>>>>>>> Dev mailing list >>>>>>>> Dev@wso2.org >>>>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>>>>>> >>>>>>>> >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> Rajith Vitharana >>>>>>> >>>>>>> Software Engineer, >>>>>>> WSO2 Inc. : wso2.com >>>>>>> Mobile : +94715883223 >>>>>>> Blog : http://lankavitharana.blogspot.com/ >>>>>>> >>>>>>> ___ >>>>>>> Dev mailing list >>>>>>> Dev@wso2.org >>>>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>>>>> >>>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> /sumedha >>>>>> m: +94 773017743 >>>>>> b : bit.ly/sumedha >>>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> Rajith Vitharana >>>>> >>>>> Software Engineer, >>>>> WSO2 Inc. : wso2.com >>>>> Mobile : +94715883223 >>>>> Blog : http://lankavitharana.blogspot.com/ >>>>> >>>> >>>> >>>> >>>> -- >>>> >>>> *Dilini GunatilakeSoftware Engineer - QA Team* >>>> Mobile : +94771162518 >>>> dili...@wso2.com >>>> >>>> >>>> ___ >>>> Dev mailing list >>>> Dev@wso2.org >>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>> >>>> >>> >>> >>> -- >>> Thanks, >>> Thushara Kasun Ranawaka >>> Software Engineer >>> WSO2 Inc.; <http://www.wso2.com> >>> lean.enterprise.middleware >>> Mobile : *+94 (0) 773438949 <%2B94%20%280%29%20773438949>* >>> *thusha...@wso2.com <thusha...@wso2.com>* >>> >>> ___ >>> Dev mailing list >>> Dev@wso2.org >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> Thank you and Best Regards, >> Chanaka Fernando >> Senior Technical Lead >> m: +94 773337238 >> https://wso2.com <https://wso2.com/signature> >> >> >> >> >> >> >> > > > -- > Thanks, > Thushara Kasun Ranawaka > Software Engineer > WSO2 Inc.; <http://www.wso2.com> > lean.enterprise.middleware > Mobile : *+94 (0) 773438949 <%2B94%20%280%29%20773438949>* > *thusha...@wso2.com <thusha...@wso2.com>* > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware Blog: http://udaraliyanage.wordpress.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Sticky Session with marathon load balancer
On Tue, Jul 12, 2016 at 5:43 AM, Imesh Gunaratne <im...@wso2.com> wrote: > On Tue, Jul 12, 2016 at 2:02 PM, Anuruddha Liyanarachchi < > anurudd...@wso2.com> wrote: > >> Hi, >> >> I have configured cookie based sticky sessions with marathon-lb for wso2 >> servers using JSESSIONID. The following labels are required to generate the >> correct ha-proxy config values and should be passed in the application >> definition. >> >> "labels": { >> "HAPROXY_1_GROUP": "marathon-lb", >> "HAPROXY_2_GROUP": "marathon-lb", >> "HAPROXY_2_BACKEND_SERVER_OPTIONS": " server {serverName} >> {host_ipv4}:{port}{cookieOptions} ssl verify none \n", >> > > A production deployment would need SSL verification enabled. Therefore, we > might need to clearly mentioned that it in the documentation/README.md > files. > Current haproxy doc <https://docs.wso2.com/display/CLUSTER420/Configuring+HAProxy> also does not have ssl verification. Yes a production system would have ssl verfication on. So it would be better to mention clearly. > > >> "HAPROXY_2_BACKEND_STICKY_OPTIONS": " cookie JSESSIONID prefix >> nocache \n", >> "HAPROXY_2_STICKY": "true", >> "HAPROXY_2_SSL_CERT": "/etc/ssl/cert.pem", >> >> "HAPROXY_2_MODE": "http" >> }, >> >> > We would need to explain what n means in HAPROXY_{n}_ labels and how to > apply this to a specific set of ports. > > >> Shall we add these labels to our mesos artifacts to enable sticky session >> with 9443 port ? >> >> Yes please, will add this to all the management console/UI transports in > all Marathon applications. > > Thanks > > >> >> [1] https://github.com/mesosphere/marathon-lb/blob/master/Longhelp.md >> >> -- >> *Thanks and Regards,* >> Anuruddha Lanka Liyanarachchi >> Software Engineer - WSO2 >> Mobile : +94 (0) 712762611 >> Tel : +94 112 145 345 >> a <thili...@wso2.com>nurudd...@wso2.com >> > > > > -- > *Imesh Gunaratne* > Software Architect > WSO2 Inc: http://wso2.com > T: +94 11 214 5345 M: +94 77 374 2057 > W: https://medium.com/@imesh TW: @imesh > > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Mesos DNS support for Mesos membership scheme
On Jun 27, 2016 9:38 PM, "Akila Ravihansa Perera"wrote: > > Hi, > > Currently Mesos membership scheme relies on Marathon REST API to discover the members in a cluster. There can be situations where access to Marathon REST API could be restricted and access cannot be granted for Carbon products due to security concerns. > > However, we can still discover members in the cluster by using Mesos DNS REST API [1]. I've implemented this functionality in [2]. We can set the DNS endpoint via MESOS_DNS_ENDPOINT parameter in axis2.xml. > We can change the member discovery scheme by defining the MESOS_MEMBER_DISCOVERY_SCHEME parameter in axis2.xml. The default will be 'Marathon' (via Marathon REST API). It is important to understand that Mesos DNS will periodically query the master node to get a list of members, therefore it is possible that there will be a delay to reflect the latest state. I've introduced a DNS update timeout (DNS_UPDATE_TIMEOUT which defaults to 10s), period of time to keep retrying if the service is not found. > > Note that if there are shared Marathon applications when creating a single Hazelcast cluster you need to include them in MARATHON_APPLICATIONS parameter as comma separated values. For eg: WSO2 ESB worker/manager setup > wso2esb manager should not have any value for MARATHON_APPLICATIONS since it should be started first, before the worker. Members in the same application (wso2esb-manager in this case) will be added by default How about using a predefined label, all apps that should be in same cluster have same value for that label. My suggestion is something like VHOST-0 in mararhonlb In a gateway worker, manager,is as KM, Greg publisher store scenario we have to mention multiple apps in MARATHON_APPLICATIONS feild. > > wso2esb worker should have "wso2esb-manager" as MARATHON_APPLICATIONS since it will be started after the manager. > > [1] https://mesosphere.github.io/mesos-dns/docs/http.html > [2] https://github.com/wso2/mesos-artifacts/tree/master/common/mesos-membership-scheme > > Thanks. > > -- > Akila Ravihansa Perera > WSO2 Inc.; http://wso2.com/ > > Blog: http://ravihansa3000.blogspot.com > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [Mesos-Marathon] Issues in Creating Point to Point TCP Connections in Mesos-Marathon based Deployments
On Tue, Jul 12, 2016 at 12:56 PM, Isuru Haththotuwa <isu...@wso2.com> wrote: > Hi all, > > This is to discuss about $subject. > > By default Mesos-Marathon [1] does not have an overlay network. Therefore > when deploying wso2 products in distributed/HA manner in mesos, the > products are unable to create point to point TCP connections directly from > container to container. > > In Carbon products, p2p connections are created by Hazelcast, within > cluster members. Since this is just for communication purposes, its > possible to do a workaround by querying the API for the IPs of the host > machine. This is done in the Mesos membership scheme [2]. > > There are few places where we need to create TCP Listeners, for an example > in CEP HA/Distributed setup [3]. For this, we can't just bind to the host > node IP since the public IP is not visible to the container; and can't use > the local container IP since container to container communication is not > possible (due to the lack of an overlay network). > > One possible option is such scenarios is to use the HOST networking mode > of Docker [4]. Then the container will be using the host IP and ports > directly. One issue with this approach is since we are mapping container > ports to host ports directly without assigning random ports from the host > side, only one container can run in one host node. But, in a way this > defeats the purpose of containerization. > Using host mode would be a good alternative. I don't think limiting one container per Mesos node (Mesos HOST=UNIQUE constrain) in this scenario since a HA Mesos deployment will have multiple Mesos nodes. Another advantage of running in host mode is performance efficiency rather than bridge mode. Network efficiency would be useful in thrift scenario since it is assumed to be fast. > > Please share your thoughts on this. > > [1]. https://github.com/mesosphere/marathon > > [2]. > https://github.com/wso2/mesos-artifacts/tree/master/common/mesos-membership-scheme > > [3]. > https://docs.wso2.com/display/CLUSTER44x/Clustering+CEP+4.0.0#ClusteringCEP4.0.0-Highavailabilitydeployment > > [4]. http://www.dasblinkenlichten.com/docker-networking-101-host-mode/ > > > -- > Thanks and Regards, > > Isuru H. > +94 716 358 048 > > > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Persist host entry in the docker image built from a dockerfile
On Fri, Jul 8, 2016 at 7:49 AM, Sabra Ossen <sa...@wso2.com> wrote: > Hi All, > > I am trying to add a host entry to /etc/hosts inside of a docker image > built from a dockerfile. An extensive search resulted in the following > results. > > 1. Add the host entry at runtime using command, > *docker run -it --add-host myhost:192.168.18.2 /bin/bash* > This method only makes the host entry available in the running > container and not in the image resulting after a docker build. > 2. Add "RUN echo "192.168.11.112 myhost" >> /etc/hosts && wget > http://myhost; to the docker file. With each RUN command a new > intermediate container will be created. This method only allows the host > entry available in the intermediate container. > I think this method will work. What do you mean by available only to intermediate container. If you add above RUN command it will persist in the final docker image, isn't it? > > Many methods allow the host entry to be available only from a container > level vs image level. Any known clean method for $subject. > > Thanks and Regards. > -- > *Sabra Ossen* > *Software Engineer* > Email: sa...@wso2.com > Mobile: +94 767 837356 > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [Dockerfile] WSO2IS docker image build fails due to missing file
Hi, The issue was IS unzipped directory was there at files directory. Thanks Thanuja for the offline help. On Mon, Jul 4, 2016 at 6:41 AM, Udara Liyanage <ud...@wso2.com> wrote: > Hi, > > WSO2 IS as KM docker image build fails due to a missing file. This file is > not found even in original pack. > > bash build.sh -v 5.1.0 -s mesos -r puppet > > 172.17.0.3 - - [04/Jul/2016 06:21:27] "GET > /modules/wso2is_km/files/wso2is_km-5.1.0/modules/ws/ HTTP/1.1" 200 - > 2016-07-04 10:21:27 URL: > http://172.17.0.1:8002/modules/wso2is_km/files/wso2is_km-5.1.0/modules/ws/ > [320/320] -> > "modules/wso2is_km/files/wso2is_km-5.1.0/modules/ws/index.html" [1] > 172.17.0.3 - - [04/Jul/2016 06:21:27] code 404, message File not found > 172.17.0.3 - - [04/Jul/2016 06:21:27] "GET > /modules/wso2is_km/files/wso2is_km-5.1.0/css/is-docs.css HTTP/1.1" 404 - > > http://172.17.0.1:8002/modules/wso2is_km/files/wso2is_km-5.1.0/css/is-docs.css > : > *2016-07-04 10:21:27 ERROR 404: File not found.* > 172.17.0.3 - - [04/Jul/2016 06:21:27] "GET /mod > ERROR: Docker image > cdtsdvo108p.rxcorp.com:8443/wso2/devl/wso2is_km-mesos:5.1.0 creation > failed > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [Dockerfile] WSO2IS docker image build fails due to missing file
Hi, WSO2 IS as KM docker image build fails due to a missing file. This file is not found even in original pack. bash build.sh -v 5.1.0 -s mesos -r puppet 172.17.0.3 - - [04/Jul/2016 06:21:27] "GET /modules/wso2is_km/files/wso2is_km-5.1.0/modules/ws/ HTTP/1.1" 200 - 2016-07-04 10:21:27 URL: http://172.17.0.1:8002/modules/wso2is_km/files/wso2is_km-5.1.0/modules/ws/ [320/320] -> "modules/wso2is_km/files/wso2is_km-5.1.0/modules/ws/index.html" [1] 172.17.0.3 - - [04/Jul/2016 06:21:27] code 404, message File not found 172.17.0.3 - - [04/Jul/2016 06:21:27] "GET /modules/wso2is_km/files/wso2is_km-5.1.0/css/is-docs.css HTTP/1.1" 404 - http://172.17.0.1:8002/modules/wso2is_km/files/wso2is_km-5.1.0/css/is-docs.css : *2016-07-04 10:21:27 ERROR 404: File not found.* 172.17.0.3 - - [04/Jul/2016 06:21:27] "GET /mod ERROR: Docker image cdtsdvo108p.rxcorp.com:8443/wso2/devl/wso2is_km-mesos:5.1.0 creation failed -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Getting error when starting WSO2 IS 5.1.0 Key Manager in Mesos DC/OS
deploy it in successfully and the server starts without any >>>>>> issue. >>>>>> >>>>>> As per the offline discussion with Niranjan, the above mentioned >>>>>> files will be created if we install the features via UI. If we can >>>>>> install >>>>>> Key Manager features using pom files, then above issue will be resolved. >>>>>> >>>>> >>>>> What does it mean? Does it mean that installing features via UI has a >>>>> bug and it should not be used? >>>>> >>>> AFAIU in the pack, the features have been installed via the feature >>>> management UI which requires in starting the server. This create temporary >>>> files as mentioned above. In Ubuntu / windows environment, when we start >>>> the pack, there are no issue. But in Mesos, it refers to the old files. The >>>> issue was resolved by deleting the temporary file. IMO since we have a >>>> workaround by deleting these temporary files and upload it to docker >>>> registry. In which case we do not have to recreate IS 5.1.0 Key Manager >>>> again. >>>> >>>> >>>>> >>>>>> @APIM_team: Shall we fix this and host the new IS 5.1.0 Key Manager >>>>>> pack? >>>>>> >>>>> >>>>> You have now successfully created the docker image right? Why do you >>>>> need the pack to be re-hosted? Its quite unlikely that we'll do it because >>>>> its a huge testing effort. And so far many people have been using this >>>>> without any issues. >>>>> >>>>>> >>>>>> [1]. https://github.com/wso2/mesos-artifacts/tree/master/wso2is-km >>>>>> [2]. >>>>>> http://product-dist.wso2.com/downloads/api-manager/1.10.0/identity-server/wso2is-5.1.0.zip >>>>>> >>>>>> Thanks. >>>>>> >>>>>> -- >>>>>> Thanuja Uruththirakodeeswaran >>>>>> Software Engineer >>>>>> WSO2 Inc.;http://wso2.com >>>>>> lean.enterprise.middleware >>>>>> >>>>>> mobile: +94 774363167 >>>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> Nuwan Dias >>>>> >>>>> Technical Lead - WSO2, Inc. http://wso2.com >>>>> email : nuw...@wso2.com >>>>> Phone : +94 777 775 729 >>>>> >>>> >>>> Regards, >>>> Nira >>>> >>>> -- >>>> >>>> >>>> *Niranjan Karunanandham* >>>> Associate Technical Lead - WSO2 Inc. >>>> WSO2 Inc.: http://www.wso2.com >>>> >>> >>> >>> >>> -- >>> *Imesh Gunaratne* >>> Software Architect >>> WSO2 Inc: http://wso2.com >>> T: +94 11 214 5345 M: +94 77 374 2057 >>> W: https://medium.com/@imesh TW: @imesh >>> Lean . Enterprise . Middleware >>> >>> >>> ___ >>> Dev mailing list >>> Dev@wso2.org >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> Akila Ravihansa Perera >> WSO2 Inc.; http://wso2.com/ >> >> Blog: http://ravihansa3000.blogspot.com >> > > > -- > Nuwan Dias > > Technical Lead - WSO2, Inc. http://wso2.com > email : nuw...@wso2.com > Phone : +94 777 775 729 > > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [wso2 IS] How to disable Shindig fetching google analytics
Hi Godwin, Thanks, your suggestion worked. Thanks others also for your suggestions. ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [IS 510] Keystore configs required in multiple locations
) at org.wso2.carbon.core.init.CarbonServerManager.initializeCarbon(CarbonServerManager.java:514) at org.wso2.carbon.core.init.CarbonServerManager.start(CarbonServerManager.java:219) at org.wso2.carbon.core.internal.CarbonCoreServiceComponent.activate(CarbonCoreServiceComponent.java:94) 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.eclipse.equinox.internal.ds.model.ServiceComponent.activate(ServiceComponent.java:260) at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.activate(ServiceComponentProp.java:146) at org.eclipse.equinox.internal.ds.model.ServiceComponentProp.build(ServiceComponentProp.java:345) at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponent(InstanceProcess.java:620) at org.eclipse.equinox.internal.ds.InstanceProcess.buildComponents(InstanceProcess.java:197) at org.eclipse.equinox.internal.ds.Resolver.getEligible(Resolver.java:343) at org.eclipse.equinox.internal.ds.SCRManager.serviceChanged(SCRManager.java:222) at org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:107) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:861) at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230) at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148) at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:819) at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:771) at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:130) at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:214) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.registerService(BundleContextImpl.java:433) at org.eclipse.equinox.http.servlet.internal.Activator.registerHttpService(Activator.java:81) at org.eclipse.equinox.http.servlet.internal.Activator.addProxyServlet(Activator.java:60) at org.eclipse.equinox.http.servlet.internal.ProxyServlet.init(ProxyServlet.java:40) at org.wso2.carbon.tomcat.ext.servlet.DelegationServlet.init(DelegationServlet.java:38) at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1284) at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1197) at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1087) at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5262) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5550) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1575) at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1565) at java.util.concurrent.FutureTask.run(FutureTask.java:262) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745) Caused by: org.wso2.carbon.tomcat.CarbonTomcatException: Webapp failed to deploy at org.wso2.carbon.tomcat.internal.CarbonTomcat.addWebApp(CarbonTomcat.java:302) at org.wso2.carbon.tomcat.internal.CarbonTomcat.addWebApp(CarbonTomcat.java:198) at org.wso2.carbon.webapp.mgt.TomcatGenericWebappsDeployer.handleWebappDeployment(TomcatGenericWebappsDeployer.java:314) ... 88 more Caused by: java.lang.Exception: Webapp failed to deploy, Lifecycle state is STOPPED at org.wso2.carbon.tomcat.internal.CarbonTomcat.addWebApp(CarbonTomcat.java:294) ... 90 more [2016-06-11 10:11:10,763] INFO {org.springframework.web.context.support.XmlWebApplicationContext} - Refreshing Root WebApplicationContext: startup date [Sat Jun 11 10:11:10 IST 2016]; root of context hierarchy On Thu, Jun 9, 2016 at 3:06 PM, Udara Liyanage <ud...@wso2.com> wrote: > Hi Maliti, > > We removed it from repo/conf, then IS throws errors when starting. > > On Thu, Jun 9, 2016 at 5:25 AM, Malithi Edirisinghe <malit...@wso2.com> > wrote: > >> >> >> On Thu, Jun 9, 2016 at 11:48 AM, Udara Liyanage <ud...@wso2.com> wrote: >> >>> Hi, >>> >>> When migrating from IS 500 to 510 we get keystore errors while starting >>> up the server regardless of the fact that all configurations are correct. >>> We noticed that IS 510 has another configuration file >>> (repository/conf/identity/EndpointConfig.properties.) which requires >>> keystore configurations. >>
Re: [Dev] [IS 510] Keystore configs required in multiple locations
Hi Maliti, We removed it from repo/conf, then IS throws errors when starting. On Thu, Jun 9, 2016 at 5:25 AM, Malithi Edirisinghe <malit...@wso2.com> wrote: > > > On Thu, Jun 9, 2016 at 11:48 AM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> When migrating from IS 500 to 510 we get keystore errors while starting >> up the server regardless of the fact that all configurations are correct. >> We noticed that IS 510 has another configuration file >> (repository/conf/identity/EndpointConfig.properties.) which requires >> keystore configurations. >> >> According to the doc, this is useful when the web app is hosted outside >> of IS. But IS gives web app deployment error if I remove this file from IS. >> If it is to be deployed externally, IS server should start without any >> issue without this file existing. >> > > Did you try removing the file from the repository/conf path or from the > webapp itself. > AFAIK, it can be removed from the repository/conf path and the app will > rely on the file within the web application it self. It will behave > similarly when deployed externally. > > >> >> [1] >> https://docs.wso2.com/display/IS510/Hosting+the+Authentication+Endpoint+on+a+Separate+Server >> >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> web: http://udaraliyanage.wordpress.com >> phone: +94 71 443 6897 >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > Thanks, > Malithi > > > -- > > *Malithi Edirisinghe* > Associate Technical Lead > WSO2 Inc. > > Mobile : +94 (0) 718176807 > malit...@wso2.com > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [IS 510] Keystore configs required in multiple locations
Hi, When migrating from IS 500 to 510 we get keystore errors while starting up the server regardless of the fact that all configurations are correct. We noticed that IS 510 has another configuration file (repository/conf/identity/EndpointConfig.properties.) which requires keystore configurations. According to the doc, this is useful when the web app is hosted outside of IS. But IS gives web app deployment error if I remove this file from IS. If it is to be deployed externally, IS server should start without any issue without this file existing. [1] https://docs.wso2.com/display/IS510/Hosting+the+Authentication+Endpoint+on+a+Separate+Server -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [wso2 IS] How to disable Shindig fetching google analytics
Hi, IS 510 tries to reach google analytic at startup. When an server is started in a docker container where no internet access is available it throws errors and server startup delays. Is there configuration to stop this? TID: [-1234] [] [2016-06-02 12:58:43,036] INFO {org.apache.shindig.gadgets.http.BasicHttpFetcher} -* The following exception occurred when fetching http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js <http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js>: 25,573 ms elapsed. * TID: [-1234] [] [2016-06-02 12:58:43,037] INFO {org.apache.shindig.gadgets.http.BasicHttpFetcher} - org.apache.http.conn.ConnectTimeoutException: Connect to ajax.googleapis.com:80 timed out at org.apache.http.conn.scheme.PlainSocketFactory.connectSocket(PlainSocketFactory.java:119) at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:177) at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:144) at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:131) at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:611) at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:446) at org.apache.http.impl.client.AbstractHttpClient.doExecute(AbstractHttpClient.java:863) at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:115) at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:57) at org.apache.shindig.gadgets.http.BasicHttpFetcher.fetch(BasicHttpFetcher.java:359) at org.apache.shindig.gadgets.features.FeatureResourceLoader$UriResource.getContent(FeatureResourceLoader.java:291) at org.apache.shindig.gadgets.features.FeatureResourceLoader$UriResource.(FeatureResourceLoader.java:270) at org.apache.shindig.gadgets.features.FeatureResourceLoader$UriResource.(FeatureResourceLoader.java:256) at org.apache.shindig.gadgets.features.FeatureResourceLoader.loadUri(FeatureResourceLoader.java:135) at org.apache.shindig.gadgets.features.FeatureResourceLoader.load(FeatureResourceLoader.java:88) at org.apache.shindig.gadgets.features.FeatureRegistry.loadFeature(FeatureRegistry.java:486) -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] APIM 191 to APIM 1.10.0 KeyStore/RegistryKeyStore configuration changes
Hi, I see a RegistryKeyStore config section in carbon.xml of 191, but it is removed in 1.10.0. As am aware, RegistryKeyStore was used when encrypting using ciphertool, correct me if I am wrong. I see keystoreFile is mentioned in catalina-server.xml in APIM 1.10.0. Does this mean that ciphertext now uses KeyStore which was earlier RegistryKeyStore and SSL encryption is done by keystore configured in catalina-server.xml? [1] https://docs.wso2.com/display/Carbon441/Configuring+Keystores+in+WSO2+Products -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] REST-API: Fine Grained resources vs Coarse Grained resources
Hi, When designing API, we need to let the clients know the API endpoints so they can invoke relevant endpoint to fetch expected resource. Assuming size of the configuration/analytic object payload is a dynamic thing, how can the client know which endpoints to invoke to fetch the required resource. How does the client know the size of the analytic payload. In this case how does a client know which API endpoint to invoke if he want to get configs. It may be GET /analysis if analysis size is low, otherwise GET /analysis/configs . Yes, we can not go extreme in fine grain or coarse grain. IMO best approach is to go in middle path, define a reasonable set of endpoints to fetch resources. On Tue, Mar 29, 2016 at 3:08 PM, Thamali Wijewardhana <tham...@wso2.com> wrote: > Hi, > > When creating a REST API to WSO2 machine learner, one of the important > problems I faced was selection among fine grained resources and coarse > grained resources. In other words, whether to define something as a > separate resource or a part of a large resource. > > Fine grained Resources are low complex and easy to maintain. But it can > make data become an inconsistent state and the server will end up receiving > higher number of HTTP requests possibly impacting its ability to serve > multiple API consumers. > > In using coarse grained resources, the data inconsistency and higher load > on the server is reduced. But it may be difficult to maintain and higher > JSON payload may be returned. > > For example, we have an API GET api/analysis/analysis_id/configs which > retrieves configurations of an API. The problem is whether to use a > separate resource for configs or return configs with the analysis resource. > If we consider configuration as a separate resource, we have to define an > API, GET api/analysis/analysis_id/configs. But if we return configs with > analysis resource, then it may be only the API GET > api/analysis/analysis_id and the configuration should be added to analysis > resource and returned with it. > > I have found an approach to solve the problem and given below is what I > have understood. > > The decision should be taken considering the situation. > > Here, the decision is based on the size of the configuration object. If it > has a large size, then if we return it with analysis resource, it may be a > large JSON payload and time wastage because every time an analysis resource > is returned configuration also have to be returned even not necessary. > Therefore, if configuration is large, it is better to use a separate > resource for configurations and use a separate API as > api/analysis/analysis_id/configs > > But, when we have to access a simple property such as algorithm-name of > the analysis, then it is better to return it with algorithm resource. > > This is the approach I have decided and highly appreciate your suggestions > on this. > > > Thanks > > > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [Architecture] [REST APIs][Analytics] GET request with a payload
t;>> Thanks. >>>> >>>> On Wed, Mar 23, 2016 at 2:31 PM, Gimantha Bandara <giman...@wso2.com> >>>> wrote: >>>> >>>>> Hi all, >>>>> >>>>> >>>>> We have a REST API in DAS to retrieve records in a specific table. It >>>>> supports GET method with the following url format. >>>>> >>>>> /analytics/tables/{tableName}/{from}/{to}/{start}/{count} >>>>> >>>>> Sending a GET request to above url will give the records between given >>>>> "from", "to" time range starting from index "start" with "count" page >>>>> size. >>>>> >>>>> Now we need to change the API, so that the user can define the record >>>>> columns/fields he wants. Current API will return the records with all the >>>>> values/columns. To do that, we can allow the user to define the columns he >>>>> needs, in the payload. But it seems that having a payload with a GET is >>>>> not >>>>> the convention/the best practice. >>>>> >>>>> POST can be used to send the column names as a payload, but here we >>>>> are not making any updates to {tableName} resource. We will be just >>>>> retrieving records using a POST. So it also seems not the convention/the >>>>> best practice. >>>>> >>>>> The only solution I can think of is, having a different resource path >>>>> to get the records with only specified fields/columns. Are there any other >>>>> solutions? >>>>> >>>>> Thanks, >>>>> Gimantha >>>>> >>>>> >>>>> ___ >>>>> Architecture mailing list >>>>> architect...@wso2.org >>>>> https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture >>>>> >>>>> >>>> >>>> >>>> -- >>>> -- >>>> Lahiru Sandaruwan >>>> Committer and PMC member, Apache Stratos, >>>> Senior Software Engineer, >>>> WSO2 Inc., http://wso2.com >>>> lean.enterprise.middleware >>>> >>>> phone: +94773325954 >>>> email: lahi...@wso2.com blog: http://lahiruwrites.blogspot.com/ >>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146 >>>> >>>> >>>> ___ >>>> Dev mailing list >>>> Dev@wso2.org >>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>> >>>> >>> >>> >>> -- >>> Ayoma Wijethunga >>> Software Engineer >>> WSO2, Inc.; http://wso2.com >>> lean.enterprise.middleware >>> >>> Mobile : +94 (0) 719428123 <+94+(0)+719428123> >>> Blog : http://www.ayomaonline.com >>> LinkedIn: https://www.linkedin.com/in/ayoma >>> >> >> >> >> -- >> -- >> Lahiru Sandaruwan >> Committer and PMC member, Apache Stratos, >> Senior Software Engineer, >> WSO2 Inc., http://wso2.com >> lean.enterprise.middleware >> >> phone: +94773325954 >> email: lahi...@wso2.com blog: http://lahiruwrites.blogspot.com/ >> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146 >> >> >> ___ >> Architecture mailing list >> architect...@wso2.org >> https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture >> >> > > > -- > Gimantha Bandara > Software Engineer > WSO2. Inc : http://wso2.com > Mobile : +94714961919 > > ___ > Architecture mailing list > architect...@wso2.org > https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Configuring load balancing in app cloud with HA Proxy
t;>>>> >>>>>> Let me explain the problem. If we offload SSL at the service load >>>>>> balancer, all traffic beyond the load balancer will use HTTP and the >>>>>> message content will be visible to anyone on network inside K8S. Which >>>>>> means someone can simply start a container in K8S and trace all HTTP >>>>>> traffic going through. >>>>>> >>>>> >>>> >>>>> Below is from HA Proxy documentation[1]. AFAIU, HA Proxy to backend >>>>> server communication happens with HTTPS enabled but not validating the >>>>> server certificate. >>>>> >>>> >>>> >>>>> verify >>>>> <http://cbonte.github.io/haproxy-dconv/configuration-1.5.html#5.2-verify> >>>>> [none|required] >>>>> >>>>> This setting is only available when support for OpenSSL was built in. If >>>>> set >>>>> to 'none', server certificate is not verified. In the other case, The >>>>> certificate provided by the server is verified using CAs from 'ca-file' >>>>> and optional CRLs from 'crl-file'. If 'ssl_server_verify' is not specified >>>>> in global section, this is the default. On verify failure the handshake >>>>> is aborted. It is critically important to verify server certificates when >>>>> using SSL to connect to servers, otherwise the communication is prone to >>>>> trivial man-in-the-middle attacks rendering SSL totally useless. >>>>> >>>>> IMO still there is a major problem if we are not verifying the SSL >>>> certificate. See the highlighted text. >>>> >>> +1. We will attend to this once initial end to end scenario got working >>> in App Cloud. I am +1 for using a self signed cert in pods and adding it to >>> truststore of HA Proxy to fix above issue. >>> >>> thank you. >>> >>>> >>>> Thanks >>>> >>>> >>>>> [1]. >>>>> http://cbonte.github.io/haproxy-dconv/configuration-1.5.html#ssl%20%28Server%20and%20default-server%20options%29 >>>>> >>>>> thank you. >>>>> >>>>> >>>>>> Thanks >>>>>> >>>>>> In configuring load balancing with SSL termination, I had to >>>>>>> customize kubernetes haproxy.conf file template of service loadbalancer >>>>>>> repo to support SSL termination. >>>>>>> >>>>>>> In order to provide SSL termination, the kubernetes services have to >>>>>>> be annotated with >>>>>>> serviceloadbalancer/lb.sslTerm: "true" >>>>>>> >>>>>>> The default approach in load balancing with service load balancer >>>>>>> repo is based on simple fan out approach which uses context path to load >>>>>>> balance the traffic. As we need to load balance based on the host name, >>>>>>> we >>>>>>> need to go with the name based virtual hosting approach. It can be >>>>>>> achieved >>>>>>> via the following annotation. >>>>>>> serviceloadbalancer/lb.Host: "" >>>>>>> >>>>>>> Any suggestions on the approach taken are highly appreciated. >>>>>>> >>>>>>> Thank you >>>>>>> >>>>>>> [1]. >>>>>>> https://github.com/kubernetes/contrib/tree/master/service-loadbalancer >>>>>>> >>>>>>> >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> *Imesh Gunaratne* >>>>>> Senior Technical Lead >>>>>> WSO2 Inc: http://wso2.com >>>>>> T: +94 11 214 5345 M: +94 77 374 2057 >>>>>> W: http://imesh.io >>>>>> Lean . Enterprise . Middleware >>>>>> >>>>>> >>>>> >>>>> >>>>> -- >>>>> Manjula Rathnayaka >>>>> Associate Technical Lead >>>>> WSO2, Inc. >>>>> Mobile:+94 77 743 1987 >>>>> >>>> >>>> >>>> >>>> -- >>>> *Imesh Gunaratne* >>>> Senior Technical Lead >>>> WSO2 Inc: http://wso2.com >>>> T: +94 11 214 5345 M: +94 77 374 2057 >>>> W: http://imesh.io >>>> Lean . Enterprise . Middleware >>>> >>>> >>> >>> >>> -- >>> Manjula Rathnayaka >>> Associate Technical Lead >>> WSO2, Inc. >>> Mobile:+94 77 743 1987 >>> >> >> >> >> -- >> *Nishadi Kirielle* >> *Software Engineering Intern* >> Mobile : +94 (0) 714722148 >> Blog : http://nishadikirielle.blogspot.com/ >> nish...@wso2.com >> > > > > -- > *Nishadi Kirielle* > *Software Engineering Intern* > Mobile : +94 (0) 714722148 > Blog : http://nishadikirielle.blogspot.com/ > nish...@wso2.com > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] DSS insert with values with spaces and special characters
Hi Chanika, After escaping text from client side, I was able to get the issue resolved. However is there any way where we can ask DSS to escape/parse those values by modifying query or some mechanism. On Thu, Mar 10, 2016 at 10:55 AM, Udara Liyanage <ud...@wso2.com> wrote: > Hi Chanika, > > Now I escapded the value using StringEscapeUtils.escapeHtml. > But still it throws a similar error. > > Escaped value: > role=Lead - HR Administration > > On Thu, Mar 10, 2016 at 10:41 AM, Chanika Geeganage <chan...@wso2.com> > wrote: > >> Hi Udara, >> >> White spaces are parsed without any issue. For the character & you can >> pass it as '' or wrap it within CDATA.For an example, >> >> >> >> Thanks >> >> >> On Thu, Mar 10, 2016 at 9:59 AM, Udara Liyanage <ud...@wso2.com> wrote: >> >>> Hi, >>> >>> I have below query in my DSS configs. However this fails when values >>> have spaces or special characters &. >>> >>> INSERT INTO >>> employees(Employee_Id,First_Name,Last_Name,Work_Email,Gender,Job_Role,Department,Reports_To,Product,) >>> VALUES ( :id, >>> :firstName,:lastName,:email,:gender,:role,:department,:reportsTo,:product,:team); >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> Problematic values: >>> department=HUMAN RESOURCES AND ADMINISTRATION, role=Lead - HR & >>> Administration, >>> >>> >>> I tried escaping with single quote (':department') and double >>> quote(":department"), both did not work for me. What modification should >>> be done to add values with spaces and special characters. >>> >>> Udara Liyanage >>> Software Engineer >>> WSO2, Inc.: http://wso2.com >>> lean. enterprise. middleware >>> >>> web: http://udaraliyanage.wordpress.com >>> phone: +94 71 443 6897 >>> >> >> >> >> -- >> Best Regards.. >> >> Chanika Geeganage >> Software Engineer >> WSO2, Inc.; http://wso2.com >> >> > > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] DSS insert with values with spaces and special characters
Hi Chanika, Now I escapded the value using StringEscapeUtils.escapeHtml. But still it throws a similar error. Escaped value: role=Lead - HR Administration On Thu, Mar 10, 2016 at 10:41 AM, Chanika Geeganage <chan...@wso2.com> wrote: > Hi Udara, > > White spaces are parsed without any issue. For the character & you can > pass it as '' or wrap it within CDATA.For an example, > > > > Thanks > > > On Thu, Mar 10, 2016 at 9:59 AM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> I have below query in my DSS configs. However this fails when values have >> spaces or special characters &. >> >> INSERT INTO >> employees(Employee_Id,First_Name,Last_Name,Work_Email,Gender,Job_Role,Department,Reports_To,Product,) >> VALUES ( :id, >> :firstName,:lastName,:email,:gender,:role,:department,:reportsTo,:product,:team); >> >> >> >> >> >> >> >> >> >> >> >> >> Problematic values: >> department=HUMAN RESOURCES AND ADMINISTRATION, role=Lead - HR & >> Administration, >> >> >> I tried escaping with single quote (':department') and double >> quote(":department"), both did not work for me. What modification should >> be done to add values with spaces and special characters. >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> web: http://udaraliyanage.wordpress.com >> phone: +94 71 443 6897 >> > > > > -- > Best Regards.. > > Chanika Geeganage > Software Engineer > WSO2, Inc.; http://wso2.com > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] DSS insert with values with spaces and special characters
Hi, I have below query in my DSS configs. However this fails when values have spaces or special characters &. INSERT INTO employees(Employee_Id,First_Name,Last_Name,Work_Email,Gender,Job_Role,Department,Reports_To,Product,) VALUES ( :id, :firstName,:lastName,:email,:gender,:role,:department,:reportsTo,:product,:team); Problematic values: department=HUMAN RESOURCES AND ADMINISTRATION, role=Lead - HR & Administration, I tried escaping with single quote (':department') and double quote(":department"), both did not work for me. What modification should be done to add values with spaces and special characters. Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Xpath expression to fetch a property which has space in name
Hi, Yes, I also think it is a bug in json to xml conversion. I will create a jira for this. ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Xpath expression to fetch a property which has space in name
Hi, It gives me following error. Below is my synapse configs. ##call external api https://api.peoplehr.net/Query"/> #iterate thru results Sample API call output { "Message": "The requested processed successfully.", "Result": [ { "Department": "HUMAN RESOURCES AND ADMINISTRATION", "Employee Id": "456", }, { "Department": "MARKETING", "Employee Id": "123", }, JsonUtil #toJsonStream. Could not create input stream from XML element [123ENGINEERING]. Error>>> Could not convert OMElement to JSON. Invalid XML payload. On Mon, Mar 7, 2016 at 2:42 PM, Keerthika Mahendralingam <keerth...@wso2.com > wrote: > Hi Udara, > Since you are getting JSON response, I think you can use json-eval to get > the value form response like, > > > > > Thanks, > > On Mon, Mar 7, 2016 at 2:31 PM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> We have an call mediator which calls and external API. API response is >> json. Json properties has spaces in names. >> { >> "Department": "ENGINEERING", >> "Employee Id": "LK", >> "First Name": "Udara", >> >> } >> >> ESB converts this to xml, those xml element names also have space in >> element name. >> >> On Mon, Mar 7, 2016 at 2:05 PM, Udara Liyanage <ud...@wso2.com> wrote: >> >>> Hi, >>> >>> Below is the log mediator output. Even the converted xml tag has space >>> in its name. >>> >>> [2016-03-07 14:00:36,587] INFO - LogMediator To: >>> http://www.w3.org/2005/08/addressing/anonymous, WSAction: , SOAPAction: >>> , MessageID: urn:uuid:2b6e4e6d-9180-4083-b06b-d12c08c5178e, Direction: >>> request, Envelope: >> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/ >>> ">**123**>> Name>udaraliyanage>> Name> >>> >>> On Mon, Mar 7, 2016 at 12:06 PM, Udara Liyanage <ud...@wso2.com> wrote: >>> >>>> Hi Thusitha, >>>> >>>> I already tried that, but negative. >>>> >>>> On Mon, Mar 7, 2016 at 11:59 AM, Thusitha Thilina Dayaratne < >>>> thusit...@wso2.com> wrote: >>>> >>>>> Hi Udara, >>>>> >>>>> Did you tried replace the space with "_x0020_"? according to the [1] >>>>> it seems work for spaces >>>>> [1] - >>>>> *http://users.jackrabbit.apache.narkive.com/r9aFPfiI/xpath-query-with-space-in-node-name >>>>> <http://users.jackrabbit.apache.narkive.com/r9aFPfiI/xpath-query-with-space-in-node-name>* >>>>> >>>>> Thanks >>>>> On Mon, Mar 7, 2016 at 11:43 AM, Udara Liyanage <ud...@wso2.com> >>>>> wrote: >>>>> >>>>>> Hi, >>>>>> >>>>>> I am trying to fetch an property value from a json payload similar to >>>>>> below. >>>>>> { >>>>>> "Department": "ABC", >>>>>> "Employee Id": "123", >>>>>> "Work Email": "ud...@wso2.com" >>>>>> }, >>>>>> >>>>>> I could extract Department value by below xpath expression. >>>>>> >>>>>> >>>>>> >>>>>> However when I found difficulties when the property name contains an >>>>>> space in middle. I tried few options which were not successful. What is >>>>>> the correct way to escape space character. >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> >>>>>> Udara Liyanage >>>>>> Software Engineer >>>>>> WSO2, Inc.: http://wso2.com >>>>>> lean. enterprise. middleware >>>>>> >>>>>> web: http://udaraliyanage.wordpress.com >>>>>> phone: +94 71 443 6897 >>>>>> >>>>>> ___ >>>>>> De
Re: [Dev] Xpath expression to fetch a property which has space in name
Hi, We have an call mediator which calls and external API. API response is json. Json properties has spaces in names. { "Department": "ENGINEERING", "Employee Id": "LK", "First Name": "Udara", } ESB converts this to xml, those xml element names also have space in element name. On Mon, Mar 7, 2016 at 2:05 PM, Udara Liyanage <ud...@wso2.com> wrote: > Hi, > > Below is the log mediator output. Even the converted xml tag has space in > its name. > > [2016-03-07 14:00:36,587] INFO - LogMediator To: > http://www.w3.org/2005/08/addressing/anonymous, WSAction: , SOAPAction: , > MessageID: urn:uuid:2b6e4e6d-9180-4083-b06b-d12c08c5178e, Direction: > request, Envelope: xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/ > ">**123** Name>udaraliyanage Name> > > On Mon, Mar 7, 2016 at 12:06 PM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi Thusitha, >> >> I already tried that, but negative. >> >> On Mon, Mar 7, 2016 at 11:59 AM, Thusitha Thilina Dayaratne < >> thusit...@wso2.com> wrote: >> >>> Hi Udara, >>> >>> Did you tried replace the space with "_x0020_"? according to the [1] it >>> seems work for spaces >>> [1] - >>> *http://users.jackrabbit.apache.narkive.com/r9aFPfiI/xpath-query-with-space-in-node-name >>> <http://users.jackrabbit.apache.narkive.com/r9aFPfiI/xpath-query-with-space-in-node-name>* >>> >>> Thanks >>> On Mon, Mar 7, 2016 at 11:43 AM, Udara Liyanage <ud...@wso2.com> wrote: >>> >>>> Hi, >>>> >>>> I am trying to fetch an property value from a json payload similar to >>>> below. >>>> { >>>> "Department": "ABC", >>>> "Employee Id": "123", >>>> "Work Email": "ud...@wso2.com" >>>> }, >>>> >>>> I could extract Department value by below xpath expression. >>>> >>>> >>>> >>>> However when I found difficulties when the property name contains an >>>> space in middle. I tried few options which were not successful. What is >>>> the correct way to escape space character. >>>> >>>> >>>> >>>> >>>> >>>> -- >>>> >>>> Udara Liyanage >>>> Software Engineer >>>> WSO2, Inc.: http://wso2.com >>>> lean. enterprise. middleware >>>> >>>> web: http://udaraliyanage.wordpress.com >>>> phone: +94 71 443 6897 >>>> >>>> _______ >>>> Dev mailing list >>>> Dev@wso2.org >>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>> >>>> >>> >>> >>> -- >>> Thusitha Dayaratne >>> Software Engineer >>> WSO2 Inc. - lean . enterprise . middleware | wso2.com >>> >>> Mobile +94712756809 >>> Blog alokayasoya.blogspot.com >>> Abouthttp://about.me/thusithathilina >>> >>> >> >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> web: http://udaraliyanage.wordpress.com >> phone: +94 71 443 6897 >> > > > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Xpath expression to fetch a property which has space in name
Hi, Below is the log mediator output. Even the converted xml tag has space in its name. [2016-03-07 14:00:36,587] INFO - LogMediator To: http://www.w3.org/2005/08/addressing/anonymous, WSAction: , SOAPAction: , MessageID: urn:uuid:2b6e4e6d-9180-4083-b06b-d12c08c5178e, Direction: request, Envelope: http://schemas.xmlsoap.org/soap/envelope/ ">**123**udaraliyanage On Mon, Mar 7, 2016 at 12:06 PM, Udara Liyanage <ud...@wso2.com> wrote: > Hi Thusitha, > > I already tried that, but negative. > > On Mon, Mar 7, 2016 at 11:59 AM, Thusitha Thilina Dayaratne < > thusit...@wso2.com> wrote: > >> Hi Udara, >> >> Did you tried replace the space with "_x0020_"? according to the [1] it >> seems work for spaces >> [1] - >> *http://users.jackrabbit.apache.narkive.com/r9aFPfiI/xpath-query-with-space-in-node-name >> <http://users.jackrabbit.apache.narkive.com/r9aFPfiI/xpath-query-with-space-in-node-name>* >> >> Thanks >> On Mon, Mar 7, 2016 at 11:43 AM, Udara Liyanage <ud...@wso2.com> wrote: >> >>> Hi, >>> >>> I am trying to fetch an property value from a json payload similar to >>> below. >>> { >>> "Department": "ABC", >>> "Employee Id": "123", >>> "Work Email": "ud...@wso2.com" >>> }, >>> >>> I could extract Department value by below xpath expression. >>> >>> >>> >>> However when I found difficulties when the property name contains an >>> space in middle. I tried few options which were not successful. What is >>> the correct way to escape space character. >>> >>> >>> >>> >>> >>> -- >>> >>> Udara Liyanage >>> Software Engineer >>> WSO2, Inc.: http://wso2.com >>> lean. enterprise. middleware >>> >>> web: http://udaraliyanage.wordpress.com >>> phone: +94 71 443 6897 >>> >>> ___ >>> Dev mailing list >>> Dev@wso2.org >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> Thusitha Dayaratne >> Software Engineer >> WSO2 Inc. - lean . enterprise . middleware | wso2.com >> >> Mobile +94712756809 >> Blog alokayasoya.blogspot.com >> Abouthttp://about.me/thusithathilina >> >> > > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Xpath expression to fetch a property which has space in name
Hi Thusitha, I already tried that, but negative. On Mon, Mar 7, 2016 at 11:59 AM, Thusitha Thilina Dayaratne < thusit...@wso2.com> wrote: > Hi Udara, > > Did you tried replace the space with "_x0020_"? according to the [1] it > seems work for spaces > [1] - > *http://users.jackrabbit.apache.narkive.com/r9aFPfiI/xpath-query-with-space-in-node-name > <http://users.jackrabbit.apache.narkive.com/r9aFPfiI/xpath-query-with-space-in-node-name>* > > Thanks > On Mon, Mar 7, 2016 at 11:43 AM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> I am trying to fetch an property value from a json payload similar to >> below. >> { >> "Department": "ABC", >> "Employee Id": "123", >> "Work Email": "ud...@wso2.com" >> }, >> >> I could extract Department value by below xpath expression. >> >> >> >> However when I found difficulties when the property name contains an >> space in middle. I tried few options which were not successful. What is >> the correct way to escape space character. >> >> >> >> >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> web: http://udaraliyanage.wordpress.com >> phone: +94 71 443 6897 >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > Thusitha Dayaratne > Software Engineer > WSO2 Inc. - lean . enterprise . middleware | wso2.com > > Mobile +94712756809 > Blog alokayasoya.blogspot.com > Abouthttp://about.me/thusithathilina > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] Xpath expression to fetch a property which has space in name
Hi, I am trying to fetch an property value from a json payload similar to below. { "Department": "ABC", "Employee Id": "123", "Work Email": "ud...@wso2.com" }, I could extract Department value by below xpath expression. However when I found difficulties when the property name contains an space in middle. I tried few options which were not successful. What is the correct way to escape space character. -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Session Affinity in Kubernetes
Hi, I tried testing this with v1.1.2. You can access this still with this IP 192.168.58.228. At that time there were few problems with session affinity. *How I test:* I created a session variable and incremented it if session already exist. In addition printed the ip of the pod. My observation is count incremented from 0 to some number(sometime 10, sometime 50 and so on) as expected, but suddenly moved the requests to another pod. May session affinity works in latest version On Mon, Feb 29, 2016 at 10:42 AM, Imesh Gunaratne <im...@wso2.com> wrote: > Hi Nishadi, > > On Sun, Feb 28, 2016 at 11:58 PM, Nishadi Kirielle <nish...@wso2.com> > wrote: > >> Hi all, >> >> In order to test the session affinity in Kubernetes, I have deployed >> WordPress on a kubernetes cluster with several replicas and enabled the >> session affinity by setting service.spec.sessionAffinity to "ClientIP". >> When the kubernetes service is exposed through NodePort, I have tested the >> accuracy of session affinity using Apache bench mark for simple load >> testing. With a load of 1000 requests and a maximum of 2 requests running >> concurrently, all requests returned successfully without a failure. Thus >> the session affinity is functioning properly when the services are exposed >> via NodePort. >> > > Good work! Can you please elaborate how you verified session affinity in > the load test? > > Thanks > >> >> The next attempt is to test the session affinity with ingress API >> exposing the services. >> >> > Any feedback or suggestions are highly appreciated. >> >> Thanks >> >> -- >> *Nishadi Kirielle* >> *Software Engineering Intern* >> Mobile : +94 (0) 714722148 >> Blog : http://nishadikirielle.blogspot.com/ >> nish...@wso2.comm >> > > > > -- > *Imesh Gunaratne* > Senior Technical Lead > WSO2 Inc: http://wso2.com > T: +94 11 214 5345 M: +94 77 374 2057 > W: http://imesh.io > Lean . Enterprise . Middleware > > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] create tenant via rest api
On Fri, Feb 26, 2016 at 3:35 AM, John Q <johnq3...@gmail.com> wrote: > Hello everyone, > > I am wondering if there is a rest api for carbon to create tenants? > > I saw that private paas have a rest api for creating tenant, but i only > have installed , wso2is, wso2am and wso2esb and don't use the private paas. > Hi Private PaaS has a REST API for creating tenant [1] . It also call org.wso2.carbon.tenant.mgt admin services eventually. [1] https://github.com/apache/stratos/blob/master/components/org.apache.stratos.rest.endpoint/src/main/java/org/apache/stratos/rest/endpoint/api/StratosApiV41.java#L1511 > > If there is such api please where can i find it? > > Thanks, > John > > > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] create separate log4j log file for proxy service in ESB
Hi Akila, Yes, you need to restart to see the changes in log4j.properties file. However you can change logging by following [1] where you don't need to restart server. [1] https://docs.wso2.com/display/ESB490/Setting+Up+Logging On Wed, Feb 24, 2016 at 1:36 PM, Udara Liyanage <ud...@wso2.com> wrote: > Hi Akila, > > Yes, you need to restart to see the changes in log4j.properties file. > However you can change logging by following [1] where you don't need to > restart server. > > [1] https://docs.wso2.com/display/ESB490/Setting+Up+Logging > > On Wed, Feb 24, 2016 at 1:31 PM, Akila Nimantha [IT/EKO/LOITS] < > aki...@lolctech.com> wrote: > >> Hi all, >> >> >> >> Do I need to restart ESB server after changing log4j.properties file??? >> >> >> >> What I want to do is to stop logs in the wso2carbon.log file and create a >> separate log file for a specific proxy service. >> >> >> >> What I did was added below lines to the log4j file, >> >> >> >> log4j.category.SERVICE_LOGGER.TestService =INFO, PROXY_APPENDER >> >> log4j.additivity.SERVICE_LOGGER.TestService=false >> >> log4j.appender.PROXY_APPENDER=org.apache.log4j.DailyRollingFileAppender >> >> >> log4j.appender.PROXY_APPENDER.File=${carbon.home}/repository/logs/${instance.log}/TestService${instance.log}.log >> >> log4j.appender.PROXY_APPENDER.Append=true >> >> log4j.appender.PROXY_APPENDER.layout=org.apache.log4j.PatternLayout >> >> log4j.appender.PROXY_APPENDER.layout.ConversionPattern=%d{HH:mm:ss,SSS} >> [%X{ip}-%X{host}] [%t] %5p %c{1} %m% >> >> >> >> Regards, >> >> Akila Rathnayake >> >> >> >> This message (including any attachments) is intended only for the use of >> the individual or entity to which it is addressed and may contain >> information that is non-public, proprietary, privileged, confidential, and >> exempt from disclosure under applicable law or may constitute as attorney >> work product. If you are not the intended recipient, you are hereby >> notified that any use, dissemination, distribution, or copying of this >> communication is strictly prohibited. If you have received this >> communication in error, notify us immediately by telephone and (i) destroy >> this message if a facsimile or (ii) delete this message immediately if this >> is an electronic communication. Thank you. >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [msf4j] Get XML output
Hi, I used below annotations in order to get a xml output. @Produces({"application/xml, 'text/xml"}) But instead, it output was "org.example.service.CustomerService$Customer@3289ca5". How do we get a xml output rather than Json output. -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [APIM] Which rest api implementation is correct
Hi, There are two similar rest api implementations within [1]. Seems 1st one is the correct one. Seems second one is removed from room pom. Is n't it better to remove it, otherwise it will leads to confusions. [1] org.wso2.carbon.apimgt.rest.api.publisher [2] org.wso2.carbon.apimgt.rest.api [1] https://github.com/wso2/carbon-apimgt -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] How can I get public key certificate
Hi, Have a look at extractAppIdFromIdToken funtion of [1] [1] https://github.com/apache/stratos/blob/master/components/org.apache.stratos.metadata.service/src/main/java/org/apache/stratos/metadata/service/handlers/OAuthHandler.java On Thu, Jan 14, 2016 at 3:07 PM, Godwin Shrimal <god...@wso2.com> wrote: > Hi Pramod, > > You can use Signature class to verify signature. Please see below code > snippet. > > java.security.Signature signature = > java.security.Signature.getInstance("SHA1withRSA"); > signature.initVerify(publicKey); > signature.verify(signature) > > Thanks > Godwin > > > > On Thu, Jan 14, 2016 at 2:51 PM, Pramod Thakur <sendpra...@gmail.com> > wrote: > >> Hi Godwin, >> >> Thanks for the reply, >> >> Then how can I validate the jwt token that is generated by the wso2 in >> the client. >> >> I need to validate the signature of jwt token generated by Wso2 using the >> public key. >> >> >> >> >> >> On Thu, Jan 14, 2016 at 2:39 PM, Godwin Shrimal <god...@wso2.com> wrote: >> >>> Hi Pramod, >>> >>> We keep only supper tenant keystore in the physical file system and >>> tenant keystores stores in registry. You can get the public certificate for >>> the specific tenant using KeyStoreManager class. Please see below code >>> snippet. >>> >>> KeyStoreManager.getInstance(tenantId).getDefaultPublicKey() >>> >>> >>> Thanks >>> Godwin >>> >>> >>> On Thu, Jan 14, 2016 at 1:20 PM, Harshan Liyanage <hars...@wso2.com> >>> wrote: >>> >>>> Hi Pramod, >>>> >>>> We are storing the public certificate file in wso2carbon.jks keystore. >>>> You can find it in /repository/resources/security directory. >>>> Refer to [1] for obtaining the certificate. For example you can use the >>>> following command to get the public certificate. Keystore password will be >>>> wso2carbon. >>>> >>>> keytool -export -keystore wso2carbon.jks -alias wso2carbon -file >>>> public_cert.cer >>>> >>>> [1]. >>>> https://docs.oracle.com/javase/tutorial/security/toolsign/step5.html >>>> [2]. https://docs.wso2.com/display/Carbon420/Keystores >>>> >>>> Thanks, >>>> >>>> Harshan Liyanage >>>> Software Engineer >>>> Mobile: *+94724423048* >>>> Email: hars...@wso2.com >>>> Blog : http://harshanliyanage.blogspot.com/ >>>> *WSO2, Inc. :** wso2.com <http://wso2.com/>* >>>> lean.enterprise.middleware. >>>> >>>> On Thu, Jan 14, 2016 at 1:02 PM, Pramod Thakur <sendpra...@gmail.com> >>>> wrote: >>>> >>>>> Hi, >>>>> >>>>> How can I get public key certificate to validate JWT token signature >>>>> in wso2 Api Manager for tenant. >>>>> >>>>> The problem I am facing is,I couldn't get the public certificate in >>>>> the physical directory but wso2 is managing to sign the token, I couldn't >>>>> get how. >>>>> >>>>> On Thu, Jan 14, 2016 at 12:57 PM, Pramod Thakur <sendpra...@gmail.com> >>>>> wrote: >>>>> >>>>>> Hi, >>>>>> >>>>>> How can I get public key certificate to validate JWT token in wso2 >>>>>> Api Manager for tenant in the client endpoint. >>>>>> >>>>>> The problem i am facing is, i couldn't get the public certificate in >>>>>> the physical directory but wso2 is managing to sign the token, i couldn't >>>>>> get how. >>>>>> >>>>>> >>>>>> -- >>>>>> * Regards* >>>>>> * Pramod Thakur* >>>>>> * 9980422825* >>>>>> * Thank you.* >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>> >>>>> >>>>> -- >>>>> * Regards* >>>>> * Pramod Thakur* >>>>> * 9980422825* >>>>> * Thank you.* >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> ___ >>>>> Dev mailing list >>>>> Dev@wso2.org >>>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>>> >>>>> >>>> >>>> ___ >>>> Dev mailing list >>>> Dev@wso2.org >>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>> >>>> >>> >>> >>> -- >>> *Godwin Amila Shrimal* >>> Senior Software Engineer >>> WSO2 Inc.; http://wso2.com >>> lean.enterprise.middleware >>> >>> mobile: *+94772264165* >>> linkedin: *http://lnkd.in/KUum6D <http://lnkd.in/KUum6D>* >>> twitter: https://twitter.com/godwinamila >>> >> >> >> >> -- >> * Regards* >> * Pramod Thakur* >> * 9980422825* >> * Thank you.* >> >> >> >> >> >> > > > -- > *Godwin Amila Shrimal* > Senior Software Engineer > WSO2 Inc.; http://wso2.com > lean.enterprise.middleware > > mobile: *+94772264165* > linkedin: *http://lnkd.in/KUum6D <http://lnkd.in/KUum6D>* > twitter: https://twitter.com/godwinamila > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [VOTE] Release WSO2 Microservices Server 1.0.0 RC2
Hi, I get following error when I tried building hello world sample inside the product. Is this a known issue? Non-resolvable parent POM for org.wso2.carbon.mss.sample:helloworld:[unknown-version]: Could not find artifact org.wso2.carbon.mss:mss-lite-parent:pom:1.0.0 in central ( https://repo.maven.apache.org/maven2) and 'parent.relativePath' points at wrong local POM @ line 22, column 13 On Wed, Jan 6, 2016 at 3:29 PM, Samiyuru Senarathne <samiy...@wso2.com> wrote: > Hi Devs, > > This is the 2nd Release Candidate of WSO2 Microservices Server 1.0.0. > > Please download, test the product and vote. > > *Source and binary distribution files:* > https://github.com/wso2/product-mss/releases/tag/v1.0.0-RC2 > <https://www.google.com/url?q=https%3A%2F%2Fgithub.com%2Fwso2%2Fproduct-mss%2Freleases%2Ftag%2Fv1.0.0-RC2=D=1=AFQjCNEPlH9995oXWdOhW8f6_PUmLlt0cw> > > *Maven staging repository:* > http://maven.wso2.org/nexus/content/repositories/orgwso2carbonmss-274 > > *The tag to be voted upon:* > *https://github.com/wso2/product-mss/tree/v1.0.0-RC2 > <https://github.com/wso2/product-mss/tree/v1.0.0-RC2>* > > > [ ] Broken - do not release (explain why) > [ ] Stable - go ahead and release > > Note: Since the artifacts that have to be uploaded to the maven central > are not yet uploaded please make sure to first build the project from the > source in order to make all artifacts available in the maven local > repository. > > Thank you, > Carbon Team > > -- > Samiyuru Senarathne > *Software Engineer* > Mobile : +94 (0) 71 134 6087 > samiy...@wso2.com > > _______ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [Private PaaS][Docs] Different java versions in prerequisites and samples
Hi, Java 8 or 7 is recommended as prerequisites [1] , but the sample in [2] Setting up JAVA_HOME is with Java 6 [1] https://docs.wso2.com/display/PP411/Installation+Prerequisites [2] https://docs.wso2.com/display/PP411/Installing+on+Linux+or+OS+X -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] HTTPS REST Client
Hi, As Isuru mentioned better to use an already implemented library as it provides more functions. Plus use an appropriate ConnectionManager, as I remember default connection manager allows only 2 concurrent requests. You will find a sample that is implemented in Stratos [1] [1] https://github.com/apache/stratos/blob/master/components/org.apache.stratos.metadata.client/src/main/java/org/apache/stratos/metadata/client/rest/DefaultRestClient.java On Thu, Dec 17, 2015 at 9:31 AM, Dharshana Warusavitharana < dharsha...@wso2.com> wrote: > Hi Malmee, > > The SSL issue comes with the rest client is because you are going to > invoke HTTPS backend with out proper certificate in path. > > you can set keys to the system path using following > > String trustStore = System.getProperty("carbon.home") + File.separator + > "repository" + File.separator + > "resources" + File.separator + "security" + > File.separator + "wso2carbon.jks"; > System.setProperty("javax.net.ssl.trustStore", trustStore); > System.setProperty("javax.net.ssl.trustStorePassword", "wso2carbon"); > System.setProperty("javax.net.ssl.trustStoreType", "JKS"); > > > In this sample WSO2 carbon keys set as keys to the system path you can use > the same. > > Apache HTTP client is bit old client instead you can try some thing like > JAX-RS 2 or RestEasy client. > > In All these clients you need to add above code segment to export keys to > call secured HTTP call. > > > Thank you, > > Dharshana. > > > On Wed, Dec 16, 2015 at 8:56 PM, Isuru Haththotuwa <isu...@wso2.com> > wrote: > >> Hi Malmee, >> >> If you have used java built in methods, that would mean your tool would >> not be required to depend on an external library such as Apache HTTP client >> as you have mentioned. This is fine for a simple use case. However, please >> note if you need more functionality, such as support for all HTTP >> operations, and other capabilities, etc. it would be advisable to use >> Apache HTTP client or any other suitable existing library without >> implementing it again by yourself. >> >> For the certificate issue that you are getting, its possible to override >> the default certificate validation mechanism and plug in your own >> implementation which can disable certificate validation (for testing >> purposes). For HTTP Client 4, please see [1]. >> >> [1]. >> http://stackoverflow.com/questions/2703161/how-to-ignore-ssl-certificate-errors-in-apache-httpclient-4-0 >> >> On Wed, Dec 16, 2015 at 8:29 PM, Malmee Weerasinghe <mal...@wso2.com> >> wrote: >> >>> Hi All, >>> >>> We have developed a HTTPS REST client using java in-built methods which >>> works properly. [1] This method is configured to allow self signed >>> certificates. >>> >>> When using apache http client we get a certificate error : >>> javax.net.ssl.SSLPeerUnverifiedException: Host name '192.168.30.227' >>> does not match the certificate subject provided by the peer (CN=localhost, >>> O=WSO2, L=Mountain View, ST=CA, C=US). >>> >>> What would be a good choice? Using apache HTTP client or java in built >>> methods. Your suggestions are highly appreciated. >>> >>> [1] >>> https://github.com/nishadi/product-private-paas/blob/master/tools/migration/ppaas-artifact-converter/src/main/java/org/wso2/ppaas/tools/artifactmigration/RestClient.java >>> >>> -- >>> Malmee Weerasinghe >>> WSO2 Intern >>> mobile : (+94)* 71 7601905* | email : <dehan.vith...@aiesec.net> >>> mal...@wso2.com >>> >>> ___ >>> Dev mailing list >>> Dev@wso2.org >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> Thanks and Regards, >> >> Isuru H. >> +94 716 358 048* <http://wso2.com/>* >> >> >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > > Dharshana Warusavitharana > Senior Software Engineer , Test Automation > WSO2 Inc. http://wso2.com > email : dharsha...@wso2.com <dharsha...@wso2.com> > Tel : +94 11 214 5345 > Fax :+94 11 2145300 > cell : +94770342233 > blog : http://dharshanaw.blogspot.com > > lean . enterprise . middleware > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] EC2 clustering guide- Security group name or ID
Hi, EC2 only allows creating security group with the same name in different regions, not in the same region. In that case it won't be an issue. Thanks Azeez for pointing this. On Wed, Nov 18, 2015 at 10:15 AM, Udara Liyanage <ud...@wso2.com> wrote: > Hi, > > Ec2 clustering guide ask for the name of the security group for > configuration. I tried this and it works. > > However should the members discovered by security group id rather than > name. Because AFAIK we can create two security groups with the same name, > but different rules. > > [1] > https://docs.wso2.com/display/CLUSTER420/Setting+up+a+Cluster+in+AWS+Mode > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] EC2 clustering guide- Security group name or ID
Hi, Ec2 clustering guide ask for the name of the security group for configuration. I tried this and it works. However should the members discovered by security group id rather than name. Because AFAIK we can create two security groups with the same name, but different rules. [1] https://docs.wso2.com/display/CLUSTER420/Setting+up+a+Cluster+in+AWS+Mode -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] BAM cron job shedule less below one minute
Hi, As mentioned in docs, smallest time gap a cron job can be is 1 minute. However when I set below as cron expression it seems to run the cron job every 30 second. Is this expected behavior? 0/30 * * * * * However according to quartz docs [1], it supports seconds too. [1] http://www.quartz-scheduler.org/documentation/quartz-2.x/tutorials/tutorial-lesson-06 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] APIM- Gateway environments
Hi, We could debug and find the root cause. Thrift server in APIM1 was bound to local interface. So APIM1 could not connect to it. Do we have a configuration to say thrift server to bind to 0.0.0.0 instead of local interface. On Tue, Sep 22, 2015 at 9:46 PM, Malintha Adikari <malin...@wso2.com> wrote: > Hi Udara, > > I faced the same problem and ended up with the error message you have > mentioned above. In my case I have enabled dep-sync in both gateway nodes > and used WSClient client type. There was a configuration issue in my > dep-sync configuration and it was the root cause for my issue. Have you > enabled dep-sync in gateway nodes in your deployment ? If you have enabled > dep-sync , you can cleanup existing artifacts and retry if possible. > > Regards, > Malintha > > On Wed, Sep 23, 2015 at 8:48 AM, Amila De Silva <ami...@wso2.com> wrote: > >> Hi Udara, >> >> What is the client type you are using? Can you switch it to WSClient and >> check. >> >> >> On Wednesday, September 23, 2015, Udara Liyanage <ud...@wso2.com> wrote: >> >>> Hi Ajith, >>> >>> APIM2 is only acting as a gateway. The only difference to have two >>> distributed gateways[1]is when APIs are created in API1, it should be >>> available in APIM2 too. >>> >>> [1] https://docs.wso2.com/display/CLUSTER420/Clustering+API+Manager >>> >>> On Tue, Sep 22, 2015 at 1:15 PM, Ajith Vitharana <aji...@wso2.com> >>> wrote: >>> >>>> If you have created the API from APIM1 , then API meta data has stored >>>> in APIM1 databases (registry and AM db). AFAIU you need to share the >>>> databases (registry and AM db) with APIM2 >>>> >>>> -Ajith >>>> >>>> On Tue, Sep 22, 2015 at 4:04 PM, Udara Liyanage <ud...@wso2.com> wrote: >>>> >>>>> Hi, >>>>> >>>>> [1] I am trying to do what described in [1]. I have two APIMs in two >>>>> regions. >>>>> >>>>> In APIM1 , I added second APIM as an environment. >>>>> >>>>> >>>>> Gateway B >>>>> https://apim2.com:9443/services/ >>>>> >>>>> admin >>>>> admin >>>>> http://apim2.com:8280, >>>>> https://apim2.com:8243 >>>>> >>>>> >>>>> >>>>> In APIM2 , I pointed APIM as the Key manager. >>>>> >>>>> >>>>> https://apim1:9443/services/ >>>>> admin >>>>> admin >>>>> >>>>> Now when I create an API in APIM, artifacts are successfully published >>>>> to APIM2 too as expected. I manually check the artifacts and both has the >>>>> same API artifacts. >>>>> >>>>> Then I tried accessing the API from APIM1 which got succeeded. >>>>> However when I try to access the API from APIM2, I get the following >>>>> error message >>>>> >>>>> *No matching resource found in the API for the given >>>>> requestAccess failure for API: /sample/v1, >>>>> version: v1 with key: c0dca4351fa3f074cd52a6087409743. Check the API >>>>> documentation and add a proper REST resource path to the invocation URL* >>>>> >>>>> *[1] * >>>>> https://docs.wso2.com/display/AM170/Maintaining+Separate+Production+and+Sandbox+Gateways >>>>> -- >>>>> >>>>> Udara Liyanage >>>>> Software Engineer >>>>> WSO2, Inc.: http://wso2.com >>>>> lean. enterprise. middleware >>>>> >>>>> web: http://udaraliyanage.wordpress.com >>>>> phone: +94 71 443 6897 >>>>> >>>> >>>> >>>> >>>> -- >>>> Ajith Vitharana. >>>> >>>> WSO2 Inc. - http://wso2.com >>>> Email : aji...@wso2.com >>>> Blog: http://vitharana.org >>>> Mobile : +1-812-360-5335 >>>> >>>> >>> >>> >>> -- >>> >>> Udara Liyanage >>> Software Engineer >>> WSO2, Inc.: http://wso2.com >>> lean. enterprise. middleware >>> >>> web: http://udaraliyanage.wordpress.com >>> phone: +94 71 443 6897 >>> >> >> >> -- >> *Amila De Silva* >> >> WSO2 Inc. >> mobile :(+94) 775119302 >> >> >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > *Malintha Adikari* > Software Engineer > WSO2 Inc.; http://wso2.com > lean.enterprise.middleware > > Mobile: +94 71 2312958 > Blog:http://malinthas.blogspot.com > Page: http://about.me/malintha > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] APIM- Gateway environments
Hi, Issue solved when I changed from localhost =>0.0.0.0 0.0.0.0 Thanks Nuwan and Amila. On Wed, Sep 23, 2015 at 9:40 AM, Udara Liyanage <ud...@wso2.com> wrote: > Hi, > > We could debug and find the root cause. Thrift server in APIM1 was bound > to local interface. So APIM1 could not connect to it. > Do we have a configuration to say thrift server to bind to 0.0.0.0 instead > of local interface. > > > On Tue, Sep 22, 2015 at 9:46 PM, Malintha Adikari <malin...@wso2.com> > wrote: > >> Hi Udara, >> >> I faced the same problem and ended up with the error message you have >> mentioned above. In my case I have enabled dep-sync in both gateway nodes >> and used WSClient client type. There was a configuration issue in my >> dep-sync configuration and it was the root cause for my issue. Have you >> enabled dep-sync in gateway nodes in your deployment ? If you have enabled >> dep-sync , you can cleanup existing artifacts and retry if possible. >> >> Regards, >> Malintha >> >> On Wed, Sep 23, 2015 at 8:48 AM, Amila De Silva <ami...@wso2.com> wrote: >> >>> Hi Udara, >>> >>> What is the client type you are using? Can you switch it to WSClient and >>> check. >>> >>> >>> On Wednesday, September 23, 2015, Udara Liyanage <ud...@wso2.com> wrote: >>> >>>> Hi Ajith, >>>> >>>> APIM2 is only acting as a gateway. The only difference to have two >>>> distributed gateways[1]is when APIs are created in API1, it should be >>>> available in APIM2 too. >>>> >>>> [1] https://docs.wso2.com/display/CLUSTER420/Clustering+API+Manager >>>> >>>> On Tue, Sep 22, 2015 at 1:15 PM, Ajith Vitharana <aji...@wso2.com> >>>> wrote: >>>> >>>>> If you have created the API from APIM1 , then API meta data has stored >>>>> in APIM1 databases (registry and AM db). AFAIU you need to share the >>>>> databases (registry and AM db) with APIM2 >>>>> >>>>> -Ajith >>>>> >>>>> On Tue, Sep 22, 2015 at 4:04 PM, Udara Liyanage <ud...@wso2.com> >>>>> wrote: >>>>> >>>>>> Hi, >>>>>> >>>>>> [1] I am trying to do what described in [1]. I have two APIMs in two >>>>>> regions. >>>>>> >>>>>> In APIM1 , I added second APIM as an environment. >>>>>> >>>>>> >>>>>> Gateway B >>>>>> https://apim2.com:9443/services/ >>>>>> >>>>>> admin >>>>>> admin >>>>>> http://apim2.com:8280, >>>>>> https://apim2.com:8243 >>>>>> >>>>>> >>>>>> >>>>>> In APIM2 , I pointed APIM as the Key manager. >>>>>> >>>>>> >>>>>> https://apim1:9443/services/ >>>>>> admin >>>>>> admin >>>>>> >>>>>> Now when I create an API in APIM, artifacts are successfully >>>>>> published to APIM2 too as expected. I manually check the artifacts and >>>>>> both >>>>>> has the same API artifacts. >>>>>> >>>>>> Then I tried accessing the API from APIM1 which got succeeded. >>>>>> However when I try to access the API from APIM2, I get the following >>>>>> error message >>>>>> >>>>>> *No matching resource found in the API for the given >>>>>> requestAccess failure for API: /sample/v1, >>>>>> version: v1 with key: c0dca4351fa3f074cd52a6087409743. Check the API >>>>>> documentation and add a proper REST resource path to the invocation URL* >>>>>> >>>>>> *[1] * >>>>>> https://docs.wso2.com/display/AM170/Maintaining+Separate+Production+and+Sandbox+Gateways >>>>>> -- >>>>>> >>>>>> Udara Liyanage >>>>>> Software Engineer >>>>>> WSO2, Inc.: http://wso2.com >>>>>> lean. enterprise. middleware >>>>>> >>>>>> web: http://udaraliyanage.wordpress.com >>>>>> phone: +94 71 443 6897 >>>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> Ajith Vitharana. >>>>> >>>>> WSO2 Inc. - http://wso2.com >>>>> Email : aji...@wso2.com >>>>> Blog: http://vitharana.org >>>>> Mobile : +1-812-360-5335 >>>>> >>>>> >>>> >>>> >>>> -- >>>> >>>> Udara Liyanage >>>> Software Engineer >>>> WSO2, Inc.: http://wso2.com >>>> lean. enterprise. middleware >>>> >>>> web: http://udaraliyanage.wordpress.com >>>> phone: +94 71 443 6897 >>>> >>> >>> >>> -- >>> *Amila De Silva* >>> >>> WSO2 Inc. >>> mobile :(+94) 775119302 >>> >>> >>> >>> ___ >>> Dev mailing list >>> Dev@wso2.org >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> *Malintha Adikari* >> Software Engineer >> WSO2 Inc.; http://wso2.com >> lean.enterprise.middleware >> >> Mobile: +94 71 2312958 >> Blog:http://malinthas.blogspot.com >> Page: http://about.me/malintha >> > > > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] APIM- Gateway environments
Hi, [1] I am trying to do what described in [1]. I have two APIMs in two regions. In APIM1 , I added second APIM as an environment. Gateway B https://apim2.com:9443/services/ admin admin http://apim2.com:8280, https://apim2.com:8243 In APIM2 , I pointed APIM as the Key manager. https://apim1:9443/services/ admin admin Now when I create an API in APIM, artifacts are successfully published to APIM2 too as expected. I manually check the artifacts and both has the same API artifacts. Then I tried accessing the API from APIM1 which got succeeded. However when I try to access the API from APIM2, I get the following error message *No matching resource found in the API for the given requestAccess failure for API: /sample/v1, version: v1 with key: c0dca4351fa3f074cd52a6087409743. Check the API documentation and add a proper REST resource path to the invocation URL* *[1] * https://docs.wso2.com/display/AM170/Maintaining+Separate+Production+and+Sandbox+Gateways -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] APIM- Gateway environments
Hi Ajith, APIM2 is only acting as a gateway. The only difference to have two distributed gateways[1]is when APIs are created in API1, it should be available in APIM2 too. [1] https://docs.wso2.com/display/CLUSTER420/Clustering+API+Manager On Tue, Sep 22, 2015 at 1:15 PM, Ajith Vitharana <aji...@wso2.com> wrote: > If you have created the API from APIM1 , then API meta data has stored in > APIM1 databases (registry and AM db). AFAIU you need to share the > databases (registry and AM db) with APIM2 > > -Ajith > > On Tue, Sep 22, 2015 at 4:04 PM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> [1] I am trying to do what described in [1]. I have two APIMs in two >> regions. >> >> In APIM1 , I added second APIM as an environment. >> >> >> Gateway B >> https://apim2.com:9443/services/ >> >> admin >> admin >> http://apim2.com:8280, >> https://apim2.com:8243 >> >> >> >> In APIM2 , I pointed APIM as the Key manager. >> >> >> https://apim1:9443/services/ >> admin >> admin >> >> Now when I create an API in APIM, artifacts are successfully published to >> APIM2 too as expected. I manually check the artifacts and both has the same >> API artifacts. >> >> Then I tried accessing the API from APIM1 which got succeeded. >> However when I try to access the API from APIM2, I get the following >> error message >> >> *No matching resource found in the API for the given >> requestAccess failure for API: /sample/v1, >> version: v1 with key: c0dca4351fa3f074cd52a6087409743. Check the API >> documentation and add a proper REST resource path to the invocation URL* >> >> *[1] * >> https://docs.wso2.com/display/AM170/Maintaining+Separate+Production+and+Sandbox+Gateways >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> web: http://udaraliyanage.wordpress.com >> phone: +94 71 443 6897 >> > > > > -- > Ajith Vitharana. > > WSO2 Inc. - http://wso2.com > Email : aji...@wso2.com > Blog: http://vitharana.org > Mobile : +1-812-360-5335 > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] APIM showing subscription details even after subscription is removed
Hi, Thanks for the info. On Tue, Sep 15, 2015 at 6:36 PM, Madusanka Premaratne <madusan...@wso2.com> wrote: > Hi Udara, > The consumer key secret pair is generated against the oauth app you select > while subscribing. After removing the subscription, only the subscribed api > wii be removed from subscribed APIs (at the bottom of the screenshot) > You may see the drop down "Applications with Subscriptions" in the top of > the subscription page. When you change the app there, the consumer_key, > consumer_secret and access_token changes accordingly. If you delete the > particular app only you will be able to delete those info. > > Thanks, > Madusanka > > > On Wed, Sep 16, 2015 at 12:08 AM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> 1) Create an API in publisher >> 2) Subscribe to the API >> 3) Generate keys - UI will show the generated keys >> 4) Now remove the subscription - Still the earlier subscription >> details(including) keys are shown. I guess it should n't ? >> >> Attached a screenshot. >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> web: http://udaraliyanage.wordpress.com >> phone: +94 71 443 6897 >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > *Madusanka Premaratne* | Associate Software Engineer > WSO2, Inc | lean. enterprise. middleware. > #20, Palm Grove, Colombo 03, Sri Lanka > Mobile: +94 71 835 70 73| Work: +94 112 145 345 > Email: madusan...@wso2.com | Web: www.wso2.com > > [image: Facebook] <https://www.facebook.com/maduzanka> [image: Twitter] > <https://twitter.com/rmmpremaratne> [image: Google Plus] > <https://plus.google.com/u/0/+MadusankaPremaratnemaduz/about/p/pub> [image: > Linkedin] <http://lk.linkedin.com/in/madusanka/> [image: Instagram] > <http://instagram.com/madusankapremaratne> [image: Skype] > <http://@rmmpremaratne> > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] APIM showing subscription details even after subscription is removed
Hi, 1) Create an API in publisher 2) Subscribe to the API 3) Generate keys - UI will show the generated keys 4) Now remove the subscription - Still the earlier subscription details(including) keys are shown. I guess it should n't ? Attached a screenshot. -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [APIM] Timeout error when creating APIs using APIM 1.9.0 REST API
Hi Nuwan, Could you please point me to the test case location, me too is looking for a similar sample. On Fri, Sep 11, 2015 at 3:39 PM, Nuwan Wimalasekara <nuw...@wso2.com> wrote: > Hi Udara, > > In APIM integration test, HTTP endpoint is used to call the > RestAPI(Publisher and Store) and It is working fine without any issue. This > should work > > Thanks, > Nuwanw > > On Fri, Sep 11, 2015 at 9:41 AM, Nuwan Dias <nuw...@wso2.com> wrote: > >> They run on HTTPS only. If you send an http request, it automatically >> redirects to https. >> >> On Fri, Sep 11, 2015 at 8:46 AM, Udara Liyanage <ud...@wso2.com> wrote: >> >>> Hi, >>> >>> I could create APIs by changing to port 9443 and protocol to HTTPS. >>> However why does REST APIs runs on HTTP? >>> >>> curl -X POST -c cookies >>> https://localhost:9443/publisher/site/blocks/user/login/ajax/login.jag >>> -d 'action=login=admin=admin' -k >>> >>> >>> curl -b cookies -k >>> https://localhost:9443/publisher/site/blocks/item-add/ajax/add.jag -d >>> "action=addAPI=PhoneVerification=/phoneverify=1.0.0=public==Verify >>> a phone >>> number=phone,mobile,multimedia=nonsecured===Gold,Bronze_checked=http_checked=https=0=GET=Application=Unlimited=/*_version_checked=default_version=xx= >>> x...@ee.com=xx=g...@ww.com" >>> -d'endpoint_config={"production_endpoints":{"url":" >>> http://ws.cdyne.com/phoneverify/phoneverify.asmx","config":null},"endpoint_type":"http >>> "}'; >>> >>> On Fri, Sep 11, 2015 at 4:18 AM, Udara Liyanage <ud...@wso2.com> wrote: >>> >>>> Hi, >>>> >>>> I got this error while trying the sample Add API command mentioned in >>>> the doc <https://docs.wso2.com/display/AM190/Publisher+APIs>. No >>>> backend error is displayed, any idea? >>>> >>>> >>>> $ curl -X POST -c cookies >>>> http://localhost:9763/publisher/site/blocks/user/login/ajax/login.jag >>>> -d 'action=login=admin=admin' >>>> {"error" : false} >>>> >>>> >>>> $ curl -X POST -b cookies >>>> http://localhost:9763/publisher/site/blocks/item-add/ajax/add.jag -d >>>> "action=addAPI=PhoneVerification=/phoneverify=1.0.0=public==Verify >>>> a phone >>>> number=phone,mobile,multimedia=nonsecured=Gold,Bronze_checked=http_checked=https=0=GET=Application=Unlimited=/*_version_checked=default_version=xx= >>>> x...@ee.com=xx=g...@ww.com" >>>> -d'endpoint_config={"production_endpoints":{"url":" >>>> http://ws.cdyne.com/phoneverify/phoneverify.asmx >>>> ","config":null},"endpoint_type":"http"}'; >>>> {"error" : true, "message" : "*timeout*"} >>>> >>>> -- >>>> >>>> Udara Liyanage >>>> Software Engineer >>>> WSO2, Inc.: http://wso2.com >>>> lean. enterprise. middleware >>>> >>>> web: http://udaraliyanage.wordpress.com >>>> phone: +94 71 443 6897 >>>> >>> >>> >>> >>> -- >>> >>> Udara Liyanage >>> Software Engineer >>> WSO2, Inc.: http://wso2.com >>> lean. enterprise. middleware >>> >>> web: http://udaraliyanage.wordpress.com >>> phone: +94 71 443 6897 >>> >>> ___ >>> Dev mailing list >>> Dev@wso2.org >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> Nuwan Dias >> >> Technical Lead - WSO2, Inc. http://wso2.com >> email : nuw...@wso2.com >> Phone : +94 777 775 729 >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > Nuwan Wimalasekara > Senior Software Engineer - Test Automation > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > phone: +94 71 668 4620 > > > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [APIM] Timeout error when creating APIs using APIM 1.9.0 REST API
Hi, I got this error while trying the sample Add API command mentioned in the doc <https://docs.wso2.com/display/AM190/Publisher+APIs>. No backend error is displayed, any idea? $ curl -X POST -c cookies http://localhost:9763/publisher/site/blocks/user/login/ajax/login.jag -d 'action=login=admin=admin' {"error" : false} $ curl -X POST -b cookies http://localhost:9763/publisher/site/blocks/item-add/ajax/add.jag -d "action=addAPI=PhoneVerification=/phoneverify=1.0.0=public==Verify a phone number=phone,mobile,multimedia=nonsecured=Gold,Bronze_checked=http_checked=https=0=GET=Application=Unlimited=/*_version_checked=default_version=xx= x...@ee.com=xx=g...@ww.com" -d'endpoint_config={"production_endpoints":{"url":" http://ws.cdyne.com/phoneverify/phoneverify.asmx ","config":null},"endpoint_type":"http"}'; {"error" : true, "message" : "*timeout*"} -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [APIM] Timeout error when creating APIs using APIM 1.9.0 REST API
Hi, I still believe it is better the documentation sample to mention https if it is recommended. We can mention the http option if we wan so they have the choice. Further provided samples are not working for me when using http and 9763 On Fri, Sep 11, 2015 at 10:38 AM, Sanjeewa Malalgoda <sanje...@wso2.com> wrote: > Its recommend to login over https. No need to specifically say it. > Its well known thing and still users can choose http if need. > > Thanks, > sanjeewa. > > On Fri, Sep 11, 2015 at 10:14 AM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> It is not safe to send credentials in a http request (login), I think we >> need to update the docs to use https. >> >> On Fri, Sep 11, 2015 at 9:41 AM, Nuwan Dias <nuw...@wso2.com> wrote: >> >>> They run on HTTPS only. If you send an http request, it automatically >>> redirects to https. >>> >>> On Fri, Sep 11, 2015 at 8:46 AM, Udara Liyanage <ud...@wso2.com> wrote: >>> >>>> Hi, >>>> >>>> I could create APIs by changing to port 9443 and protocol to HTTPS. >>>> However why does REST APIs runs on HTTP? >>>> >>>> curl -X POST -c cookies >>>> https://localhost:9443/publisher/site/blocks/user/login/ajax/login.jag >>>> -d 'action=login=admin=admin' -k >>>> >>>> >>>> curl -b cookies -k >>>> https://localhost:9443/publisher/site/blocks/item-add/ajax/add.jag -d >>>> "action=addAPI=PhoneVerification=/phoneverify=1.0.0=public==Verify >>>> a phone >>>> number=phone,mobile,multimedia=nonsecured===Gold,Bronze_checked=http_checked=https=0=GET=Application=Unlimited=/*_version_checked=default_version=xx= >>>> x...@ee.com=xx=g...@ww.com" >>>> -d'endpoint_config={"production_endpoints":{"url":" >>>> http://ws.cdyne.com/phoneverify/phoneverify.asmx","config":null},"endpoint_type":"http >>>> "}'; >>>> >>>> On Fri, Sep 11, 2015 at 4:18 AM, Udara Liyanage <ud...@wso2.com> wrote: >>>> >>>>> Hi, >>>>> >>>>> I got this error while trying the sample Add API command mentioned in >>>>> the doc <https://docs.wso2.com/display/AM190/Publisher+APIs>. No >>>>> backend error is displayed, any idea? >>>>> >>>>> >>>>> $ curl -X POST -c cookies >>>>> http://localhost:9763/publisher/site/blocks/user/login/ajax/login.jag >>>>> -d 'action=login=admin=admin' >>>>> {"error" : false} >>>>> >>>>> >>>>> $ curl -X POST -b cookies >>>>> http://localhost:9763/publisher/site/blocks/item-add/ajax/add.jag -d >>>>> "action=addAPI=PhoneVerification=/phoneverify=1.0.0=public==Verify >>>>> a phone >>>>> number=phone,mobile,multimedia=nonsecured=Gold,Bronze_checked=http_checked=https=0=GET=Application=Unlimited=/*_version_checked=default_version=xx= >>>>> x...@ee.com=xx=g...@ww.com" >>>>> -d'endpoint_config={"production_endpoints":{"url":" >>>>> http://ws.cdyne.com/phoneverify/phoneverify.asmx >>>>> ","config":null},"endpoint_type":"http"}'; >>>>> {"error" : true, "message" : "*timeout*"} >>>>> >>>>> -- >>>>> >>>>> Udara Liyanage >>>>> Software Engineer >>>>> WSO2, Inc.: http://wso2.com >>>>> lean. enterprise. middleware >>>>> >>>>> web: http://udaraliyanage.wordpress.com >>>>> phone: +94 71 443 6897 >>>>> >>>> >>>> >>>> >>>> -- >>>> >>>> Udara Liyanage >>>> Software Engineer >>>> WSO2, Inc.: http://wso2.com >>>> lean. enterprise. middleware >>>> >>>> web: http://udaraliyanage.wordpress.com >>>> phone: +94 71 443 6897 >>>> >>>> ___ >>>> Dev mailing list >>>> Dev@wso2.org >>>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>>> >>>> >>> >>> >>> -- >>> Nuwan Dias >>> >>> Technical Lead - WSO2, Inc. http://wso2.com >>> email : nuw...@wso2.com >>> Phone : +94 777 775 729 >>> >> >> >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> web: http://udaraliyanage.wordpress.com >> phone: +94 71 443 6897 >> >> ___ >> 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/> > > > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [APIM] Timeout error when creating APIs using APIM 1.9.0 REST API
Hi, I could create APIs by changing to port 9443 and protocol to HTTPS. However why does REST APIs runs on HTTP? curl -X POST -c cookies https://localhost:9443/publisher/site/blocks/user/login/ajax/login.jag -d 'action=login=admin=admin' -k curl -b cookies -k https://localhost:9443/publisher/site/blocks/item-add/ajax/add.jag -d "action=addAPI=PhoneVerification=/phoneverify=1.0.0=public==Verify a phone number=phone,mobile,multimedia=nonsecured===Gold,Bronze_checked=http_checked=https=0=GET=Application=Unlimited=/*_version_checked=default_version=xx= x...@ee.com=xx=g...@ww.com" -d'endpoint_config={"production_endpoints":{"url":" http://ws.cdyne.com/phoneverify/phoneverify.asmx","config":null},"endpoint_type":"http "}'; On Fri, Sep 11, 2015 at 4:18 AM, Udara Liyanage <ud...@wso2.com> wrote: > Hi, > > I got this error while trying the sample Add API command mentioned in the > doc <https://docs.wso2.com/display/AM190/Publisher+APIs>. No backend > error is displayed, any idea? > > > $ curl -X POST -c cookies > http://localhost:9763/publisher/site/blocks/user/login/ajax/login.jag -d > 'action=login=admin=admin' > {"error" : false} > > > $ curl -X POST -b cookies > http://localhost:9763/publisher/site/blocks/item-add/ajax/add.jag -d > "action=addAPI=PhoneVerification=/phoneverify=1.0.0=public==Verify > a phone > number=phone,mobile,multimedia=nonsecured=Gold,Bronze_checked=http_checked=https=0=GET=Application=Unlimited=/*_version_checked=default_version=xx= > x...@ee.com=xx=g...@ww.com" > -d'endpoint_config={"production_endpoints":{"url":" > http://ws.cdyne.com/phoneverify/phoneverify.asmx > ","config":null},"endpoint_type":"http"}'; > {"error" : true, "message" : "*timeout*"} > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [APIM] Timeout error when creating APIs using APIM 1.9.0 REST API
Hi, It is not safe to send credentials in a http request (login), I think we need to update the docs to use https. On Fri, Sep 11, 2015 at 9:41 AM, Nuwan Dias <nuw...@wso2.com> wrote: > They run on HTTPS only. If you send an http request, it automatically > redirects to https. > > On Fri, Sep 11, 2015 at 8:46 AM, Udara Liyanage <ud...@wso2.com> wrote: > >> Hi, >> >> I could create APIs by changing to port 9443 and protocol to HTTPS. >> However why does REST APIs runs on HTTP? >> >> curl -X POST -c cookies >> https://localhost:9443/publisher/site/blocks/user/login/ajax/login.jag >> -d 'action=login=admin=admin' -k >> >> >> curl -b cookies -k >> https://localhost:9443/publisher/site/blocks/item-add/ajax/add.jag -d >> "action=addAPI=PhoneVerification=/phoneverify=1.0.0=public==Verify >> a phone >> number=phone,mobile,multimedia=nonsecured===Gold,Bronze_checked=http_checked=https=0=GET=Application=Unlimited=/*_version_checked=default_version=xx= >> x...@ee.com=xx=g...@ww.com" >> -d'endpoint_config={"production_endpoints":{"url":" >> http://ws.cdyne.com/phoneverify/phoneverify.asmx","config":null},"endpoint_type":"http >> "}'; >> >> On Fri, Sep 11, 2015 at 4:18 AM, Udara Liyanage <ud...@wso2.com> wrote: >> >>> Hi, >>> >>> I got this error while trying the sample Add API command mentioned in >>> the doc <https://docs.wso2.com/display/AM190/Publisher+APIs>. No >>> backend error is displayed, any idea? >>> >>> >>> $ curl -X POST -c cookies >>> http://localhost:9763/publisher/site/blocks/user/login/ajax/login.jag >>> -d 'action=login=admin=admin' >>> {"error" : false} >>> >>> >>> $ curl -X POST -b cookies >>> http://localhost:9763/publisher/site/blocks/item-add/ajax/add.jag -d >>> "action=addAPI=PhoneVerification=/phoneverify=1.0.0=public==Verify >>> a phone >>> number=phone,mobile,multimedia=nonsecured=Gold,Bronze_checked=http_checked=https=0=GET=Application=Unlimited=/*_version_checked=default_version=xx= >>> x...@ee.com=xx=g...@ww.com" >>> -d'endpoint_config={"production_endpoints":{"url":" >>> http://ws.cdyne.com/phoneverify/phoneverify.asmx >>> ","config":null},"endpoint_type":"http"}'; >>> {"error" : true, "message" : "*timeout*"} >>> >>> -- >>> >>> Udara Liyanage >>> Software Engineer >>> WSO2, Inc.: http://wso2.com >>> lean. enterprise. middleware >>> >>> web: http://udaraliyanage.wordpress.com >>> phone: +94 71 443 6897 >>> >> >> >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> web: http://udaraliyanage.wordpress.com >> phone: +94 71 443 6897 >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > Nuwan Dias > > Technical Lead - WSO2, Inc. http://wso2.com > email : nuw...@wso2.com > Phone : +94 777 775 729 > -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Private PaaS build fails with Stratos 412
Hi, Issue vanished after I install the newer mvn. Thanks Thanuja for looking into this. On Fri, Sep 4, 2015 at 10:07 AM, Imesh Gunaratne <im...@wso2.com> wrote: > Do you still see this issue? > > On Mon, Aug 31, 2015 at 6:19 PM, Udara Liyanage <ud...@wso2.com> wrote: > >> >> HI, >> >> With the intention of getting the latest Stratos, I build Stratos from >> 41x branch and changed Stratos version in PP to 412 and build PP. However I >> get the following error. Seems it tries to install 412-SNAPSHOT of RESTful >> admin services feature. >> >> >> Installing org.wso2.carbon.event.server.feature.group 4.2.1. >> Installing org.wso2.carbon.event.common.feature.group 4.2.0. >> Installing org.wso2.carbon.captcha.mgt.server.feature.group 4.2.0. >> Installing org.jaggeryjs.feature.group 0.0.0.0_9_0_ALPHA4_wso2v3. >> Installing caramel.feature.group 1.0.1. >> Installing org.wso2.store.feature.group 1.0.1. >> Installing org.wso2.carbon.idp.mgt.feature.group 4.2.3. >> Installing org.wso2.carbon.as.runtimes.cxf.feature.group 4.2.2. >> Installing org.wso2.carbon.user.mgt.feature.group 4.2.1. >> Installation failed. >> Cannot complete the install because of a conflicting dependency. >> Software being installed: Apache Stratos - RESTful admin services >> feature 4.1.2 (org.apache.stratos.rest.endpoint.feature.group 4.1.2) >> Software currently installed: Apache Stratos - RESTful admin services >> feature 4.1.2.SNAPSHOT (org.apache.stratos.rest.endpoint.feature.group >> 4.1.2.SNAPSHOT) >> Only one of the following can be installed at once: >> Apache Stratos - RESTful admin services feature 4.1.2 >> (org.apache.stratos.rest.endpoint.feature.jar 4.1.2) >> Apache Stratos - RESTful admin services feature 4.1.2.SNAPSHOT >> (org.apache.stratos.rest.endpoint.feature.jar 4.1.2.SNAPSHOT) >> Cannot satisfy dependency: >> From: Apache Stratos - RESTful admin services feature 4.1.2 >> (org.apache.stratos.rest.endpoint.feature.group 4.1.2) >> To: org.apache.stratos.rest.endpoint.feature.jar [4.1.2] >> Cannot satisfy dependency: >> From: Apache Stratos - RESTful admin services feature 4.1.2.SNAPSHOT >> (org.apache.stratos.rest.endpoint.feature.group 4.1.2.SNAPSHOT) >> To: org.apache.stratos.rest.endpoint.feature.jar [4.1.2.SNAPSHOT] >> Application failed, log file location: >> /home/udara/.m2/repository/org/eclipse/tycho/tycho-p2-runtime/0.13.0/eclipse/configuration/1440999235703.log >> >> [INFO] >> >> [INFO] Reactor Summary: >> [INFO] >> [INFO] WSO2 PPaaS - Parent ... SUCCESS [ >> 0.830 s] >> [INFO] WSO2 PPaaS - Cartridges ... SUCCESS [ >> 0.025 s] >> [INFO] WSO2 PPaaS - Cartridges - Template Modules SUCCESS [ >> 0.021 s] >> [INFO] WSO2 PPaaS - WSO2 AM 1.9.0 Template Module SUCCESS [ >> 0.457 s] >> [INFO] WSO2 PPaaS - WSO2 AS 5.2.1 Template Module SUCCESS [ >> 0.074 s] >> [INFO] WSO2 PPaaS - WSO2 ESB 4.8.1 Template Module ... SUCCESS [ >> 0.047 s] >> [INFO] WSO2 PPaaS - WSO2 IS 5.0.0 Template Module SUCCESS [ >> 0.050 s] >> [INFO] WSO2 PPaaS - Components ... SUCCESS [ >> 0.021 s] >> [INFO] WSO2 PPaaS - Python Configurator .. SUCCESS [ >> 0.082 s] >> [INFO] WSO2 PPaaS - Features . SUCCESS [ >> 0.024 s] >> [INFO] WSO2 PPaaS - Products . SUCCESS [ >> 0.020 s] >> [INFO] WSO2 PPaaS - Product .. SUCCESS [ >> 0.018 s] >> [INFO] WSO2 PPaaS - Profile Generation ... FAILURE [ >> 47.325 s] >> [INFO] WSO2 PPaaS - Product - Distribution ... SKIPPED >> [INFO] WSO2 Private PaaS - Integration Tests . SKIPPED >> [INFO] WSO2 PPaaS - Configurator - Product ... SKIPPED >> [INFO] WSO2 PPaaS - Extensions ... SKIPPED >> [INFO] WSO2 PPaaS - Carbon Extensions SKIPPED >> [INFO] WSO2 PPaaS - Carbon Extensions - Membership Scheme SKIPPED >> [INFO] >> >> [INFO] BUILD FAILURE >> [INFO] >> >> [INFO] Total time: 49.852 s >> [INFO] Finished at: 2015-08-31T11:04:01+05:30 >> [INFO] Final Memory: 30M/424M >> [INFO] >>
[Dev] Private PaaS build fails with Stratos 412
HI, With the intention of getting the latest Stratos, I build Stratos from 41x branch and changed Stratos version in PP to 412 and build PP. However I get the following error. Seems it tries to install 412-SNAPSHOT of RESTful admin services feature. Installing org.wso2.carbon.event.server.feature.group 4.2.1. Installing org.wso2.carbon.event.common.feature.group 4.2.0. Installing org.wso2.carbon.captcha.mgt.server.feature.group 4.2.0. Installing org.jaggeryjs.feature.group 0.0.0.0_9_0_ALPHA4_wso2v3. Installing caramel.feature.group 1.0.1. Installing org.wso2.store.feature.group 1.0.1. Installing org.wso2.carbon.idp.mgt.feature.group 4.2.3. Installing org.wso2.carbon.as.runtimes.cxf.feature.group 4.2.2. Installing org.wso2.carbon.user.mgt.feature.group 4.2.1. Installation failed. Cannot complete the install because of a conflicting dependency. Software being installed: Apache Stratos - RESTful admin services feature 4.1.2 (org.apache.stratos.rest.endpoint.feature.group 4.1.2) Software currently installed: Apache Stratos - RESTful admin services feature 4.1.2.SNAPSHOT (org.apache.stratos.rest.endpoint.feature.group 4.1.2.SNAPSHOT) Only one of the following can be installed at once: Apache Stratos - RESTful admin services feature 4.1.2 (org.apache.stratos.rest.endpoint.feature.jar 4.1.2) Apache Stratos - RESTful admin services feature 4.1.2.SNAPSHOT (org.apache.stratos.rest.endpoint.feature.jar 4.1.2.SNAPSHOT) Cannot satisfy dependency: From: Apache Stratos - RESTful admin services feature 4.1.2 (org.apache.stratos.rest.endpoint.feature.group 4.1.2) To: org.apache.stratos.rest.endpoint.feature.jar [4.1.2] Cannot satisfy dependency: From: Apache Stratos - RESTful admin services feature 4.1.2.SNAPSHOT (org.apache.stratos.rest.endpoint.feature.group 4.1.2.SNAPSHOT) To: org.apache.stratos.rest.endpoint.feature.jar [4.1.2.SNAPSHOT] Application failed, log file location: /home/udara/.m2/repository/org/eclipse/tycho/tycho-p2-runtime/0.13.0/eclipse/configuration/1440999235703.log [INFO] [INFO] Reactor Summary: [INFO] [INFO] WSO2 PPaaS - Parent ... SUCCESS [ 0.830 s] [INFO] WSO2 PPaaS - Cartridges ... SUCCESS [ 0.025 s] [INFO] WSO2 PPaaS - Cartridges - Template Modules SUCCESS [ 0.021 s] [INFO] WSO2 PPaaS - WSO2 AM 1.9.0 Template Module SUCCESS [ 0.457 s] [INFO] WSO2 PPaaS - WSO2 AS 5.2.1 Template Module SUCCESS [ 0.074 s] [INFO] WSO2 PPaaS - WSO2 ESB 4.8.1 Template Module ... SUCCESS [ 0.047 s] [INFO] WSO2 PPaaS - WSO2 IS 5.0.0 Template Module SUCCESS [ 0.050 s] [INFO] WSO2 PPaaS - Components ... SUCCESS [ 0.021 s] [INFO] WSO2 PPaaS - Python Configurator .. SUCCESS [ 0.082 s] [INFO] WSO2 PPaaS - Features . SUCCESS [ 0.024 s] [INFO] WSO2 PPaaS - Products . SUCCESS [ 0.020 s] [INFO] WSO2 PPaaS - Product .. SUCCESS [ 0.018 s] [INFO] WSO2 PPaaS - Profile Generation ... FAILURE [ 47.325 s] [INFO] WSO2 PPaaS - Product - Distribution ... SKIPPED [INFO] WSO2 Private PaaS - Integration Tests . SKIPPED [INFO] WSO2 PPaaS - Configurator - Product ... SKIPPED [INFO] WSO2 PPaaS - Extensions ... SKIPPED [INFO] WSO2 PPaaS - Carbon Extensions SKIPPED [INFO] WSO2 PPaaS - Carbon Extensions - Membership Scheme SKIPPED [INFO] [INFO] BUILD FAILURE [INFO] [INFO] Total time: 49.852 s [INFO] Finished at: 2015-08-31T11:04:01+05:30 [INFO] Final Memory: 30M/424M [INFO] [ERROR] Failed to execute goal org.wso2.maven:carbon-p2-plugin:1.5.4:p2-profile-gen (p2 profile generation for stratos manager) on project ppaas-p2-profile-gen: P2 publisher return code was 13 -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException [ERROR] [ERROR] After correcting the problems, you can resume the build with the command [ERROR] mvn -rf :ppaas-p2-profile-gen -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] unknown directive sticky when configuring Nginx
Hi Akila, Error got resolved when I removed below parameters sticky learn create=$upstream_cookie_jsessionid lookup=$cookie_jsessionid zone=client_sessions:1m; On Wed, Aug 12, 2015 at 11:37 AM, Akila Ravihansa Perera raviha...@wso2.com wrote: Hi Udara, Sticky sessions are only available in Nginx Plus (enterprise version). Or else you need to compile Nginx with sticky session module [1] to get it working. [1] https://bitbucket.org/nginx-goodies/nginx-sticky-module-ng/overview Thanks. On Wed, Aug 12, 2015 at 10:45 AM, Udara Liyanage ud...@wso2.com wrote: Hi, I got the following error message when following [1] for Nignx configuration. $ sudo service nginx status ● nginx.service - A high performance web server and a reverse proxy server Loaded: loaded (/lib/systemd/system/nginx.service; enabled) Active: active (running) (Result: exit-code) since Wed 2015-08-12 10:12:56 IST; 25min ago Process: 29227 ExecReload=/usr/sbin/nginx -g daemon on; master_process on; -s reload (code=exited, status=1/FAILURE) Process: 28190 ExecStart=/usr/sbin/nginx -g daemon on; master_process on; (code=exited, status=0/SUCCESS) Process: 28187 ExecStartPre=/usr/sbin/nginx -t -q -g daemon on; master_process on; (code=exited, status=0/SUCCESS) Main PID: 28191 (nginx) CGroup: /system.slice/nginx.service ├─28191 nginx: master process /usr/sbin/nginx -g daemon on; master_process on; ├─28192 nginx: worker process ├─28193 nginx: worker process ├─28194 nginx: worker process └─28195 nginx: worker process Aug 12 10:37:45 udarapc *nginx[29227]: nginx: [emerg] unknown directive sticky in /etc/nginx/conf.d/is-wso2.conf:6* Aug 12 10:37:45 udarapc systemd[1]: nginx.service: control process exited, code=exited status=1 Aug 12 10:37:45 udarapc systemd[1]: Reload failed for A high performance web server and a reverse proxy server. Below is my Nginx configuration. *is-wso2.conf content* upstream ssl.wso2.as.com { server 127.0.0.1:9443; sticky learn create=$upstream_cookie_jsessionid lookup=$cookie_jsessionid zone=client_sessions:1m; } server { listen 443; server_name is.wso2.com; ssl on; ssl_certificate /etc/nginx/ssl/is.wso2.com.crt; ssl_certificate_key /etc/nginx/ssl/is.wso2.com.key; location / { proxy_set_header X-Forwarded-Host $host; proxy_set_header X-Forwarded-Server $host; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $http_host; proxy_read_timeout 5m; proxy_send_timeout 5m; proxy_pass https://ssl.wso2.is.com; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection upgrade; } } [1] https://docs.wso2.com/display/CLUSTER420/Configuring+NGINX+Plus -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Akila Ravihansa Perera WSO2 Inc.; http://wso2.com/ Blog: http://ravihansa3000.blogspot.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] at_hash hash size
Hi, The fixing PR of [3] (Access Token hash value is calculated incorrectly) pick the first 16 bytes as the left most half of the digest. Just for my curiosity, can we guarantee it is always 16 bytes, or otherwise digest is always 32 bytes. Does n't it vary depending on the algorithm use(alg header). byte[] leftmost = new byte[16]; +for (int i = 0; i 16; i++){ +leftmost[i]=digest[i]; +} at_hash OPTIONAL. Access Token hash value. Its value is the base64url encoding of the left-most half of the hash of the octets of the ASCII representation of the access_token value, where the hash algorithm used is the hash algorithm used in the alg parameter of the State Token's JWS [JWS] header. * For instance, if the alg* * is RS256*, hash the access_token value with SHA-256, then take the left-most 128 bits and base64url encode them. The at_hash [1] https://github.com/wso2/carbon-identity/commit/1756178b9ad62295eb5274a47b06775de13eab95 [2] https://tools.ietf.org/html/draft-bradley-oauth-jwt-encoded-state-01 [3] https://wso2.org/jira/browse/IDENTITY-3385 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] unknown directive sticky when configuring Nginx
Hi, I got the following error message when following [1] for Nignx configuration. $ sudo service nginx status ● nginx.service - A high performance web server and a reverse proxy server Loaded: loaded (/lib/systemd/system/nginx.service; enabled) Active: active (running) (Result: exit-code) since Wed 2015-08-12 10:12:56 IST; 25min ago Process: 29227 ExecReload=/usr/sbin/nginx -g daemon on; master_process on; -s reload (code=exited, status=1/FAILURE) Process: 28190 ExecStart=/usr/sbin/nginx -g daemon on; master_process on; (code=exited, status=0/SUCCESS) Process: 28187 ExecStartPre=/usr/sbin/nginx -t -q -g daemon on; master_process on; (code=exited, status=0/SUCCESS) Main PID: 28191 (nginx) CGroup: /system.slice/nginx.service ├─28191 nginx: master process /usr/sbin/nginx -g daemon on; master_process on; ├─28192 nginx: worker process ├─28193 nginx: worker process ├─28194 nginx: worker process └─28195 nginx: worker process Aug 12 10:37:45 udarapc *nginx[29227]: nginx: [emerg] unknown directive sticky in /etc/nginx/conf.d/is-wso2.conf:6* Aug 12 10:37:45 udarapc systemd[1]: nginx.service: control process exited, code=exited status=1 Aug 12 10:37:45 udarapc systemd[1]: Reload failed for A high performance web server and a reverse proxy server. Below is my Nginx configuration. *is-wso2.conf content* upstream ssl.wso2.as.com { server 127.0.0.1:9443; sticky learn create=$upstream_cookie_jsessionid lookup=$cookie_jsessionid zone=client_sessions:1m; } server { listen 443; server_name is.wso2.com; ssl on; ssl_certificate /etc/nginx/ssl/is.wso2.com.crt; ssl_certificate_key /etc/nginx/ssl/is.wso2.com.key; location / { proxy_set_header X-Forwarded-Host $host; proxy_set_header X-Forwarded-Server $host; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header Host $http_host; proxy_read_timeout 5m; proxy_send_timeout 5m; proxy_pass https://ssl.wso2.is.com; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection upgrade; } } [1] https://docs.wso2.com/display/CLUSTER420/Configuring+NGINX+Plus -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Developer Studio custom mediator pack dependencies
Hi, Got it resolved after embed-dependency is put inside instruction tag. On Tue, Jul 28, 2015 at 11:15 AM, Udara Liyanage ud...@wso2.com wrote: Hi Rajitha, Thanks for the information. I tried packing all dependencies with *, but it did not pack any dependencies. configuration instructions Bundle-SymbolicNameJsonValidatorMediator/Bundle-SymbolicName Bundle-NameJsonValidatorMediator/Bundle-Name Export-Packageorg.udara.mediation,/Export-Package DynamicImport-Package*/DynamicImport-Package /instructions Embed-Dependency*/Embed-Dependency /configuration On Tue, Jul 28, 2015 at 10:43 AM, Rajith Vitharana raji...@wso2.com wrote: Hi Udara, This is ok too, but AFAIK it's better to use Private-Packageorg.foo.myproject.*/Private-Package as in [1] o that those classes won't get exposed to others(Since only you need these packages). Or either you can use Embed-Dependencydependencies/Embed-Dependency as well. Then those jars will be embedded in the osgi jar [1] - http://felix.apache.org/documentation/subprojects/apache-felix-maven-bundle-plugin-bnd.html Thanks, On Tue, Jul 28, 2015 at 10:36 AM, Udara Liyanage ud...@wso2.com wrote: Hi, I'v created a mediator project in order to write a custom mediator. However if I am using some dependencies(not available in ESB) how can I bundle them with the mediator jar. Dependencies were added to the pom, yet they are not bundled by default. Dependencies were bundled when I added them to export package. Is this the correct way of packing dependencies, or is there is another way I can specify which dependencies to be packed. Export-Packageorg.udara.mediation, org.mydependency/Export-Package -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Rajith Vitharana Software Engineer, WSO2 Inc. : wso2.com Mobile : +94715883223 Blog : http://lankavitharana.blogspot.com/ -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Developer Studio custom mediator pack dependencies
Hi Rajitha, Thanks for the information. I tried packing all dependencies with *, but it did not pack any dependencies. configuration instructions Bundle-SymbolicNameJsonValidatorMediator/Bundle-SymbolicName Bundle-NameJsonValidatorMediator/Bundle-Name Export-Packageorg.udara.mediation,/Export-Package DynamicImport-Package*/DynamicImport-Package /instructions Embed-Dependency*/Embed-Dependency /configuration On Tue, Jul 28, 2015 at 10:43 AM, Rajith Vitharana raji...@wso2.com wrote: Hi Udara, This is ok too, but AFAIK it's better to use Private-Packageorg.foo.myproject.*/Private-Package as in [1] o that those classes won't get exposed to others(Since only you need these packages). Or either you can use Embed-Dependencydependencies/Embed-Dependency as well. Then those jars will be embedded in the osgi jar [1] - http://felix.apache.org/documentation/subprojects/apache-felix-maven-bundle-plugin-bnd.html Thanks, On Tue, Jul 28, 2015 at 10:36 AM, Udara Liyanage ud...@wso2.com wrote: Hi, I'v created a mediator project in order to write a custom mediator. However if I am using some dependencies(not available in ESB) how can I bundle them with the mediator jar. Dependencies were added to the pom, yet they are not bundled by default. Dependencies were bundled when I added them to export package. Is this the correct way of packing dependencies, or is there is another way I can specify which dependencies to be packed. Export-Packageorg.udara.mediation, org.mydependency/Export-Package -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Rajith Vitharana Software Engineer, WSO2 Inc. : wso2.com Mobile : +94715883223 Blog : http://lankavitharana.blogspot.com/ -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] Developer Studio custom mediator pack dependencies
Hi, I'v created a mediator project in order to write a custom mediator. However if I am using some dependencies(not available in ESB) how can I bundle them with the mediator jar. Dependencies were added to the pom, yet they are not bundled by default. Dependencies were bundled when I added them to export package. Is this the correct way of packing dependencies, or is there is another way I can specify which dependencies to be packed. Export-Packageorg.udara.mediation, org.mydependency/Export-Package -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] Finding tomcat version of Carbon products
Hi, How do we find the tomcat version of Carbon products rather than searching for the jar in plugins folder. Don't we mention the tomcat version of Carbon products at any configuration file? -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] IS Error while adding a user
) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98) at org.wso2.carbon.tomcat.ext.valves.CompositeValve.invoke(CompositeValve.java:172) at org.wso2.carbon.tomcat.ext.valves.CarbonStuckThreadDetectionValve.invoke(CarbonStuckThreadDetectionValve.java:156) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:927) 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:1001) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:579) at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1653) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) at java.lang.Thread.run(Thread.java:662) -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] How to add a SCIM user to secondary userstore
Hi, I will apply SP and try again. ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] How to add a SCIM user to secondary userstore
Hi Ushani, Yes I reffered the same doc you shared, I did the claim mapping. On Thu, Jul 23, 2015 at 11:08 AM, Ushani Balasooriya ush...@wso2.com wrote: Hi Udara, Have you done the claim mapping correctly? E.g., urn:scim:schemas:core:1.0:id - homePostalAddress;udaraad/homePostalAddress; Then the command should be as below : Please refer [1] curl -v -k --user admin:admin --data {schemas:[],userName:'udaraad /user1',password:Wso2@123} --header Content-Type:application/json https://localhost:9443/wso2/scim/Users [1] https://docs.wso2.com/display/IS500/Provisioning+Users+to+Active+Directory+User+Store+Using+SCIM On Thu, Jul 23, 2015 at 10:59 AM, Udara Liyanage ud...@wso2.com wrote: Hi, I used below REST call to create a SCIM user. This create a users in primary userstore sucesfully. I want to how to create the user in my secondary userstore (AD) which has domain name udaraad. curl -v -k --user admin:admin --data {schemas:[],name:{familyName:gunasinghe,givenName:hasinitg},userName:'hasinit',password:hasinitg,emails:[{primary:true,value: hasini_home.com,type:home},{value:hasini_work.com,type:work}]} --header Content-Type:application/json https://localhost:9443/wso2/scim/Users I tried with following combinations and found no luck and encountered below error response. But still no error message is shown in Carbon logs which should. userName:'udaraad/hasinit' userName:'udaraad\/hasinit' userName:udaraad/hasinit userName:udaraad//hasinit {Errors:[{description:Error in adding the user: udaraad/hasinit to the user store..,code:500}]} -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- *Ushani Balasooriya* Senior Software Engineer - QA; WSO2 Inc; http://www.wso2.com/. Mobile; +94772636796 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] User already exist when AD as a userstore
Hi, I used org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager usermanager for AD On Wed, Jul 22, 2015 at 2:02 PM, Udara Liyanage ud...@wso2.com wrote: Hi, I tried adding a AD as a RW userstore and encountered the following exception. I tried setting AddAdmin false but found no luck. Then I changed admin name to admin1 and encountered the exception [2](*One or more attributes you are trying to add/update are not supported by underlying LDAP*). Please note that I am using IS 410. [2015-07-22 13:52:02,484] INFO {org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager} - LDAP connection created successfully in read-write mode [2015-07-22 13:52:03,179] ERROR {org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager} - Can not access the directory context or user already exists in the system javax.naming.NameAlreadyBoundException: [LDAP: error code 68 - 2071: UpdErr: DSID-0305031D, problem 6005 (ENTRY_EXISTS), data 0 ]; remaining name 'cn=admin' at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3062) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:3013) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2820) at com.sun.jndi.ldap.LdapCtx.c_bind(LdapCtx.java:400) at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_bind(ComponentDirContext.java:277) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.bind(PartialCompositeDirContext.java:197) at org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager.doAddUser(ReadWriteLDAPUserStoreManager.java:242) at org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager.doAddUser(ReadWriteLDAPUserStoreManager.java:211) at org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager.addInitialData(ReadWriteLDAPUserStoreManager.java:1805) at org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager.init(ReadWriteLDAPUserStoreManager.java:142) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at org.wso2.carbon.user.core.common.DefaultRealm.createObjectWithOptions(DefaultRealm.java:225) at org.wso2.carbon.user.core.common.DefaultRealm.initializeObjects(DefaultRealm.java:147) at org.wso2.carbon.user.core.common.DefaultRealm.init(DefaultRealm.java:113) at org.wso2.carbon.user.core.common.DefaultRealmService.initializeRealm(DefaultRealmService.java:223) at org.wso2.carbon.user.core.common.DefaultRealmService.init(DefaultRealmService.java:103) at org.wso2.carbon.user.core.common.DefaultRealmService.init(DefaultRealmService.java:116) at org.wso2.carbon.user.core.internal.Activator.startDeploy(Activator.java:67) at org.wso2.carbon.user.core.internal.BundleCheckActivator.start(BundleCheckActivator.java:61) at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:711) at java.security.AccessController.doPrivileged(Native Method) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:702) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:683) at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381) at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:389) at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1130) at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559) at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544) at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457) at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243) at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438) at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1) at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230) at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340) [2015-07-22 13:52:03,181] ERROR {org.wso2.carbon.user.core.common.DefaultRealm} - Cannot create org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager java.lang.reflect.InvocationTargetException at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513
[Dev] User already exist when AD as a userstore
) at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:389) at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1130) at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559) at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544) at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457) at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243) at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438) at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1) at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230) at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340) [2015-07-22 13:55:36,105] ERROR {org.wso2.carbon.identity.mgt.IdentityMgtEventListener} - Error while init identity listener org.wso2.carbon.user.core.UserStoreException: One or more attributes you are trying to add/update are not supported by underlying LDAP. at org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager.doSetUserClaimValue(ReadWriteLDAPUserStoreManager.java:900) at org.wso2.carbon.user.core.common.AbstractUserStoreManager.setUserClaimValue(AbstractUserStoreManager.java:823) at org.wso2.carbon.identity.mgt.IdentityMgtEventListener.init(IdentityMgtEventListener.java:68) -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] User already exist when AD as a userstore
Hi, However I don't get this issue when I configured AD as the secondary userstore. On Wed, Jul 22, 2015 at 2:05 PM, Udara Liyanage ud...@wso2.com wrote: Hi, I used org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager usermanager for AD On Wed, Jul 22, 2015 at 2:02 PM, Udara Liyanage ud...@wso2.com wrote: Hi, I tried adding a AD as a RW userstore and encountered the following exception. I tried setting AddAdmin false but found no luck. Then I changed admin name to admin1 and encountered the exception [2](*One or more attributes you are trying to add/update are not supported by underlying LDAP*). Please note that I am using IS 410. [2015-07-22 13:52:02,484] INFO {org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager} - LDAP connection created successfully in read-write mode [2015-07-22 13:52:03,179] ERROR {org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager} - Can not access the directory context or user already exists in the system javax.naming.NameAlreadyBoundException: [LDAP: error code 68 - 2071: UpdErr: DSID-0305031D, problem 6005 (ENTRY_EXISTS), data 0 ]; remaining name 'cn=admin' at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3062) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:3013) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2820) at com.sun.jndi.ldap.LdapCtx.c_bind(LdapCtx.java:400) at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_bind(ComponentDirContext.java:277) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.bind(PartialCompositeDirContext.java:197) at org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager.doAddUser(ReadWriteLDAPUserStoreManager.java:242) at org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager.doAddUser(ReadWriteLDAPUserStoreManager.java:211) at org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager.addInitialData(ReadWriteLDAPUserStoreManager.java:1805) at org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager.init(ReadWriteLDAPUserStoreManager.java:142) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at org.wso2.carbon.user.core.common.DefaultRealm.createObjectWithOptions(DefaultRealm.java:225) at org.wso2.carbon.user.core.common.DefaultRealm.initializeObjects(DefaultRealm.java:147) at org.wso2.carbon.user.core.common.DefaultRealm.init(DefaultRealm.java:113) at org.wso2.carbon.user.core.common.DefaultRealmService.initializeRealm(DefaultRealmService.java:223) at org.wso2.carbon.user.core.common.DefaultRealmService.init(DefaultRealmService.java:103) at org.wso2.carbon.user.core.common.DefaultRealmService.init(DefaultRealmService.java:116) at org.wso2.carbon.user.core.internal.Activator.startDeploy(Activator.java:67) at org.wso2.carbon.user.core.internal.BundleCheckActivator.start(BundleCheckActivator.java:61) at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:711) at java.security.AccessController.doPrivileged(Native Method) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:702) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:683) at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381) at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:389) at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1130) at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559) at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544) at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457) at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243) at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438) at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1) at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230) at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340) [2015-07-22 13:52:03,181] ERROR {org.wso2.carbon.user.core.common.DefaultRealm} - Cannot create org.wso2.carbon.user.core.ldap.ReadWriteLDAPUserStoreManager java.lang.reflect.InvocationTargetException at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39
[Dev] How to add a SCIM user to secondary userstore
Hi, I used below REST call to create a SCIM user. This create a users in primary userstore sucesfully. I want to how to create the user in my secondary userstore (AD) which has domain name udaraad. curl -v -k --user admin:admin --data {schemas:[],name:{familyName:gunasinghe,givenName:hasinitg},userName:'hasinit',password:hasinitg,emails:[{primary:true,value: hasini_home.com,type:home},{value:hasini_work.com,type:work}]} --header Content-Type:application/json https://localhost:9443/wso2/scim/Users I tried with following combinations and found no luck and encountered below error response. But still no error message is shown in Carbon logs which should. userName:'udaraad/hasinit' userName:'udaraad\/hasinit' userName:udaraad/hasinit userName:udaraad//hasinit {Errors:[{description:Error in adding the user: udaraad/hasinit to the user store..,code:500}]} -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [PPaaS] Integrating DAS with Stratos for Metering Service and Monitoring Health Statistics
Hi Iranga, In Stratos cartridge agents inside the instances or containers sends their health statistics to CEP. Then CEP aggregates and publish aggregated results to the message broker which is then used by Stratos Auto Scaler for scaling decisions. This is what exist in Stratos now. I guess this diagram shows those details are published to DAS as well for health monitoring. In a real deployment Stratos components (CC, AS and SM) and CEP and DAS are deployed in deployed in destroyed fashion. Thus using external CEP is better rather than in DAS. In addition we need CEP even if someone disable metering and health monitoring On Fri, Jul 10, 2015 at 8:17 PM, Pubudu Gunatilaka pubu...@wso2.com wrote: Hi Iranga, Actually Stratos uses separate CEP to analyse health statistics that are published from cartridges and services. Those analysed data are sent to the Autoscaler to take autoscaling decisions. You can find more information in [1]. In this DAS integration with Stratos, for the requirement of monitoring health statistics we need those summerized data from CEP. Therefore we need to publish those data from CEP to DAS. Other thing is DAS is an extension point in Stratos. Depend on the user requirement, he can use DAS for monitoring real time statistics. [1] - https://cwiki.apache.org/confluence/display/STRATOS/4.1.0+Complex+Event+Processor Thank you! On Fri, Jul 10, 2015 at 2:12 PM, Iranga Muthuthanthri ira...@wso2.com wrote: On Fri, Jul 10, 2015 at 2:08 PM, Thanuja Uruththirakodeeswaran thanu...@wso2.com wrote: Hi Devs, Stratos is integrated with DAS for Metering service and Monitoring Health Statistics. In order to implement this requirement, following idea is used: - Here for the Metering service, Instance details (cluster level instance count with time and member level instance details with autoscaling decision) are published from Stratos to DAS, persisted in HBase, analyzed using Spark and saved in MySQL and then shown in DAS dashboard. - For the Monitoring service, Health Statistics aggregated by CEP is sent to DAS and then shown in dashboard as shown above. Would it not be possible to do this within DAS it self, since CEP(realtime) features are available in DAS itself? Currently, I'm in the stage of getting part of instance details and showing it in dashboard. Thanks. -- Thanuja Uruththirakodeeswaran Software Engineer WSO2 Inc.;http://wso2.com lean.enterprise.middleware mobile: +94 774363167 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Thanks Regards Iranga Muthuthanthri (M) -0777-255773 Team Product Management ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- *Pubudu Gunatilaka* Software Engineer WSO2, Inc.: http://wso2.com lean.enterprise.middleware mobile: +94 77 4078049 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [DAS] Zoookeeper connection error when HBase datasource is added
before retry #0... {org.apache.hadoop.hbase.util.RetryCounter} TID: [-1] [] [2015-07-03 14:19:23,401] INFO {org.apache.zookeeper.ClientCnxn} - Opening socket connection to server localhost/127.0.0.1:2181. Will not attempt to authenticate using SASL (unknown error) {org.apache.zookeeper.ClientCnxn} TID: [-1] [] [2015-07-03 14:19:23,402] WARN {org.apache.zookeeper.ClientCnxn} - Session 0x0 for server null, unexpected error, closing socket connection and attempting reconnect {org.apache.zookeeper.ClientCnxn} java.net.ConnectException: Connection refused at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:739) at org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) TID: [-1] [] [2015-07-03 14:19:23,503] WARN {org.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper} - Possibly transient ZooKeeper, quorum=localhost:2181, exception=org.apache.zookeeper.KeeperException$ConnectionLossException: KeeperErrorCode = ConnectionLoss for /hbase/hbaseid {org.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper} TID: [-1] [] [2015-07-03 14:19:23,503] INFO {org.apache.hadoop.hbase.util.RetryCounter} - Sleeping 2000ms before retry #1... {org.apache.hadoop.hbase.util.RetryCounter} TID: [-1] [] [2015-07-03 14:19:24,503] INFO {org.apache.zookeeper.ClientCnxn} - Opening socket connection to server localhost/127.0.0.1:2181. Will not attempt to authenticate using SASL (unknown error) {org.apache.zookeeper.ClientCnxn} TID: [-1] [] [2015-07-03 14:19:24,503] WARN {org.apache.zookeeper.ClientCnxn} - Session 0x0 for server null, unexpected error, closing socket connection and attempting reconnect {org.apache.zookeeper.ClientCnxn} java.net.ConnectException: Connection refused at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:739) at org.apache.zookeeper.ClientCnxnSocketNIO.doTransport(ClientCnxnSocketNIO.java:350) at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1068) TID: [-1] [] [2015-07-03 14:19:25,604] INFO {org.apache.zookeeper.ClientCnxn} - Opening socket connection to server localhost/127.0.0.1:2181. Will not attempt to authenticate using SASL (unknown error) {org.apache.zookeeper.ClientCnxn} 294,7127% -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] PP- Docker base image
Hi, Shall we move Java installation and configurater to base image. Otherwise we have to repeat the task in every cartridge. Hope every cartridge require Java. If there are cartridges which does not require Java we can create an intermediate image (carbon base) which all Carbon products inherits from, other cartridges just inherit from current base image. WDYT? -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] PP - Docker best practices - ADD or COPY
Hi, I had a look at Docker best practices http://docs.docker.com/v1.2/articles/dockerfile_best-practices/#add-or-copy which recommend to use COPY instead of ADD unless it is a tar. For other items (files, directories) that do not require ADD’s tar auto-extraction capability, you should always use COPY. With that we can improve WSO2 ESB cartridge by replacing ADD by COPY. Below are some sample places which can be replaced. ADD scripts/init.sh /usr/local/bin/init.sh ADD scripts/export-envs.sh /tmp/export-envs.sh ADD packages/${CONFIGURATOR_NAME}.zip /opt/ ADD packages/wso2esb-${WSO2_ESB_VERSION}.zip /opt/ ADD plugins /${PCA_HOME}/plugins WDYT? -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] PP base image docker file - noninteractive
Hi Imesh, Is there any specific reason not to include below in base image docker file only, we are installing basic software in base image too. ENV DEBIAN_FRONTEND noninteractive -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] PP base image docker file - noninteractive
Hi Imesh, Thanks for the explanation. Added in e9405acad70508c On Tue, Jun 9, 2015 at 12:12 PM, Imesh Gunaratne im...@wso2.com wrote: Hi Udara, A good point! We did not encounter any user interactions during the apt-get operations therefore this was not added. Anyway +1 for adding it. Thanks On Tue, Jun 9, 2015 at 11:36 AM, Udara Liyanage ud...@wso2.com wrote: Hi Imesh, Is there any specific reason not to include below in base image docker file only, we are installing basic software in base image too. ENV DEBIAN_FRONTEND noninteractive -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 -- *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 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] Remove redundants which are inherited from root pom
Hi Imesh, Do we need below since we already inherit from root pom [1] licenses license nameThe Apache Software License, Version 2.0/name urlhttp://www.apache.org/licenses/LICENSE-2.0.txt/url distributionrepo/distribution /license /licenses organization nameWSO2/name urlhttps://www.wso2.org/url /organization issueManagement systemJIRA/system urlhttps://wso2.org/jira/url /issueManagement mailingLists mailingList nameDeveloper List/name subscribedev-requ...@wso2.org?subject=subscribe/subscribe unsubscribedev-requ...@wso2.org?subject=unsubscribe /unsubscribe postdev@wso2.org/post archivehttp://wso2.markmail.org/search/list:org.wso2.dev /archive /mailingList /mailingLists scm urlhttps://github.com/wso2/product-private-paas.git/url developerConnectionscm:git: https://github.com/wso2/product-private-paas.git /developerConnection connectionscm:git:https://github.com/wso2/product-private-paas.git /connection tagHEAD/tag /scm distributionManagement repository idnexus-releases/id nameWSO2 Release Distribution Repository/name url http://maven.wso2.org/nexus/service/local/staging/deploy/maven2//url /repository /distributionManagement [1] https://github.com/wso2/carbon-parent/blob/master/pom.xml -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Private PaaS product pack name
Hi, We need to rename stratos.sh to wso2server.sh then? On Wed, May 27, 2015 at 10:56 AM, Imesh Gunaratne im...@wso2.com wrote: +1 for naming the product as wso2ppaas-4.1.0. On Wed, May 27, 2015 at 10:53 AM, Lahiru Sandaruwan lahi...@wso2.com wrote: IMO we should rename it to ppaas*. Thanks. On Wed, May 27, 2015 at 10:50 AM, Udara Liyanage ud...@wso2.com wrote: Hi, Since we clone Stratos in PP 400, the name of the product was Stratos. However since we are not cloning Stratos code base, but just create a new product with existing features except for UI, are we going to rename the product or keep the same name as in 400? -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 -- -- Lahiru Sandaruwan Committer and PMC member, Apache Stratos, Senior Software Engineer, WSO2 Inc., http://wso2.com lean.enterprise.middleware phone: +94773325954 email: lahi...@wso2.com blog: http://lahiruwrites.blogspot.com/ linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146 -- *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 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] Remove redundants which are inherited from root pom
Hi Imesh, Committed in f7df03687 On Wed, May 27, 2015 at 5:26 PM, Imesh Gunaratne im...@wso2.com wrote: Hi Udara, A good point! Yes we can remove elements which being inherited from the WSO2 parent pom.xml. Thanks On Wed, May 27, 2015 at 2:44 PM, Udara Liyanage ud...@wso2.com wrote: Hi Imesh, Do we need below since we already inherit from root pom [1] licenses license nameThe Apache Software License, Version 2.0/name urlhttp://www.apache.org/licenses/LICENSE-2.0.txt/url distributionrepo/distribution /license /licenses organization nameWSO2/name urlhttps://www.wso2.org/url /organization issueManagement systemJIRA/system urlhttps://wso2.org/jira/url /issueManagement mailingLists mailingList nameDeveloper List/name subscribedev-requ...@wso2.org?subject=subscribe/subscribe unsubscribedev-requ...@wso2.org?subject=unsubscribe /unsubscribe postdev@wso2.org/post archivehttp://wso2.markmail.org/search/list:org.wso2.dev /archive /mailingList /mailingLists scm urlhttps://github.com/wso2/product-private-paas.git/url developerConnectionscm:git: https://github.com/wso2/product-private-paas.git /developerConnection connectionscm:git: https://github.com/wso2/product-private-paas.git/connection tagHEAD/tag /scm distributionManagement repository idnexus-releases/id nameWSO2 Release Distribution Repository/name url http://maven.wso2.org/nexus/service/local/staging/deploy/maven2//url /repository /distributionManagement [1] https://github.com/wso2/carbon-parent/blob/master/pom.xml -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 -- *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 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] Private PaaS product pack name
Hi, Since we clone Stratos in PP 400, the name of the product was Stratos. However since we are not cloning Stratos code base, but just create a new product with existing features except for UI, are we going to rename the product or keep the same name as in 400? -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [PPaaS] Need to move Configurator to Components and Create a Distribution
Hi Anurudda, I put some comments for the pull request. Please consider/fix them. On Tue, May 26, 2015 at 11:56 AM, Anuruddha Liyanarachchi anurudd...@wso2.com wrote: Hi Imesh, I have now created configurator feature. Can you please review and merge [1] for the same. [1] https://github.com/wso2/product-private-paas/pull/73 Thanks On Tue, May 26, 2015 at 10:24 AM, Imesh Gunaratne im...@wso2.com wrote: Hi Anuruddha, I think we also need to create a feature for the Configurator and use that to build its product distribution. In addition we need to make sure that Configurator maven artifacts are uploaded to Nexus on maven deploy command. Thanks On Mon, May 25, 2015 at 9:20 PM, Imesh Gunaratne im...@wso2.com wrote: Thanks Anuruddha! I reviewed your pull request and merged. On Mon, May 25, 2015 at 5:30 PM, Anuruddha Liyanarachchi anurudd...@wso2.com wrote: Hi Imesh, I have now completed $subject. Can you please review and merge [1] [1]https://github.com/wso2/product-private-paas/pull/72 On Mon, May 25, 2015 at 12:25 PM, Imesh Gunaratne im...@wso2.com wrote: Hi Anuruddha, I think we need to move the Configurator to components folder [1] and rename it to org.wso2.ppaas.configurator. In addition we need to create a product inside products folder [2] for generating its distribution (wso2ppaas-configurator-4.1.0.zip). We need to follow the standard guidelines when creating the folder structure and maven modules. [1] https://github.com/wso2/product-private-paas/tree/master/components [2] https://github.com/wso2/product-private-paas/tree/master/products 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 -- *Thanks and Regards,* Anuruddha Lanka Liyanarachchi Software Engineer - WSO2 Mobile : +94 (0) 712762611 Tel : +94 112 145 345 a thili...@wso2.comnurudd...@wso2.com -- *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 -- *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 -- *Thanks and Regards,* Anuruddha Lanka Liyanarachchi Software Engineer - WSO2 Mobile : +94 (0) 712762611 Tel : +94 112 145 345 a thili...@wso2.comnurudd...@wso2.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [PPaaS] Need to move Configurator to Components and Create a Distribution
Hi Anurudda, Merged. On Tue, May 26, 2015 at 12:38 PM, Anuruddha Liyanarachchi anurudd...@wso2.com wrote: Hi Udara, I have fixed them now. Thanks, On Tue, May 26, 2015 at 12:07 PM, Udara Liyanage ud...@wso2.com wrote: Hi Anurudda, I put some comments for the pull request. Please consider/fix them. On Tue, May 26, 2015 at 11:56 AM, Anuruddha Liyanarachchi anurudd...@wso2.com wrote: Hi Imesh, I have now created configurator feature. Can you please review and merge [1] for the same. [1] https://github.com/wso2/product-private-paas/pull/73 Thanks On Tue, May 26, 2015 at 10:24 AM, Imesh Gunaratne im...@wso2.com wrote: Hi Anuruddha, I think we also need to create a feature for the Configurator and use that to build its product distribution. In addition we need to make sure that Configurator maven artifacts are uploaded to Nexus on maven deploy command. Thanks On Mon, May 25, 2015 at 9:20 PM, Imesh Gunaratne im...@wso2.com wrote: Thanks Anuruddha! I reviewed your pull request and merged. On Mon, May 25, 2015 at 5:30 PM, Anuruddha Liyanarachchi anurudd...@wso2.com wrote: Hi Imesh, I have now completed $subject. Can you please review and merge [1] [1]https://github.com/wso2/product-private-paas/pull/72 On Mon, May 25, 2015 at 12:25 PM, Imesh Gunaratne im...@wso2.com wrote: Hi Anuruddha, I think we need to move the Configurator to components folder [1] and rename it to org.wso2.ppaas.configurator. In addition we need to create a product inside products folder [2] for generating its distribution (wso2ppaas-configurator-4.1.0.zip). We need to follow the standard guidelines when creating the folder structure and maven modules. [1] https://github.com/wso2/product-private-paas/tree/master/components [2] https://github.com/wso2/product-private-paas/tree/master/products 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 -- *Thanks and Regards,* Anuruddha Lanka Liyanarachchi Software Engineer - WSO2 Mobile : +94 (0) 712762611 Tel : +94 112 145 345 a thili...@wso2.comnurudd...@wso2.com -- *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 -- *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 -- *Thanks and Regards,* Anuruddha Lanka Liyanarachchi Software Engineer - WSO2 Mobile : +94 (0) 712762611 Tel : +94 112 145 345 a thili...@wso2.comnurudd...@wso2.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 -- *Thanks and Regards,* Anuruddha Lanka Liyanarachchi Software Engineer - WSO2 Mobile : +94 (0) 712762611 Tel : +94 112 145 345 a thili...@wso2.comnurudd...@wso2.com -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [WSO2 PP] Clustering for WSO2 products in Private PaaS
Hi, As we discussed offline I tested weather carbon clustering works with hostnames instead of Ips. I tried with two AS 5.2.1 nodes, each becoming to WKA member to the other member. Members get joined and registry based deb sync worked. I will try with multiple nodes and with a different product and update the thread. @Imesh If clustering works with hostnames, shall we proceed with this approach? -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [WSO2 PP] Clustering for WSO2 products in Private PaaS
Hi , I tested with a three nodes cluster. Tested caching with the web app provided by Isuruh and it seems to work. Lets go with that approach. On Sun, May 24, 2015 at 11:32 PM, Isuru Haththotuwa isu...@wso2.com wrote: Hi, On Sun, May 24, 2015 at 6:55 PM, Imesh Gunaratne im...@wso2.com wrote: +1 Yes that would be the simplest approach that we can take. @IsuruH: Can you please share the information you found on Hazelcast on this regard? Its at [1], section 'Discover by TCP/IP' [1]. http://docs.hazelcast.org/docs/3.4/manual/html/hazelcastclusters.html Thanks On Sun, May 24, 2015 at 4:26 PM, Lakmal Warusawithana lak...@wso2.com wrote: On Sunday, May 24, 2015, Udara Liyanage ud...@wso2.com wrote: Hi, As we discussed offline I tested weather carbon clustering works with hostnames instead of Ips. I tried with two AS 5.2.1 nodes, each becoming to WKA member to the other member. Members get joined and registry based deb sync worked. I will try with multiple nodes and with a different product and update the thread. @Imesh If clustering works with hostnames, shall we proceed with this approach? +1 will use hostnames -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 -- Sent from Gmail Mobile -- *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 -- Thanks and Regards, Isuru H. +94 716 358 048* http://wso2.com/* -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] AS cluster registry debsync issue
Hi Jayanga, I tried registry based in order to check weather cluster is working. I will check svn based deb sync and let you know the results. On Sun, May 24, 2015 at 9:18 AM, Jayanga Dissanayake jaya...@wso2.com wrote: Hi Udara, As your worker node has received the cluster message, I assume clustering works properly in your setup. Can you please check your DepSync configurations. And verify whether your new artifact is uploaded to the SVN by your master node. Thanks, Jayanga. *Jayanga Dissanayake* Senior Software Engineer WSO2 Inc. - http://wso2.com/ lean . enterprise . middleware email: jaya...@wso2.com mobile: +94772207259 On Sat, May 23, 2015 at 11:01 AM, Udara Liyanage ud...@wso2.com wrote: Hi, I create a AS 5.2.1 cluster with two nodes as each members is a WKA member for other members. Member join messages appeared. However when a web app is deployed to the manager node, it is not propagated to the other node. However following repo notification message appeared in the worker node. Note that I have applied the hazelcast patch patch1297 to both nodes. [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.clustering.hazelcast.HazelcastClusterMessageListener} - Received ClusteringMessage: SynchronizeRepositoryRequest{tenantId=-1234, tenantDomain='carbon.super', messageId=68bd3b2f-598a-423c-b876-bd3eb5e9bd3c} [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.deployment.SynchronizeRepositoryRequest} - Received [SynchronizeRepositoryRequest{tenantId=-1234, tenantDomain='carbon.super', messageId=68bd3b2f-598a-423c-b876-bd3eb5e9bd3c}] [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.deployment.SynchronizeRepositoryRequest} - Updating repo update required parameter -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] AS cluster registry debsync issue
Hi, I tried svn based deb sync and got the following issue. DeploymentSynchronizer Enabledtrue/Enabled AutoCommittrue/AutoCommit AutoCheckouttrue/AutoCheckout RepositoryTypesvn/RepositoryType SvnUrlfile:///home/udara/experiments/depsync//SvnUrl !-- SvnUrlhttp://svnrepo.example.com/repos//SvnUrl -- SvnUserudara/SvnUser SvnPasswordudara/SvnPassword SvnUrlAppendTenantIdtrue/SvnUrlAppendTenantId /DeploymentSynchronizer Error while attempting to create the directory: file:///home/udara/experiments/depsync/-1234 org.tigris.subversion.svnclientadapter.SVNClientException: org.tigris.subversion.javahl.ClientException: svn: Unable to open an ra_local session to URL svn: Unable to open repository 'file:///home/udara/experiments/depsync' svn: Expected FS format between '1' and '4'; found format '6' at org.tigris.subversion.svnclientadapter.javahl.AbstractJhlClientAdapter.mkdir(AbstractJhlClientAdapter.java:2524) at org.wso2.carbon.deployment.synchronizer.subversion.SVNBasedArtifactRepository.checkRemoteDirectory(SVNBasedArtifactRepository.java:240) at org.wso2.carbon.deployment.synchronizer.subversion.SVNBasedArtifactRepository.init(SVNBasedArtifactRepository.java:167) at org.wso2.carbon.deployment.synchronizer.internal.repository.CarbonRepositoryUtils.newCarbonRepositorySynchronizer(CarbonRepositoryUtils.java:71) at org.wso2.carbon.deployment.synchronizer.internal.DeploymentSynchronizerComponent.initDeploymentSynchronizerForSuperTenant(DeploymentSynchronizerComponent.java:108) at org.wso2.carbon.deployment.synchronizer.internal.DeploymentSynchronizerComponent.activate(DeploymentSynchronizerComponent.java:77) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) On Sun, May 24, 2015 at 10:29 AM, Ajith Vitharana aji...@wso2.com wrote: Hi All The registry based depsync is deprecated. Please try with SVN. -Ajith On Sun, May 24, 2015 at 12:54 AM, Manoj Kumara ma...@wso2.com wrote: Hi Udara, Did you mounted the registry database between the nodes ? Please follow [1] [1] http://emsooriyabandara.blogspot.com/2013/01/registry-based-deployment-synchronizer.html *Manoj Kumara* Software Engineer WSO2 Inc. http://wso2.com/ *lean.enterprise.middleware* Mobile: +94713448188 On Sat, May 23, 2015 at 11:01 AM, Udara Liyanage ud...@wso2.com wrote: Hi, I create a AS 5.2.1 cluster with two nodes as each members is a WKA member for other members. Member join messages appeared. However when a web app is deployed to the manager node, it is not propagated to the other node. However following repo notification message appeared in the worker node. Note that I have applied the hazelcast patch patch1297 to both nodes. [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.clustering.hazelcast.HazelcastClusterMessageListener} - Received ClusteringMessage: SynchronizeRepositoryRequest{tenantId=-1234, tenantDomain='carbon.super', messageId=68bd3b2f-598a-423c-b876-bd3eb5e9bd3c} [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.deployment.SynchronizeRepositoryRequest} - Received [SynchronizeRepositoryRequest{tenantId=-1234, tenantDomain='carbon.super', messageId=68bd3b2f-598a-423c-b876-bd3eb5e9bd3c}] [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.deployment.SynchronizeRepositoryRequest} - Updating repo update required parameter -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Ajith Vitharana. WSO2 Inc. - http://wso2.com Email : aji...@wso2.com Blog: http://vitharana.org Mobile : +1-812-360-5335 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] AS cluster registry debsync issue
Hi, Is this due to a version issue. My svn version is 1.8.8 which seems to be not supported according to [1] svn --version svn, version 1.8.8 (r1568071) [1] https://docs.wso2.com/display/CLUSTER420/SVN-based+Deployment+Synchronizer On Sun, May 24, 2015 at 10:51 AM, Udara Liyanage ud...@wso2.com wrote: Hi, I tried svn based deb sync and got the following issue. DeploymentSynchronizer Enabledtrue/Enabled AutoCommittrue/AutoCommit AutoCheckouttrue/AutoCheckout RepositoryTypesvn/RepositoryType SvnUrlfile:///home/udara/experiments/depsync//SvnUrl !-- SvnUrlhttp://svnrepo.example.com/repos//SvnUrl -- SvnUserudara/SvnUser SvnPasswordudara/SvnPassword SvnUrlAppendTenantIdtrue/SvnUrlAppendTenantId /DeploymentSynchronizer Error while attempting to create the directory: file:///home/udara/experiments/depsync/-1234 org.tigris.subversion.svnclientadapter.SVNClientException: org.tigris.subversion.javahl.ClientException: svn: Unable to open an ra_local session to URL svn: Unable to open repository 'file:///home/udara/experiments/depsync' svn: Expected FS format between '1' and '4'; found format '6' at org.tigris.subversion.svnclientadapter.javahl.AbstractJhlClientAdapter.mkdir(AbstractJhlClientAdapter.java:2524) at org.wso2.carbon.deployment.synchronizer.subversion.SVNBasedArtifactRepository.checkRemoteDirectory(SVNBasedArtifactRepository.java:240) at org.wso2.carbon.deployment.synchronizer.subversion.SVNBasedArtifactRepository.init(SVNBasedArtifactRepository.java:167) at org.wso2.carbon.deployment.synchronizer.internal.repository.CarbonRepositoryUtils.newCarbonRepositorySynchronizer(CarbonRepositoryUtils.java:71) at org.wso2.carbon.deployment.synchronizer.internal.DeploymentSynchronizerComponent.initDeploymentSynchronizerForSuperTenant(DeploymentSynchronizerComponent.java:108) at org.wso2.carbon.deployment.synchronizer.internal.DeploymentSynchronizerComponent.activate(DeploymentSynchronizerComponent.java:77) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) On Sun, May 24, 2015 at 10:29 AM, Ajith Vitharana aji...@wso2.com wrote: Hi All The registry based depsync is deprecated. Please try with SVN. -Ajith On Sun, May 24, 2015 at 12:54 AM, Manoj Kumara ma...@wso2.com wrote: Hi Udara, Did you mounted the registry database between the nodes ? Please follow [1] [1] http://emsooriyabandara.blogspot.com/2013/01/registry-based-deployment-synchronizer.html *Manoj Kumara* Software Engineer WSO2 Inc. http://wso2.com/ *lean.enterprise.middleware* Mobile: +94713448188 On Sat, May 23, 2015 at 11:01 AM, Udara Liyanage ud...@wso2.com wrote: Hi, I create a AS 5.2.1 cluster with two nodes as each members is a WKA member for other members. Member join messages appeared. However when a web app is deployed to the manager node, it is not propagated to the other node. However following repo notification message appeared in the worker node. Note that I have applied the hazelcast patch patch1297 to both nodes. [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.clustering.hazelcast.HazelcastClusterMessageListener} - Received ClusteringMessage: SynchronizeRepositoryRequest{tenantId=-1234, tenantDomain='carbon.super', messageId=68bd3b2f-598a-423c-b876-bd3eb5e9bd3c} [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.deployment.SynchronizeRepositoryRequest} - Received [SynchronizeRepositoryRequest{tenantId=-1234, tenantDomain='carbon.super', messageId=68bd3b2f-598a-423c-b876-bd3eb5e9bd3c}] [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.deployment.SynchronizeRepositoryRequest} - Updating repo update required parameter -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev -- Ajith Vitharana. WSO2 Inc. - http://wso2.com Email : aji...@wso2.com Blog: http://vitharana.org Mobile : +1-812-360-5335 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] AS cluster registry debsync issue
Hi, I create a AS 5.2.1 cluster with two nodes as each members is a WKA member for other members. Member join messages appeared. However when a web app is deployed to the manager node, it is not propagated to the other node. However following repo notification message appeared in the worker node. Note that I have applied the hazelcast patch patch1297 to both nodes. [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.clustering.hazelcast.HazelcastClusterMessageListener} - Received ClusteringMessage: SynchronizeRepositoryRequest{tenantId=-1234, tenantDomain='carbon.super', messageId=68bd3b2f-598a-423c-b876-bd3eb5e9bd3c} [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.deployment.SynchronizeRepositoryRequest} - Received [SynchronizeRepositoryRequest{tenantId=-1234, tenantDomain='carbon.super', messageId=68bd3b2f-598a-423c-b876-bd3eb5e9bd3c}] [2015-05-23 10:44:35,797] INFO {org.wso2.carbon.core.deployment.SynchronizeRepositoryRequest} - Updating repo update required parameter -- Udara Liyanage Software Engineer WSO2, Inc.: http://wso2.com lean. enterprise. middleware web: http://udaraliyanage.wordpress.com phone: +94 71 443 6897 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev