andrew.beals@nintex.com

When publishing a workflow you receive the error "soap:ServerServer was unable to process request."

Blog Post created by andrew.beals@nintex.com Support on Mar 19, 2015

You receive one of the following errors upon publishing a workflow/form after anupgrade/install of Nintex

 

 

You also find the following entries in the ULS logs:

Failed to handle workflow upload starting event. Error: Object reference not set to an instance of an object.. Stack trace:    at Nintex.Forms.SharePoint.MobileAppForms.NfMobileFormsRepository.MarkFormAsDeletedIfExists(Guid workflowId)     at Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting.ProcessStartForm(WorkflowUploadStartingEventReceiverContext eventArgs, Boolean& expectedException)     at Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting.Execute(WorkflowUploadStartingEventReceiverContext eventArgs

Failed to raise event to receiver or the receiver threw an exception. Type: WorkflowUploadStarting. Receiver assembly: Nintex.Forms.SharePoint, Version=1.0.0.0, Culture=neutral, PublicKeyToken=c52d764dcf7ec883. Receiver class: Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting: System.NullReferenceException: Object reference not set to an instance of an object. at Nintex.Forms.SharePoint.MobileAppForms.NfMobileFormsRepository.MarkFormAsDeletedIfExists(Guid workflowId) at Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting.ProcessStartForm(WorkflowUploadStartingEventReceiverContext eventArgs, Boolean& expectedException) at Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting.Execute(WorkflowUploadStartingEventReceiverContext eventArgs) at Nintex.Workflow.Events.EventReceiverCollection.FireEvents(EventType type, SPWeb web, ReceiverContext eventArgs)

Error saving from workflow export file.: System.Exception: Object reference not set to an instance of an object.      at Nintex.Workflow.Publishing.Publish.AR8=(XomlWorkflow Ah8=, SPList Ax8=, WorkflowRepository BB8=, Boolean BR8=, String& Bh8=)     at Nintex.Workflow.Publishing.Publish.xB4=(XomlWorkflow 1B4=, Boolean 1R4=, Boolean 1h4=, PublishOperationTrackingCollection 1x4=, Boolean 2B4=, WorkflowRepository 2R4=, Boolean 2h4=, Boolean 2x4=)     at Nintex.Workflow.Publishing.Publish.PublishAWorkflow(String wfName, NWActionConfigurations configs, Guid listId, SPWeb web, ImportContext importCtx, Boolean validate, SPContentTypeId contentTypeId, String changeNotes, String& publishWorkflowString)     at Nintex.Workflow.Publishing.Publish.PublishAWorkflow(String wfName, NWActionConfigurations configs, Guid listId, SPWeb web, ImportContext importCtx, Boolean validate, SPContentTypeId contentTypeId, String changeNotes)     at NintexWorkflowWS.PublishWorkflow(String wfName, String activityConfigs, Guid listId, String contentTypeId, String changeNotes)

Resolution

These errors are indicative of either a missing Nintex Forms database or your forms database is not update to date. Nintex Workflow is trying to access a stored procedure in the Nintex Forms database during publish validation which can cause the publishing of your workflow to fail if these stored procedures are not present or up to date.

 

The call "Nintex.Forms.SharePoint.MobileAppForms.NfMobileFormsRepository.MarkFormAsDeletedIfExists(Guid workflowId)" is key to this error. This method makes a call to the Nintex Forms database for the stored procedure "MarkFormasDeletedIfExists".

 

Creating the forms database under Nintex Forms Management > Manage Database will resolve this issue if you do not already have one. If your forms database has already been created and you have verified it is indeed connected you may simply need to upgrade the database. You can do this by running the following command: Upgrade-NFservice

 

---Warning---

The the following error "Object reference not set to an instance of an object." is a very common and ambiguous error in .NET and can be found in many other errors in SharePoint. Be certain to confirm the error you are seeing is similar to the ULS log stack trace errors I have provided.

 

- - UPDATE - -

With recent updates to the product you may see the below errors / log messages instead of the above errors. However the resolution remains the same:

 

 

 

Failed to Publish Nintex Form. Error: Procedure or function NLF_GetOnlineFormByItem has too many arguments specified.. Stack trace:
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
at System.Data.SqlClient.SqlDataReader.get_MetaData()
at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior)
at Nintex.Forms.SharePoint.LiveForms.Data.Access.SqlSession.ExecuteReader(SqlCommand command, CommandBehavior behavior, Boolean retryForDeadLock)
at Nintex.Forms.SharePoint.LiveForms.Data.OnlineFormRepository.GetForms(SqlCommand command)
at Nintex.Forms.SharePoint.LiveForms.Data.OnlineFormRepository.GetFromItem(Guid siteId, Nullable`1 listId, String contentTypeId, Nullable`1 workflowBaseId, Nullable`1 taskListId, Nullable`1 taskItemId, String taskTemplate, Nullable`1 taskReference, OnlineFormType type, String workflowVersion)
at Nintex.Forms.SharePoint.LiveForms.LiveFormsMaintenence.RemoveListFormIfExists(SPSite site, Guid listId, String contentTypeId)
at Nintex.Forms.SharePoint.Services.NfWcfService.PublishForm(String contentTypeId, String listId, Form form)

 

 

Failed to raise event to receiver or the receiver threw an exception. Type: WorkflowUploadStarting. Receiver assembly: Nintex.Forms.SharePoint, Version=1.0.0.0, Culture=neutral, PublicKeyToken=c52d764dcf7ec883. Receiver class: Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting: System.Data.SqlClient.SqlException (0x80131904): Procedure or function NLF_GetOnlineFormByItem has too many arguments specified.
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
at System.Data.SqlClient.SqlDataReader.get_MetaData()
at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior)
at Nintex.Forms.SharePoint.LiveForms.Data.Access.SqlSession.ExecuteReader(SqlCommand command, CommandBehavior behavior, Boolean retryForDeadLock)
at Nintex.Forms.SharePoint.LiveForms.Data.OnlineFormRepository.GetForms(SqlCommand command)
at Nintex.Forms.SharePoint.LiveForms.Data.OnlineFormRepository.GetFromItem(Guid siteId, Nullable`1 listId, String contentTypeId, Nullable`1 workflowBaseId, Nullable`1 taskListId, Nullable`1 taskItemId, String taskTemplate, Nullable`1 taskReference, OnlineFormType type, String workflowVersion)
at Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting.ProcessStartForm(WorkflowUploadStartingEventReceiverContext eventArgs, Boolean& expectedException)
at Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting.Execute(WorkflowUploadStartingEventReceiverContext eventArgs)
at Nintex.Workflow.Events.EventReceiverCollection.FireEvents(EventType type, SPWeb web, ReceiverContext eventArgs) ClientConnectionId:8b6d1ffc-abcb-4c69-8529-10a6a6e88122 Error Number:8144,State:2,Class:16 (Build:3160)

Failed to handle workflow upload starting event. Error: Procedure or function NLF_GetOnlineFormByItem has too many arguments specified.. Stack trace:
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
at System.Data.SqlClient.SqlDataReader.get_MetaData()
at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior)
at Nintex.Forms.SharePoint.LiveForms.Data.Access.SqlSession.ExecuteReader(SqlCommand command, CommandBehavior behavior, Boolean retryForDeadLock)
at Nintex.Forms.SharePoint.LiveForms.Data.OnlineFormRepository.GetForms(SqlCommand command)
at Nintex.Forms.SharePoint.LiveForms.Data.OnlineFormRepository.GetFromItem(Guid siteId, Nullable`1 listId, String contentTypeId, Nullable`1 workflowBaseId, Nullable`1 taskListId, Nullable`1 taskItemId, String taskTemplate, Nullable`1 taskReference, OnlineFormType type, String workflowVersion)
at Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting.ProcessStartForm(WorkflowUploadStartingEventReceiverContext eventArgs, Boolean& expectedException)
at Nintex.Forms.SharePoint.EventHandlers.OnWorkflowUploadStarting.Execute(WorkflowUploadStartingEventReceiverContext eventArgs)

Error saving from workflow export file.: System.Exception: Procedure or function NLF_GetOnlineFormByItem has too many arguments specified.
at Nintex.Workflow.Publishing.Publish.3SA=(XomlWorkflow 3iA=, SPList 3yA=, WorkflowRepository 4CA=, Boolean 4SA=, String& 4iA=)
at Nintex.Workflow.Publishing.Publish.pCA=(XomlWorkflow tCA=, Boolean tSA=, Boolean tiA=, PublishOperationTrackingCollection tyA=, Boolean uCA=, WorkflowRepository uSA=, Boolean uiA=, Boolean uyA=)
at Nintex.Workflow.Publishing.Publish.PublishAWorkflow(String wfName, NWActionConfigurations configs, Guid listId, SPWeb web, ImportContext importCtx, Boolean validate, SPContentTypeId contentTypeId, String changeNotes, String& publishWorkflowString)
at NintexWorkflowWS.PublishWorkflow(String wfName, String activityConfigs, Guid listId, String contentTypeId, String changeNotes) (Build:3160)

 

Cheers,

Andrew Beals

Outcomes