.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

Workflow Runtime and Long Running Processes

Posted By:      Posted Date: August 30, 2010    Points: 0   Category :Windows Application
I am trying to get a handle on the fact that applications have to manage the persistance of workflows directly. in 4.0.  If I set a workflow to run every night at 3:00 AM and then be persisted, how will I know that my application will be awake and ready to do the job.  I know that SharePoint currently uses a timer on the server which fires off every 5 minutes (default). 

View Complete Post

More Related Resource Links

ASP.NET Workflow: Web Apps That Support Long-Running Operations


Integrating workflow into ASP.NET applications means communicating with activities via a workflow queue and hosting the runtime in the global application class. We'll show you how.

Michael Kennedy

MSDN Magazine January 2009

Web Service Workflows: Deploy Distributed Business Processes With Windows Workflow And Web Services


Due to the distributed nature of a business process it makes sense for a workflow to be deployed as a distributed application. See how Windows Workflow and Web Services hold the key.

Israel Hilerio

MSDN Magazine October 2006

.NET Internals: Examine Running Processes Using Both Managed and Unmanaged Code


There are plenty of times when you need to get information on running processes, not the least of which is during performance tuning. Using the techniques in this article and special .NET classes you'll see how to get a process' ID, name, priority, number of threads, kernel handle, and memory consumption, as well as its user-mode, kernel-mode, and total elapsed running time and put them to use in a custom app called AssemblyBrowser.

Christophe Nasarre

MSDN Magazine October 2004

BizTalk 2004: Automate Your Business Processes with Human Workflow Services and Visual Studio


BizTalk Server is an excellent platform for automating B2B and EAI workflows. Process-driven workflows send messages between machines and access data. Until now, such processes were very difficult to automate, but with the introduction of Human Workflow Services in BizTalk Server 2004, this class of workflow automation is a very real possibility. This article explains it all.

Chris Whytock

MSDN Magazine October 2004

Workflow E-mails with Long Text Truncate the Text

The title is pretty self-explanatory.  I have a few fields that are generated from some Infopath Forms.  The text, however, truncates and doesn't display the entire text.

Anyone have any suggestions?

SharePoint 2010 Long Starting if start workflow programatically


In SharePoint 2010, I'm starting workflow #2 programatically from my workflow #1. See code below:

					SPList currentList = web.Lists[new Guid(ListId)];
					SPListItem currentListItem = currentList.GetItemById(ListItem);

					//resolve any lookup parameters
					string workflowId = base.ProcessStringField(WorkflowIdentifier);

					//find workflow association by name
					SPWorkflowAssociation workflowAssoc = currentList.WorkflowAssociations.GetAssociationByName(workflowId, Thread.CurrentThread.CurrentCulture);

					if (workflowAssoc != null)
						//start the workflow
						SPWorkflow workflow = site.WorkflowManager.StartWorkflow(currentListItem, workflowAssoc, workflowAssoc.AssociationData, SPWorkflowRunOptions.Synchronous);

And workflow #2  will hang with Starting status (1-10 minutes), Then the workflow #2 status would be modified  to Completed.

I couldn't find how to start the workflow # 2 immediately and complete immediately without several minutes delay

Serial approval workflow keeps running


I have a serial approval workflow created out of the box. The setting cancell this workflow when the document is rejected is selected. But if one of the approvers rejects it the workflow keeps running. After this is it will give acces denied errors for the other approvers.

So for example what is happening. The workflow is started and sends a email to persone 1. This persone approves so the workflow sends a email to persone 2. Persone 2 decided to reject the document. Now i want the workflow to be cancelled, but it keep running and sends a email to persone 3 for approval. If persone 3 opens the workflow he get's a acces denied error, i guess because of the reject.

Anyone has a idea what is happening here?

How to get information about Sharepoint Running Workflow in Visual Studio 2008

Can any one tell me about. How i can get information about sharepoint running workflow in visual studio 2008.

Video: Coding a Long-Running Operation Page in SharePoint Server 2007 or Windows SharePoint Services

Watch this visual how-to video as you learn to write code to mimic the default long-running operations page (the "spinning wheel") in SharePoint Server 2007 or Windows SharePoint Services 3.0. (Length: 7:56)

