Microsoft Dynamics CRM 2011 E-mail Router SchedulingPeriod in milliseconds? - dynamics-crm

I am attempting to speed up sent e-mail in CRM 2011 by editing the Microsoft.Crm.Tools.EmailAgent.xml file. I am modifying the SchedulingPeriod element and I am not sure if the interval setting is in seconds or milliseconds.
The CRM 4.0 documentation from Microsoft states “all time intervals in the configuration file are specified in milliseconds.” http://msdn.microsoft.com/en-us/library/cc906241.aspx
The Microsoft Dynamics CRM 2011 Unleashed Book states “The outgoing e-mails are processed asynchronously, and the default polling is scheduled for every 1,000 seconds (about 15 minutes), so you must wait that time before the e-mails are actually sent.”
Tip: To increase the speed at which outgoing e-mails are sent, you can edit the configuration file Microsoft.Crm.Tools.EmailAgent.xml (which is usually located at C:\Program Files\Microsoft CRM Email\Service) and find the SchedulingPeriod element. We recommend changing its default value to 10 seconds.
Question 1: In CRM 2011, is the SchedulingPeriod specified in milliseconds or seconds?
Question 2: In CRM 2011, is the default SchedulingPeriod (1,000) = 1 second or 15 minutes?
The Microsoft Dynamics CRM 2011 Unleashed book mentions speeding up outgoing e-mails by changing the default value to 10 seconds.
Question 3: In CRM 2011, will changing the SchedulingPeriod to (10) = 10 seconds or 10 milliseconds?

it is in seconds, 1000 seconds == 16 minutes 35 seconds, there should also be a setting for number of threads just above this in the file that you can increase to improve performance.
Like everything CRM though test it first as your setup might behave differently to mine, speeding this up might just move your bottleneck elsewhere - usually the UI if you havent put it on another server. also concider if you are using Virtual Servers and they are on the same physical hardware making one work more can slow the others if they aren't balenced correctly.

Related

Dynamics 365 on premise First request creation takes longer time

I've been two days struggling to know the reason but with no luck
I have dynamics 365 on premise and we have some customizations on case form and workflows and plugins on create
When I open new fresh session the request creation took almost 8 seconds , however after save first request and try to submit a new request again it took almost 2 seconds
I need to understand what's the caching behavior on server side that make first request took all this time compared to the upcoming requests coz this is misleading to decide performance is good or not
Thank you,

Case SLA timer not matching Default SLA Settings

I have SLA Failure defined as 2 Days in the Service Management in my Dynamics Customer Service Sandbox, however each time I create a case, the case timer starts as 7 days.
Is this a bug in Dynamics 365 or do we need to change some settings for it?
Make sure to validate all these:
Setup the Business hours (Work days/Work hours), and holidays. This will drive the behavior you are seeing. Read more
Setup the SLA/items, if you have multiple SLA - verify it is activated and set as default. Read more
And multiple SLA items can be reordered and verify the SLA associated to your case record using this technique
Verify the timer settings

Outlook 365 Cached Mode - Need Clarification

I have a query regarding outlook 365 cached mode. Say for example a new user has a outlook mails on server for three months say JAN, FEB and MAR. Let's say we are in 1st of April, iam configuring outlook365 cached mode to 1 month. So March mails will be available offline. Let's say one month is passed, now we are in MAY. Now what happens to MAR month mail which is already downloaded offline, since cache is set to one month. Will MARCH and APRIL mails will be available offline, or only APRIL mails will be available and march gets removed locally?
By default, if Cached Exchange Mode is enabled, Outlook caches email messages only from the last N months (in your case - 1-month-old) and removes anything older from the local cache for the PC. These default settings depend on the device, with mobile devices having smaller default settings. The email messages that are removed from the local cache are still available for users to view, but they’ll need to be connected to Exchange Server to view them. Users can view messages that were removed from the local cache by scrolling to the end of a message list in a folder and clicking the message Click here to view more on Microsoft Exchange. Users can also change how much email to keep offline. The administrator can change the default age or enforce the age of email messages that are removed from the local cache.

What is the default schedule for the default CRM 2011 maintenance jobs?

