Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Detected duplicate HTTP-based FlexSessions in CF10 with Air Mobile (3.4) IOS and Android apps

Explorer ,
Oct 03, 2012 Oct 03, 2012

We're getting the "duplicate session" error using Flash Remoting from Air 3.4 Mobile Apps ( IOS and Android ) with Coldfusion 10 Standard.

faultCode:Server.Processing.DuplicateSessionDetected faultString:'Detected duplicate HTTP-based FlexSessions,

generally due to the remote host disabling session cookies.

Session cookies must be enabled to manage the client connection correctly.' faultDetail:'null'

Have read most of the docs about this error -all to do with LCDS

Notes:

  • Not using LCDS,
  • No Remote Calls from loaded Sub-Apps, 
  • No Errors from the Flex Web App which is pretty  much identical and calls the same cfcs.
  • The error does not happen all the time and is hard to reproduce - say 5% of app sessions at a guess.
  • Could it be a two first time remote calls hitting the server together before a session is set up?
  • Our remoteObjects are in two places 1) Main Application.mxml and within a class compiled into the main app - can't see how this would be an issue.
  • I enabled session management for the CFCs in Application.cfc but still occurs. Is this neccessary - it's not in any docs?
  • Could this be something to do with the app not being shut down - as is typical with mobile users? When they resume use after a day or two surely a new session will be created?

Please advise thank you.

TOPICS
Flash integration
9.6K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Oct 13, 2012 Oct 13, 2012

I enabled session management for the CFCs in Application.cfc

What are the values of sessionTimeout and applicationTimeout? Do you rewrite the session anywhere, for example, using structDelete or structClear? Any cfcookie code, too?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Oct 13, 2012 Oct 13, 2012
LATEST

For our profect I think this issue was caused as follows:

Believing that remoting was full asynchronous we fired a 2 or 3 remote calls to the server at the same time ( within the same function ) - usually when the users goes to a new section of the app.

This seemed to trigger the duplicate http session error since according to http://blogs.adobe.com/lin/2011/05/duplication-session-error.html  two remote calls arriving before a session is created will cause 2 sessions to be created.

Our current solution ( too early to say it works ) is to daisy chain the multiple calls together .

Also there seemed to be an issue where mobile apps that never quit ( thanks Apple! )  caused the error when activated after a few hours.

I guess the session expires on the server and the error above occurs on activation.

So the mobile apps now ping the server with a remote call when activated after sleeping for more than one hour.

All duplicate http errors are silently caught and reported.

Fingers crossed we won't get any more!

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources