[Axis2]

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

[Axis2]

Faizan Khan

Hi I have implemented my own module with handler for axis2 web service, following the writing your own Axis2 module guide on axis.apache.org website.

My handler is getting invoked properly but MessageContext value is coming as null, I tried to get solution from many place but nothing is working can you please help.

 

I will be obliged if any help can be provided.

Thanks in advance

 

Sent from Mail for Windows 10

 

Reply | Threaded
Open this post in threaded view
|

Re: [Axis2]

robertlazarski .
Hard to say without seeing your code.

Try enabling debug logging. I suggest double checking your axis2.xml
config, using the logging module or soap monitor as a reference.

Regards,
Robert

On Thu, Jan 30, 2020 at 12:15 AM Faizan Khan <[hidden email]> wrote:

>
> Hi I have implemented my own module with handler for axis2 web service, following the writing your own Axis2 module guide on axis.apache.org website.
>
> My handler is getting invoked properly but MessageContext value is coming as null, I tried to get solution from many place but nothing is working can you please help.
>
>
>
> I will be obliged if any help can be provided.
>
> Thanks in advance
>
>
>
> Sent from Mail for Windows 10
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [Axis2]

Faizan Khan
Hi Robert, 
Thanks For replying, I have attached all files Screen Shots below, please if you can have a look once and tell that where I am going wrong.

axis2.xml (creditSoapPhase)
image.png

Handler Class
image.png
HandlerModule.java class
image.png
Module.xml
image.png

On Fri, Jan 31, 2020 at 8:53 AM robertlazarski . <[hidden email]> wrote:
Hard to say without seeing your code.

Try enabling debug logging. I suggest double checking your axis2.xml
config, using the logging module or soap monitor as a reference.

Regards,
Robert

On Thu, Jan 30, 2020 at 12:15 AM Faizan Khan <[hidden email]> wrote:
>
> Hi I have implemented my own module with handler for axis2 web service, following the writing your own Axis2 module guide on axis.apache.org website.
>
> My handler is getting invoked properly but MessageContext value is coming as null, I tried to get solution from many place but nothing is working can you please help.
>
>
>
> I will be obliged if any help can be provided.
>
> Thanks in advance
>
>
>
> Sent from Mail for Windows 10
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [Axis2]

robertlazarski .
I couldn't find your creditSoapPhase in your axis2.xml, could you post the text of the file?

Also, please post the entire stacktrace of your error. Putting axis2 into debug mode may also help clarify the problem.

Does your invoke() method of your handler get executed?

Regards,
Robert

On Wed, Feb 5, 2020 at 9:58 PM faizan khan <[hidden email]> wrote:
Hi Robert, 
Thanks For replying, I have attached all files Screen Shots below, please if you can have a look once and tell that where I am going wrong.

axis2.xml (creditSoapPhase)
image.png

Handler Class
image.png
HandlerModule.java class
image.png
Module.xml
image.png

On Fri, Jan 31, 2020 at 8:53 AM robertlazarski . <[hidden email]> wrote:
Hard to say without seeing your code.

Try enabling debug logging. I suggest double checking your axis2.xml
config, using the logging module or soap monitor as a reference.

Regards,
Robert

On Thu, Jan 30, 2020 at 12:15 AM Faizan Khan <[hidden email]> wrote:
>
> Hi I have implemented my own module with handler for axis2 web service, following the writing your own Axis2 module guide on axis.apache.org website.
>
> My handler is getting invoked properly but MessageContext value is coming as null, I tried to get solution from many place but nothing is working can you please help.
>
>
>
> I will be obliged if any help can be provided.
>
> Thanks in advance
>
>
>
> Sent from Mail for Windows 10
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [Axis2]

