AnsweredAssumed Answered

AF SDK Timeout not Respected

Question asked by rohanar on Feb 9, 2015
Latest reply on Feb 10, 2015 by gachen

We are using the AF SDK 2.2 to connect to an AF Server from a .NET website. In code, it seems like the Connection Timeout property is not being respected. We disabled IIS/SQL on the AF server, then ran the web code against it with a 5 second connect timeout specified. The Connect() call took 5 minutes to timeout.  However, when the setting is changed manually using PI System Explorer, the website properly times out at 5 seconds.  Any ideas?

                   

           If mPiSystems Is Nothing Then

                mPiSystems = New PISystems(True)

            End If

 

 

     If mPiSystem Is Nothing Then

 

                Try

                    mPiSystem = mPiSystems(mServerInfo.Server)

                    mPiSystem.ConnectionInfo.TimeOut = New TimeSpan(0, 0, 5)

                Catch exRange As IndexOutOfRangeException

                    mPiSystem = Nothing

                    Return False

                End Try

 

                If mPiSystem Is Nothing Then

                    Return False

                End If

 

            End If

 

 

            If mPiSystem.ConnectionInfo.IsConnected = False Then

                mPiSystem.Connect(mCredentials)

             End If

 

 

 

PI System Explorer properties are respected by the website running on the same machine.

Outcomes