SQL timeout in publishing all applications

SQL timeout in publishing all applications

  

For my internship software engineering I'm following the tutorial for web developer and encountered a problem.

Before the weekend I published my movie database application without any problems. However, today (after minor modifications) the applications keeps giving a SQL timeout, even though I havent changed anything in the database. It appears the timeout is not application based (when making a fresh, simple database it was giving me the same timeout error. Also importing the quickstart application from the tutorial was giving me an error that it couldn't create the SkipCompilation.sql). The error log is posted below. Any help or input would be greatly appreciated, since i cannot publish (and thus test) any application at this moment.



Internal Error




Invalid compiler output.


Timeout expired.  The timeout period elapsed prior to completion of the operation or the server is not responding.




Exception Details:


[1] 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.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, Boolean describeParameterEncryptionRequest)


   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 OutSystems.HubEdition.DatabaseProvider.SqlServer.ExecutionService.ExecutionService.ExecuteReader(IDbCommand cmd)


   at OutSystems.HubEdition.DatabaseProvider.SqlServer.IntrospectionService.IntrospectionService.GetPrimaryKeyColumns(TableSourceInfo tableSource)


   at OutSystems.HubEdition.DatabaseProvider.SqlServer.Platform.IntrospectionService.PlatformIntrospectionService.<GetColumns>d__70.MoveNext()


   at System.Linq.Enumerable.Single[TSource](IEnumerable`1 source, Func`2 predicate)


   at OutSystems.HubEdition.DatabaseProvider.SqlServer.Platform.IntrospectionService.PlatformIntrospectionService.GetIndexes(TableSourceInfo tableSource, IEnumerable`1 columns)


   at OutSystems.HubEdition.DatabaseProvider.SqlServer.Platform.IntrospectionService.PlatformIntrospectionService.GetTableInfo(ITableSourceInfo tableSource)


   at OutSystems.HubEdition.DatabaseProvider.SqlServer.Platform.IntrospectionService.PlatformIntrospectionService.GetTableSourcesDetails(ITableSourceInfo[] tables)


   at OutSystems.HubEdition.Compiler.Context.CompilationContext.get_TableSourcesDetails()


   at OutSystems.HubEdition.Compiler.Database.EntitySchema.EntitySchemaUpdater.DumpEspaceEntities(Boolean forceFullIntrospection)


   at OutSystems.HubEdition.Compiler.Database.EntitySchema.EntitySchemaUpdater.Dump(CompilationContext compilationContext)


   at OutSystems.HubEdition.Compiler.ESpace.UpdateDatabaseScript()


   at OutSystems.HubEdition.Compiler.ESpace.UpdateDatabaseScriptThread()


ClientConnectionId:8d175c49-8033-40ff-8beb-dcb0f86ae817


Error Number:-2,State:0,Class:11[2] System.ComponentModel.Win32Exception (0x80004005): The wait operation timed out


hi Annemieke Staal,

have you tried to connect your sql DB without using outsystem or have tested any inbuilt aggregate query i.e. data is coming from DB or not. This might be the problem with your Database connection. Please check that.

Regards,

Manish Jawla

Hi Manish,


The problem here is that I'm working with the free personal edition of this program, and thus cannot access the SQL Server DB, am I correct (found this answer in another topic)?

Would it then be the only solution to contact support (since i cannot have any influence on the DB, like restarting the server)?

hi Annemieke Staal,

In this case:

1. You have to wait for few hours because it happens in free environment sometimes.

2. If u have made some recent changes and after that u are facing this issue then please try to remove those changes and try again.

3. Create a new sample application in your environment and check whether u are facing the same issue or not, in order to verify the DB issue.

Regards,

Manish Jawla

Hi Manish,

Unfortunately I already tried all these options. The issues started yesterday morning (after being able to run perfectly on the friday before). I have tried to republish it today but still giving me the same timeout error.

The only change I have made back then is adding a user role to the application (not changing visibilities of widgets). Even when reversing this, it was still giving me the same problems.

I also made a new application with a very simple database (just a couple of entities with attributes) which also refused to publish (timeout).

When looking in the service center I have noticed that in the weekend, the SQL client went into deadlock when the scheduler was trying to dequeue (error is found below). Could this be the cause of the issue?



System.Data.SqlClient.SqlException (0x80131904): Transaction (Process ID 3175) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
   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, Boolean describeParameterEncryptionRequest)
   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 OutSystems.HubEdition.DatabaseProvider.SqlServer.ExecutionService.ExecutionService.ExecuteReader(IDbCommand cmd)
   at #uCb.#PCb.ExecuteStoredProcedureWithResultSet(Boolean skipLog, String readerParamName)
   at OutSystems.HubEdition.RuntimePlatform.DBRuntimePlatform.DequeueEvent(Transaction trans, Int32 batch, String ip, Int32 activityId)
   at #KYc.#QZc.#MZc(Int32 batch, String myIp)
ClientConnectionId:53a2473e-7f97-4699-91bb-ea36ea92bfc2
Error Number:1205,State:56,Class:13




Hi Annemieke,

If the problem is not specific to a single application you can contact support.

 Also are you able to open service center ? if yes than it should not be a database connection problem because service center also connects the same database.


Regards

-PJ-


Hi Pramod,


I am able to open the service center (though the connection can be really 'slow' (taking longer than normal) from time to time. Hence my suspicions). I will contact support. Hopefully they can help to resolve the issues. Thank you for all the help.