Coding a Long-Running Operation Page in SharePoint Server 2007 or Windows SharePoint Services 3.0 (V

Watch the video and explore code as you learn how to write code to mimic the default long-running operations page (the "spinning wheel") in SharePoint Server 2007 or Windows SharePoint Services 3.0.

How to keep my Workflow alive only during the time my client application is running ?

Hi, I want to my workflow do some action when server  lose connection with client and at the same time client get exceptions about it. It is possible to implement some session mechanism or something like that with workflow service ? Regards Marcin

System.InvalidOperationException: Instance operation is not valid on workflow runtime thread

Am getting the exception related in the title of this article when using the StateMachineWorkflowInstance object to arbitarily set state in my workflow code; and am unsure why.  The code follows below:   500     Protected Overrides Function Execute(ByVal executionContext As System.Workflow.ComponentModel.ActivityExecutionContext) As System.Workflow.ComponentModel.ActivityExecutionStatus   501    502    506         Dim smwi As StateMachineWorkflowInstance = New StateMachineWorkflowInstance(StaticWFRuntime.LocalRuntime, Me.WorkflowInstanceId)   511    512         'set workflow-wide database connection string   513         _connectionString = ConfigurationManager.ConnectionStrings("ConnectionString").ConnectionString   518    519         Utility.LogEnabled()   520    521         Utility.FoaeaLogger.WriteEntry("Processing TracingApplication.Execute()....", EventLogEntryType.Information)   522         If StaticWFRuntime.LocalRuntime Is Nothing OrElse StaticWFRuntime.LocalRuntime.IsStarted = False Then   523             Utility.FoaeaLogger.WriteEntry("No static RuntimeService object exists!", EventLogEntryType.Warning)   524         End If   525    526         Return MyBase.Execute(executionContext)   527    528     End Function   796     Private Sub gotoState2_ExecuteCode(ByVal sender As System.Object, ByVal e As System.EventArgs)   797    798        

Workflow Runtime

I was going to build one for myself, but has anyone developed a full-featured, production caliber WF 4.0 runtime for ASP.NET which includes persistence and dynamic control of instances?  I was hoping to just buy one to save time.

Long running WPF application - Garbage Collection

Hi All, I have a long running WPF application; users start the application and keep it open for at least 6 hours straight. I spend a couple days with a Memory Profiler, solving a couple of memory leaks. According to the Memory Profiler, all is good now. However, when I run the application, and monitor the Memory in the Windows Task Manager, it only seems to grow. When I create a button to force the garbage collection (GC.Collect()), a lot of memory is freed from the app. My questions: 1. I don't feel like it's a good idea to call GC.Collect() explicitly; is there any case where it is advised to do so? 2. Is it normal that it takes WPF that long to start garbage collecting automatically? Thanks, Koen

Error editing a document that is running a workflow

After workflow is started i try edit document, but this error is displayed: System.ArgumentNullException: Value cannot be null.  Parameter name: s     em System.IO.StringReader..ctor(String s)      em System.Xml.XmlDocument.LoadXml(String xml)      em Microsoft.SharePoint.Publishing.Internal.WorkflowUtilities.FlattenXmlToHashtable(String strXml)      em Microsoft.SharePoint.Publishing.Internal.WorkflowUtilities.DoesWorkflowCancelWhenItemEdited(String associationXml)      em Microsoft.SharePoint.Publishing.WebControls.ConsoleDataSource.EnsurePageNotInLockingWorkflowIfInEditMode()      em Microsoft.SharePoint.Publishing.WebControls.ConsoleDataSource.LoadDataSource()      em Microsoft.SharePoint.Publishing.WebControls.ConsoleDataSource.OnLoad(EventArgs e)      em Microsoft.SharePoint.Publishing.WebControls.XmlConsoleDataSource.OnLoad(EventArgs e)      em Microsoft.Share.Point.Publishing.WebControls.PublishingSiteActionsMenuCustomizer.OnLoad(EventArgs e)      em System.Web.UI.Control.LoadRecursive()      em System.Web.UI.Control.LoadRecursive()      em System.Web.UI.Control.L

help need for long running task

i have wcf service and method which runs very long running task and i have subscription service which let's out all the notifications. From asp.net web page i subscribe for the notifications and call the async method..notifications are being recived by the page (kept a debug and can see). On the web page i kept ajax timer, update panel with a label which refreshes every 10 sec. But asp.net seems to be waiting for async completed even to be fired and then update panels shows me all the notification (no use of notifications as the activity is over). I feel because both are in the same thread, that's why asp.net s behaving this way. Any help you guys can offer?

System.Workflow.Runtime.Hosting.PersistenceException Timeout expired.

Is there a way for me to set the CommandTimeout property on the SqlCommand. I can see that there is a DbResourceAllocator that has a NewCommand that creates the SqlCommand but there is now way that I can change the CommandTimeout property. My workflow is quite large and I am save the Tracking information as well with the SharedConnectionWorkflowCommitWorkBatchService. These are the service that I load: string connectionString = ConfigurationManager.ConnectionStrings["DBConnectionWorkflowTracking"].ConnectionString; SqlWorkflowPersistenceService persistenceService = new SqlWorkflowPersistenceService(connectionString); persistenceService.EnableRetries = true; wr.AddService(persistenceService); SqlTrackingService sqlTrackingService = new SqlTrackingService(connectionString); sqlTrackingService.PartitionOnCompletion = true; sqlTrackingService.EnableRetries = true; wr.AddService(sqlTrackingService); SharedConnectionWorkflowCommitWorkBatchService wb = new SharedConnectionWorkflowCommitWorkBatchService(connectionString); wb.EnableRetries = true; wr.AddService(wb); wr.AddService(new CallWorkflowService()); wr.AddService(new CallWorkflowWorkflowLoaderService()); Can anyone help? Thanks Gert   
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend