StrataFrame Forum

Unable to read beyond the end of the stream error

http://forum.strataframe.net/Topic33301.aspx

By Gina Heitlager - 6/2/2016

Hi guys,

All of a sudden we get the above error.  It had been running fine for months and we hadn't made any changes to our software.  We are running ES version 1.7.3.5 on Windows server 2012 R2.  The weird thing is it works fine when I run the program from another server on the same local network.  But outside of that we get the error.

Any ideas?

Thanks,

Marcel


The error detail is:

{"Unable to read beyond theend of the stream."}   atSystem.IO.BinaryReader.FillBuffer(Int32 numBytes)

   atSystem.IO.BinaryReader.ReadBoolean()

   atMicroFour.StrataFrame.Data.Enterprise.BaseResults.ReadDataFromStream(BinaryReaderreader, String dataSourceKey)

   atMicroFour.StrataFrame.Data.Enterprise.ExecuteScalarResults.CreateFromStream(BinaryReaderReader, String dataSourceKey)

   at MicroFour.StrataFrame.Data.Enterprise.EnterpriseDataSourceItem.SendRequestCore(BaseParamsParams, RemoteDataSourceCommand Command, String dataSourceKey)

   atMicroFour.StrataFrame.Data.Enterprise.EnterpriseDataSourceItem.(BaseParams A_0, RemoteDataSourceCommand A_1)

   atMicroFour.StrataFrame.Data.Enterprise.EnterpriseDataSourceItem.(DbCommand A_0, Boolean A_1, String A_2)

  atMicroFour.StrataFrame.Data.Enterprise.EnterpriseDataSourceItem.ExecuteScalar(DbCommandCommand)

   atMicroFour.StrataFrame.Data.DataLayer.ExecuteScalar(DbCommand Command)

   atMicroFour.StrataFrame.Business.BusinessLayer.ExecuteScalar(DbCommandCommandToExecute)

   atAES.BOL.PPMStudentBO.GetRecordCount() inE:\_VS2013Projects\DEV\AES.BOL\AES.BOL\BO\PPMStudentBO.vb:line 609

   at AESMC.ESConnectionManager.TestConnections(RemoteDataApplicationSettingsBOoMyAppSettings) in E:\_VS2013Projects\DEV\AESMC




The code that causes the error is:

Public Function GetRecordCount() As Integer

        '-- Establish Locals

        Dim loCommand As New SqlCommand()

         '-- Build the Query

        loCommand.CommandText = "SELECT count(*) AS RecordCount FROM PPMUsers"

       Return CType(Me.ExecuteScalar(loCommand), Integer)

End Function


By Ivan George Borges - 6/2/2016

Hi Gina.

If you haven't changed any of the ES DLLs either in the server nor the workstations, and since you say it works fine when running on a different server, I would guess that it could be a connection issue, maybe a bad network card or something like that breaking the communication and sending an incomplete stream.

But it is hard to say for sure.

Cheers.

Ivan