Faizan Khan
Hi Robert,
Thanks for your reply, below i have attached my logs which i am getting:-
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:294 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Checking pre-condition for Phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:305 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:336 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking Handler 'InFlowCreditSoapHandler' in Phase 'creditSoapPhase'
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:26 - null
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b]
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:28 - null
[20-02-07 06:16:59:275 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:30 - null

I am also attaching my axis2.xml text file.

Yes invoke() method of my handler is getting executed properly but messageContext is coming as null.

Thanks in advance.

On Thu, Feb 6, 2020 at 9:16 PM robertlazarski . <[hidden email]> wrote:
I couldn't find your creditSoapPhase in your axis2.xml, could you post the text of the file?

Also, please post the entire stacktrace of your error. Putting axis2 into debug mode may also help clarify the problem.

Does your invoke() method of your handler get executed?

Regards,
Robert

On Wed, Feb 5, 2020 at 9:58 PM faizan khan <[hidden email]> wrote:
Hi Robert, 
Thanks For replying, I have attached all files Screen Shots below, please if you can have a look once and tell that where I am going wrong.

axis2.xml (creditSoapPhase)
image.png

Handler Class
image.png
HandlerModule.java class
image.png
Module.xml
image.png

On Fri, Jan 31, 2020 at 8:53 AM robertlazarski . <[hidden email]> wrote:
Hard to say without seeing your code.

Try enabling debug logging. I suggest double checking your axis2.xml
config, using the logging module or soap monitor as a reference.

Regards,
Robert

On Thu, Jan 30, 2020 at 12:15 AM Faizan Khan <[hidden email]> wrote:
>
> Hi I have implemented my own module with handler for axis2 web service, following the writing your own Axis2 module guide on axis.apache.org website.
>
> My handler is getting invoked properly but MessageContext value is coming as null, I tried to get solution from many place but nothing is working can you please help.
>
>
>
> I will be obliged if any help can be provided.
>
> Thanks in advance
>
>
>
> Sent from Mail for Windows 10
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]



---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

axis2.ml (37K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [Axis2]

robertlazarski .
I modified the axis2.xml slightly and attached it, just going on an educated guess.

Mainly your handler maybe needs to come after InFlowCreditSoapHandler, since the logs shows this after your handler:

[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b]

Let us know how that turns out.

Regards,
Robert

On Fri, Feb 7, 2020 at 2:21 AM faizan khan <[hidden email]> wrote:
Hi Robert,
Thanks for your reply, below i have attached my logs which i am getting:-
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:294 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Checking pre-condition for Phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:305 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:336 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking Handler 'InFlowCreditSoapHandler' in Phase 'creditSoapPhase'
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:26 - null
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b]
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:28 - null
[20-02-07 06:16:59:275 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:30 - null

I am also attaching my axis2.xml text file.

Yes invoke() method of my handler is getting executed properly but messageContext is coming as null.

Thanks in advance.

On Thu, Feb 6, 2020 at 9:16 PM robertlazarski . <[hidden email]> wrote:
I couldn't find your creditSoapPhase in your axis2.xml, could you post the text of the file?

Also, please post the entire stacktrace of your error. Putting axis2 into debug mode may also help clarify the problem.

Does your invoke() method of your handler get executed?

Regards,
Robert

On Wed, Feb 5, 2020 at 9:58 PM faizan khan <[hidden email]> wrote:
Hi Robert, 
Thanks For replying, I have attached all files Screen Shots below, please if you can have a look once and tell that where I am going wrong.

axis2.xml (creditSoapPhase)
image.png

Handler Class
image.png
HandlerModule.java class
image.png
Module.xml
image.png

On Fri, Jan 31, 2020 at 8:53 AM robertlazarski . <[hidden email]> wrote:
Hard to say without seeing your code.

Try enabling debug logging. I suggest double checking your axis2.xml
config, using the logging module or soap monitor as a reference.

Regards,
Robert

On Thu, Jan 30, 2020 at 12:15 AM Faizan Khan <[hidden email]> wrote:
>
> Hi I have implemented my own module with handler for axis2 web service, following the writing your own Axis2 module guide on axis.apache.org website.
>
> My handler is getting invoked properly but MessageContext value is coming as null, I tried to get solution from many place but nothing is working can you please help.
>
>
>
> I will be obliged if any help can be provided.
>
> Thanks in advance
>
>
>
> Sent from Mail for Windows 10
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

axis2.xml (37K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [Axis2]

Faizan Khan
Hi Robert,
I did the required change which you asked for but getting below logs.
[20-02-12 03:23:32:586 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] engine.Phase:294 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0] Checking pre-condition for Phase "creditSoapPhase"
[20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] engine.Phase:305 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0] Invoking phase "creditSoapPhase"
[20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] engine.Phase:336 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0] Invoking Handler 'InFlowCreditSoapHandler' in Phase 'creditSoapPhase'
[20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:26 - null
[20-02-12 03:23:32:588 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0]
[20-02-12 03:23:32:588 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:28 - null
[20-02-12 03:23:32:588 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:30 - null
[20-02-12 03:23:32:589 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] http.AxisServlet:55 - OnDemandLogger initialized for class org.apache.axis2.transport.http.AxisServlet is:org.apache.logging.log4j.jcl.Log4jLog@340de563

On Tue, Feb 11, 2020 at 7:17 AM robertlazarski . <[hidden email]> wrote:
I modified the axis2.xml slightly and attached it, just going on an educated guess.

Mainly your handler maybe needs to come after InFlowCreditSoapHandler, since the logs shows this after your handler:

[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b]

Let us know how that turns out.

Regards,
Robert

On Fri, Feb 7, 2020 at 2:21 AM faizan khan <[hidden email]> wrote:
Hi Robert,
Thanks for your reply, below i have attached my logs which i am getting:-
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:294 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Checking pre-condition for Phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:305 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:336 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking Handler 'InFlowCreditSoapHandler' in Phase 'creditSoapPhase'
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:26 - null
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b]
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:28 - null
[20-02-07 06:16:59:275 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:30 - null

I am also attaching my axis2.xml text file.

Yes invoke() method of my handler is getting executed properly but messageContext is coming as null.

Thanks in advance.

On Thu, Feb 6, 2020 at 9:16 PM robertlazarski . <[hidden email]> wrote:
I couldn't find your creditSoapPhase in your axis2.xml, could you post the text of the file?

Also, please post the entire stacktrace of your error. Putting axis2 into debug mode may also help clarify the problem.

Does your invoke() method of your handler get executed?

Regards,
Robert

On Wed, Feb 5, 2020 at 9:58 PM faizan khan <[hidden email]> wrote:
Hi Robert, 
Thanks For replying, I have attached all files Screen Shots below, please if you can have a look once and tell that where I am going wrong.

axis2.xml (creditSoapPhase)
image.png

Handler Class
image.png
HandlerModule.java class
image.png
Module.xml
image.png

On Fri, Jan 31, 2020 at 8:53 AM robertlazarski . <[hidden email]> wrote:
Hard to say without seeing your code.

Try enabling debug logging. I suggest double checking your axis2.xml
config, using the logging module or soap monitor as a reference.

Regards,
Robert

On Thu, Jan 30, 2020 at 12:15 AM Faizan Khan <[hidden email]> wrote:
>
> Hi I have implemented my own module with handler for axis2 web service, following the writing your own Axis2 module guide on axis.apache.org website.
>
> My handler is getting invoked properly but MessageContext value is coming as null, I tried to get solution from many place but nothing is working can you please help.
>
>
>
> I will be obliged if any help can be provided.
>
> Thanks in advance
>
>
>
> Sent from Mail for Windows 10
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: [Axis2]

robertlazarski .
I don't see an error. Is your message context still null?

On Tue, Feb 11, 2020 at 11:30 PM faizan khan <[hidden email]> wrote:
Hi Robert,
I did the required change which you asked for but getting below logs.
[20-02-12 03:23:32:586 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] engine.Phase:294 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0] Checking pre-condition for Phase "creditSoapPhase"
[20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] engine.Phase:305 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0] Invoking phase "creditSoapPhase"
[20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] engine.Phase:336 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0] Invoking Handler 'InFlowCreditSoapHandler' in Phase 'creditSoapPhase'
[20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:26 - null
[20-02-12 03:23:32:588 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0]
[20-02-12 03:23:32:588 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:28 - null
[20-02-12 03:23:32:588 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:30 - null
[20-02-12 03:23:32:589 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] http.AxisServlet:55 - OnDemandLogger initialized for class org.apache.axis2.transport.http.AxisServlet is:org.apache.logging.log4j.jcl.Log4jLog@340de563

On Tue, Feb 11, 2020 at 7:17 AM robertlazarski . <[hidden email]> wrote:
I modified the axis2.xml slightly and attached it, just going on an educated guess.

Mainly your handler maybe needs to come after InFlowCreditSoapHandler, since the logs shows this after your handler:

[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b]

Let us know how that turns out.

Regards,
Robert

On Fri, Feb 7, 2020 at 2:21 AM faizan khan <[hidden email]> wrote:
Hi Robert,
Thanks for your reply, below i have attached my logs which i am getting:-
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:294 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Checking pre-condition for Phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:305 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:336 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking Handler 'InFlowCreditSoapHandler' in Phase 'creditSoapPhase'
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:26 - null
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b]
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:28 - null
[20-02-07 06:16:59:275 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:30 - null

I am also attaching my axis2.xml text file.

Yes invoke() method of my handler is getting executed properly but messageContext is coming as null.

Thanks in advance.

On Thu, Feb 6, 2020 at 9:16 PM robertlazarski . <[hidden email]> wrote:
I couldn't find your creditSoapPhase in your axis2.xml, could you post the text of the file?

Also, please post the entire stacktrace of your error. Putting axis2 into debug mode may also help clarify the problem.

Does your invoke() method of your handler get executed?

Regards,
Robert

On Wed, Feb 5, 2020 at 9:58 PM faizan khan <[hidden email]> wrote:
Hi Robert, 
Thanks For replying, I have attached all files Screen Shots below, please if you can have a look once and tell that where I am going wrong.

axis2.xml (creditSoapPhase)
image.png

Handler Class
image.png
HandlerModule.java class
image.png
Module.xml
image.png

On Fri, Jan 31, 2020 at 8:53 AM robertlazarski . <[hidden email]> wrote:
Hard to say without seeing your code.

Try enabling debug logging. I suggest double checking your axis2.xml
config, using the logging module or soap monitor as a reference.

Regards,
Robert

On Thu, Jan 30, 2020 at 12:15 AM Faizan Khan <[hidden email]> wrote:
>
> Hi I have implemented my own module with handler for axis2 web service, following the writing your own Axis2 module guide on axis.apache.org website.
>
> My handler is getting invoked properly but MessageContext value is coming as null, I tried to get solution from many place but nothing is working can you please help.
>
>
>
> I will be obliged if any help can be provided.
>
> Thanks in advance
>
>
>
> Sent from Mail for Windows 10
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: [Axis2]

Faizan Khan
Yes, if you will see the below line is printing:-
20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:26 - null 
Null and if you will see line number 26 of MyHandler.java class is simply printing tha MessageContext object.

On Wed, Feb 12, 2020, 9:12 PM robertlazarski . <[hidden email]> wrote:
I don't see an error. Is your message context still null?

On Tue, Feb 11, 2020 at 11:30 PM faizan khan <[hidden email]> wrote:
Hi Robert,
I did the required change which you asked for but getting below logs.
[20-02-12 03:23:32:586 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] engine.Phase:294 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0] Checking pre-condition for Phase "creditSoapPhase"
[20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] engine.Phase:305 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0] Invoking phase "creditSoapPhase"
[20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] engine.Phase:336 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0] Invoking Handler 'InFlowCreditSoapHandler' in Phase 'creditSoapPhase'
[20-02-12 03:23:32:587 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:26 - null
[20-02-12 03:23:32:588 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=7616552369d179d8bc60c4f47dd4c1ecb49287dc04df80e0]
[20-02-12 03:23:32:588 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:28 - null
[20-02-12 03:23:32:588 CST] [ajp-nio-8016-exec-7] [] [] [ INFO] creditsoap.MyHandler:30 - null
[20-02-12 03:23:32:589 CST] [ajp-nio-8016-exec-7] [] [] [DEBUG] http.AxisServlet:55 - OnDemandLogger initialized for class org.apache.axis2.transport.http.AxisServlet is:org.apache.logging.log4j.jcl.Log4jLog@340de563

On Tue, Feb 11, 2020 at 7:17 AM robertlazarski . <[hidden email]> wrote:
I modified the axis2.xml slightly and attached it, just going on an educated guess.

Mainly your handler maybe needs to come after InFlowCreditSoapHandler, since the logs shows this after your handler:

[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b]

Let us know how that turns out.

Regards,
Robert

On Fri, Feb 7, 2020 at 2:21 AM faizan khan <[hidden email]> wrote:
Hi Robert,
Thanks for your reply, below i have attached my logs which i am getting:-
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:294 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Checking pre-condition for Phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:305 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking phase "creditSoapPhase"
[20-02-07 06:16:59:273 CST] [ajp-nio-8016-exec-20] [] [] [DEBUG] engine.Phase:336 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b] Invoking Handler 'InFlowCreditSoapHandler' in Phase 'creditSoapPhase'
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:26 - null
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:27 - [MessageContext: logID=79dddcf5380a5da866fd508e3bffc5f0063c049da9f4747b]
[20-02-07 06:16:59:274 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:28 - null
[20-02-07 06:16:59:275 CST] [ajp-nio-8016-exec-20] [] [] [ INFO] creditsoap.MyHandler:30 - null

I am also attaching my axis2.xml text file.

Yes invoke() method of my handler is getting executed properly but messageContext is coming as null.

Thanks in advance.

On Thu, Feb 6, 2020 at 9:16 PM robertlazarski . <[hidden email]> wrote:
I couldn't find your creditSoapPhase in your axis2.xml, could you post the text of the file?

Also, please post the entire stacktrace of your error. Putting axis2 into debug mode may also help clarify the problem.

Does your invoke() method of your handler get executed?

Regards,
Robert

On Wed, Feb 5, 2020 at 9:58 PM faizan khan <[hidden email]> wrote:
Hi Robert, 
Thanks For replying, I have attached all files Screen Shots below, please if you can have a look once and tell that where I am going wrong.

axis2.xml (creditSoapPhase)
image.png

Handler Class
image.png
HandlerModule.java class
image.png
Module.xml
image.png

On Fri, Jan 31, 2020 at 8:53 AM robertlazarski . <[hidden email]> wrote:
Hard to say without seeing your code.

Try enabling debug logging. I suggest double checking your axis2.xml
config, using the logging module or soap monitor as a reference.

Regards,
Robert

On Thu, Jan 30, 2020 at 12:15 AM Faizan Khan <[hidden email]> wrote:
>
> Hi I have implemented my own module with handler for axis2 web service, following the writing your own Axis2 module guide on axis.apache.org website.
>
> My handler is getting invoked properly but MessageContext value is coming as null, I tried to get solution from many place but nothing is working can you please help.
>
>
>
> I will be obliged if any help can be provided.
>
> Thanks in advance
>
>
>
> Sent from Mail for Windows 10
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

image.png (108K) Download Attachment
image.png (72K) Download Attachment
image.png (61K) Download Attachment
image.png (75K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [Axis2]

robertlazarski .
I reviewed your code and logs, can you please post your services.xml for completeness? Its probably correct since your module is getting invoked.

Its been a while since I looked at this module code, I contributed the soap monitor module many years ago.

So it seems the messagecontext is not null, but rather the return values from the methods of the Object are null. Looking at some of my previous comments in this area, I noticed that the phase is important.

Here's an example, it may be the case that these values will not be null in a different phase.

invoke(MessageContext messageContext) {
  EndpointReference ref = null;

  if (messageContext.getFLOW() == MessageContext.IN_FLOW) {
        ref = messageContext.getTo();
    } else if (messageContext.getFLOW() == MessageContext.OUT_FLOW) {
        ref = messageContext.getFrom();
    }
}