locked
why are sys.transmission_queue and sys.conversation_endpoints filling up?? RRS feed

  • Question

  •  hi all!

     

    I have 2 instances that communicate via service broker.

    The conversations are only one way from initiator server1 db to target server2 db.

    I also reuse dialog id's in BEGIN DIALOG @dlgId

    i save @dlgId from the first run into a table and then retreive it for each message send

    since the messages are constant i don't close the dialog at the target for each message.

     

    i'm just wodering why do both sys.transmission_queue and sys.conversation_endpoints get a row

    for each message i send but the transmission_status in sys.transmission_queue is emtpy.

     

    also each conversation_handle and conversation_id is different for each row and

    only one row in each sys table has the same conversation_handle as my saved @dlgId.

     

    just wondering what is going on.

     

    this code is done on the initiator

     

    DECLARE @dlgId UNIQUEIDENTIFIER

    -- each database has one dialog id

    SELECT @dlgId = DialogId

    FROM dbo.Dialogs

    WHERE DbId = DB_ID()

    -- Begin the dialog, either with existing or new Id

    BEGIN DIALOG @dlgId

    FROM SERVICE [//DataSender] -- service on initiator server

    TO SERVICE '//DataWriter', -- service on target server

    -- Target's Service Broker Id

    '83382A22-2830-4B25-B067-15AAC255EB03'

    ON CONTRACT [//Contract1]

    WITH ENCRYPTION = OFF;

    -- Send data

    ;SEND ON CONVERSATION @dlgId

    MESSAGE TYPE [//Message1] (@msg)

     

    Thanx,

       Mladen

    Wednesday, July 25, 2007 8:43 PM

Answers

All replies

  • most likely acknowledgements from //DataWriter cannot reach back the //DataSender service. Check //DataWriter's service database and ensure it has the proper route for the ''//DataSender" service
    Wednesday, July 25, 2007 9:58 PM
  • aha, so i have to have a route from the target to the initator too??

    so if i have multiple initiators sending stuff to a single target

    i have to have a route from target to initiator for each initiator?

     

    Thursday, July 26, 2007 8:36 AM
  • Yes. Each initiator must have it's own route. If the initiators use the same service name, then you must distinguish them using the BROKER_INSTANCE (which will be the value of the sys.databases.service_broker_guid of the database hosting the initiator service).

    Thursday, July 26, 2007 8:49 AM
  • and i have to do this even if i don't need any information sent back from target to initiators??

     

    what i'm doing is building a kind of a repository of needed information on a central server. there are a few other servers each having a few databases. each db on each server has to send it's data to our central server.

    any advice on how to best accomplish this?

     

     

    Thursday, July 26, 2007 9:59 AM
  • There is always information sent back, the acknowledgements and the EndDialog sent my the target (make sure you end the dialogs, and you end from the target first if you never send a message back). See this previous thread on a similar topic: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1693489&SiteID=1

     

    Thursday, July 26, 2007 10:13 AM
  •  

    thanx a lot.
    Thursday, July 26, 2007 11:06 AM