[Dev] WSO2 Committers += Rukshani Athapathu

2017-11-12 Thread Gihan Anuruddha
Hi Devs,

It is my pleasure to welcome Rukshani Athapathu as a WSO2 Committer.
Rukshani has made some great contributions to product-EI and Ballerina
during the last few months and in recognition of her commitment and
contributions, she has been voted as a Committer for WSO2.

@Rukshani, welcome aboard and keep up the good work.

Regards,
Gihan

-- 
W.G. Gihan Anuruddha
Associate Technical Lead | WSO2, Inc.
M: +94772272595
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Fixing the cache mediator

2017-11-12 Thread Riyafa Abdul Hameed
Hi Milinda,

Here are some implementation details:


​
​

   - The message comes to the cache finder
   - A hash value is generated
   - This hash value is used to check if a cacheable response is there in
   the guava cache. If there's none create a new one
   - Check if the payload is null of this cacheableResponse object
   - if not null respond with the payload
   - If null add the CacheableResponse object to messageContext and
   continue to the next mediator
   - In this case when the response goes to collector store the payload in
   the CachableResponse object.


Thanks,

Riyafa

On Fri, Aug 18, 2017 at 3:43 PM, Milinda Perera  wrote:

> Hi Riyafa,
>
> What I expect is to find some implementation details without going through
> the code. For example, what kind of data structure used to store cached
> messages, whether there is a single data structure available to hold all
> cached messages or whether there is cached message holder per service,
> Whether messages are encoded to some other format, etc. If we have a little
> high-level diagram (no need to very complex one with tiny details, just
> expressing implementation details, that require attention) expressing that
> information, that will be great. Some examples [1][2].
>
> Does the documentation contain implementation information (if so that will
> be great) or documentation for WSO2 EI docs?
>
> [1] mail:AS4 support in EI
> [2] mail:[Architecture] MB4 active-passive clustering implementation
>
> Thanks,
> Milinda
>
> On Fri, Aug 18, 2017 at 1:47 PM, Riyafa Abdul Hameed 
> wrote:
>
>> Hi Milinda,
>>
>> What kind of diagram do you expect?
>> I would soon be writing the documentation on this and will be sharing
>> with everyone.
>>
>> Thanks.
>> Riyafa
>>
>> On Fri, Aug 18, 2017 at 1:39 PM, Milinda Perera 
>> wrote:
>>
>>> Hi Riyafa,
>>>
>>> Can you share some design diagram if it is possible to get some idea of
>>> current implementation?
>>>
>>> Thanks,
>>> Milinda
>>>
>>> On Mon, Jul 10, 2017 at 4:40 PM, Riyafa Abdul Hameed 
>>> wrote:
>>>
 Dear all,

 I came up with the following configurations for the cache mediator
 rewrite:

>  [scope=(per-host | per-mediator)] collector=(true | false)
> [maxMessageSize="in-bytes"] HTTPMethodToCache = (GET | POST)]>
>
>   
>
> (mediator)+
>
>   ?
>
>   
>
> 
>

 As I have mentioned in the requirements doc[1], the only reason we are
 allowing responses to POST messages to be cached is because POST is the
 only method used in SOAP implementations. Now having looked at the
 implementation details further I understand that it is possible to identify
 whether a request is soap or not without having it externally configured.
 So my question is whether the configuration "HTTPMethodToCache" is actually
 required because it can be internally processed whether request is SOAP or
 REST and then cache accordingly.


 [1] https://docs.google.com/document/d/1iPtArrW6C-VgzAzjjSsLmG9a
 qAFEubmFgNkQhoDvqz8/edit


 Thank you.

 Yours sincerely,

 Riyafa


 On Thu, Jul 6, 2017 at 9:50 AM, Riyafa Abdul Hameed 
 wrote:

> Thank you for the suggestions Rajkumar.
>
>
> On Thu, Jul 6, 2017 at 6:57 AM, Rajkumar Rajaratnam <
> rajkum...@wso2.com> wrote:
>
>> Also the existing cache mediator doesn't honor the cache ID as per my
>> testing sometimes back (not sure it's fixed though). It means caching 
>> works
>> globally, not at cache mediator instance level.
>>
>> If we can't correlate a finder with a collector (using cache mediator
>> ID), then we are going to hit memory issues.
>>
>> Here is the reason.
>>
>> Let's say we have two APIs - location and exchange.
>>
>>1. /location API response size is 10 MB and we have 100 different
>>responses
>>2. /exchange API response size is 1MB and we have 1000 different
>>responses
>>
>> If we want to enable response caching for these two APIs, if we can
>> correlate a finder with a collector (i.e if we support caching at cache
>> mediator instance level), then I can allocate 100*10 + 1000*1 = 2000 MB
>> memory to the JVM in addition to our recommended memory settings, so that
>> it will never go OOM.
>>
>> If we can't correlate a finder with a collector (i.e, if we support
>> global caching), then I have to allocate 1100 * 10 = 11000 MB memory. 
>> See I
>> have to use additional 9000 MB if we don't honor cache ID. It's not
>> practical and efficient because memory is expensive - so it doesn't 
>> scale.
>>
>> Can we fix this issue and honor cache ID please in the next EI
>> release?
>>
>
> Yes we need to honor this as you suggest and I shall 

Re: [Dev] Extending BCJSSE for Token binding

2017-11-12 Thread Inthirakumaaran Tharmakulasingham
I think there is a signature verification problem when using bouncy castle
provider.You can find the details of the past problem in the link[1].(got
this problem 3 years ago)

I started the conversation with BC developers and they're not going to
implement token binding extension by them self in near future.The new
extension, they added on user request was a small one and they already
had implemented it but commented out for some reason.Details about that
extension are in this link[2].But they are okay with sending PR for token
binding implementation.If it is merged then we can reach java community
easily.More details about the conversation can be found at this link[3].

When I talked to BC providers they mentioned about an extension API which
can be used to add a new extension in the handshake.I did some digging into
that and it seems is possible to create a token binding extension and have
to put that into that API.Rest of the negotiations will be done by that
API.So currently I am in the process of developing an extension that could
fit into that API.

Reference:
  [1]Bouncy castle issue mail thread

  [2]https://github.com/bcgit/bc-java/issues/234
  [3]https://github.com/bcgit/bc-java/issues/250



On Fri, Nov 10, 2017 at 8:34 AM, KasunG Gajasinghe  wrote:

> Hi Indra,
>
> Can you find out exactly what issues we faced before? I'm assuming it has
> something to do with jar signing.
>
> The work we are doing is not specific to wso2 but applies to entire Java
> community and bouncycastle users. So, our end goal should be get this
> merged into bouncycastle project.
>
> Please start a dialogue with BC developers asap. They are on GitHub now I
> suppose.
>
> Bouncycastle just added a new tls extension last month, and the community
> quite active.
>
> @Prabath, please share your thoughts.
>
> Thanks,
> KasunG
>
> On Thu, Nov 9, 2017 at 2:10 PM Inthirakumaaran Tharmakulasingham <
> inthirakumaa...@wso2.com> wrote:
>
>> Hi,
>> I am trying to create a Token binding library for TLS layer.One option
>> for this to extend BCJSSE and write the implementations on top of it.But in
>> the past, there have been some issues in making changes in Bouncy
>> Castle.How can I proceed with this?OR any better way to write the library?
>>
>> Basically, our intention is to make a token binding library so that
>> anyone can create HTTP client which can support token binding.Thus we hope
>> to send a PR to BC after completing the implementation.
>>
>>
>> --
>> Inthirakumaaran
>> Software Engineering - Intern | WSO2
>>
>> Email: inthirakumaa...@wso2.com
>> Mobile:0766598050
>>
>> --
>
> *Kasun Gajasinghe*Associate Technical Lead, WSO2 Inc.
> email: kasung AT spamfree wso2.com
> linked-in: http://lk.linkedin.com/in/gajasinghe
> blog: http://kasunbg.org
> phone: +1 650-745-4499 <(650)%20745-4499>, 77 678 0813
>
>



-- 
Inthirakumaaran
Software Engineering - Intern | WSO2

Email: inthirakumaa...@wso2.com
Mobile:0766598050
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [IS as Key Manager] Error when generating keys for application

2017-11-12 Thread Ruthryi Kulasekaran
Ack for docs!

Thanks,
Ruthryi

On Mon, Nov 13, 2017 at 12:20 PM, Dilshani Subasinghe 
wrote:

> Adding Documentation team.
>
> Yes, I agree with Rajith. It will be better to mention in docs as normal
> users not gonna identify the requirement of having client credential grant
> type with SAML grant type.
>
> Reported Jira on this to track the progress [1].
>
> [1] https://wso2.org/jira/browse/DOCUMENTATION-6403
>
> On Fri, Nov 10, 2017 at 9:40 AM, Rajith Roshan  wrote:
>
>> Hi all,
>> I think it's better to include this in our documentation (quick start
>> [1], cloud -[2]), that in store UI generate keys and regenerate will always
>> generate access token using client credentials, even though the Oauth app
>> is enabled for multiple grant types.
>> Or shall we add a tool tip to generate keys button and regenerate button
>> to say that this will use client credential grant type.
>>
>> [1] - https://docs.wso2.com/display/AM210/Quick+Start+Guide
>> [2] - https://docs.wso2.com/display/APICloud/Subscribe+to+and+
>> Invoke+an+API
>>
>> On Thu, Nov 9, 2017 at 7:58 PM, Sanjeewa Malalgoda 
>> wrote:
>>
>>> Yes in UI when we click on generate keys button it will create oauth2
>>> app and generate tokens using client credentials(first time).
>>> To complete both we need client credentials grant. In back end we do not
>>> have such limitation we are anyway doing 2 different service calls.
>>> If someone need to enable only SAML then after initial token generation
>>> we can disable it. Its good to have options to generate key/secret,
>>> generate tokens separately.
>>> Since this behavior was there for sometime we will not need to change it
>>> suddenly. But we can consider that in future.
>>>
>>> Thanks,
>>> sanjeewa.
>>>
>>> On Thu, Nov 9, 2017 at 7:32 PM, Saneth Dharmakeerthi 
>>> wrote:
>>>
 Hi APIM Team,

 Docent this a limitation of Store UI?

 Customer who is using SAML or authorization code grant,  Why he needs
 to enable client_credential? Inst this a security risk? The only thing
 he needs to do is getting the  Client ID and Client Secret, But in Store UI
 it only shows those after click Generate Key button.



 Thanks and Best Regards,

 Saneth Dharmakeerthi
 *Associate Technical Lead*
 WSO2, Inc.
 Mobile: +94772325511 <077%20232%205511>

 

 On Thu, Nov 9, 2017 at 9:37 AM, Dilshani Subasinghe 
 wrote:

> Hi Fazlan,
>
> Ok, now I got it. Thanks for explaining it.
>
> Regards,
> Dilshani
>
> On Thu, Nov 9, 2017 at 9:21 AM, Fazlan Nazeem 
> wrote:
>
>> Hi Dilshani,
>>
>> SAML grant does not depend on client_credentials grant being enabled,
>> but in store UI when we generate keys using the Generate Keys button,
>> client_credentials grant is used to generate the token. Therefore you 
>> have
>> to enable client_credentials grant if you are generating keys via UI. I
>> think this is what Hrasha meant.
>>
>> On Thu, Nov 9, 2017 at 12:20 AM, Dilshani Subasinghe <
>> dilsh...@wso2.com> wrote:
>>
>>> Hi Harsha,
>>>
>>> Thanks for prompt reply. Will follow that. Hope we need to specify
>>> that client_credentials grant need for enabling SAML grant in the
>>> documentation.
>>>
>>> Regards,
>>> Dilshani
>>>
>>> On Thu, Nov 9, 2017 at 12:08 AM, Harsha Kumara 
>>> wrote:
>>>
 Hi Dilshani,

 If you need to generate a token using SAML2 grant you may follow
 [1]. In store, you need to select client_credentials grant as we used 
 it in
 the store to generate the token for an application.

 [1] https://docs.wso2.com/display/AM1100/Exchanging+SAML2+Be
 arer+Tokens+with+OAuth2+-+SAML+Extension+Grant+Type

 On Thu, Nov 9, 2017 at 12:01 AM, Dilshani Subasinghe <
 dilsh...@wso2.com> wrote:

> Hi APIM/IS Team,
>
> I'm working with IS as Key manager setup. (APIM 2.1.0 and
> wso2is-km-5.3.0). In APIM, while generating keys for Applications with
> "SAML" as grant type, it may give an error as follows [1]:
>
> [2017-11-08 23:51:34,102] ERROR - APIUtil Error occurred while
> executing SubscriberKeyMgtClient.
> java.lang.RuntimeException: Error occurred while calling token
> endpoint: HTTP error code : 400
> at org.wso2.carbon.apimgt.impl.AMDefaultKeyManagerImpl.getNewAp
> plicationAccessToken(AMDefaultKeyManagerImpl.java:367)
> at org.wso2.carbon.apimgt.impl.workflow.AbstractApplicationRegi
> strationWorkflowExecutor.dogenerateKeysForApplication(Abstra
> ctApplicationRegistrationWorkflowExecutor.java:151)
> at 

Re: [Dev] Exception while invoking proxy service in ESB 5.0.0

2017-11-12 Thread Dilusha Alphonso
1.I invoke the proxy service in ESB 5.0.0.

2.I attached a wire log of the proxy service.

[2017-11-13 12:48:06,483] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"POST /services/Durdans HTTP/1.1[\r][\n]"
[2017-11-13 12:48:06,484] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"Accept-Encoding: gzip,deflate[\r][\n]"
[2017-11-13 12:48:06,484] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"Content-Type: text/xml;charset=UTF-8[\r][\n]"
[2017-11-13 12:48:06,484] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"SOAPAction: "urn:postMediData"[\r][\n]"
[2017-11-13 12:48:06,484] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"Content-Length: 2149[\r][\n]"
[2017-11-13 12:48:06,484] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"Host: dilusha-ThinkPad-X1-Carbon-5th:8243[\r][\n]"
[2017-11-13 12:48:06,484] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"Connection: Keep-Alive[\r][\n]"
[2017-11-13 12:48:06,484] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"User-Agent: Apache-HttpClient/4.1.1 (java 1.5)[\r][\n]"
[2017-11-13 12:48:06,484] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\r][\n]"
[2017-11-13 12:48:06,484] DEBUG - headers http-incoming-4 >> POST
/services/Durdans HTTP/1.1
[2017-11-13 12:48:06,484] DEBUG - headers http-incoming-4 >>
Accept-Encoding: gzip,deflate
[2017-11-13 12:48:06,484] DEBUG - headers http-incoming-4 >> Content-Type:
text/xml;charset=UTF-8
[2017-11-13 12:48:06,484] DEBUG - headers http-incoming-4 >> SOAPAction:
"urn:postMediData"
[2017-11-13 12:48:06,484] DEBUG - headers http-incoming-4 >>
Content-Length: 2149
[2017-11-13 12:48:06,484] DEBUG - headers http-incoming-4 >> Host:
dilusha-ThinkPad-X1-Carbon-5th:8243
[2017-11-13 12:48:06,484] DEBUG - headers http-incoming-4 >> Connection:
Keep-Alive
[2017-11-13 12:48:06,485] DEBUG - headers http-incoming-4 >> User-Agent:
Apache-HttpClient/4.1.1 (java 1.5)
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"http://schemas.xmlsoap.org/soap/envelope/;
xmlns:ser="http://service.sample.durdans.com; xmlns:xsd="
http://dto.service.sample.durdans.com/xsd;>[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"  [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
" [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
" [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   ?[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   ?[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   ?[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   ?[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   ?[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,487] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   ?[\n]"
[2017-11-13 12:48:06,488] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,488] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   ?[\n]"
[2017-11-13 12:48:06,488] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   [\n]"
[2017-11-13 12:48:06,488] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"   ?[\n]"
[2017-11-13 12:48:06,488] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"
[2017-11-13 12:48:06,488] DEBUG - wire HTTPS-Listener I/O dispatcher-1 >>
"[\n]"

Re: [Dev] Exception in ESB 5.0.0 while creating an API.

2017-11-12 Thread Piriya Sivalingam
Hi,

I think its something similar to [1] and according to that I managed to
resolve it by adding a dummy header.

[1] [Dev] Exception with header

Thanks,
Piriya

On Sun, Nov 12, 2017 at 12:27 PM, Piriya Sivalingam  wrote:

> I am attaching the WSDL of my deployed backend service.
>
>
>
> On Sun, Nov 12, 2017 at 11:47 AM, Piriya Sivalingam 
> wrote:
>
>> I am attaching the WSDL of my proxy service.
>>
>>
>>
>> On Sun, Nov 12, 2017 at 11:44 AM, Mushthaq Rumy 
>> wrote:
>>
>>> Hi Piriya,
>>>
>>> Can you attach the proxy WSDL file?
>>>
>>> Thanks & Regards,
>>> Mushthaq
>>>
>>> On Sun, Nov 12, 2017 at 10:53 AM, Piriya Sivalingam 
>>> wrote:
>>>
 Hi Mushthaq,

 I tried the same operation in SOAPUI and it works fine. "readNinewells"
 is a correct operation.

 Thanks.

 On Sun, Nov 12, 2017 at 12:55 AM, Mushthaq Rumy 
 wrote:

> Hi Pririya,
>
> Seems like the operation you use is an incorrect operation. Was this
> working fine in SOAPUI? Could you please check if *"readNinewells" *is
> the correct operation?
>
> Thanks & Regards,
> Mushthaq
>
> On Sat, Nov 11, 2017 at 11:59 PM, Piriya Sivalingam 
> wrote:
>
>> Hi,
>>
>> I am creating an API in ESB 5.0.0 for GET Resource, where I have a
>> secured SOAP backend service. Below is my synapse configuration of the 
>> API.
>> I find some error logged in the console.
>>
>> 
>> http://ws.apache.org/ns/synapse;
>>  name="PatientAPI"
>>  context="/patientapi">
>>
>>   
>>  >  scope="transport"
>>  value="Basic cGlyaXlhOnBpcml5YTEyMw=="/>
>>  
>> 
>>http://schemas.
>> xmlsoap.org/soap/envelope/"
>>  xmlns:ser="http://service.sam
>> ple.ninewells.com">
>>   
>>   
>>  
>> 
>>  
>>   
>>
>> 
>> 
>>
>> 
>>  
>>  
>>  > scope="transport"/>
>>  >value="application/soap+xml"
>>scope="axis2"
>>type="STRING"/>
>>  
>> 
>>https://.xx.xx.xx:xxx
>> 3/services/NinewellsPatientService"
>> format="soap11"/>
>> 
>>  
>>   
>>   
>>  >value="application/json"
>>scope="axis2"
>>type="STRING"/>
>>  
>>   
>>
>> 
>>
>> There is a 500 Internal Server Error logged in the console.
>>
>> Below is the exception found.
>> {"faultstring":"The endpoint reference (EPR) for the Operation not
>> found is /services/DurdansPatientService and the WSA Action = null.
>> If this EPR was previously reachable, please contact the server
>> administrator."}
>>
>> Highly appreciate your advice on this.
>>
>> Thanks.
>>
>> --
>> Regards,
>>
>> *Piriya Sivalingam*
>>
>> *Software Engineer - Support Team*
>>
>> *WSO2*
>> *Mobile : +94 77 8462039 <+94%2077%20846%202039>*
>>
>> [image: http://wso2.com/signature] 
>>
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Mushthaq Rumy
> *Software Engineer*
> Mobile : +94 (0) 779 492140 <%2B94%20%280%29%20773%20451194>
> Email : musht...@wso2.com
> WSO2, Inc.; http://wso2.com/
> lean . enterprise . middleware.
>
> 
>



 --
 Regards,

 *Piriya Sivalingam*

 *Software Engineer - Support Team*

 *WSO2*
 *Mobile : +94 77 8462039 <+94%2077%20846%202039>*

 [image: http://wso2.com/signature] 


>>>
>>>
>>> --
>>> Mushthaq Rumy
>>> *Software Engineer*
>>> Mobile : +94 (0) 779 492140 <%2B94%20%280%29%20773%20451194>
>>> Email : musht...@wso2.com
>>> WSO2, Inc.; http://wso2.com/
>>> lean . enterprise . middleware.
>>>
>>> 
>>>
>>
>>
>>
>> --
>> Regards,
>>
>> *Piriya Sivalingam*
>>
>> *Software Engineer - Support Team*
>>
>> *WSO2*
>> *Mobile : +94 77 8462039 <+94%2077%20846%202039>*
>>
>> [image: http://wso2.com/signature] 
>>
>>
>
>
> --
> Regards,
>
> *Piriya Sivalingam*
>
> *Software Engineer - Support Team*
>
> *WSO2*
> 

Re: [Dev] Exception when Publishing API in API Manager 2.1.0

2017-11-12 Thread Piriya Sivalingam
Hi,

Since I have some mediation to be done inside the sequences, I think it is
better to create the API in ESB than in API Manager. And now I managed to
create the API in ESB 5.0.0 and it works fine.
However, I will try it and let you know.

Thanks,
Piriya

On Sat, Nov 11, 2017 at 7:48 PM, Rukshan Premathunga 
wrote:

> Hi Priya,
>
> In the screenshot you have attached, it says to select a GW environment to
> be publish. Can you expand the gateway environment section and select a
> option first.
>
> Thanks and Regards
>
> On Sat, Nov 11, 2017 at 11:47 AM, Piriya Sivalingam 
> wrote:
>
>> Thank you Mushthaq for your prompt response.
>>
>> But I couldn't find any errors logged in the console. I am attaching the
>> wso2carbon.log file.
>>
>> On Fri, Nov 10, 2017 at 7:23 PM, Mushthaq Rumy  wrote:
>>
>>> Hi Piriya,
>>>
>>> Was there any error logged in the console. If so could you please attach
>>> the error log?
>>>
>>> Thanks & Regards,
>>> Mushthaq
>>>
>>> On Fri, Nov 10, 2017 at 5:27 PM, Piriya Sivalingam 
>>> wrote:
>>>
 Hi,

 I am working on a task where I have followed the below steps:


- There is a SOAP backend which is hosted on Application Server and
secured UT over Transport.
- I have created a proxy service in ESB 5.0.0 having the SOAP
backend as the endpoint of the proxy.
- Then I followed this [1] blog to create an API in API Manager
2.1.0 having the created ESB as the endpoint of the API.
- According to the blog when I create the API, I couldn't publish
this API. I could notice some exception in the Publisher UI.

 I am attaching a screenshot of the Publisher when it gives the
 exception.
 Could you please suggest me the reason for this exception and whether I
 have done something wrong here and how can I solve this issue?

 [1] https://medium.com/@shenavi21/exposing-a-soap-service-as
 -a-managed-rest-api-288676e06418

 Highly appreciate your suggestion on this.

 Thanks.
 --
 Regards,

 *Piriya Sivalingam*

 *Software Engineer - Support Team*

 *WSO2*
 *Mobile : +94 77 8462039 <+94%2077%20846%202039>*

 [image: http://wso2.com/signature] 

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


>>>
>>>
>>> --
>>> Mushthaq Rumy
>>> *Software Engineer*
>>> Mobile : +94 (0) 779 492140 <%2B94%20%280%29%20773%20451194>
>>> Email : musht...@wso2.com
>>> WSO2, Inc.; http://wso2.com/
>>> lean . enterprise . middleware.
>>>
>>> 
>>>
>>
>>
>>
>> --
>> Regards,
>>
>> *Piriya Sivalingam*
>>
>> *Software Engineer - Support Team*
>>
>> *WSO2*
>> *Mobile : +94 77 8462039 <+94%2077%20846%202039>*
>>
>> [image: http://wso2.com/signature] 
>>
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> Rukshan Chathuranga.
> Software Engineer.
> WSO2, Inc.
> +94711822074 <+94%2071%20182%202074>
>



-- 
Regards,

*Piriya Sivalingam*

*Software Engineer - Support Team*

*WSO2*
*Mobile : +94 77 8462039*

[image: http://wso2.com/signature] 
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [IS as Key Manager] Error when generating keys for application

2017-11-12 Thread Dilshani Subasinghe
Adding Documentation team.

Yes, I agree with Rajith. It will be better to mention in docs as normal
users not gonna identify the requirement of having client credential grant
type with SAML grant type.

Reported Jira on this to track the progress [1].

[1] https://wso2.org/jira/browse/DOCUMENTATION-6403

On Fri, Nov 10, 2017 at 9:40 AM, Rajith Roshan  wrote:

> Hi all,
> I think it's better to include this in our documentation (quick start [1],
> cloud -[2]), that in store UI generate keys and regenerate will always
> generate access token using client credentials, even though the Oauth app
> is enabled for multiple grant types.
> Or shall we add a tool tip to generate keys button and regenerate button
> to say that this will use client credential grant type.
>
> [1] - https://docs.wso2.com/display/AM210/Quick+Start+Guide
> [2] - https://docs.wso2.com/display/APICloud/Subscribe+to+
> and+Invoke+an+API
>
> On Thu, Nov 9, 2017 at 7:58 PM, Sanjeewa Malalgoda 
> wrote:
>
>> Yes in UI when we click on generate keys button it will create oauth2 app
>> and generate tokens using client credentials(first time).
>> To complete both we need client credentials grant. In back end we do not
>> have such limitation we are anyway doing 2 different service calls.
>> If someone need to enable only SAML then after initial token generation
>> we can disable it. Its good to have options to generate key/secret,
>> generate tokens separately.
>> Since this behavior was there for sometime we will not need to change it
>> suddenly. But we can consider that in future.
>>
>> Thanks,
>> sanjeewa.
>>
>> On Thu, Nov 9, 2017 at 7:32 PM, Saneth Dharmakeerthi 
>> wrote:
>>
>>> Hi APIM Team,
>>>
>>> Docent this a limitation of Store UI?
>>>
>>> Customer who is using SAML or authorization code grant,  Why he needs
>>> to enable client_credential? Inst this a security risk? The only thing
>>> he needs to do is getting the  Client ID and Client Secret, But in Store UI
>>> it only shows those after click Generate Key button.
>>>
>>>
>>>
>>> Thanks and Best Regards,
>>>
>>> Saneth Dharmakeerthi
>>> *Associate Technical Lead*
>>> WSO2, Inc.
>>> Mobile: +94772325511 <077%20232%205511>
>>>
>>> 
>>>
>>> On Thu, Nov 9, 2017 at 9:37 AM, Dilshani Subasinghe 
>>> wrote:
>>>
 Hi Fazlan,

 Ok, now I got it. Thanks for explaining it.

 Regards,
 Dilshani

 On Thu, Nov 9, 2017 at 9:21 AM, Fazlan Nazeem  wrote:

> Hi Dilshani,
>
> SAML grant does not depend on client_credentials grant being enabled,
> but in store UI when we generate keys using the Generate Keys button,
> client_credentials grant is used to generate the token. Therefore you have
> to enable client_credentials grant if you are generating keys via UI. I
> think this is what Hrasha meant.
>
> On Thu, Nov 9, 2017 at 12:20 AM, Dilshani Subasinghe <
> dilsh...@wso2.com> wrote:
>
>> Hi Harsha,
>>
>> Thanks for prompt reply. Will follow that. Hope we need to specify
>> that client_credentials grant need for enabling SAML grant in the
>> documentation.
>>
>> Regards,
>> Dilshani
>>
>> On Thu, Nov 9, 2017 at 12:08 AM, Harsha Kumara 
>> wrote:
>>
>>> Hi Dilshani,
>>>
>>> If you need to generate a token using SAML2 grant you may follow
>>> [1]. In store, you need to select client_credentials grant as we used 
>>> it in
>>> the store to generate the token for an application.
>>>
>>> [1] https://docs.wso2.com/display/AM1100/Exchanging+SAML2+Be
>>> arer+Tokens+with+OAuth2+-+SAML+Extension+Grant+Type
>>>
>>> On Thu, Nov 9, 2017 at 12:01 AM, Dilshani Subasinghe <
>>> dilsh...@wso2.com> wrote:
>>>
 Hi APIM/IS Team,

 I'm working with IS as Key manager setup. (APIM 2.1.0 and
 wso2is-km-5.3.0). In APIM, while generating keys for Applications with
 "SAML" as grant type, it may give an error as follows [1]:

 [2017-11-08 23:51:34,102] ERROR - APIUtil Error occurred while
 executing SubscriberKeyMgtClient.
 java.lang.RuntimeException: Error occurred while calling token
 endpoint: HTTP error code : 400
 at org.wso2.carbon.apimgt.impl.AMDefaultKeyManagerImpl.getNewAp
 plicationAccessToken(AMDefaultKeyManagerImpl.java:367)
 at org.wso2.carbon.apimgt.impl.workflow.AbstractApplicationRegi
 strationWorkflowExecutor.dogenerateKeysForApplication(Abstra
 ctApplicationRegistrationWorkflowExecutor.java:151)
 at org.wso2.carbon.apimgt.impl.workflow.AbstractApplicationRegi
 strationWorkflowExecutor.generateKeysForApplication(Abstract
 ApplicationRegistrationWorkflowExecutor.java:118)
 at org.wso2.carbon.apimgt.impl.workflow.ApplicationRegistration
 

Re: [Dev] Enabling REST to SOAP sample gives an error

2017-11-12 Thread Praneesha Chandrasiri
hi Buddhimala,

Thanks for pointing that out!

It is better to explain why we need to do that in the doc. Therefore, I
have corrected the note now.

On Mon, Nov 13, 2017 at 11:24 AM, Thivya Mahenthirarasa 
wrote:

> Thank you vijitha, I could able to resolve the error by using your
> proposed method.
>
>
>
> On Mon, Nov 13, 2017 at 10:35 AM, Buddhimala Ranasinghe <
> buddhim...@wso2.com> wrote:
>
>> Hi Praneesha,
>>
>> I have checked the update done in [1].
>>
>> However, the line "Therefore, when you uncomment this property, WSO2 ESB
>> does not apply this default content type when sending the message." seems
>> like confusing the readers with the line "Comment out the
>> http.headers.preserve=Content-Type parameter in the
>> /conf/passthru-http.properties file.".
>>
>> Therefore, shall we simply say the reader to comment out the relevant
>> parameter?
>>
>> [1] https://docs.wso2.com/display/ESB500/Configuring+Specifi
>> c+Use+Cases#ConfiguringSpecificUseCases-EnablingRESTtoSOAP
>>
>> Regards,
>> Buddhimala
>>
>> On Mon, Nov 13, 2017 at 10:33 AM, Buddhimala Ranasinghe <
>> buddhim...@wso2.com> wrote:
>>
>>> Hi Praneesha,
>>>
>>> I have checked the update done in [1].
>>>
>>> However, the line "Therefore, when you uncomment this property, WSO2 ESB
>>> does not apply this default content type when sending the message." seems
>>> like confusing the readers with the line "Comment out the
>>> http.headers.preserve=Content-Type parameter in the
>>> /conf/passthru-http.properties file.".
>>>
>>> Therefore, shall we simply say the reader to comment out the relevant
>>> parameter?
>>>
>>> Regards,
>>> Buddhimala
>>>
>>> On Fri, Nov 10, 2017 at 7:53 PM, Praneesha Chandrasiri <
>>> pranee...@wso2.com> wrote:
>>>
 This is applicable only to WSO2 ESB 5.0.0 and is fixed in WSO2 EI.
 Therefore, updated [1] accordingly.

 Thanks for the support Vijitha and Milinda!

 [1] https://docs.wso2.com/display/ESB500/Configuring+Specific+Use+Cases

 On Fri, Nov 10, 2017 at 5:21 PM, Vijitha Ekanayake 
 wrote:

> [++ documentation]
>
> The reason for the issue seems to be, ESB is preserving the
> Content-Type header as the default behavior. Since GET request doesn't 
> have
> a Content-Type, ESB sends application/x-www-form-urlencoded as the
> Content-Type to the backend which is the reason for this failure. To
> overcome this issue you can comment out the following parameter in the
> passthru-http.properties.
>
> http.headers.preserve=Content-Type
>
> Thanks,
> Vijitha.
>
> On Fri, Nov 10, 2017 at 5:04 PM, Vijitha Ekanayake 
> wrote:
>
>> Hi Buddhimala,
>>
>> The reason for the issue seems to be, ESB is preserving the
>> Content-Type header as the default behavior. Since GET request doesn't 
>> have
>> a Content-Type, ESB sends application/x-www-form-urlencoded as the
>> Content-Type to the backend which is the reason for this failure. To
>> overcome this issue you can comment out the following parameter in the
>> passthru-http.properties.
>>
>> http.headers.preserve=Content-Type
>>
>> Thanks,
>> Vijitha.
>>
>>
>> On Fri, Nov 10, 2017 at 4:29 PM, Buddhimala Ranasinghe <
>> buddhim...@wso2.com> wrote:
>>
>>> Hi All,
>>>
>>> Today I tried out "Enabling REST to SOAP" sample in ESB as per the
>>> following wso2 document.
>>>
>>> https://docs.wso2.com/display/ESB500/Configuring+Specific+Us
>>> e+Cases#ConfiguringSpecificUseCases-EnablingRESTtoSOAP
>>>
>>> But when I tried to invoke the API using the curl command, I got
>>> following error.
>>>
>>> The endpoint reference (EPR) for the Operation not
>>> found is /services/SimpleStockQuoteService and the WSA Action =
>>> null. If this EPR was previously reachable, please contact the server
>>> administrator.
>>>
>>> And the axis2 server side it gave the following error.
>>>
>>> [2017-11-10 16:25:33,268] ERROR {org.apache.axis2.engine.AxisEngine}
>>> -  The endpoint reference (EPR) for the Operation not found is
>>> /services/SimpleStockQuoteService and the WSA Action = null. If
>>> this EPR was previously reachable, please contact the server 
>>> administrator.
>>> org.apache.axis2.AxisFault: The endpoint reference (EPR) for the
>>> Operation not found is /services/SimpleStockQuoteService and the
>>> WSA Action = null. If this EPR was previously reachable, please contact 
>>> the
>>> server administrator.
>>> at org.apache.axis2.engine.DispatchPhase.checkPostConditions(Di
>>> spatchPhase.java:102)
>>> at org.apache.axis2.engine.Phase.invoke(Phase.java:329)
>>> at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:26
>>> 1)
>>> at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:1

Re: [Dev] Exception while invoking proxy service in ESB 5.0.0

2017-11-12 Thread Saneth Dharmakeerthi
Hi Dilusha,


Its bit unclear  how you execute this,

1) From SOAP-UI you invoke APIM or ESB?

2) Enable the wire logs and share them (both APIM and ESB as needed)





Thanks and Best Regards,

Saneth Dharmakeerthi
*Associate Technical Lead*
WSO2, Inc.
Mobile: +94772325511



On Sat, Nov 11, 2017 at 3:22 PM, Dilusha Alphonso  wrote:

> I have attached the diagram of task.
> [image: Inline image 1]
>
> In ESB 5.0.0 I created the proxy service. Those configurations attached
> below.
>
> 
> http://ws.apache.org/ns/synapse;
>name="Durdans"
>startOnLoad="true"
>statistics="disable"
>trace="disable"
>transports="http,https">
>
>   
>  scope="transport"
>value="Basic ZGlsdXNoYTpkaWx1c2hhMTIz"/>
>  
> 
>https://192.168.55.160:9443/services/
> DurdansPatientService"/>
> 
>  
>   
>   
>  
>   
>
>http://192.168.55.160:9763/services/
> DurdansPatientService?wsdl"/>
>
> 
>
> When I invoke the proxy service using SOAPUI. I got the above exception.
>
> Thanks
> Dilusha
>
>
>
>
> On Sat, Nov 11, 2017 at 12:38 AM, Vijitha Ekanayake 
> wrote:
>
>> Hi Dilusha,
>>
>> Can you provide more context about the scenario and share the complete
>> configurations to provide you a solution.
>>
>> Thanks.
>>
>> On Fri, Nov 10, 2017 at 5:29 PM, Dilusha Alphonso 
>> wrote:
>>
>>> Hi All,
>>>
>>> I am working on the scenario. where I have to create a proxy service in
>>> ESB 5.0.0 using a WSDL of a SOAP backend service. When I invoke the proxy
>>> service using SOAPUI I am getting some error.
>>>
>>>  When I invoke the service with the GET method I get the proper
>>> response, but for POST method I could get 202 Accepted response with some
>>> exception in the log.
>>>
>>> java.lang.UnsupportedOperationException: An access occurred
>>> that is not valid.
>>> at org.apache.axis2.description.InOnlyAxisOperation.getMessage(
>>> InOnlyAxisOperation.java:117)
>>> at org.apache.synapse.core.axis2.SynapseCallbackReceiver.handle
>>> Message(SynapseCallbackReceiver.java:324)
>>> at org.apache.synapse.core.axis2.SynapseCallbackReceiver.receiv
>>> e(SynapseCallbackReceiver.java:188)
>>> at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:180)
>>> at org.apache.synapse.transport.passthru.ClientWorker.run(Clien
>>> tWorker.java:261)
>>> at org.apache.axis2.transport.base.threads.NativeWorkerPool$1.r
>>> un(NativeWorkerPool.java:172)
>>> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPool
>>> Executor.java:1142)
>>> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoo
>>> lExecutor.java:617)
>>> at java.lang.Thread.run(Thread.java:748)
>>>
>>> Could you please advice on this?
>>>
>>> Thanks
>>> Dilusha
>>> --
>>>
>>>
>>> *Best Regards,Dilusha Alphonso*
>>>
>>> *Software Engineer - Support Team*
>>>
>>>
>>> *WSO2*
>>> *Mobile : *
>>>
>>> *+94766837098 <+94%2076%20683%207098>[image: http://wso2.com/signature]
>>> *
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Vijitha Ekanayake
>> Senior Software Engineer*, *WSO2, Inc.; http://wso2.com/
>> Mobile : +94 777 24 73 39 | +94 718 74 44 08
>> lean.enterprise.middleware
>>
>
>
>
> --
>
>
> *Best Regards,Dilusha Alphonso*
>
> *Software Engineer - Support Team*
>
>
> *WSO2*
> *Mobile : *
>
> *+94766837098 <+94%2076%20683%207098>[image: http://wso2.com/signature]
> *
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DEV] CRUD operation in API response with 202 accepted but operations are not performed

2017-11-12 Thread Thivya Mahenthirarasa
Hi Himasha,

Thank you for the prompt response. I have got it work fine.


Thanks,
Thivya

On Mon, Nov 13, 2017 at 11:38 AM, Himasha Guruge  wrote:

> Hi Thivya,
>
> As discussed offline given [1],  since you are not setting a content type
> header in the request, 'application/x-www-form-urlencoded' is preserved
> as default hence above fix would work.
>
> [1] https://docs.wso2.com/display/ESB500/Configuring+Specific+Use+Cases#
> ConfiguringSpecificUseCases-EnablingRESTtoSOAP
>
> Thanks,
> Himasha
>
> On Mon, Nov 13, 2017 at 11:30 AM, Thivya Mahenthirarasa 
> wrote:
>
>> Hi Himasha,
>>
>> ESB sends application/x-www-form-urlencoded as the Content-Type to the
>> backend which is the reason for this failure. When I do comment out the
>> following parameter in the passthru-http.properties.
>>
>> http.headers.preserve=Content-Type.
>>
>> Also When i configured  args as > expression="get-property('uri.var.patientId')"/> I could able to receive
>> the json response.
>>
>> Thank you
>>
>> On Mon, Nov 13, 2017 at 9:53 AM, Thivya Mahenthirarasa 
>> wrote:
>>
>>> Hi Himasha
>>>
>>> As you said having xml in the media type also ended up with the same
>>> response. What could be the root cause that the request couldn' t reach the
>>> backend?
>>>
>>>
>>> Thank you
>>>
>>> On Mon, Nov 13, 2017 at 8:21 AM, Himasha Guruge 
>>> wrote:
>>>
 Hi Thivya,

  Could you verify the media type you have used in payload 
 mediator?(>>> media-type="soap+xml">)  AFAIK, you can only use xml/json there [1] .
 According to the wire logs the request that is been sent is an empty
 soap envelope which means your request content has not been set through
 payload mediator.

 "Direction: request, Envelope: >>> encoding='utf-8'?>http://schemas.
 xmlsoap.org/soap/envelope/">"

 [1] https://docs.wso2.com/display/ESB500/PayloadFactory+Medi
 ator#PayloadFactoryMediator-Syntax

 Thanks,
 Himasha

 On Mon, Nov 13, 2017 at 12:33 AM, Thivya Mahenthirarasa <
 thi...@wso2.com> wrote:

> Hi ,
> Thank you for the response.
>
> I wonder that no request is sent to the back-end service. Just ESB is
> sending a response to the rest client that it accepts the requests. What
> might be the root cause?. This behavior occurs in all other resources
> too(DELETE, PUT, POST).
>
> What might be the root cause for this? Find the wire logs attached.
>
>
> [2017-11-13 00:27:48,651] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "GET /services/CentralPatientService/readCMedi HTTP/1.1[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "cache-control: no-cache[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "patientId: 15[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "Accept: application/json[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "Content-Type: application/json[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "User-Agent: PostmanRuntime/6.1.6[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "Host: 172.16.2.73:8285[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "accept-encoding: gzip, deflate[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "Connection: keep-alive[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
> >> "[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> GET
> /services/CentralPatientService/readCMedi HTTP/1.1
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> cache-control: no-cache
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> patientId: 15
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Accept:
> application/json
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> Content-Type: application/json
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> User-Agent: PostmanRuntime/6.1.6
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Host:
> 172.16.2.73:8285
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> accept-encoding: gzip, deflate
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> Connection: keep-alive
> [2017-11-13 00:27:48,653]  INFO - LogMediator To:
> 

Re: [Dev] [DEV] CRUD operation in API response with 202 accepted but operations are not performed

2017-11-12 Thread Himasha Guruge
Hi Thivya,

As discussed offline given [1],  since you are not setting a content type
header in the request, 'application/x-www-form-urlencoded' is preserved as
default hence above fix would work.

[1]
https://docs.wso2.com/display/ESB500/Configuring+Specific+Use+Cases#ConfiguringSpecificUseCases-EnablingRESTtoSOAP

Thanks,
Himasha

On Mon, Nov 13, 2017 at 11:30 AM, Thivya Mahenthirarasa 
wrote:

> Hi Himasha,
>
> ESB sends application/x-www-form-urlencoded as the Content-Type to the
> backend which is the reason for this failure. When I do comment out the
> following parameter in the passthru-http.properties.
>
> http.headers.preserve=Content-Type.
>
> Also When i configured  args as  expression="get-property('uri.var.patientId')"/> I could able to receive
> the json response.
>
> Thank you
>
> On Mon, Nov 13, 2017 at 9:53 AM, Thivya Mahenthirarasa 
> wrote:
>
>> Hi Himasha
>>
>> As you said having xml in the media type also ended up with the same
>> response. What could be the root cause that the request couldn' t reach the
>> backend?
>>
>>
>> Thank you
>>
>> On Mon, Nov 13, 2017 at 8:21 AM, Himasha Guruge 
>> wrote:
>>
>>> Hi Thivya,
>>>
>>>  Could you verify the media type you have used in payload 
>>> mediator?(>> media-type="soap+xml">)  AFAIK, you can only use xml/json there [1] .
>>> According to the wire logs the request that is been sent is an empty
>>> soap envelope which means your request content has not been set through
>>> payload mediator.
>>>
>>> "Direction: request, Envelope: >> encoding='utf-8'?>http://schemas.
>>> xmlsoap.org/soap/envelope/">"
>>>
>>> [1] https://docs.wso2.com/display/ESB500/PayloadFactory+Medi
>>> ator#PayloadFactoryMediator-Syntax
>>>
>>> Thanks,
>>> Himasha
>>>
>>> On Mon, Nov 13, 2017 at 12:33 AM, Thivya Mahenthirarasa >> > wrote:
>>>
 Hi ,
 Thank you for the response.

 I wonder that no request is sent to the back-end service. Just ESB is
 sending a response to the rest client that it accepts the requests. What
 might be the root cause?. This behavior occurs in all other resources
 too(DELETE, PUT, POST).

 What might be the root cause for this? Find the wire logs attached.


 [2017-11-13 00:27:48,651] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "GET /services/CentralPatientService/readCMedi HTTP/1.1[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "cache-control: no-cache[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "patientId: 15[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "Accept: application/json[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "Content-Type: application/json[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "User-Agent: PostmanRuntime/6.1.6[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "Host: 172.16.2.73:8285[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "accept-encoding: gzip, deflate[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "Connection: keep-alive[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2
 >> "[\r][\n]"
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> GET
 /services/CentralPatientService/readCMedi HTTP/1.1
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
 cache-control: no-cache
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
 Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> patientId:
 15
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Accept:
 application/json
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
 Content-Type: application/json
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
 User-Agent: PostmanRuntime/6.1.6
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Host:
 172.16.2.73:8285
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
 accept-encoding: gzip, deflate
 [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
 Connection: keep-alive
 [2017-11-13 00:27:48,653]  INFO - LogMediator To:
 /services/CentralPatientService/readCMedi, MessageID:
 urn:uuid:db12eb62-ec97-45ff-8956-488d8b366d75, Direction: request,
 Envelope: >>> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/; oapenv:Body/>
 [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << HTTP/1.1
 202 

Re: [Dev] [DEV] CRUD operation in API response with 202 accepted but operations are not performed

2017-11-12 Thread Thivya Mahenthirarasa
Hi Himasha,

ESB sends application/x-www-form-urlencoded as the Content-Type to the
backend which is the reason for this failure. When I do comment out the
following parameter in the passthru-http.properties.

http.headers.preserve=Content-Type.

Also When i configured  args as  I could able to receive
the json response.

Thank you

On Mon, Nov 13, 2017 at 9:53 AM, Thivya Mahenthirarasa 
wrote:

> Hi Himasha
>
> As you said having xml in the media type also ended up with the same
> response. What could be the root cause that the request couldn' t reach the
> backend?
>
>
> Thank you
>
> On Mon, Nov 13, 2017 at 8:21 AM, Himasha Guruge  wrote:
>
>> Hi Thivya,
>>
>>  Could you verify the media type you have used in payload 
>> mediator?(> media-type="soap+xml">)  AFAIK, you can only use xml/json there [1] .
>> According to the wire logs the request that is been sent is an empty soap
>> envelope which means your request content has not been set through payload
>> mediator.
>>
>> "Direction: request, Envelope: > encoding='utf-8'?>http://schemas.
>> xmlsoap.org/soap/envelope/">"
>>
>> [1] https://docs.wso2.com/display/ESB500/PayloadFactory+Medi
>> ator#PayloadFactoryMediator-Syntax
>>
>> Thanks,
>> Himasha
>>
>> On Mon, Nov 13, 2017 at 12:33 AM, Thivya Mahenthirarasa 
>> wrote:
>>
>>> Hi ,
>>> Thank you for the response.
>>>
>>> I wonder that no request is sent to the back-end service. Just ESB is
>>> sending a response to the rest client that it accepts the requests. What
>>> might be the root cause?. This behavior occurs in all other resources
>>> too(DELETE, PUT, POST).
>>>
>>> What might be the root cause for this? Find the wire logs attached.
>>>
>>>
>>> [2017-11-13 00:27:48,651] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "GET /services/CentralPatientService/readCMedi HTTP/1.1[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "cache-control: no-cache[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "patientId: 15[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "Accept: application/json[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "Content-Type: application/json[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "User-Agent: PostmanRuntime/6.1.6[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "Host: 172.16.2.73:8285[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "accept-encoding: gzip, deflate[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "Connection: keep-alive[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>>> "[\r][\n]"
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> GET
>>> /services/CentralPatientService/readCMedi HTTP/1.1
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
>>> cache-control: no-cache
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
>>> Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> patientId:
>>> 15
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Accept:
>>> application/json
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
>>> Content-Type: application/json
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> User-Agent:
>>> PostmanRuntime/6.1.6
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Host:
>>> 172.16.2.73:8285
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
>>> accept-encoding: gzip, deflate
>>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Connection:
>>> keep-alive
>>> [2017-11-13 00:27:48,653]  INFO - LogMediator To:
>>> /services/CentralPatientService/readCMedi, MessageID:
>>> urn:uuid:db12eb62-ec97-45ff-8956-488d8b366d75, Direction: request,
>>> Envelope: >> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/;>>> oapenv:Body/>
>>> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << HTTP/1.1
>>> 202 Accepted
>>> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << Date: Sun,
>>> 12 Nov 2017 18:57:48 GMT
>>> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 <<
>>> Transfer-Encoding: chunked
>>> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << Connection:
>>> keep-alive
>>> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
>>> "HTTP/1.1 202 Accepted[\r][\n]"
>>> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
>>> "Date: Sun, 12 Nov 2017 18:57:48 GMT[\r][\n]"
>>> [2017-11-13 00:27:48,655] DEBUG - wire 

Re: [Dev] No response when sending patientId as an argument

2017-11-12 Thread Buddhimala Ranasinghe
changing the URL template to "/read/{*+*patientid}" resolved the issue.

Thanks for the support.

Regards,
Buddhimala

On Mon, Nov 13, 2017 at 11:25 AM, Buddhimala Ranasinghe  wrote:

> Hi Thivya,
>
> Still it doesn't work. I'm getting the same error.
>
> Regards,
> Buddhimala
>
> On Mon, Nov 13, 2017 at 11:19 AM, Thivya Mahenthirarasa 
> wrote:
>
>> Hi Budhimala,
>>
>> Apologies for the above. I think the GET method you are having is in the
>> name read. Can you try by adding
>>  
>>
>> On Mon, Nov 13, 2017 at 11:12 AM, Thivya Mahenthirarasa 
>> wrote:
>>
>>> Hi Budhimala,
>>>
>>>  Instead of  
>>> you need to refine your uri-template as follows since you are sending the
>>> parameter via uri.
>>>
>>>   
>>>
>>>
>>> Hope it would be helpful.
>>>
>>> Thanks,
>>> Thivya
>>>
>>> On Mon, Nov 13, 2017 at 10:24 AM, Buddhimala Ranasinghe <
>>> buddhim...@wso2.com> wrote:
>>>
 Here is my API configuartion.

 http://ws.apache.org/ns/synapse; name="NawalokaPatientAPI"
 context="/nawaloka">

   
  
  
 
http://schemas.
 xmlsoap.org/soap/envelope/" xmlns:ser="http://service.samp
 le.nawaloka.com">
   
  12
   
   
  
 $1
  
   

 
 

 
  
  
  >>> scope="transport"/>
  
  
  
 
https://192.168.55.160:94
 43/services/NawalokaPatientService" format="soap11"/>
 
  
   
   
  >>> scope="axis2"/>
  
   

 

 On Mon, Nov 13, 2017 at 10:14 AM, Sam Sivayogam  wrote:

> Seems like your synapse api context and resource definition doesn't
> match with the URL you invoke.Thats why you are getting a error like No
> matching resource. Can you please send your api configurations ?
>
> Thanks,
> Sam
>
> On Mon, Nov 13, 2017 at 9:46 AM, Buddhimala Ranasinghe <
> buddhim...@wso2.com> wrote:
>
>> Hi All,
>>
>> I have created an API in ESB 5.0.0 to access a secured SOAP BE
>> service. As per [1] I have added a dummy header into the paylaod so that 
>> my
>> payload will be as follows.
>>
>> 
>> 
>>http://schemas.
>> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.samp
>> le.nawaloka.com">
>>   
>>  12
>>   
>>   
>>  
>> $1
>>  
>>   
>>
>> 
>> 
>>
>> 
>>  
>>
>> My problem now is, when I tried to invoke the API using SOAPUI, it
>> doen't show any response and the server side, it logs an error as below.
>>
>> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3
>> >> "GET /nawaloka/read/a...@abc.com HTTP/1.1[\r][\n]"
>> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3
>> >> "Accept-Encoding: gzip,deflate[\r][\n]"
>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
>> >> "Host: 172.17.0.1:8280[\r][\n]"
>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
>> >> "Connection: Keep-Alive[\r][\n]"
>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
>> >> "User-Agent: Apache-HttpClient/4.1.1 (java 1.5)[\r][\n]"
>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
>> >> "[\r][\n]"
>> [2017-11-13 09:30:21,682] DEBUG - SynapseMessageReceiver Synapse
>> received a new message for message mediation...
>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver Received To:
>> /nawaloka/read/a...@abc.com
>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver SOAPAction:
>> null
>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver WSA-Action:
>> null
>> [2017-11-13 09:30:21,683] DEBUG - Axis2SynapseEnvironment Injecting
>> MessageContext
>> [2017-11-13 09:30:21,683] DEBUG - RESTRequestHandler Located specific
>> API: NawalokaPatientAPI for processing message
>> [2017-11-13 09:30:21,684] DEBUG - API Processing message with ID:
>> urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95 through the API:
>> NawalokaPatientAPI
>> [2017-11-13 09:30:21,684] DEBUG - API No matching resource was found
>> for the request: urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95
>> 

Re: [Dev] No response when sending patientId as an argument

2017-11-12 Thread Buddhimala Ranasinghe
Hi Thivya,

Still it doesn't work. I'm getting the same error.

Regards,
Buddhimala

On Mon, Nov 13, 2017 at 11:19 AM, Thivya Mahenthirarasa 
wrote:

> Hi Budhimala,
>
> Apologies for the above. I think the GET method you are having is in the
> name read. Can you try by adding
>  
>
> On Mon, Nov 13, 2017 at 11:12 AM, Thivya Mahenthirarasa 
> wrote:
>
>> Hi Budhimala,
>>
>>  Instead of  
>> you need to refine your uri-template as follows since you are sending the
>> parameter via uri.
>>
>>   
>>
>>
>> Hope it would be helpful.
>>
>> Thanks,
>> Thivya
>>
>> On Mon, Nov 13, 2017 at 10:24 AM, Buddhimala Ranasinghe <
>> buddhim...@wso2.com> wrote:
>>
>>> Here is my API configuartion.
>>>
>>> http://ws.apache.org/ns/synapse; name="NawalokaPatientAPI"
>>> context="/nawaloka">
>>>
>>>   
>>>  
>>>  
>>> 
>>>http://schemas.
>>> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.samp
>>> le.nawaloka.com">
>>>   
>>>  12
>>>   
>>>   
>>>  
>>> $1
>>>  
>>>   
>>>
>>> 
>>> 
>>>
>>> 
>>>  
>>>  
>>>  
>>>  
>>>  
>>>  
>>> 
>>>https://192.168.55.160:94
>>> 43/services/NawalokaPatientService" format="soap11"/>
>>> 
>>>  
>>>   
>>>   
>>>  >> scope="axis2"/>
>>>  
>>>   
>>>
>>> 
>>>
>>> On Mon, Nov 13, 2017 at 10:14 AM, Sam Sivayogam  wrote:
>>>
 Seems like your synapse api context and resource definition doesn't
 match with the URL you invoke.Thats why you are getting a error like No
 matching resource. Can you please send your api configurations ?

 Thanks,
 Sam

 On Mon, Nov 13, 2017 at 9:46 AM, Buddhimala Ranasinghe <
 buddhim...@wso2.com> wrote:

> Hi All,
>
> I have created an API in ESB 5.0.0 to access a secured SOAP BE
> service. As per [1] I have added a dummy header into the paylaod so that 
> my
> payload will be as follows.
>
> 
> 
>http://schemas.
> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.samp
> le.nawaloka.com">
>   
>  12
>   
>   
>  
> $1
>  
>   
>
> 
> 
>
> 
>  
>
> My problem now is, when I tried to invoke the API using SOAPUI, it
> doen't show any response and the server side, it logs an error as below.
>
> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3
> >> "GET /nawaloka/read/a...@abc.com HTTP/1.1[\r][\n]"
> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3
> >> "Accept-Encoding: gzip,deflate[\r][\n]"
> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
> >> "Host: 172.17.0.1:8280[\r][\n]"
> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
> >> "Connection: Keep-Alive[\r][\n]"
> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
> >> "User-Agent: Apache-HttpClient/4.1.1 (java 1.5)[\r][\n]"
> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
> >> "[\r][\n]"
> [2017-11-13 09:30:21,682] DEBUG - SynapseMessageReceiver Synapse
> received a new message for message mediation...
> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver Received To:
> /nawaloka/read/a...@abc.com
> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver SOAPAction:
> null
> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver WSA-Action:
> null
> [2017-11-13 09:30:21,683] DEBUG - Axis2SynapseEnvironment Injecting
> MessageContext
> [2017-11-13 09:30:21,683] DEBUG - RESTRequestHandler Located specific
> API: NawalokaPatientAPI for processing message
> [2017-11-13 09:30:21,684] DEBUG - API Processing message with ID:
> urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95 through the API:
> NawalokaPatientAPI
> [2017-11-13 09:30:21,684] DEBUG - API No matching resource was found
> for the request: urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95
> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3
> << "HTTP/1.1 404 Not Found[\r][\n]"
> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3
> << "Date: Mon, 13 Nov 2017 04:00:21 GMT[\r][\n]"
> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3
> << "Transfer-Encoding: chunked[\r][\n]"
> [2017-11-13 

Re: [Dev] Enabling REST to SOAP sample gives an error

2017-11-12 Thread Thivya Mahenthirarasa
Thank you vijitha, I could able to resolve the error by using your proposed
method.



On Mon, Nov 13, 2017 at 10:35 AM, Buddhimala Ranasinghe  wrote:

> Hi Praneesha,
>
> I have checked the update done in [1].
>
> However, the line "Therefore, when you uncomment this property, WSO2 ESB
> does not apply this default content type when sending the message." seems
> like confusing the readers with the line "Comment out the
> http.headers.preserve=Content-Type parameter in the
> /conf/passthru-http.properties file.".
>
> Therefore, shall we simply say the reader to comment out the relevant
> parameter?
>
> [1] https://docs.wso2.com/display/ESB500/Configuring+Specific+Use+Cases#
> ConfiguringSpecificUseCases-EnablingRESTtoSOAP
>
> Regards,
> Buddhimala
>
> On Mon, Nov 13, 2017 at 10:33 AM, Buddhimala Ranasinghe <
> buddhim...@wso2.com> wrote:
>
>> Hi Praneesha,
>>
>> I have checked the update done in [1].
>>
>> However, the line "Therefore, when you uncomment this property, WSO2 ESB
>> does not apply this default content type when sending the message." seems
>> like confusing the readers with the line "Comment out the
>> http.headers.preserve=Content-Type parameter in the
>> /conf/passthru-http.properties file.".
>>
>> Therefore, shall we simply say the reader to comment out the relevant
>> parameter?
>>
>> Regards,
>> Buddhimala
>>
>> On Fri, Nov 10, 2017 at 7:53 PM, Praneesha Chandrasiri <
>> pranee...@wso2.com> wrote:
>>
>>> This is applicable only to WSO2 ESB 5.0.0 and is fixed in WSO2 EI.
>>> Therefore, updated [1] accordingly.
>>>
>>> Thanks for the support Vijitha and Milinda!
>>>
>>> [1] https://docs.wso2.com/display/ESB500/Configuring+Specific+Use+Cases
>>>
>>> On Fri, Nov 10, 2017 at 5:21 PM, Vijitha Ekanayake 
>>> wrote:
>>>
 [++ documentation]

 The reason for the issue seems to be, ESB is preserving the
 Content-Type header as the default behavior. Since GET request doesn't have
 a Content-Type, ESB sends application/x-www-form-urlencoded as the
 Content-Type to the backend which is the reason for this failure. To
 overcome this issue you can comment out the following parameter in the
 passthru-http.properties.

 http.headers.preserve=Content-Type

 Thanks,
 Vijitha.

 On Fri, Nov 10, 2017 at 5:04 PM, Vijitha Ekanayake 
 wrote:

> Hi Buddhimala,
>
> The reason for the issue seems to be, ESB is preserving the
> Content-Type header as the default behavior. Since GET request doesn't 
> have
> a Content-Type, ESB sends application/x-www-form-urlencoded as the
> Content-Type to the backend which is the reason for this failure. To
> overcome this issue you can comment out the following parameter in the
> passthru-http.properties.
>
> http.headers.preserve=Content-Type
>
> Thanks,
> Vijitha.
>
>
> On Fri, Nov 10, 2017 at 4:29 PM, Buddhimala Ranasinghe <
> buddhim...@wso2.com> wrote:
>
>> Hi All,
>>
>> Today I tried out "Enabling REST to SOAP" sample in ESB as per the
>> following wso2 document.
>>
>> https://docs.wso2.com/display/ESB500/Configuring+Specific+Us
>> e+Cases#ConfiguringSpecificUseCases-EnablingRESTtoSOAP
>>
>> But when I tried to invoke the API using the curl command, I got
>> following error.
>>
>> The endpoint reference (EPR) for the Operation not found
>> is /services/SimpleStockQuoteService and the WSA Action = null. If
>> this EPR was previously reachable, please contact the server
>> administrator.
>>
>> And the axis2 server side it gave the following error.
>>
>> [2017-11-10 16:25:33,268] ERROR {org.apache.axis2.engine.AxisEngine}
>> -  The endpoint reference (EPR) for the Operation not found is
>> /services/SimpleStockQuoteService and the WSA Action = null. If this
>> EPR was previously reachable, please contact the server administrator.
>> org.apache.axis2.AxisFault: The endpoint reference (EPR) for the
>> Operation not found is /services/SimpleStockQuoteService and the WSA
>> Action = null. If this EPR was previously reachable, please contact the
>> server administrator.
>> at org.apache.axis2.engine.DispatchPhase.checkPostConditions(Di
>> spatchPhase.java:102)
>> at org.apache.axis2.engine.Phase.invoke(Phase.java:329)
>> at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:261)
>> at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:1
>> 67)
>> at org.apache.axis2.transport.http.util.RESTUtil.invokeAxisEngi
>> ne(RESTUtil.java:144)
>> at org.apache.axis2.transport.http.util.RESTUtil.processXMLRequ
>> est(RESTUtil.java:89)
>> at org.apache.synapse.transport.nhttp.util.RESTUtil.processPOST
>> Request(RESTUtil.java:213)
>> at 

Re: [Dev] No response when sending patientId as an argument

2017-11-12 Thread Thivya Mahenthirarasa
Hi Budhimala,

Apologies for the above. I think the GET method you are having is in the
name read. Can you try by adding
 

On Mon, Nov 13, 2017 at 11:12 AM, Thivya Mahenthirarasa 
wrote:

> Hi Budhimala,
>
>  Instead of  
> you need to refine your uri-template as follows since you are sending the
> parameter via uri.
>
>   
>
>
> Hope it would be helpful.
>
> Thanks,
> Thivya
>
> On Mon, Nov 13, 2017 at 10:24 AM, Buddhimala Ranasinghe <
> buddhim...@wso2.com> wrote:
>
>> Here is my API configuartion.
>>
>> http://ws.apache.org/ns/synapse; name="NawalokaPatientAPI"
>> context="/nawaloka">
>>
>>   
>>  
>>  
>> 
>>http://schemas.
>> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.sample.nawaloka.com
>> ">
>>   
>>  12
>>   
>>   
>>  
>> $1
>>  
>>   
>>
>> 
>> 
>>
>> 
>>  
>>  
>>  
>>  
>>  
>>  
>> 
>>https://192.168.55.160:94
>> 43/services/NawalokaPatientService" format="soap11"/>
>> 
>>  
>>   
>>   
>>  > scope="axis2"/>
>>  
>>   
>>
>> 
>>
>> On Mon, Nov 13, 2017 at 10:14 AM, Sam Sivayogam  wrote:
>>
>>> Seems like your synapse api context and resource definition doesn't
>>> match with the URL you invoke.Thats why you are getting a error like No
>>> matching resource. Can you please send your api configurations ?
>>>
>>> Thanks,
>>> Sam
>>>
>>> On Mon, Nov 13, 2017 at 9:46 AM, Buddhimala Ranasinghe <
>>> buddhim...@wso2.com> wrote:
>>>
 Hi All,

 I have created an API in ESB 5.0.0 to access a secured SOAP BE service.
 As per [1] I have added a dummy header into the paylaod so that my payload
 will be as follows.

 
 
http://schemas.
 xmlsoap.org/soap/envelope/" xmlns:ser="http://service.samp
 le.nawaloka.com">
   
  12
   
   
  
 $1
  
   

 
 

 
  

 My problem now is, when I tried to invoke the API using SOAPUI, it
 doen't show any response and the server side, it logs an error as below.

 [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3
 >> "GET /nawaloka/read/a...@abc.com HTTP/1.1[\r][\n]"
 [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3
 >> "Accept-Encoding: gzip,deflate[\r][\n]"
 [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
 >> "Host: 172.17.0.1:8280[\r][\n]"
 [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
 >> "Connection: Keep-Alive[\r][\n]"
 [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
 >> "User-Agent: Apache-HttpClient/4.1.1 (java 1.5)[\r][\n]"
 [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3
 >> "[\r][\n]"
 [2017-11-13 09:30:21,682] DEBUG - SynapseMessageReceiver Synapse
 received a new message for message mediation...
 [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver Received To:
 /nawaloka/read/a...@abc.com
 [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver SOAPAction:
 null
 [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver WSA-Action:
 null
 [2017-11-13 09:30:21,683] DEBUG - Axis2SynapseEnvironment Injecting
 MessageContext
 [2017-11-13 09:30:21,683] DEBUG - RESTRequestHandler Located specific
 API: NawalokaPatientAPI for processing message
 [2017-11-13 09:30:21,684] DEBUG - API Processing message with ID:
 urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95 through the API:
 NawalokaPatientAPI
 [2017-11-13 09:30:21,684] DEBUG - API No matching resource was found
 for the request: urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95
 [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3
 << "HTTP/1.1 404 Not Found[\r][\n]"
 [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3
 << "Date: Mon, 13 Nov 2017 04:00:21 GMT[\r][\n]"
 [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3
 << "Transfer-Encoding: chunked[\r][\n]"
 [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3
 << "Connection: Keep-Alive[\r][\n]"
 [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3
 << "[\r][\n]"
 [2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3
 << "0[\r][\n]"
 [2017-11-13 09:30:21,688] DEBUG - wire 

Re: [Dev] No response when sending patientId as an argument

2017-11-12 Thread Sam Sivayogam
I tried your api in my local ESB. Seems like the issue is with the path
param you send there is a *@ * in the query param you send. When invoking
the api you can send a path param without a special characters something
like below
GET /nawaloka/read/ab cUser

or you can modify your url template like below to allow special charcters
/read/{*+*patientid}

Thanks,
Sam

On Mon, Nov 13, 2017 at 10:24 AM, Buddhimala Ranasinghe  wrote:

> Here is my API configuartion.
>
> http://ws.apache.org/ns/synapse; name="NawalokaPatientAPI"
> context="/nawaloka">
>
>   
>  
>  
> 
>http://schemas.
> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.sample.nawaloka.com
> ">
>   
>  12
>   
>   
>  
> $1
>  
>   
>
> 
> 
>
> 
>  
>  
>  
>  
>  
>  
> 
>https://192.168.55.160:9443/services/
> NawalokaPatientService" format="soap11"/>
> 
>  
>   
>   
>   scope="axis2"/>
>  
>   
>
> 
>
> On Mon, Nov 13, 2017 at 10:14 AM, Sam Sivayogam  wrote:
>
>> Seems like your synapse api context and resource definition doesn't match
>> with the URL you invoke.Thats why you are getting a error like No
>> matching resource. Can you please send your api configurations ?
>>
>> Thanks,
>> Sam
>>
>> On Mon, Nov 13, 2017 at 9:46 AM, Buddhimala Ranasinghe <
>> buddhim...@wso2.com> wrote:
>>
>>> Hi All,
>>>
>>> I have created an API in ESB 5.0.0 to access a secured SOAP BE service.
>>> As per [1] I have added a dummy header into the paylaod so that my payload
>>> will be as follows.
>>>
>>> 
>>> 
>>>http://schemas.
>>> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.samp
>>> le.nawaloka.com">
>>>   
>>>  12
>>>   
>>>   
>>>  
>>> $1
>>>  
>>>   
>>>
>>> 
>>> 
>>>
>>> 
>>>  
>>>
>>> My problem now is, when I tried to invoke the API using SOAPUI, it
>>> doen't show any response and the server side, it logs an error as below.
>>>
>>> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "GET /nawaloka/read/a...@abc.com HTTP/1.1[\r][\n]"
>>> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "Accept-Encoding: gzip,deflate[\r][\n]"
>>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "Host: 172.17.0.1:8280[\r][\n]"
>>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "Connection: Keep-Alive[\r][\n]"
>>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "User-Agent: Apache-HttpClient/4.1.1 (java 1.5)[\r][\n]"
>>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "[\r][\n]"
>>> [2017-11-13 09:30:21,682] DEBUG - SynapseMessageReceiver Synapse
>>> received a new message for message mediation...
>>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver Received To:
>>> /nawaloka/read/a...@abc.com
>>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver SOAPAction: null
>>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver WSA-Action: null
>>> [2017-11-13 09:30:21,683] DEBUG - Axis2SynapseEnvironment Injecting
>>> MessageContext
>>> [2017-11-13 09:30:21,683] DEBUG - RESTRequestHandler Located specific
>>> API: NawalokaPatientAPI for processing message
>>> [2017-11-13 09:30:21,684] DEBUG - API Processing message with ID:
>>> urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95 through the API:
>>> NawalokaPatientAPI
>>> [2017-11-13 09:30:21,684] DEBUG - API No matching resource was found for
>>> the request: urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "HTTP/1.1 404 Not Found[\r][\n]"
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "Date: Mon, 13 Nov 2017 04:00:21 GMT[\r][\n]"
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "Transfer-Encoding: chunked[\r][\n]"
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "Connection: Keep-Alive[\r][\n]"
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "[\r][\n]"
>>> [2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "0[\r][\n]"
>>> [2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "[\r][\n]"
>>>
>>>
>>> But it shows a response when I enter a value for patientId parameter as
>>> follows.
>>>
>>>  

Re: [Dev] No response when sending patientId as an argument

2017-11-12 Thread Thivya Mahenthirarasa
Hi Budhimala,

 Instead of   you
need to refine your uri-template as follows since you are sending the
parameter via uri.

  


Hope it would be helpful.

Thanks,
Thivya

On Mon, Nov 13, 2017 at 10:24 AM, Buddhimala Ranasinghe  wrote:

> Here is my API configuartion.
>
> http://ws.apache.org/ns/synapse; name="NawalokaPatientAPI"
> context="/nawaloka">
>
>   
>  
>  
> 
>http://schemas.
> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.sample.nawaloka.com
> ">
>   
>  12
>   
>   
>  
> $1
>  
>   
>
> 
> 
>
> 
>  
>  
>  
>  
>  
>  
> 
>https://192.168.55.160:9443/services/
> NawalokaPatientService" format="soap11"/>
> 
>  
>   
>   
>   scope="axis2"/>
>  
>   
>
> 
>
> On Mon, Nov 13, 2017 at 10:14 AM, Sam Sivayogam  wrote:
>
>> Seems like your synapse api context and resource definition doesn't match
>> with the URL you invoke.Thats why you are getting a error like No
>> matching resource. Can you please send your api configurations ?
>>
>> Thanks,
>> Sam
>>
>> On Mon, Nov 13, 2017 at 9:46 AM, Buddhimala Ranasinghe <
>> buddhim...@wso2.com> wrote:
>>
>>> Hi All,
>>>
>>> I have created an API in ESB 5.0.0 to access a secured SOAP BE service.
>>> As per [1] I have added a dummy header into the paylaod so that my payload
>>> will be as follows.
>>>
>>> 
>>> 
>>>http://schemas.
>>> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.samp
>>> le.nawaloka.com">
>>>   
>>>  12
>>>   
>>>   
>>>  
>>> $1
>>>  
>>>   
>>>
>>> 
>>> 
>>>
>>> 
>>>  
>>>
>>> My problem now is, when I tried to invoke the API using SOAPUI, it
>>> doen't show any response and the server side, it logs an error as below.
>>>
>>> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "GET /nawaloka/read/a...@abc.com HTTP/1.1[\r][\n]"
>>> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "Accept-Encoding: gzip,deflate[\r][\n]"
>>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "Host: 172.17.0.1:8280[\r][\n]"
>>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "Connection: Keep-Alive[\r][\n]"
>>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "User-Agent: Apache-HttpClient/4.1.1 (java 1.5)[\r][\n]"
>>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>>> "[\r][\n]"
>>> [2017-11-13 09:30:21,682] DEBUG - SynapseMessageReceiver Synapse
>>> received a new message for message mediation...
>>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver Received To:
>>> /nawaloka/read/a...@abc.com
>>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver SOAPAction: null
>>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver WSA-Action: null
>>> [2017-11-13 09:30:21,683] DEBUG - Axis2SynapseEnvironment Injecting
>>> MessageContext
>>> [2017-11-13 09:30:21,683] DEBUG - RESTRequestHandler Located specific
>>> API: NawalokaPatientAPI for processing message
>>> [2017-11-13 09:30:21,684] DEBUG - API Processing message with ID:
>>> urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95 through the API:
>>> NawalokaPatientAPI
>>> [2017-11-13 09:30:21,684] DEBUG - API No matching resource was found for
>>> the request: urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "HTTP/1.1 404 Not Found[\r][\n]"
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "Date: Mon, 13 Nov 2017 04:00:21 GMT[\r][\n]"
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "Transfer-Encoding: chunked[\r][\n]"
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "Connection: Keep-Alive[\r][\n]"
>>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "[\r][\n]"
>>> [2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "0[\r][\n]"
>>> [2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>>> "[\r][\n]"
>>>
>>>
>>> But it shows a response when I enter a value for patientId parameter as
>>> follows.
>>>
>>>  a...@abc.com
>>>
>>> FYI: patientId should be the patient's e-mail address.
>>>
>>> [1] "API gives "SOAP Envelope can not have children other than SOAP
>>> Header and Body" Exception"
>>> --
>>>
>>>
>>> *Buddhimala 

Re: [Dev] Enabling REST to SOAP sample gives an error

2017-11-12 Thread Buddhimala Ranasinghe
Hi Praneesha,

I have checked the update done in [1].

However, the line "Therefore, when you uncomment this property, WSO2 ESB
does not apply this default content type when sending the message." seems
like confusing the readers with the line "Comment out the
http.headers.preserve=Content-Type parameter in the
/conf/passthru-http.properties file.".

Therefore, shall we simply say the reader to comment out the relevant
parameter?

[1]
https://docs.wso2.com/display/ESB500/Configuring+Specific+Use+Cases#ConfiguringSpecificUseCases-EnablingRESTtoSOAP

Regards,
Buddhimala

On Mon, Nov 13, 2017 at 10:33 AM, Buddhimala Ranasinghe  wrote:

> Hi Praneesha,
>
> I have checked the update done in [1].
>
> However, the line "Therefore, when you uncomment this property, WSO2 ESB
> does not apply this default content type when sending the message." seems
> like confusing the readers with the line "Comment out the
> http.headers.preserve=Content-Type parameter in the
> /conf/passthru-http.properties file.".
>
> Therefore, shall we simply say the reader to comment out the relevant
> parameter?
>
> Regards,
> Buddhimala
>
> On Fri, Nov 10, 2017 at 7:53 PM, Praneesha Chandrasiri  > wrote:
>
>> This is applicable only to WSO2 ESB 5.0.0 and is fixed in WSO2 EI.
>> Therefore, updated [1] accordingly.
>>
>> Thanks for the support Vijitha and Milinda!
>>
>> [1] https://docs.wso2.com/display/ESB500/Configuring+Specific+Use+Cases
>>
>> On Fri, Nov 10, 2017 at 5:21 PM, Vijitha Ekanayake 
>> wrote:
>>
>>> [++ documentation]
>>>
>>> The reason for the issue seems to be, ESB is preserving the Content-Type
>>> header as the default behavior. Since GET request doesn't have a
>>> Content-Type, ESB sends application/x-www-form-urlencoded as the
>>> Content-Type to the backend which is the reason for this failure. To
>>> overcome this issue you can comment out the following parameter in the
>>> passthru-http.properties.
>>>
>>> http.headers.preserve=Content-Type
>>>
>>> Thanks,
>>> Vijitha.
>>>
>>> On Fri, Nov 10, 2017 at 5:04 PM, Vijitha Ekanayake 
>>> wrote:
>>>
 Hi Buddhimala,

 The reason for the issue seems to be, ESB is preserving the
 Content-Type header as the default behavior. Since GET request doesn't have
 a Content-Type, ESB sends application/x-www-form-urlencoded as the
 Content-Type to the backend which is the reason for this failure. To
 overcome this issue you can comment out the following parameter in the
 passthru-http.properties.

 http.headers.preserve=Content-Type

 Thanks,
 Vijitha.


 On Fri, Nov 10, 2017 at 4:29 PM, Buddhimala Ranasinghe <
 buddhim...@wso2.com> wrote:

> Hi All,
>
> Today I tried out "Enabling REST to SOAP" sample in ESB as per the
> following wso2 document.
>
> https://docs.wso2.com/display/ESB500/Configuring+Specific+Us
> e+Cases#ConfiguringSpecificUseCases-EnablingRESTtoSOAP
>
> But when I tried to invoke the API using the curl command, I got
> following error.
>
> The endpoint reference (EPR) for the Operation not found
> is /services/SimpleStockQuoteService and the WSA Action = null. If
> this EPR was previously reachable, please contact the server
> administrator.
>
> And the axis2 server side it gave the following error.
>
> [2017-11-10 16:25:33,268] ERROR {org.apache.axis2.engine.AxisEngine}
> -  The endpoint reference (EPR) for the Operation not found is
> /services/SimpleStockQuoteService and the WSA Action = null. If this
> EPR was previously reachable, please contact the server administrator.
> org.apache.axis2.AxisFault: The endpoint reference (EPR) for the
> Operation not found is /services/SimpleStockQuoteService and the WSA
> Action = null. If this EPR was previously reachable, please contact the
> server administrator.
> at org.apache.axis2.engine.DispatchPhase.checkPostConditions(Di
> spatchPhase.java:102)
> at org.apache.axis2.engine.Phase.invoke(Phase.java:329)
> at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:261)
> at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:167)
> at org.apache.axis2.transport.http.util.RESTUtil.invokeAxisEngi
> ne(RESTUtil.java:144)
> at org.apache.axis2.transport.http.util.RESTUtil.processXMLRequ
> est(RESTUtil.java:89)
> at org.apache.synapse.transport.nhttp.util.RESTUtil.processPOST
> Request(RESTUtil.java:213)
> at org.apache.synapse.transport.nhttp.ServerWorker.processEntit
> yEnclosingMethod(ServerWorker.java:468)
> at org.apache.synapse.transport.nhttp.ServerWorker.run(ServerWo
> rker.java:291)
> at org.apache.axis2.transport.base.threads.NativeWorkerPool$1.r
> un(NativeWorkerPool.java:172)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPool

Re: [Dev] Enabling REST to SOAP sample gives an error

2017-11-12 Thread Buddhimala Ranasinghe
Hi Praneesha,

I have checked the update done in [1].

However, the line "Therefore, when you uncomment this property, WSO2 ESB
does not apply this default content type when sending the message." seems
like confusing the readers with the line "Comment out the
http.headers.preserve=Content-Type parameter in the
/conf/passthru-http.properties file.".

Therefore, shall we simply say the reader to comment out the relevant
parameter?

Regards,
Buddhimala

On Fri, Nov 10, 2017 at 7:53 PM, Praneesha Chandrasiri 
wrote:

> This is applicable only to WSO2 ESB 5.0.0 and is fixed in WSO2 EI.
> Therefore, updated [1] accordingly.
>
> Thanks for the support Vijitha and Milinda!
>
> [1] https://docs.wso2.com/display/ESB500/Configuring+Specific+Use+Cases
>
> On Fri, Nov 10, 2017 at 5:21 PM, Vijitha Ekanayake 
> wrote:
>
>> [++ documentation]
>>
>> The reason for the issue seems to be, ESB is preserving the Content-Type
>> header as the default behavior. Since GET request doesn't have a
>> Content-Type, ESB sends application/x-www-form-urlencoded as the
>> Content-Type to the backend which is the reason for this failure. To
>> overcome this issue you can comment out the following parameter in the
>> passthru-http.properties.
>>
>> http.headers.preserve=Content-Type
>>
>> Thanks,
>> Vijitha.
>>
>> On Fri, Nov 10, 2017 at 5:04 PM, Vijitha Ekanayake 
>> wrote:
>>
>>> Hi Buddhimala,
>>>
>>> The reason for the issue seems to be, ESB is preserving the Content-Type
>>> header as the default behavior. Since GET request doesn't have a
>>> Content-Type, ESB sends application/x-www-form-urlencoded as the
>>> Content-Type to the backend which is the reason for this failure. To
>>> overcome this issue you can comment out the following parameter in the
>>> passthru-http.properties.
>>>
>>> http.headers.preserve=Content-Type
>>>
>>> Thanks,
>>> Vijitha.
>>>
>>>
>>> On Fri, Nov 10, 2017 at 4:29 PM, Buddhimala Ranasinghe <
>>> buddhim...@wso2.com> wrote:
>>>
 Hi All,

 Today I tried out "Enabling REST to SOAP" sample in ESB as per the
 following wso2 document.

 https://docs.wso2.com/display/ESB500/Configuring+Specific+Us
 e+Cases#ConfiguringSpecificUseCases-EnablingRESTtoSOAP

 But when I tried to invoke the API using the curl command, I got
 following error.

 The endpoint reference (EPR) for the Operation not found
 is /services/SimpleStockQuoteService and the WSA Action = null. If
 this EPR was previously reachable, please contact the server
 administrator.

 And the axis2 server side it gave the following error.

 [2017-11-10 16:25:33,268] ERROR {org.apache.axis2.engine.AxisEngine}
 -  The endpoint reference (EPR) for the Operation not found is
 /services/SimpleStockQuoteService and the WSA Action = null. If this
 EPR was previously reachable, please contact the server administrator.
 org.apache.axis2.AxisFault: The endpoint reference (EPR) for the
 Operation not found is /services/SimpleStockQuoteService and the WSA
 Action = null. If this EPR was previously reachable, please contact the
 server administrator.
 at org.apache.axis2.engine.DispatchPhase.checkPostConditions(Di
 spatchPhase.java:102)
 at org.apache.axis2.engine.Phase.invoke(Phase.java:329)
 at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:261)
 at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:167)
 at org.apache.axis2.transport.http.util.RESTUtil.invokeAxisEngi
 ne(RESTUtil.java:144)
 at org.apache.axis2.transport.http.util.RESTUtil.processXMLRequ
 est(RESTUtil.java:89)
 at org.apache.synapse.transport.nhttp.util.RESTUtil.processPOST
 Request(RESTUtil.java:213)
 at org.apache.synapse.transport.nhttp.ServerWorker.processEntit
 yEnclosingMethod(ServerWorker.java:468)
 at org.apache.synapse.transport.nhttp.ServerWorker.run(ServerWo
 rker.java:291)
 at org.apache.axis2.transport.base.threads.NativeWorkerPool$1.r
 un(NativeWorkerPool.java:172)
 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPool
 Executor.java:1142)
 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoo
 lExecutor.java:617)
 at java.lang.Thread.run(Thread.java:748)
 [2017-11-10 16:25:33,270] ERROR 
 {org.apache.synapse.transport.nhttp.ServerWorker}
 -  Error processing POST request
 org.apache.axis2.AxisFault: The endpoint reference (EPR) for the
 Operation not found is /services/SimpleStockQuoteService and the WSA
 Action = null. If this EPR was previously reachable, please contact the
 server administrator.
 at org.apache.axis2.engine.DispatchPhase.checkPostConditions(Di
 spatchPhase.java:102)
 at org.apache.axis2.engine.Phase.invoke(Phase.java:329)
 at 

Re: [Dev] No response when sending patientId as an argument

2017-11-12 Thread Buddhimala Ranasinghe
Here is my API configuartion.

http://ws.apache.org/ns/synapse; name="NawalokaPatientAPI"
context="/nawaloka">
   
  
 
 

   http://schemas.xmlsoap.org/soap/envelope/; xmlns:ser="
http://service.sample.nawaloka.com;>
  
 12
  
  
 
$1
 
  
   


   

 
 
 
 
 
 

   https://192.168.55.160:9443/services/NawalokaPatientService;
format="soap11"/>

 
  
  
 
 
  
   


On Mon, Nov 13, 2017 at 10:14 AM, Sam Sivayogam  wrote:

> Seems like your synapse api context and resource definition doesn't match
> with the URL you invoke.Thats why you are getting a error like No
> matching resource. Can you please send your api configurations ?
>
> Thanks,
> Sam
>
> On Mon, Nov 13, 2017 at 9:46 AM, Buddhimala Ranasinghe <
> buddhim...@wso2.com> wrote:
>
>> Hi All,
>>
>> I have created an API in ESB 5.0.0 to access a secured SOAP BE service.
>> As per [1] I have added a dummy header into the paylaod so that my payload
>> will be as follows.
>>
>> 
>> 
>>http://schemas.
>> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.sample.nawaloka.com
>> ">
>>   
>>  12
>>   
>>   
>>  
>> $1
>>  
>>   
>>
>> 
>> 
>>
>> 
>>  
>>
>> My problem now is, when I tried to invoke the API using SOAPUI, it doen't
>> show any response and the server side, it logs an error as below.
>>
>> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>> "GET /nawaloka/read/a...@abc.com HTTP/1.1[\r][\n]"
>> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>> "Accept-Encoding: gzip,deflate[\r][\n]"
>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>> "Host: 172.17.0.1:8280[\r][\n]"
>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>> "Connection: Keep-Alive[\r][\n]"
>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>> "User-Agent: Apache-HttpClient/4.1.1 (java 1.5)[\r][\n]"
>> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
>> "[\r][\n]"
>> [2017-11-13 09:30:21,682] DEBUG - SynapseMessageReceiver Synapse received
>> a new message for message mediation...
>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver Received To:
>> /nawaloka/read/a...@abc.com
>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver SOAPAction: null
>> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver WSA-Action: null
>> [2017-11-13 09:30:21,683] DEBUG - Axis2SynapseEnvironment Injecting
>> MessageContext
>> [2017-11-13 09:30:21,683] DEBUG - RESTRequestHandler Located specific
>> API: NawalokaPatientAPI for processing message
>> [2017-11-13 09:30:21,684] DEBUG - API Processing message with ID:
>> urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95 through the API:
>> NawalokaPatientAPI
>> [2017-11-13 09:30:21,684] DEBUG - API No matching resource was found for
>> the request: urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95
>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>> "HTTP/1.1 404 Not Found[\r][\n]"
>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>> "Date: Mon, 13 Nov 2017 04:00:21 GMT[\r][\n]"
>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>> "Transfer-Encoding: chunked[\r][\n]"
>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>> "Connection: Keep-Alive[\r][\n]"
>> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>> "[\r][\n]"
>> [2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>> "0[\r][\n]"
>> [2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
>> "[\r][\n]"
>>
>>
>> But it shows a response when I enter a value for patientId parameter as
>> follows.
>>
>>  a...@abc.com
>>
>> FYI: patientId should be the patient's e-mail address.
>>
>> [1] "API gives "SOAP Envelope can not have children other than SOAP
>> Header and Body" Exception"
>> --
>>
>>
>> *Buddhimala Ranasinghe *
>> Software Engineer-Support Team | WSO2
>> Emil: buddhim...@wso2.com
>> Mobile:+94771563138 <+94%2077%20156%203138>
>> Web:http://wso2.com
>> [image: https://wso2.com/signature] 
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> *Sam Sivayogam*
>
> Senior Software Engineer
> Mobile  : +94 772 906 439
> Office   : 

Re: [Dev] No response when sending patientId as an argument

2017-11-12 Thread Sam Sivayogam
Seems like your synapse api context and resource definition doesn't match
with the URL you invoke.Thats why you are getting a error like No matching
resource. Can you please send your api configurations ?

Thanks,
Sam

On Mon, Nov 13, 2017 at 9:46 AM, Buddhimala Ranasinghe 
wrote:

> Hi All,
>
> I have created an API in ESB 5.0.0 to access a secured SOAP BE service. As
> per [1] I have added a dummy header into the paylaod so that my payload
> will be as follows.
>
> 
> 
>http://schemas.
> xmlsoap.org/soap/envelope/" xmlns:ser="http://service.sample.nawaloka.com
> ">
>   
>  12
>   
>   
>  
> $1
>  
>   
>
> 
> 
>
> 
>  
>
> My problem now is, when I tried to invoke the API using SOAPUI, it doen't
> show any response and the server side, it logs an error as below.
>
> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
> "GET /nawaloka/read/a...@abc.com HTTP/1.1[\r][\n]"
> [2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
> "Accept-Encoding: gzip,deflate[\r][\n]"
> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
> "Host: 172.17.0.1:8280[\r][\n]"
> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
> "Connection: Keep-Alive[\r][\n]"
> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
> "User-Agent: Apache-HttpClient/4.1.1 (java 1.5)[\r][\n]"
> [2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
> "[\r][\n]"
> [2017-11-13 09:30:21,682] DEBUG - SynapseMessageReceiver Synapse received
> a new message for message mediation...
> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver Received To:
> /nawaloka/read/a...@abc.com
> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver SOAPAction: null
> [2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver WSA-Action: null
> [2017-11-13 09:30:21,683] DEBUG - Axis2SynapseEnvironment Injecting
> MessageContext
> [2017-11-13 09:30:21,683] DEBUG - RESTRequestHandler Located specific API:
> NawalokaPatientAPI for processing message
> [2017-11-13 09:30:21,684] DEBUG - API Processing message with ID:
> urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95 through the API:
> NawalokaPatientAPI
> [2017-11-13 09:30:21,684] DEBUG - API No matching resource was found for
> the request: urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95
> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
> "HTTP/1.1 404 Not Found[\r][\n]"
> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
> "Date: Mon, 13 Nov 2017 04:00:21 GMT[\r][\n]"
> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
> "Transfer-Encoding: chunked[\r][\n]"
> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
> "Connection: Keep-Alive[\r][\n]"
> [2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
> "[\r][\n]"
> [2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
> "0[\r][\n]"
> [2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
> "[\r][\n]"
>
>
> But it shows a response when I enter a value for patientId parameter as
> follows.
>
>  a...@abc.com
>
> FYI: patientId should be the patient's e-mail address.
>
> [1] "API gives "SOAP Envelope can not have children other than SOAP Header
> and Body" Exception"
> --
>
>
> *Buddhimala Ranasinghe *
> Software Engineer-Support Team | WSO2
> Emil: buddhim...@wso2.com
> Mobile:+94771563138 <+94%2077%20156%203138>
> Web:http://wso2.com
> [image: https://wso2.com/signature] 
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Sam Sivayogam*

Senior Software Engineer
Mobile  : +94 772 906 439
Office   : +94 112 145 345
*WSO2, Inc. :** wso2.com *
lean.enterprise.middleware.
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DEV] CRUD operation in API response with 202 accepted but operations are not performed

2017-11-12 Thread Thivya Mahenthirarasa
Hi Himasha

As you said having xml in the media type also ended up with the same
response. What could be the root cause that the request couldn' t reach the
backend?


Thank you

On Mon, Nov 13, 2017 at 8:21 AM, Himasha Guruge  wrote:

> Hi Thivya,
>
>  Could you verify the media type you have used in payload 
> mediator?( media-type="soap+xml">)  AFAIK, you can only use xml/json there [1] .
> According to the wire logs the request that is been sent is an empty soap
> envelope which means your request content has not been set through payload
> mediator.
>
> "Direction: request, Envelope:  encoding='utf-8'?>http://schemas.
> xmlsoap.org/soap/envelope/">"
>
> [1] https://docs.wso2.com/display/ESB500/PayloadFactory+Mediator#
> PayloadFactoryMediator-Syntax
>
> Thanks,
> Himasha
>
> On Mon, Nov 13, 2017 at 12:33 AM, Thivya Mahenthirarasa 
> wrote:
>
>> Hi ,
>> Thank you for the response.
>>
>> I wonder that no request is sent to the back-end service. Just ESB is
>> sending a response to the rest client that it accepts the requests. What
>> might be the root cause?. This behavior occurs in all other resources
>> too(DELETE, PUT, POST).
>>
>> What might be the root cause for this? Find the wire logs attached.
>>
>>
>> [2017-11-13 00:27:48,651] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "GET /services/CentralPatientService/readCMedi HTTP/1.1[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "cache-control: no-cache[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "patientId: 15[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "Accept: application/json[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "Content-Type: application/json[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "User-Agent: PostmanRuntime/6.1.6[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "Host: 172.16.2.73:8285[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "accept-encoding: gzip, deflate[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "Connection: keep-alive[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
>> "[\r][\n]"
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> GET
>> /services/CentralPatientService/readCMedi HTTP/1.1
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
>> cache-control: no-cache
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
>> Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> patientId: 15
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Accept:
>> application/json
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
>> Content-Type: application/json
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> User-Agent:
>> PostmanRuntime/6.1.6
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Host:
>> 172.16.2.73:8285
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
>> accept-encoding: gzip, deflate
>> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Connection:
>> keep-alive
>> [2017-11-13 00:27:48,653]  INFO - LogMediator To:
>> /services/CentralPatientService/readCMedi, MessageID:
>> urn:uuid:db12eb62-ec97-45ff-8956-488d8b366d75, Direction: request,
>> Envelope: > xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/;>> oapenv:Body/>
>> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << HTTP/1.1 202
>> Accepted
>> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << Date: Sun,
>> 12 Nov 2017 18:57:48 GMT
>> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 <<
>> Transfer-Encoding: chunked
>> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << Connection:
>> keep-alive
>> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
>> "HTTP/1.1 202 Accepted[\r][\n]"
>> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
>> "Date: Sun, 12 Nov 2017 18:57:48 GMT[\r][\n]"
>> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
>> "Transfer-Encoding: chunked[\r][\n]"
>> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
>> "Connection: keep-alive[\r][\n]"
>> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
>> "[\r][\n]"
>> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
>> "0[\r][\n]"
>> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
>> "[\r][\n]"
>>
>> Cheers,
>> Thivya
>>
>> On Sun, Nov 12, 2017 at 11:44 PM, Bhathiya Jayasekara 

[Dev] No response when sending patientId as an argument

2017-11-12 Thread Buddhimala Ranasinghe
Hi All,

I have created an API in ESB 5.0.0 to access a secured SOAP BE service. As
per [1] I have added a dummy header into the paylaod so that my payload
will be as follows.



   http://schemas.xmlsoap.org/soap/envelope/; xmlns:ser="
http://service.sample.nawaloka.com;>
  
 12
  
  
 
$1
 
  
   


   

 

My problem now is, when I tried to invoke the API using SOAPUI, it doen't
show any response and the server side, it logs an error as below.

[2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
"GET /nawaloka/read/a...@abc.com HTTP/1.1[\r][\n]"
[2017-11-13 09:30:21,678] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
"Accept-Encoding: gzip,deflate[\r][\n]"
[2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
"Host: 172.17.0.1:8280[\r][\n]"
[2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
"Connection: Keep-Alive[\r][\n]"
[2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
"User-Agent: Apache-HttpClient/4.1.1 (java 1.5)[\r][\n]"
[2017-11-13 09:30:21,679] DEBUG - wire HTTP-Listener I/O dispatcher-3 >>
"[\r][\n]"
[2017-11-13 09:30:21,682] DEBUG - SynapseMessageReceiver Synapse received a
new message for message mediation...
[2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver Received To:
/nawaloka/read/a...@abc.com
[2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver SOAPAction: null
[2017-11-13 09:30:21,683] DEBUG - SynapseMessageReceiver WSA-Action: null
[2017-11-13 09:30:21,683] DEBUG - Axis2SynapseEnvironment Injecting
MessageContext
[2017-11-13 09:30:21,683] DEBUG - RESTRequestHandler Located specific API:
NawalokaPatientAPI for processing message
[2017-11-13 09:30:21,684] DEBUG - API Processing message with ID:
urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95 through the API:
NawalokaPatientAPI
[2017-11-13 09:30:21,684] DEBUG - API No matching resource was found for
the request: urn:uuid:9a9121dd-2025-489b-bba7-c4fba5a2eb95
[2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
"HTTP/1.1 404 Not Found[\r][\n]"
[2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
"Date: Mon, 13 Nov 2017 04:00:21 GMT[\r][\n]"
[2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
"Transfer-Encoding: chunked[\r][\n]"
[2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
"Connection: Keep-Alive[\r][\n]"
[2017-11-13 09:30:21,687] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
"[\r][\n]"
[2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
"0[\r][\n]"
[2017-11-13 09:30:21,688] DEBUG - wire HTTP-Listener I/O dispatcher-3 <<
"[\r][\n]"


But it shows a response when I enter a value for patientId parameter as
follows.

 a...@abc.com

FYI: patientId should be the patient's e-mail address.

[1] "API gives "SOAP Envelope can not have children other than SOAP Header
and Body" Exception"
-- 


*Buddhimala Ranasinghe *
Software Engineer-Support Team | WSO2
Emil: buddhim...@wso2.com
Mobile:+94771563138
Web:http://wso2.com
[image: https://wso2.com/signature] 
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [IS] Multiple stubs version in 5.4.0 pack

2017-11-12 Thread Harsha Thirimanna
On Sun, Nov 12, 2017 at 7:21 AM, Ruwan Abeykoon  wrote:

> Hi All,
> We need to work on removing previous version.
>
​Thanks Ruwan.​


>
>
> On Sat, Nov 11, 2017 at 12:01 PM, Harsha Thirimanna 
> wrote:
>
>> Hi Devs,
>>
>> We have zipped two stub versions in IS 5.4.0 pack OOB. Any special reason
>> for that ?
>>
>> org.wso2.carbon.identity.sso.saml.stub_5.1.3.jar
>> org.wso2.carbon.identity.sso.saml.stub_5.3.34.jar
>>
>>
>> thanks
>>
>> *Harsha Thirimanna*
>> *Associate Tech Lead | WSO2*
>>
>> Email: hars...@wso2.com
>> Mob: +94715186770 <+94%2071%20518%206770>
>> Blog: http://harshathirimanna.blogspot.com/
>> Twitter: http://twitter.com/harshathirimann
>> Linked-In: linked-in: http://www.linkedin.com/pub/ha
>> rsha-thirimanna/10/ab8/122
>> 
>>
>
>
>
> --
>
> *Ruwan Abeykoon*
> *Associate Director/Architect**,*
> *WSO2, Inc. http://wso2.com  *
> *lean.enterprise.middleware.*
>
>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Please review and merge PR

2017-11-12 Thread Harsha Kumara
On Sun, Nov 12, 2017 at 7:28 PM, 김대경  wrote:

> Can you please review and merge PR[1] and PR[2].
>
> [1] https://github.com/wso2/wso2-synapse/pull/952
> [2] https://github.com/wso2/carbon-mediation/pull/906
>
> Best Regards.
> Daekyung Kim.
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


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


Re: [Dev] API gives "SOAP Envelope can not have children other than SOAP Header and Body" Exception

2017-11-12 Thread Buddhimala Ranasinghe
Hi Bhathiya,

I could resolve the problem by adding a dummy header in the payload. Thank
you for your prompt response.

Regards,
Buddhimala

On Sun, Nov 12, 2017 at 1:08 PM, Bhathiya Jayasekara 
wrote:

> Looks like you're facing the same error mentioned here[1]. It seems the
> backend is expecting at least a dummy header. Try that.
>
> [1] "[Dev] Exception with header"
>
> Thanks,
> Bhathiya
>
> On Sun, Nov 12, 2017 at 12:34 PM, Buddhimala Ranasinghe <
> buddhim...@wso2.com> wrote:
>
>> Hi All,
>>
>> I have create an API in ESB 5.0.0 for accessing a secured  SOAP BE
>> service. Attached is the sysnapse configuraion for my API.
>>
>> http://ws.apache.org/ns/synapse; name="NawalokaPatientAPI"
>> context="/nawaloka">
>>
>>   
>>  
>>  
>> 
>>http://service.sample.nawaloka.com;>
>>   123
>>
>> 
>> 
>>
>> 
>>  
>>  
>>  
>>  
>>  
>>  
>> 
>>https://192.168.55.160:94
>> 43/services/NawalokaPatientService" format="soap11"/>
>> 
>>  
>>   
>>   
>>  > scope="axis2"/>
>>  
>>   
>>
>> 
>>
>> The WSDL for my BE service can be found in following URL location.
>>
>> http://192.168.55.160:9763/services/NawalokaPatientService?wsdl
>>
>>
>> My problem is, when I tried to invoke the API using SOAPUI, the following
>> error message prompt with 500 error code.
>>
>> {"Exception": "SOAP Envelope can not have children other than SOAP Header
>> and Body"}
>>
>> Attached what is logged in ESB, enabled wirelogs and debug logs.
>>
>> How can I resolve this issue? Appreciate your support.
>> --
>>
>>
>> *Buddhimala Ranasinghe*
>> Software Engineer-Support Team | WSO2
>> Emil: buddhim...@wso2.com
>> Mobile:+94771563138 <077%20156%203138>
>> Web:http://wso2.com
>> [image: https://wso2.com/signature] 
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> *Bhathiya Jayasekara*
> *Associate Technical Lead,*
> *WSO2 inc., http://wso2.com *
>
> *Phone: +94715478185 <+94%2071%20547%208185>*
> *LinkedIn: http://www.linkedin.com/in/bhathiyaj
> *
> *Twitter: https://twitter.com/bhathiyax *
> *Blog: http://movingaheadblog.blogspot.com
> *
>



-- 


*Buddhimala Ranasinghe*
Software Engineer-Support Team | WSO2
Emil: buddhim...@wso2.com
Mobile:+94771563138
Web:http://wso2.com
[image: https://wso2.com/signature] 
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [DEV] CRUD operation in API response with 202 accepted but operations are not performed

2017-11-12 Thread Himasha Guruge
Hi Thivya,

 Could you verify the media type you have used in payload
mediator?()  AFAIK, you can only use xml/json there [1] .
According to the wire logs the request that is been sent is an empty soap
envelope which means your request content has not been set through payload
mediator.

"Direction: request, Envelope: http://schemas.
xmlsoap.org/soap/envelope/">"

[1]
https://docs.wso2.com/display/ESB500/PayloadFactory+Mediator#PayloadFactoryMediator-Syntax

Thanks,
Himasha

On Mon, Nov 13, 2017 at 12:33 AM, Thivya Mahenthirarasa 
wrote:

> Hi ,
> Thank you for the response.
>
> I wonder that no request is sent to the back-end service. Just ESB is
> sending a response to the rest client that it accepts the requests. What
> might be the root cause?. This behavior occurs in all other resources
> too(DELETE, PUT, POST).
>
> What might be the root cause for this? Find the wire logs attached.
>
>
> [2017-11-13 00:27:48,651] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "GET /services/CentralPatientService/readCMedi HTTP/1.1[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "cache-control: no-cache[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "patientId: 15[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "Accept: application/json[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "Content-Type: application/json[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "User-Agent: PostmanRuntime/6.1.6[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "Host: 172.16.2.73:8285[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "accept-encoding: gzip, deflate[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "Connection: keep-alive[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
> "[\r][\n]"
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> GET /services/
> CentralPatientService/readCMedi HTTP/1.1
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> cache-control: no-cache
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> patientId: 15
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Accept:
> application/json
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Content-Type:
> application/json
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> User-Agent:
> PostmanRuntime/6.1.6
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Host:
> 172.16.2.73:8285
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
> accept-encoding: gzip, deflate
> [2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Connection:
> keep-alive
> [2017-11-13 00:27:48,653]  INFO - LogMediator To: /services/
> CentralPatientService/readCMedi, MessageID: 
> urn:uuid:db12eb62-ec97-45ff-8956-488d8b366d75,
> Direction: request, Envelope:  encoding='utf-8'?>http://schemas.
> xmlsoap.org/soap/envelope/">
> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << HTTP/1.1 202
> Accepted
> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << Date: Sun, 12
> Nov 2017 18:57:48 GMT
> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 <<
> Transfer-Encoding: chunked
> [2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << Connection:
> keep-alive
> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
> "HTTP/1.1 202 Accepted[\r][\n]"
> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
> "Date: Sun, 12 Nov 2017 18:57:48 GMT[\r][\n]"
> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
> "Transfer-Encoding: chunked[\r][\n]"
> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
> "Connection: keep-alive[\r][\n]"
> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
> "[\r][\n]"
> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
> "0[\r][\n]"
> [2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
> "[\r][\n]"
>
> Cheers,
> Thivya
>
> On Sun, Nov 12, 2017 at 11:44 PM, Bhathiya Jayasekara 
> wrote:
>
>> You can enable wire logs and see where the issue is. (i.e. the API itself
>> or backend).
>>
>> Thanks,
>> Bhathiya
>>
>> On Sun, Nov 12, 2017 at 11:22 PM, Thivya Mahenthirarasa 
>> wrote:
>>
>>> Hi,
>>>
>>> I created an API for CRUD operation in ESB 5.0.0 and tried to access a
>>> soap backend. And where
>>> the responses I get from all CRUD operations are 202 

Re: [Dev] [DEV] CRUD operation in API response with 202 accepted but operations are not performed

2017-11-12 Thread Thivya Mahenthirarasa
Hi ,
Thank you for the response.

I wonder that no request is sent to the back-end service. Just ESB is
sending a response to the rest client that it accepts the requests. What
might be the root cause?. This behavior occurs in all other resources
too(DELETE, PUT, POST).

What might be the root cause for this? Find the wire logs attached.


[2017-11-13 00:27:48,651] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"GET /services/CentralPatientService/readCMedi HTTP/1.1[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"cache-control: no-cache[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"Postman-Token: bfba4351-46c4-4fed-90f5-745566dbfdf7[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"patientId: 15[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"Accept: application/json[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"Content-Type: application/json[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"User-Agent: PostmanRuntime/6.1.6[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"Host: 172.16.2.73:8285[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"accept-encoding: gzip, deflate[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"Connection: keep-alive[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - wire HTTP-Listener I/O dispatcher-2 >>
"[\r][\n]"
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> GET
/services/CentralPatientService/readCMedi HTTP/1.1
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> cache-control:
no-cache
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Postman-Token:
bfba4351-46c4-4fed-90f5-745566dbfdf7
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> patientId: 15
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Accept:
application/json
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Content-Type:
application/json
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> User-Agent:
PostmanRuntime/6.1.6
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Host:
172.16.2.73:8285
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >>
accept-encoding: gzip, deflate
[2017-11-13 00:27:48,652] DEBUG - headers http-incoming-7 >> Connection:
keep-alive
[2017-11-13 00:27:48,653]  INFO - LogMediator To:
/services/CentralPatientService/readCMedi, MessageID:
urn:uuid:db12eb62-ec97-45ff-8956-488d8b366d75, Direction: request,
Envelope: http://schemas.xmlsoap.org/soap/envelope/
">
[2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << HTTP/1.1 202
Accepted
[2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << Date: Sun, 12
Nov 2017 18:57:48 GMT
[2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 <<
Transfer-Encoding: chunked
[2017-11-13 00:27:48,654] DEBUG - headers http-incoming-7 << Connection:
keep-alive
[2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
"HTTP/1.1 202 Accepted[\r][\n]"
[2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
"Date: Sun, 12 Nov 2017 18:57:48 GMT[\r][\n]"
[2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
"Transfer-Encoding: chunked[\r][\n]"
[2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
"Connection: keep-alive[\r][\n]"
[2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
"[\r][\n]"
[2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
"0[\r][\n]"
[2017-11-13 00:27:48,655] DEBUG - wire HTTP-Listener I/O dispatcher-2 <<
"[\r][\n]"

Cheers,
Thivya

On Sun, Nov 12, 2017 at 11:44 PM, Bhathiya Jayasekara 
wrote:

> You can enable wire logs and see where the issue is. (i.e. the API itself
> or backend).
>
> Thanks,
> Bhathiya
>
> On Sun, Nov 12, 2017 at 11:22 PM, Thivya Mahenthirarasa 
> wrote:
>
>> Hi,
>>
>> I created an API for CRUD operation in ESB 5.0.0 and tried to access a
>> soap backend. And where
>> the responses I get from all CRUD operations are 202 accepted. But no of
>> the operations are performed. Also, I'm not observing any error logs.
>>
>> I have attached here the GET operation resource of my API as a sample.
>>
>>
>>
>>  
>>   
>>  
>> 
>>http://www.w3.org/
>> 2003/05/soap-envelope">
>>   
>>  http://service.samp
>> le.central.com">
>> $1
>>  
>>   
>>
>> 
>> 
>>http://dto.service.sample.central.com/xsd;
>> evaluator="xml" expression="//m0:patientId"/>
>> 
>>  
>>  
>>  
>>  
>> 
>>https://192.168.55.160:94
>> 

Re: [Dev] [DEV] CRUD operation in API response with 202 accepted but operations are not performed

2017-11-12 Thread Bhathiya Jayasekara
You can enable wire logs and see where the issue is. (i.e. the API itself
or backend).

Thanks,
Bhathiya

On Sun, Nov 12, 2017 at 11:22 PM, Thivya Mahenthirarasa 
wrote:

> Hi,
>
> I created an API for CRUD operation in ESB 5.0.0 and tried to access a
> soap backend. And where
> the responses I get from all CRUD operations are 202 accepted. But no of
> the operations are performed. Also, I'm not observing any error logs.
>
> I have attached here the GET operation resource of my API as a sample.
>
>
>
>  
>   
>  
> 
>http://www.w3.org/
> 2003/05/soap-envelope">
>   
>  http://service.samp
> le.central.com">
> $1
>  
>   
>
> 
> 
>http://dto.service.sample.central.com/xsd;
> evaluator="xml" expression="//m0:patientId"/>
> 
>  
>  
>  
>  
> 
>https://192.168.55.160:94
> 43/services/CentralPatientService" format="soap11"/>
> 
>  
>  
>   
>   
>  
>   scope="axis2" type="STRING"/>
>  
>   
>
>
>
> WSDL location http://192.168.55.160:9763/services/CentralPatientService?
> wsdl
>
> Could you please advice on this?
>
>
> Cheers,
> Thivya
>
>
> --
>
> *Thivya Mahenthirarasa*
>
> *Software Engineer -Support Team | WSO2*
>
>
> *Email: thi...@wso2.com *
>
> *Mobile: +94766461966 <076%20646%201966> *
> *Web: http://wso2.com *
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Bhathiya Jayasekara*
*Associate Technical Lead,*
*WSO2 inc., http://wso2.com *

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


[Dev] [DEV] CRUD operation in API response with 202 accepted but operations are not performed

2017-11-12 Thread Thivya Mahenthirarasa
Hi,

I created an API for CRUD operation in ESB 5.0.0 and tried to access a soap
backend. And where
the responses I get from all CRUD operations are 202 accepted. But no of
the operations are performed. Also, I'm not observing any error logs.

I have attached here the GET operation resource of my API as a sample.



 
  
 

   http://www.w3.org/
2003/05/soap-envelope">
  
 http://service.
sample.central.com">
$1
 
  
   


   http://dto.service.sample.central.com/xsd;
evaluator="xml" expression="//m0:patientId"/>

 
 
 
 

   https://192.168.55.160:9443/services/
CentralPatientService" format="soap11"/>

 
 
  
  
 
 
 
  
   


WSDL location http://192.168.55.160:9763/services/CentralPatientService?wsdl

Could you please advice on this?


Cheers,
Thivya


-- 

*Thivya Mahenthirarasa*

*Software Engineer -Support Team | WSO2*


*Email: thi...@wso2.com *

*Mobile: +94766461966 *
*Web: http://wso2.com *
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Fwd: [DEV] CRUD operation in API response with 202 accepted but operations are not performed

2017-11-12 Thread Thivya Mahenthirarasa
Hi,

I created an API for CRUD operation in ESB 5.0.0 and tried to access a soap
backend. And where

The responses I get from all CRUD operations are 202 accepted. But no of
the operations are performed. Also, I'm not observing any error logs.

I have attached here the GET operation resource of my API as a sample.



 
  
 

   http://www.w3.org/
2003/05/soap-envelope">
  
 http://service.
sample.central.com">
$1
 
  
   


   http://dto.service.sample.central.com/xsd;
evaluator="xml" expression="//m0:patientId"/>

 
 
 
 

   https://192.168.55.160:9443/services/
CentralPatientService" format="soap11"/>

 
 
  
  
 
 
 
  
   


WSDL location http://192.168.55.160:9763/services/CentralPatientService?wsdl

Could you please advice on this?


Cheers,
Thivya

-- 

*Thivya Mahenthirarasa*

*Software Engineer -Support Team | WSO2*


*Email: thi...@wso2.com *

*Mobile: +94766461966 <+94%2076%20646%201966> *
*Web: http://wso2.com *



-- 

*Thivya Mahenthirarasa*

*Software Engineer -Support Team | WSO2*


*Email: thi...@wso2.com *

*Mobile: +94766461966 *
*Web: http://wso2.com *
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Please review and merge PR

2017-11-12 Thread 김대경
Can you please review and merge PR[1] and PR[2].

[1] https://github.com/wso2/wso2-synapse/pull/952
[2] https://github.com/wso2/carbon-mediation/pull/906

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