Results 1 to 10 of 27

Thread: Random Access Queue

Hybrid View

  1. #1
    Join Date
    Feb 2008
    Location
    Dublin - Ireland
    Posts
    102

    Default Random Access Queue

    I'm in the process of extending AbstractMessageChannel to obtain a Random Access Queue, is there something similar under way? Any suggestions on this? Should I publish the code in here?

    It's nothing complicated, though, just a simple wrapper around a Map.

  2. #2
    Join Date
    Oct 2005
    Location
    Boston, MA
    Posts
    2,840

    Default

    Can you elaborate a bit on the motivation/use-case?

    I'm curious if it's something that could be handled with a ChannelInterceptor or ChannelPurger.

    -Mark

  3. #3
    Join Date
    Feb 2008
    Location
    Dublin - Ireland
    Posts
    102

    Default

    Well, as I said in another post, I'm building a "service layer" based on REST to our in-house framework. In it I can have (at least) 3 types of invocations:

    1) Fire & Forget
    2) Request-and-wait-for-Response
    3) Request-and-get-Id
    4) get the response by id from 3)

    So for 3) and 4) I can have something like

    A) GET /slayer/reports/reportABC -> 8e596fd2-216e-4015-8609-463f3b83a253

    B) GET /slayer/reports -> list of reports on the "reports" queue not yet consumed

    C) GET /slayer/reports/8e596fd2-216e-4015-8609-463f3b83a253 -> the report from A)

    So I have to access the queue in a random way.

    What do you think?

  4. #4
    Join Date
    Feb 2008
    Location
    Dublin - Ireland
    Posts
    102

    Default

    BTW, how do I define what type of channel to use? Is using the datatype?

    <channel id="responseChannel" datatype="XXXXXXXX"/>


    And for other completely different thing, since I updated spring integration from trunk today I always get

    BeanDefinitionParsingException: Configuration problem: Unable to locate Spring NamespaceHandler for XML schema namespace [http://www.springframework.org/schema/integration]

    Have I missed anything?

    Thanks.

  5. #5
    Join Date
    Oct 2005
    Location
    Boston, MA
    Posts
    2,840

    Default

    The "datatype" attribute is for the accepted types of Message payload (see: ttp://static.springframework.org/spring-integration/reference/htmlsingle/spring-integration-reference.html#namespace-channel)

    When using <channel/> currently it will always create a SimpleChannel (with different internal queue based on the capacity you provide). If you want to use a PriorityChannel, you would need to define a generic <bean/> at this point (the namespace support for that is on the M3 roadmap).

    As far as the XSD resolution, can you post your xmlns declarations from the top-level element? (or try this... it was temporarily expecting "spring-integration-adapters-1.0.xsd" but now should be just "spring-integration-1.0.xsd").

    Mark

  6. #6
    Join Date
    Feb 2008
    Location
    Dublin - Ireland
    Posts
    102

    Default

    Ok, no problem with that. But I have another question. (moved to here)
    Last edited by amsmota; Mar 3rd, 2008 at 09:41 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •