KeepAlive Issue

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • doctormike
    Junior Member
    • Nov 2012
    • 55

    #1

    KeepAlive Issue

    Following the development team's announcement that session expiry time would be reduced from 12 hours to 1 hour, I modified the code in my apps to include a KeepAlive function executable every hour following login. I used a timer to do this and it worked fine in testing, but when the apps were in full flow at the weekend they were frequently crashing. Hitherto I haven't used KeepAlive as my sessions never approached 12 hours.

    To prevent further crashes I took out the KeepAlive code so that I could continue to trade, with the intention of logging in again every hour from my manual login dialog form. However it turned out that I did not need to do this, as the hour intervals passed without my sessions expiring. I'm now confused as I understood that expiry was not activity dependent, so I expected to be automatically logged out every hour if I wasn't employing KeepAlive. Am I misunderstanding the nature of Betfair's new session protocols or have they not been implemented as announced?

    Any guidance from members of the development team would be appreciated.

    With regards
    Mike
  • Mr Magoo
    Junior Member
    • Jan 2011
    • 86

    #2
    I'd like to know the answer to this too! I've never called KeepAlive from my programs, and they appear to stay logged in fine.

    I had just assumed that KeepAlive was for when you want to hold open a Betfair session when you aren't making any other requests. After all, if your app is regularly querying the Betfair servers, why should they have any reason to throw away active sessions?

    Comment

    • BetfairDeveloperProgram
      Administrator
      • Oct 2008
      • 679

      #3
      Hi doctormike,

      The implementation of the 60 minute session expiry has been delayed and the current expiry time is 4 hours.

      Mr_Magoo are your session times longer than 4 hours?

      Thanks

      Neil

      Comment

      • Mr Magoo
        Junior Member
        • Jan 2011
        • 86

        #4
        Oops, I just checked some old logs and it does seem that my program was re-logging in every 4 hours. Sorry for the confusion and the wrong information

        Comment

        • Merlin
          Junior Member
          • Jan 2009
          • 56

          #5
          KeepAlive

          Hi Neil,

          is there any chance of sticking the revised time-out details in the thread under 'Announcements', together with any plans to change to an hour in the near future?
          I realise you lot are quite busy there, but not everyone has the time to check through all the forum posts; instead we rely on the 'Announcements' section to flag up anything which has a direct bearing on changes to the API.

          cheers,

          Merlin

          Comment

          • doctormike
            Junior Member
            • Nov 2012
            • 55

            #6
            Announcements

            Many thanks for the info, Neil. I agree with Merlin that key changes should be emphasised more clearly & consistently so that developers cannot miss them. This is in everyone's interests as I'm sure it would save BDP much hassle by pre-empting problems encountered by app users. Incidentally, many of my sessions in the past two weeks have greatly exceeded 4 hours and I'm not currently employing a KeepAlive function.
            With regards
            Mike

            Comment

            • BetfairDeveloperProgram
              Administrator
              • Oct 2008
              • 679

              #7
              Hi Melrin/doctormike,

              Thanks for your feedback, the original post has been updated now.

              Sorry for any confusion caused by the delay of the implementation of the 1 hour session time. We try to give as much notice as possible regarding API changes, in this case this didn't happen on the planned date, and this delay was overlooked.

              Kind Regards

              Neil

              Comment

              Working...
              X