Sql errors

Vote:
 

Hi,

I need help.

Sometimes we have these errors on prod machine.
But we can not reproduce on other environments.

System.NullReferenceException: Object reference not set to an instance of an object.
   at Mediachase.BusinessFoundation.Data.Sql.SqlHelper.PrepareCommand(SqlCommand command, SqlConnection connection, SqlTransaction transaction, CommandType commandType, String commandText, SqlParameter[] commandParameters)
   at Mediachase.BusinessFoundation.Data.Sql.SqlHelper.ExecuteReader(SqlConnection connection, SqlTransaction transaction, CommandType commandType, String commandText, SqlParameter[] commandParameters, SqlConnectionOwnership connectionOwnership)
   at Mediachase.BusinessFoundation.Data.Sql.SqlHelper.ExecuteReader(SqlContext context, CommandType commandType, String commandText, SqlParameter[] commandParameters)
   at Mediachase.BusinessFoundation.Data.Meta.Management.SqlSerialization.SqlSerializer.GetVersionId()
   at Mediachase.BusinessFoundation.Data.Meta.Management.SqlSerialization.SqlSerializer.Deserialize()
   at Mediachase.BusinessFoundation.Data.DataContext.get_MetaModel()
   at Project.Commerce.Business.ProductAvailability.Foundation.AutoInstallMetaDataPlugin.Execute(BusinessContext context)
   at Mediachase.BusinessFoundation.Data.Business.BusinessManager.ExecutePlugins(EventPipeLineStage eventPipeLineStage)
   at Mediachase.BusinessFoundation.Data.Business.BusinessManager.Execute(Request request)
   at Project.Commerce.Business.BusinessFoundation.EntityContext`1.InnerListDBRetrieve(FilterElement[] filters, SortingElement[] sortings)
InnerListDBRetrieve -> BusinessManager.List(metaClassName, filters, sortings)
...

System.InvalidOperationException: There is already an open DataReader associated with this Command which must be closed first.
   at System.Data.SqlClient.SqlInternalConnectionTds.ValidateConnectionForExecute(SqlCommand command)
   at System.Data.SqlClient.SqlInternalTransaction.Commit()
   at System.Data.SqlClient.SqlTransaction.Commit()
   at Mediachase.BusinessFoundation.Data.Sql.SqlContext.InnerCommit()
   at Mediachase.BusinessFoundation.Data.Sql.SqlTransactionScope.Commit()
   at Project.Commerce.Business.BusinessFoundation.EntityContext`1.Save(T entity, Boolean cacheData, Boolean refreshCache)

   Save -> var tran = DataContext.Current.BeginTransaction(), BusinessManager.Create\Update(entity), tran.Commit().

...

System.Data.SqlClient.SqlException (0x80131904): Timeout expired.  The timeout period elapsed prior to completion of the operation or the server is not responding. ---> System.ComponentModel.Win32Exception (0x80004005): The wait operation timed out
   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.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
   at System.Data.SqlClient.TdsParser.TdsExecuteTransactionManagerRequest(Byte[] buffer, TransactionManagerRequestType request, String transactionName, TransactionManagerIsolationLevel isoLevel, Int32 timeout, SqlInternalTransaction transaction, TdsParserStateObject stateObj, Boolean isDelegateControlRequest)
   at System.Data.SqlClient.SqlInternalConnectionTds.ExecuteTransactionYukon(TransactionRequest transactionRequest, String transactionName, IsolationLevel iso, SqlInternalTransaction internalTransaction, Boolean isDelegateControlRequest)
   at System.Data.SqlClient.SqlInternalConnection.BeginSqlTransaction(IsolationLevel iso, String transactionName, Boolean shouldReconnect)
   at System.Data.SqlClient.SqlConnection.BeginTransaction(IsolationLevel iso, String transactionName)
   at Mediachase.BusinessFoundation.Data.Sql.SqlContext.BeginTransaction()
   at Mediachase.BusinessFoundation.Data.DataContext.BeginTransaction()
   at Mediachase.BusinessFoundation.Data.Business.BusinessManager.Execute(Request request)
   at Project.Commerce.Business.BusinessFoundation.EntityContext`1.InnerListDBRetrieve(FilterElement[] filters, SortingElement[] sortings)
InnerListDBRetrieve -> BusinessManager.List(metaClassName, filters, sortings)


May be we do wrong something? Can somebody help?

Version:
EPiServer.Commerce.Core.8.9.0

#133167
Aug 27, 2015 7:52
Vote:
 

Can somebody help?

Best Regards

#133510
Sep 08, 2015 10:35
Vote:
 

Try posting your question on the commerce forum instead, you will get a response much quicker.

#133629
Sep 08, 2015 11:02
Vote:
 

Hi,

I suspect this might be related to a recent fixed bug: 

http://world.episerver.com/support/Bug-list/bug/128798

I would suggest you to upgrade to 8.16.1 to see if it fixes the issue for you.

Regards,

/Q

#133638
Sep 08, 2015 11:09
Vote:
 

Hi,

Thank you for replays.

We will update our version and then we will check this issue.

Best Regards.

#135886
Sep 16, 2015 16:05
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.