JiBX
  1. JiBX
  2. JIBX-325

JiBX/WS: Provide better errors when binding doesn't contain mapping for class

    Details

    • Type: Improvement Improvement
    • Status: Closed Closed
    • Priority: Minor Minor
    • Resolution: Won't Fix
    • Affects Version/s: JiBX/WS 0.9
    • Fix Version/s: None
    • Component/s: JiBX/WS
    • Labels:
      None
    • Number of attachments :
      0

      Description

      When implementing multiple operations at one endpoint, the binding file must contain mappings for all of the in and out classes. This can be checked when the service is configured, rather than relying on the current runtime check, and a more detailed exception raised.

      (Note: JiBX/WS supports separate binding files for inbound and outbound parameters, so that all of the classes for inbound parameters can be in one binding file, and all of the outbound in a separate binding file. This supports unidirectional bindings.)

        Activity

        Hide
        Nigel Charman added a comment -

        Dynamic mappings are allowed for output values where the actual return type is a child of the declared type. For example, org.jibx.ws.example.custom.exception.server.HelloServer declares the method

        public Object welcomeService(Greetee greetee)

        which at runtime returns either a ServiceError or Welcome object.

        Given this, the binding cannot be checked until runtime for output classes.

        Have checked in some commented out code that validates the bindings, but this breaks in the above scenario.

        Not implementing the fix, since it provides marginal benefit and breaks some cases. Will now remove the commented out code,

        Show
        Nigel Charman added a comment - Dynamic mappings are allowed for output values where the actual return type is a child of the declared type. For example, org.jibx.ws.example.custom.exception.server.HelloServer declares the method public Object welcomeService(Greetee greetee) which at runtime returns either a ServiceError or Welcome object. Given this, the binding cannot be checked until runtime for output classes. Have checked in some commented out code that validates the bindings, but this breaks in the above scenario. Not implementing the fix, since it provides marginal benefit and breaks some cases. Will now remove the commented out code,

          People

          • Assignee:
            Nigel Charman
            Reporter:
            Nigel Charman
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: