2
이벤트 알림에 BROKER_QUEUE_DISABLED
옵션을 사용하려고 시도하면 올바르게 브로커 대기열 사용 안 함 이벤트가 생성되지 않는 것으로 보입니다. 어떤 스크립트를 내가 만든 스크립트의 유효성을 검사 할 수 있습니까?Service Broker 응용 프로그램 대기열 이벤트 사용 안 함
CREATE QUEUE NotifyQueue
GO
CREATE
SERVICE NotifyService
ON
QUEUE NotifyQueue
[http://schemas.microsoft.com/SQL/Notifications/PostEventNotification]);
GO
CREATE ROUTE NotifyRoute
WITH SERVICE_NAME = 'NotifyService',
ADDRESS = 'LOCAL';
GO
CREATE
EVENT NOTIFICATION [CHS_QueueDisabledNotif]
ON QUEUE [CHS_Change_Queue] WITH FAN_IN
FOR BROKER_QUEUE_DISABLED
TO SERVICE 'NotifyService', 'current database'
--Testing
--Try Disabling Application Queue
ALTER QUEUE dbo.CHS_Change_Queue WITH STATUS = OFF
SELECT * FROM NotifyQueue