Commit Graph

49 Commits

Author SHA1 Message Date
Shannon
1067b1e245 BackgroundTaskRunner - refactor recurring tasks, improve shutdown
Conflicts:
	src/Umbraco.Web/PublishedCache/XmlPublishedCache/XmlCacheFilePersister.cs
	src/Umbraco.Web/Scheduling/LogScrubber.cs
	src/Umbraco.Web/Scheduling/Scheduler.cs
	src/Umbraco.Web/Umbraco.Web.csproj
2015-07-08 17:41:20 +02:00
Shannon
7987f13a11 U4-6788 - refactor OriginalRequestUrl into UmbracoApplicationUrl
and fixes merge issues.
2015-07-08 17:32:36 +02:00
Shannon
ccda1bdd73 Refactor scheduled tasks & publishing cancellation 2015-07-08 17:23:15 +02:00
Shannon
76a6f2d2d0 Updates scheduled tasks to be async with cancellation token 2015-07-08 17:23:00 +02:00
Shannon
69428b2281 Scheduled publishing is executing request async with cancellation token 2015-07-08 17:22:44 +02:00
Stephan
fa8fe8ec66 BackgroundTaskRunner - few fixes 2015-05-21 21:54:30 +02:00
Stephan
a76ba9a0a7 BackgroundTaskRunner - more fixes 2015-05-21 19:37:22 +02:00
Shannon
4c4117a052 Fixes BackgroundTaskRunner - moves the OnStopped call to where it should be. Un-ignores tests - these need to execute and cannot be ignored. They are not long running but if there are issues then they will timeout - DO NOT IGNORE. if the build server has issues with these then it's our logic that is at fault. 2015-05-21 13:05:58 +10:00
Stephan
521b8076d2 U4-6638 - bugfix BackgroundTaskRunner 2015-05-20 20:56:05 +02:00
Stephan
ac7ff31a67 U4-6626 - XmlCache, bugfix locks 2015-05-19 20:08:52 +02:00
Stephan
8121fc42e5 U4-6626 - fix log level 2015-05-17 21:47:31 +02:00
Shannon
c78b371965 updates the BackgroundTaskRunnerAwaiter so that it exits if the runner is not running when it is ctor'd, adds diags. 2015-04-09 17:59:34 +10:00
Shannon
cc804bd3bd removes duplicate test 2015-04-08 17:57:00 +10:00
Shannon
24dc8309f1 sets ConfigureAwait(false) for XmlCacheFilePersister await calls and BackgroundTaskRunner await calls since these are always on background threads, no synchronizing with any context. 2015-04-08 17:15:21 +10:00
Shannon
147cc92ac5 Updates BackgroundTaskRunner & tests: removes the need for most Thread.Sleep which is error prone, this is done by updating the GetAwaiter() method to be a custom awaiter so we can await the entire background task running operations. We then add a property called CurrentThraedingTask which then allows awaiting the current Task instance. Adds error handling to all event handlers for the task runner. Changes events to be TypedEventHandlers 2015-04-08 16:28:42 +10:00
Shannon
4bdac1475f fixes log scrub interval with ms with updated background tasks 2015-03-27 14:52:38 +11:00
Stephan
58ce04e26b cleanup 2015-03-27 14:49:31 +11:00
Shannon
4c3de920c6 Removes the 'else' so that 'wait' is always checked. 2015-03-27 14:49:31 +11:00
Stephan
be37026587 refactor latched background tasks, now use a task for xml
Conflicts:
	src/Umbraco.Web.UI/config/ClientDependency.config
2015-03-27 14:49:25 +11:00
Stephan
a73b7a5849 refactor Scheduler to use new BackgroundTaskRunner capabilities
Conflicts:
	src/Umbraco.Web/Scheduling/Scheduler.cs
2015-03-27 14:48:47 +11:00
Stephan
b7436dc55f refactor BackgroundTaskRunner 2015-03-27 14:47:42 +11:00
Shannon
bc068b201d Updates BackgroundTaskRunner to ensure canceled or skipped tasks are disposed, updated tests to reflect 2015-03-27 14:47:42 +11:00
Shannon
912b01c9aa Updates BackgroundTaskRunner to support more complex options including the ability to only execute the last/final task in the queue. Added tests to support, updated the 'content' object to use this option so that only the last task in the queue will execute so that file persisting doesn't get queued but the correctly queued data will be written. 2015-03-27 14:47:42 +11:00
Shannon
a82035061c Updates BackgroundTaskRunner to support async operations. Updates the content xml cache file persisting to use a IBackgroundTask instead of the strange queuing for persistence - which was super strange because in many cases another request thread will actually be the thread that is persisting the xml file than the request thread that requested it created. This implementation is far better, the xml file will be persisted on a non request thread and will handle multiple documents being published at the same time guaranteeing that the latest published version is the one persisted. The file persistence is also web aware (due to how BackgroundTaskRunner works) so during app shutdown the file will still be written if it's currently being processed. 2015-03-27 14:47:41 +11:00
Stephan
a44b19da18 U4-6320 - fix default scrubbing interval, set to 4hrs 2015-03-16 09:16:28 +01:00
Shannon
d2dbd91b17 Fixes merge issues 2014-12-08 17:19:48 +11:00
Shannon
0a7bbfb1ca Merge remote-tracking branch 'origin/6.2.5' into 7.2.1
Conflicts:
	src/Umbraco.Core/Configuration/UmbracoSettings.cs
	src/Umbraco.Core/Sync/ServerEnvironmentHelper.cs
	src/Umbraco.Tests/Scheduling/BackgroundTaskRunnerTests.cs
	src/Umbraco.Tests/Umbraco.Tests.csproj
	src/Umbraco.Web.UI/install/steps/defaultUser.ascx
	src/Umbraco.Web.UI/web.Template.Debug.config
	src/Umbraco.Web/Scheduling/BackgroundTaskRunner.cs
	src/Umbraco.Web/Scheduling/IBackgroundTask.cs
	src/Umbraco.Web/Scheduling/KeepAlive.cs
	src/Umbraco.Web/Scheduling/LogScrubber.cs
	src/Umbraco.Web/Scheduling/ScheduledPublishing.cs
	src/Umbraco.Web/Scheduling/ScheduledTasks.cs
	src/Umbraco.Web/Scheduling/Scheduler.cs
	src/Umbraco.Web/Scheduling/TaskEventArgs.cs
	src/Umbraco.Web/Umbraco.Web.csproj