I have a CRM 2011 installation that experiences a huge spike in I/O at a certain time of day (11 am).
I have a good suspicion that it's the default Rebuild Index Job.
Everything is at default values, and the latest applied update is RU13.
Sql is sql 2008 r2, sp1.
I've found this MSDN blog and also other sources suggesting updating the default job's schedule to run at night, or not at all.
But I haven't been able to find what is the default schedule for these default CRM jobs. I understand they are executing daily, but when?
at 1am, 1pm, 1h after service start?
Also, is there a way to view execution history?
Dynamics CRM 2011 Asynchronous Service regularly executes multiple internal maintenance jobs for each organization (database) and that these are scheduled initially at the time of organization creation on default frequencies (daily, monthly, etc.). Hopefully, you're also aware of the need to reschedule these jobs to execute during non-peak usage hours so as to minimize impact on system performance
You can find more details in this MSDN blog
The interesting comment there from Austin give you some insight.
MSCRM_CONFIG.[dbo].ScalegroupOrganizationMaintenanceJobs table keeps track of LastResultCode and LastRunTime
Useful query:
select
LastRunTime,
CASE OperationType
WHEN 14 THEN 'DeletionService'
WHEN 15 THEN 'IndexManagement'
WHEN 30 THEN 'ReindexAll'
WHEN 32 THEN 'CleanupInactiveWorkflowAssemblies'
WHEN 40 THEN 'GoalRollup'
END OperationType, OperationType,
enabled, ExecutionTime,LastResultCode,LastResultData
,MaintenanceWindowEndTime,MaintenanceWindowStartTime, ModifiedOn
,NextRunTime,RecurrencePattern, RecurrenceStartTime, StartedOn, State, IsDeleted
from ScaleGroupOrganizationMaintenanceJobs
order by LastRunTime desc
I remember finding the answer to this a long time ago, but I can't find the link now. The jobs' default schedule depends on when in the day you originally installed Dynamics. IIRC, the jobs are scheduled to start 24 hours after installation. This is kind of a silly default since most would install it in the middle of the workday, but that's why they recommend that you change it to be more appropriate for your business schedule.

How can I optimize MVC and IIS pipeline to obtain higher speed?

I am doing performance tweaking of a simple app that uses MVC on IIS 7.5.
I have a StopWatch starting up in Application_BeginRequest and I take a snapshot at Controller.OnActionExecuting.
So I measure the time spend in the entire IIS pipeline: from request receipt to the moment execution finally gets to my controller.
I obtain 700 microseconds on my 3GHz quad-core (project compiled Release x64), and I wonder where the bottleneck is, especially hearing some people say that one can get up to 8000 page loads per second with MVC.
How can I optimize MVC and IIS pipeline to obtain higher speed?
The tool "IIS Tuner" may be helpful. It is an open source tool and you may investigate the tricks that application made. the tool is available at codeplex
I obtain 700 microseconds on my 3GHz quad-core (project compiled Release x64), and I wonder where the bottleneck is, especially hearing some people say that one can get up to 8000 page loads per second with MVC.
Note that a result of 700 µs in the pipeline is not incompatible with getting throughput of 8,000 requests per second. (You may be confusing response time with throughput.) If 8,000 people simultaneously made requests and each one was fulfilled less than one second later, that would be 8,000 requests per second regardless of whether the response time was 1 µs, 700 µs, or 700 ms.
Is 700 microseconds too long for IIS+MVC pipeline to run on every page load?
Not necessarily. You'd have to evaluate whether or not you're actually getting saturated with requests.
The tool "IIS Tuner" may be helpful.
And makes WCAT not works. Any views?
more details as below,
D:\Program Files\IIS Resources\WCAT Client>wcclient.exe localhost
wcclient.exe 5.2.3652 - Web Capacity Analysis Toolkit Client.
Copyright (c) 1995-2002 Microsoft Corporation. All rights reserved.
Compiled May 29 2003, 16:28:20
Connecting main client thread...
Connected.
Waiting for Config Message: Connecting Dead controller thread...
Done.
IP version requested for testing is unspecified
Receiving script header message: Done.
Receiving string table: Receiving 1 script pages ...
Fail to resolve server address for IP supported by the client: localhost
Connecting client abort notification...
Failed to resolve server address(es).
Have you looked into:
- async controllers? ASP.NET processes are limited to 12 threads (or 12 threads per CPU) not sure which.
- there are a bunch of micro-optmization tricks (for example, MVC loads all the view engines...when you only need Razor remove the others)
So, there are definitely ways to improve performance and you have full control over the HTML in MVC as well (no viewstate, obstrusive markup, unecessary postbacks etc)

Resources