1 Reply Latest reply on Apr 22, 2010 3:43 AM by ataylor

    RA configuration and documentation

    jmesnil

      I'm documenting our Resource Adapter and there are a few things I'm not sure about.

      AIUI, the RA can be configured at 3 different places:
      - global configuration, mapped to HornetQRAProperties, from ra.xml
      - outbound configuration, mapped to HornetQRAMCFProperties, from *-ds.xml and ra.xml's <outbound-resourceadapter>
      - inbound configurationn, mapped to HornetQActivationSpec, from MDB annotations or DD and ra.xml's <inbound-resourceadapter>
      The 3 classes all extend ConnectionFactoryProperties.
      So far so good.
      - Connector parameters
      Both HornetQRAMCFProperties & HornetQActivationSpec defines the live connector parameters but not HornetQRAProperties...
      I suppose the connector params should go in the base classe ConnectionFactoryProperties instead. right?
      - Backup
      Only HornetQRAMCFProperties can configure backup connector parameters. Is there a reason for that? I'd move the parameters in ConnectionFactoryProperties else.
      - HornetQResourceAdapter
      this class has public accessors for all RA properties. What's their use? Is the AS supposed to automagically call them?  When and how?
      - HornetQActivationSpec (inbound adapter)
      MaxMessage is defined but is not used. What's this parameter for?
      MinSession is defined but not used. I supposed it should be used in HornetQActivation.setup() when creating the sessions.
      What are their default values? in HornetQActivationSpec ctor, we have min=1, max=15 but the getter say both=0 if they're not defined
      (but they're defined in the ctor!)
        • 1. Re: RA configuration and documentation
          ataylor

          {quote}I'm documenting our Resource Adapter and there are a few things I'm not sure about.

          AIUI, the RA can be configured at 3 different places:
          - global configuration, mapped to HornetQRAProperties, from ra.xml
          - outbound configuration, mapped to HornetQRAMCFProperties, from *-ds.xml and ra.xml's <outbound-resourceadapter>
          - inbound configurationn, mapped to HornetQActivationSpec, from MDB annotations or DD and ra.xml's <inbound-resourceadapter>
          The 3 classes all extend ConnectionFactoryProperties.
          So far so good.{quote}

           

          Ok

           

          {quote}- Connector parameters
          Both HornetQRAMCFProperties & HornetQActivationSpec defines the live connector parameters but not HornetQRAProperties...
          I suppose the connector params should go in the base classe ConnectionFactoryProperties instead. right?
          {quote}

          Yeah that makes sense

           

          - Backup
          Only HornetQRAMCFProperties can configure backup connector parameters. Is there a reason for that? I'd move the parameters in ConnectionFactoryProperties else.

          Yes, do that

           

           

          {quote}- HornetQResourceAdapter
          this class has public accessors for all RA properties. What's their use? Is the AS supposed to automagically call them?  When and how?
          {quote}

          Yes, these are set via the global properties in the ra.xml file and we delegate them to HornetQRAProperties which is used when creating the connection

           

           

          {quote}- HornetQActivationSpec (inbound adapter)
          MaxMessage is defined but is not used. What's this parameter for?
          MinSession is defined but not used. I supposed it should be used in HornetQActivation.setup() when creating the sessions.
          {quote}

          Max messages can be removed it was used when the RA was using a connection consumer.

          MinSession i dont think we need as we always create max session