Service Broker New Service Broker Application
  Home FAQ Contact Sign in
microsoft.public.sqlserver.tools only
 
Advanced search
POPULAR GROUPS

more...

microsoft ... sqlserver.tools Profile…
 Up
Service Broker New Service Broker Application         


Author: newscorrespondent
Date: Sep 10, 2008 20:12

In Sql Server Management Studio when I right click on the Service Broker and
select New Service Broker Application the code that it generates (included
below) looks like it has an error to me.

Should the code that checks for an 'End Dialog' message have an
ELSE
BEGIN BREAK;
END;

or why do the loop again?

Thanks
Tom

-- ============================================================
-- Create Request Response Application with Activation Template
-- ============================================================

-- Create the stored procedure
Show full article (3.04Kb)
1 Comment
Re: Service Broker New Service Broker Application         


Author: Dan Guzman
Date: Sep 11, 2008 05:14

> Should the code that checks for an 'End Dialog' message have an
> ELSE
> BEGIN BREAK;
> END;

A common activated proc pattern is to wait for another message instead of
exiting immediately upon receipt of the EndDialog message. This way, SB
doesn't need to activate another proc instance when another message is
available in the queue. No problem exiting with smaller message volumes but
be sure to commit before exiting.

--
Hope this helps.

Dan Guzman
SQL Server MVP
http://weblogs.sqlteam.com/dang/

charter.net> wrote in message
news:J00yk.767$Il.544@newsfe09.iad...
> In Sql Server Management Studio when I right click on the Service Broker
> and
> select New Service Broker Application...
Show full article (3.78Kb)
no comments