Uploaded image for project: 'CXF'
  1. CXF
  2. CXF-3277

soap headers can't be carried back when exception happen

Agile BoardAttach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.3.3, 2.4
    • None
    • None

    Description

      for example we have a methoh like

      public BareDocumentResponse testDocLitFault(String in) throws BadRecordLitFault {
              System.out.println("Executing testDocLitFault sayHi\n");
              List<Header> headers = new ArrayList<Header>();
              Header header = null;
              try {
                  header = new Header(new QName("http://test", "test"), 
                                      new String("test"), new JAXBDataBinding(String.class));
              } catch (JAXBException e) {
                  e.printStackTrace();
              }                        
              headers.add(header);
              context.getMessageContext().put(Header.HEADER_LIST, headers);
              throw new BadRecordLitFault("int fault", 5);
      
          }
      

      we explicitly put some headers for response message, it works in normal response, but doesn't work when throw Fault/Exception

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            ffang Freeman Yue Fang
            ffang Freeman Yue Fang
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment