I am running NS on a single desktop machine, which hosts NS, SQL Server and
IIS for testing (I know this is not nice deployment environment).
I created 10000 users who are subscribed to an event. I used
HTTPDeliveryProtocol for the notifications created.
The quantum time is 30 secs both for NS and delivery. I have increased the
NotificationThrottle to 11000.
The DigestDelivery and MulticastDelivery are both false. (this is what I
want to test, each Notification is to be handled one by one)
I set the retry schedeule to 30 Secs (which only worked once for failed
events).
I fired the event, everything worked fine and I had 10000 Notification
deliveries to handle...
So NS Started making web requests (on the same development machine).
As result I've had about 200 succesfull deliveries, 800 failed deliveries
(on the second retry, I've 200 more successfull deliveries so I was left
with 600 failed deliveries) and 9000 undelivered notifications (where their
delivery status is 0, - the successful ones are 6 and failed ones are 4, I
believe).
The IIS couldn't handle more... Later NS didn't even tried to handle the
left 9000 deliveries. (Note the numbers are not exact, they are rounded to
100 or to 1000)
Retrying failed delivereies is not a good solution. By assuming the IIS can
handle 100 requests per second, how can I send notifications in group of 100
in every (for example)3 seconds.
For more information, the ICF and ADF files are below:
Regards,
Mert Sakarya
ICF File:
<?xml version="1.0" encoding="utf-8"?>
<NotificationServicesInstance xmlns:xsd="
http://www.w3.org/2001/XMLSchema" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance" xmlns="
http://www.microsoft.com/MicrosoftNotificationServices/ConfigurationFileSchema"> <InstanceName>Content</InstanceName>
<SqlServerSystem>%_SQLServer_%</SqlServerSystem>
<Applications>
<Application>
<ApplicationName>Alerts</ApplicationName>
<BaseDirectoryPath>C:\SQL-NS\Content\Application</BaseDirectoryPath>
<ApplicationDefinitionFilePath>ApplicationDefinition.xml</ApplicationDefinitionFilePath>
<Parameters>
<Parameter>
<Name>_NSServer_</Name>
<Value>%_NSServer_%</Value>
</Parameter>
<Parameter>
<Name>_ApplicationBaseDirectoryPath_</Name>
<Value>C:\SQL-NS\Content\Application</Value>
</Parameter>
</Parameters>
</Application>
</Applications>
<Protocols>
<Protocol>
<ProtocolName>SMS</ProtocolName>
<ClassName>HttpExtension</ClassName>
</Protocol>
</Protocols>
<DeliveryChannels>
<DeliveryChannel>
<DeliveryChannelName>SMSChannel</DeliveryChannelName>
<ProtocolName>SMS</ProtocolName>
<Arguments>
<Argument>
<Name>ProtocolProviderClassName</Name>
<Value>HTTPDeliveryProtocol.HTTPDeliveryProtocol</Value>
</Argument>
<Argument>
<Name>ProtocolProviderAssemblyName</Name>
<Value>C:\SQL-NS\Content\DeliveryProtocol\HttpDeliveryProtocol.dll</Value>
</Argument>
<Argument>
<Name>PostURL</Name>
<!--
<Value>http://localhost/webapplication2/data.aspx</Value> -->
<Value>
https://kisamesaj.e-kolay.net/sendsms.aspx</Value>
</Argument>
</Arguments>
</DeliveryChannel>
<DeliveryChannel>
<DeliveryChannelName>FileChannel</DeliveryChannelName>
<ProtocolName>File</ProtocolName>
<Arguments>
<Argument>
<Name>FileName</Name>
<Value>C:\SQL-NS\Content\Output\Notifications\FileNotifications.txt</Value>
</Argument>
</Arguments>
</DeliveryChannel>
<DeliveryChannel>
<DeliveryChannelName>SMTPChannel</DeliveryChannelName>
<ProtocolName>SMTP</ProtocolName>
<Arguments>
<Argument><Name>SmtpServer</Name><Value></Value></Argument>
<Argument><Name>BodyEncoding</Name><Value>utf-8</Value></Argument>
</Arguments>
</DeliveryChannel>
</DeliveryChannels>
</NotificationServicesInstance>
ADF File
<?xml version="1.0" encoding="utf-8" ?>
<Application xmlns:xsd="
http://www.w3.org/2001/XMLSchema" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance" xmlns="
http://www.microsoft.com/MicrosoftNotificationServices/ApplicationDefinitionFileSchema"> <Version>
<Major>1</Major>
<Minor>1</Minor>
<Build>1</Build>
<Revision>0</Revision>
</Version>
<EventClasses>
<EventClass>
<EventClassName>CategoryEvent</EventClassName>
<Schema>
<Field>
<FieldName>CategoryId</FieldName>
<FieldType>INT</FieldType>
<FieldTypeMods>NOT NULL</FieldTypeMods>
</Field>
</Schema>
</EventClass>
</EventClasses>
<SubscriptionClasses>
<SubscriptionClass>
<SubscriptionClassName>UpdatedContent</SubscriptionClassName>
<Schema>
<Field>
<FieldName>CategoryId</FieldName>
<FieldType>INT</FieldType>
<FieldTypeMods>NOT NULL</FieldTypeMods>
</Field>
</Schema>
<EventRules>
<EventRule>
<RuleName>MatchNewNewsByCategory</RuleName>
<Action>
SELECT dbo.NewContentNotify(
subscriptions.SubscriberId,
N'DefaultDevice',
N'en-US',
content.CategoryName,
content.Description)
FROM CategoryEvent events
JOIN NotificationData..CategoryData content
ON events.CategoryId = content.CategoryId
JOIN UpdatedContent subscriptions ON
subscriptions.CategoryId = content.CategoryId
</Action>
<EventClassName>CategoryEvent</EventClassName>
</EventRule>
</EventRules>
</SubscriptionClass>
<SubscriptionClass>
<SubscriptionClassName>ScheduledContent</SubscriptionClassName>
<Schema>
<Field>
<FieldName>CategoryId</FieldName>
<FieldType>INT</FieldType>
<FieldTypeMods>NOT NULL</FieldTypeMods>
</Field>
</Schema>
<ScheduledRules>
<ScheduledRule>
<RuleName>MatchScheduledContent</RuleName>
<Action>
INSERT INTO
ScheduledContentProcessingTimes(SubscriberId, LastProcessingTime)
SELECT subscription.SubscriberId,
subscription.Created
FROM ScheduledContent subscription
WHERE NOT EXISTS (