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

issue #1: AIR [desktop] application stops running after semi-long periods of time (frm 1h to 1night)

Community Beginner ,
Feb 13, 2014 Feb 13, 2014

Copy link to clipboard

Copied

Good day guys,

I'm having this veeeery bad [system] issue that I'm unable to understand:

my AIR application [mac_desktop only at the moment] stops running after semi-long periods of time (from 1h to 1 night) -> till I click on its dock icon on my Mac, which seems to reactive the application core - and my app from its boot[1]).

[1] in t0 the app (re)connects to my application server - connection that in the meanwhile was lost because the flash client disappeared to the server - and starts to (re)load a set of external swf modules from my web repository to (re)launch its service

Since the time needed to fall in the behaviour is very long, this should not be related to:

1. NativeApplication.nativeApplication.systemIdleMode=SystemIdleMode.KEEP_AWAKE, which I put as first istruction of the constructor of the first class of the desktop [external component loader] App

and:

2. today I don't care of Event.DEACTIVE from my NativeApplication singletone since at this building time my App is expected to work in the same manner when looses the OS focus as when it has it. Is it correct and is it enought - not carying the event condition? (see the 1 above) Or may be am I missing something to tell AIR core to keep my App working in background for_ever like it would be in foreground and till the App wants? (see 1 above again)

please note that:

a) my App is something like an instant messanger and needs of course to be always at 100% running, both in background and in foreground

b) I want to be able to make videoconferencing at top performance also while moving OS focus on other applications, and most of the time I receive conference calls of course when my Application is not in focus

c) my App have to react _in realtime_ to some server notifications with or without OS focus

d) in all the other cases my App does use CPU at the minimum just answering to my application server datachannel pings. What I expect from AIR/desktop should be a normal manner to design native service applications

3. user idle mode should not be an issue even it seems something related (or related to some OS idle time -- see 1 above again): relative to what I learnt, user idle mode is usefull to be detected by apps but should not involve the background/foreground AIR application core working model (isn't it correct?) so my App do not use this useful event.  

I read a lot on google for days but strangely I can't find an equivalent issue from any other developer at least at recent times (AIR 3.8+). May be I'm missing something, so I decided to ask for help @ Adobe Forums (does anybody already did a real-life-working multiplatform videocollaboration/instant messenger app with Flash/AIR? ps Unicom by Adobe seems to be just an old 2011-abandoned(?) project).

Please not that I'm not yet working with AIR for Android or for iOS (I read some old issues related to this topic but ONLY about the mobile platforms.. and they are not YET my topic), I'm just still working only at a first alpha of my app for the Mac (and its equivalent for the Web).

Let's say I'm still at the beginning on building the App: I'm testing AIR in-background stability, h264 codec and the enhanced microphone support (..), the rtmfp protocol and some more while improving my semi-recent AS3 knowledgebase and while making the basement of the Application... but I make this kind of apps since 2002/AS1.

ps today I never close the native window of the Application and I do not use awalysInFront: today the app simply goes beyond the other application windows (and in the future I will visible=false the native windows at user request)

any help direction, guys? It is terrible.

mc

ps Let's say that Flash Player 6 (Flash MX) was used to work perfectly instead (on the web and when installed as Windows Active Desktop web component at the Windows XP times) even it was not AVM2 (jump that I love).

TOPICS
Performance issues

Views

1.2K

Translate

Translate

Report

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 Beginner ,
Feb 13, 2014 Feb 13, 2014

Copy link to clipboard

Copied

just tracing some kind of tests I'm doing.

A couple of hours ago I left working 2 instances of my Application, leaving alone this computer: one instance is the Mac desktop version and the other one is the Web version. In this case both versions were running on the same computer (an iMac with OS X Mavericks):

1) the AIR/Mac version have been recompiled yesterday with the new AIR4(.0.0.1619 - AIR 3.8 is used to fall in a equivalent way - no changes)

2) the Web version have been compiled targeting FP 11.8 and it is running on Chrome browser with PepperFlash NOT disabled (which reports version MAC 13.0.0.80, the latest)

I left working both the Mac and the Web versions of the Application opened on the pc screen (= not minimized) but kept totally behind some Terminal/ssh windows (= not on OS focus and the system is not asked to update any screen area of the app for sure).

I came back after about 2 hours and I got the browser version connected&running (but it is not a rule) and I also found the AIR-based Mac version disconnected (uau, usually I found the app disconnected but with the screen freezed at last user look ->) which rapidly reconnects upon my click on the Apple dock icon (bring to front).

Why these different behaviours? I ask to myself.

The two versions of the software are TOTALLY the SAME application: except for the first Flash file (a 24kb swf file for the Web version and a 170kb dmg file for the Mac version), basically a platform-dependent loader, both versions loads the same remote swf modules. Of course t is AIR (or my first Flash file?).

I attach the source code of the Mac version of the [first file] AIR-based application at the following url:

http://92.63.230.100/others/others/wtstarter_mac.as.txt

_Adobe_, is it a bug? isn't it?

mc

Votes

Translate

Translate

Report

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
Participant ,
Feb 14, 2014 Feb 14, 2014

Copy link to clipboard

Copied

Hi,

Could this be just a memory leak?

Have you tried to run your code through a memory profiler, like the one that's included in Flash Builder?

I think Adobe Scout could give you some insights too.

You could also simply track the available memory over time, via a Timer:

_currMemory = System.totalMemory / 1048576; // in megabytes. 1 mb = 1024 kilobytes.  1 kb = 1024 bytes.  ( 1024^2 = 1048576 )

Votes

Translate

Translate

Report

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 Beginner ,
Feb 14, 2014 Feb 14, 2014

Copy link to clipboard

Copied

Hi Aster,

thanks for your reply.

It can't be a memory issue: when I give OS focus to the Application it restarts working normally (without closing and relaunching the app). It is just something that stops actionscript engine (.. so my questions above).

Anyway, I'm exactly having a look to Flash memory usage with Adobe Scout.. and at a first look I don't like what I see (I know my code). but this is another story.. I'm thinking to mobile.

thank you anyway.

mc

Votes

Translate

Translate

Report

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
Adobe Employee ,
Feb 14, 2014 Feb 14, 2014

Copy link to clipboard

Copied

Could you please open a new bug report on this over at https://bugbase.adobe.com?  When adding the bug, please include your sample code or a sample application so we can quickly test this out internally. It might also be useful to get your Scout output.

Once added, please post back with the URL or bug number and I'll have someone follow up.

Thanks,

Chris

Votes

Translate

Translate

Report

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 Beginner ,
Feb 14, 2014 Feb 14, 2014

Copy link to clipboard

Copied

LATEST

Hi Chris,

since I did not read any answer for my simple questions above (may be I'm right) I will do some tests more and than [in case] I'm going to open the bug report. Thank you.

mc

Votes

Translate

Translate

Report

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