geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "vu.nguyen (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (GERONIMO-6104) @HandlerChain
Date Sat, 06 Aug 2011 09:13:27 GMT

    [ https://issues.apache.org/jira/browse/GERONIMO-6104?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13080377#comment-13080377
] 

vu.nguyen commented on GERONIMO-6104:
-------------------------------------

Ivan,

The problem is not related to the structure of the handlers.xml file, but is the system cannot
find the location of the handlers.xml file. That cause the NPE error and I fixed by my patch

FYI,
+ handlers.xml
==========
<handler-chains xmlns="http://java.sun.com/xml/ns/javaee" 
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
        xsi:schemaLocation="http://java.sun.com/xml/ns/javaee">
    <handler-chain>
        <handler>
            <handler-name>JAXWSHandler</handler-name>
            <handler-class>examples.JAXWSHandler</handler-class>
        </handler>
    </handler-chain>
</handler-chains>                
=================================================================

+ JAXWSHandler.java
===========
public class JAXWSHandler implements SOAPHandler<SOAPMessageContext> {

    public boolean handleMessage(SOAPMessageContext context) {
        System.out.println("handleMessage()......");
        return true;
    }

    public boolean handleFault(SOAPMessageContext context) {
        System.out.println("handleFault()......");
        return true;
    }

    public void close(MessageContext context) {
        System.out.println("close()......");
    }

    public Set<QName> getHeaders() {
        System.out.println("getHeaders()......");
        return null;
    }
 }
=================================================================

+ ServerInfo.java
========
@WebService
@HandlerChain(file="handlers.xml")
public class ServerInfo{
    @WebMethod
    public String getServerName() {
        return "abc";
    }
}
=================================================================

> @HandlerChain
> -------------
>
>                 Key: GERONIMO-6104
>                 URL: https://issues.apache.org/jira/browse/GERONIMO-6104
>             Project: Geronimo
>          Issue Type: Bug
>      Security Level: public(Regular issues) 
>          Components: webservices
>    Affects Versions: 2.2.1
>            Reporter: vu.nguyen
>            Assignee: Ivan
>              Labels: patch
>         Attachments: patch.txt
>
>
> Got NPE when using the @HandlerChain annotation in WebService

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message