2014-12-08 17:16:16 +11:00
Shannon
864994a56e updates error msgs when sending requests to the same server pointing to docs on baseUrl 2014-12-08 17:04:22 +11:00
Shannon
3405c5001b working on U4-5964, U4-5907, U4-5965 2014-12-08 15:18:32 +11:00
Sebastiaan Janssen
4eb9a54fa5 Ports v7 changes for U4-5728 - OriginalRequestUrl not initialized, KeepAlive or ScheduledPublishing run too soon
#U4-5728
2014-12-07 16:16:29 +01:00
Shannon
6df6e3bdad Fixes: U4-3737 macro container make sure you can define the allowed macros + the max number 2014-11-13 17:44:03 +11:00
Shannon
9019c49ee8 Merge branch '7.1.9' into 7.2.0
Conflicts:
	build/NuSpecs/UmbracoCms.Core.nuspec
	build/UmbracoVersion.txt
	src/Umbraco.Core/Configuration/UmbracoVersion.cs
	src/Umbraco.Core/Sync/ServerEnvironmentHelper.cs
	src/Umbraco.Tests/Plugins/PluginManagerTests.cs
	src/Umbraco.Web.UI/Umbraco.Web.UI.csproj
	src/Umbraco.Web/Scheduling/KeepAlive.cs
	src/Umbraco.Web/Scheduling/ScheduledPublishing.cs
	src/Umbraco.Web/Trees/ApplicationTreeRegistrar.cs
	src/UmbracoExamine/BaseUmbracoIndexer.cs
	src/UmbracoExamine/DataServices/UmbracoContentService.cs
	src/UmbracoExamine/DataServices/UmbracoMediaService.cs
	src/UmbracoExamine/UmbracoContentIndexer.cs
	src/UmbracoExamine/UmbracoMemberIndexer.cs
2014-11-13 16:32:50 +11:00
Shannon
4ec37b9d3a Fixes: U4-5391 Create config to explicitly set the 'base url' for a website that is not running as a load balanced site - used for scheduled tasks/publishing/keepalive 2014-11-13 13:05:27 +11:00
Shannon
b1d4a99510 U4-5728 - Do not run KeepAlive, ScheduledPublishing, without an url
Updates the scheduler and the scheduled tasks to use a background task runner (ported from new courier codebase with tests) so that they are web aware and wind down properly.
2014-11-12 16:00:17 +11:00
Stephan
0f4436a465 U4-5728 - Do not run KeepAlive, ScheduledPublishing, without an url 2014-11-03 20:20:10 +01:00
Shannon
38c4bc72cd Merge remote-tracking branch 'origin/6.2.1' into 7.1.5 2014-06-25 12:03:53 +10:00
Shannon
7cf7ac687c last issue with state/keep alive timer 2014-06-25 12:03:31 +10:00
Shannon
6b626baffb Merge remote-tracking branch 'origin/6.2.1' into 7.1.5 2014-06-25 11:56:56 +10:00
Shannon
7ce0272169 updates state param with timers to use singleton 2014-06-25 11:56:36 +10:00
Shannon
acb934e3f1 ensures timer's are not GCd 2014-06-25 11:52:48 +10:00
Shannon
6485e625b1 Merge remote-tracking branch 'origin/6.2.1' into 7.1.5 2014-06-25 11:37:21 +10:00
Shannon
3aa486a463 another log 2014-06-25 11:36:58 +10:00
Shannon
5aa0621c90 adds some notes 2014-06-25 11:36:14 +10:00
Shannon
625b8f7e65 Ensures the 'Index' portion of the path is used for scheduled publishing 2014-06-25 11:26:08 +10:00
Shannon
72b7b443e9 Merge remote-tracking branch 'origin/6.2.1' into 7.1.5 2014-06-25 11:02:04 +10:00
Shannon
5011eee037 fixes merge issue 2014-06-25 11:00:53 +10:00
Shannon
e27163f3a7 adds logging to scheduled bits 2014-06-25 11:00:11 +10:00
Shannon
65ea6f94d3 adds authorization to the scheduled publishing , this new attribute can be used to secure scheduled tasks as well. 2014-06-23 15:02:23 +10:00
Shannon
e8f7f77bb6 Fixes: U4-581 Automatic publishing not working in load balanced setup - added some more convention and configuration to distributed calls so that servers are aware of the master and how to call into themselves for scheduled tasks, ping and scheduled publishing. Will need to update the docs on LB regarding this too. Cleaned up the code that does the scheduling and separates it into proper segments. Obsoletes the old presentation classes that were doing it. 2014-06-20 14:34:21 +10:00