[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16339768#comment-16339768 ] ASF subversion and git services commented on CB-11513: -- Commit c8925b832ef18561a49a40d115a22e14f7ad6e03 in cordova-plugin-media's branch refs/heads/5.0.x from [~romedius] [ https://gitbox.apache.org/repos/asf?p=cordova-plugin-media.git;h=c8925b8 ] Fix for CB-11513 https://issues.apache.org/jira/browse/CB-11513 > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. >Priority: Major > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16339766#comment-16339766 ] ASF subversion and git services commented on CB-11513: -- Commit c8925b832ef18561a49a40d115a22e14f7ad6e03 in cordova-plugin-media's branch refs/heads/5.0.x from [~romedius] [ https://gitbox.apache.org/repos/asf?p=cordova-plugin-media.git;h=c8925b8 ] Fix for CB-11513 https://issues.apache.org/jira/browse/CB-11513 > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. >Priority: Major > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16319657#comment-16319657 ] ASF subversion and git services commented on CB-11513: -- Commit ad25d1059c44ce2229c40dabf6b7136f89356952 in cordova-plugin-media's branch refs/heads/master from [~romedius] [ https://gitbox.apache.org/repos/asf?p=cordova-plugin-media.git;h=ad25d10 ] Fix for CB-11513 https://issues.apache.org/jira/browse/CB-11513 > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.4.14#64029) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16319658#comment-16319658 ] ASF subversion and git services commented on CB-11513: -- Commit 42fef751d49fea39c00994cb58467ed01e19717b in cordova-plugin-media's branch refs/heads/master from [~shazron] [ https://gitbox.apache.org/repos/asf?p=cordova-plugin-media.git;h=42fef75 ] Merge pull request #120 from romedius/patch-1 CB-11513: (ios) Fixed: iOS memory warning stops sound, but does not send status to JS-client > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.4.14#64029) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16319656#comment-16319656 ] ASF subversion and git services commented on CB-11513: -- Commit ad25d1059c44ce2229c40dabf6b7136f89356952 in cordova-plugin-media's branch refs/heads/master from [~romedius] [ https://gitbox.apache.org/repos/asf?p=cordova-plugin-media.git;h=ad25d10 ] Fix for CB-11513 https://issues.apache.org/jira/browse/CB-11513 > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.4.14#64029) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16319655#comment-16319655 ] ASF GitHub Bot commented on CB-11513: - shazron closed pull request #120: CB-11513: (ios) Fixed: iOS memory warning stops sound, but does not send status to JS-client URL: https://github.com/apache/cordova-plugin-media/pull/120 This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.4.14#64029) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16317915#comment-16317915 ] ASF GitHub Bot commented on CB-11513: - damienleroux commented on issue #120: CB-11513: (ios) Fixed: iOS memory warning stops sound, but does not send status to JS-client URL: https://github.com/apache/cordova-plugin-media/pull/120#issuecomment-356202039 +1 This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.4.14#64029) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16299148#comment-16299148 ] ASF GitHub Bot commented on CB-11513: - damienleroux commented on issue #120: CB-11513: (ios) Fixed: iOS memory warning stops sound, but does not send status to JS-client URL: https://github.com/apache/cordova-plugin-media/pull/120#issuecomment-353190609 This has been merged? This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.4.14#64029) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16166030#comment-16166030 ] ASF GitHub Bot commented on CB-11513: - Github user pincombe commented on the issue: https://github.com/apache/cordova-plugin-media/pull/120 I would also love to see this get merged. It works and it is crazy that a memory warning would stop the audio from playing. > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.4.14#64029) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16136493#comment-16136493 ] ASF GitHub Bot commented on CB-11513: - Github user ghenry22 commented on the issue: https://github.com/apache/cordova-plugin-media/pull/120 could this get merged? I have been maintaining a forked plugin for months with this PR merged and it works well. > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.4.14#64029) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16036585#comment-16036585 ] ASF GitHub Bot commented on CB-11513: - Github user ghenry22 commented on the issue: https://github.com/apache/cordova-plugin-media/pull/120 I have merged this into my project and tested and confirm that it does what it says on the box. Before: simulate memory warning on the iOS simulator and audio stops instantly on the native side. App continues to function otherwise but no longer plays any audio After: simulate a memory warning on the iOS simulator and audio continues to play as expected, all works as normal. > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: cordova-plugin-media >Affects Versions: 3.6.3, 4.1.3, 6.4.0 > Environment: iOS 9 and iOS 10 >Reporter: Thomas K. > Labels: easyfix > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.3.15#6346) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15670689#comment-15670689 ] ASF GitHub Bot commented on CB-11513: - Github user romedius commented on the issue: https://github.com/apache/cordova-plugin-media/pull/120 @stevengill if you have some spare time, could you take a look at this patch too, or point me to the right maintainer? Thank you! > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: Plugin Media >Affects Versions: 3.6.3, 4.1.3, 6.1.0 > Environment: iOS 9.3 iPhone 6 >Reporter: Thomas K. > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15666853#comment-15666853 ] Thomas K. commented on CB-11513: This fix may also fix: https://issues.apache.org/jira/browse/CB-11409 > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: Plugin Media >Affects Versions: 3.6.3, 4.1.3, 6.1.0 > Environment: iOS 9.3 iPhone 6 >Reporter: Thomas K. > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15637020#comment-15637020 ] ASF GitHub Bot commented on CB-11513: - Github user cordova-qa commented on the issue: https://github.com/apache/cordova-plugin-media/pull/120 Cordova CI Build has completed successfully. **Commit** - [Link](https://github.com/apache/cordova-plugin-media/pull/120/commits/ad25d1059c44ce2229c40dabf6b7136f89356952) **Dashboard** - [Link](http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83/) | Builder Name | Console Output | Test Report | Device Logs | | :---: | :---: | :---: | :---:| | [Windows 8.1 Store]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-8.1-store/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-8.1-store/console) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-8.1-store/testReport/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-8.1-store/artifact/) | | [Windows 10 Store]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-10-store/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-10-store/console) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-10-store/testReport/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-10-store/artifact/) | | [Windows 8.1 Phone]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-8.1-phone/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-8.1-phone/console) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-8.1-phone/testReport/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=windows-8.1-phone/artifact/) | | [iOS]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=ios/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=ios/console) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=ios/testReport/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=ios/artifact/) | | [Android]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=android/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=android/console) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=android/testReport/) | [Link]( http://cordova-ci.cloudapp.net:8080/job/cordova-plugin-media-pr/83//PLATFORM=android/artifact/) | > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: Plugin Media >Affects Versions: 3.6.3, 4.1.3, 6.1.0 > Environment: iOS 9.3 iPhone 6 >Reporter: Thomas K. > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15636315#comment-15636315 ] ASF GitHub Bot commented on CB-11513: - Github user romedius commented on the issue: https://github.com/apache/cordova-plugin-media/pull/120 original author of this bugfix: @katzlbt > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: Plugin Media >Affects Versions: 3.6.3, 4.1.3, 6.1.0 > Environment: iOS 9.3 iPhone 6 >Reporter: Thomas K. > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15636313#comment-15636313 ] ASF GitHub Bot commented on CB-11513: - GitHub user romedius opened a pull request: https://github.com/apache/cordova-plugin-media/pull/120 CB-11513: (ios) Fixed: iOS memory warning stops sound, but does not send status to JS-client ### Platforms affected iOs ### What does this PR do? If iOS issues a memory warning while playing a sound, all sounds are terminated. However the ios/CDVSound.m plugin does not update the state of its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, which is untrue after a memory warning. This results in incorrect clientside status. Problem: A user's software component may send pause() instead of play() (toggle button) effectively rendering the sound unplayable without recovery. This happened in our case. Fix: Do not discard currently playing sounds. The first memory warning arrives exactly when the App enters the yellow area and consumes 500MB however it may consume 750MB and more according to Xcode so terminating sounds on "memory warning" is incorrect behavior. ### What testing has been done on this change? Tested on iOs simulator. How to reproduce the Issue: Add 1 or 2 large animated GIFs with 200+ frames to the UIWebView, this will consume 500MB quickly while playing the GIFs, or simulate the memory warning using the iOS Simulator while playing a sound. ### Checklist - [x] [Reported an issue](http://cordova.apache.org/contribute/issues.html) in the JIRA database - [x] Commit message follows the format: "CB-3232: (android) Fix bug with resolving file paths", where CB- is the JIRA ID & "android" is the platform affected. - [x] Added automated test coverage as appropriate for this change. https://issues.apache.org/jira/browse/CB-11513 You can merge this pull request into a Git repository by running: $ git pull https://github.com/romedius/cordova-plugin-media patch-1 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/cordova-plugin-media/pull/120.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #120 commit ad25d1059c44ce2229c40dabf6b7136f89356952 Author: Romedius WeissDate: 2016-11-04T13:17:04Z Fix for CB-11513 https://issues.apache.org/jira/browse/CB-11513 > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: Plugin Media >Affects Versions: 3.6.3, 4.1.3, 6.1.0 > Environment: iOS 9.3 iPhone 6 >Reporter: Thomas K. > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Do not discard currently playing sounds. The first memory warning > arrives exactly when the App enters the yellow area and consumes 500MB > however it may consume 750MB and more according to Xcode so terminating > sounds on "memory warning" is incorrect behavior. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org
[jira] [Commented] (CB-11513) iOS memory warning stops sound, but does not send status to JS-client
[ https://issues.apache.org/jira/browse/CB-11513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15356934#comment-15356934 ] Thomas K. commented on CB-11513: - (void)onMemoryWarning { NSMutableArray* keysToRemove = [[NSMutableArray alloc] init]; for(id key in [self soundCache]) { CDVAudioFile* audioFile = [[self soundCache] objectForKey:key]; if (audioFile != nil) { if (audioFile.player != nil && ![audioFile.player isPlaying]) { [keysToRemove addObject:key]; } if (audioFile.recorder != nil && ![audioFile.recorder isRecording]) { [keysToRemove addObject:key]; } } } [[self soundCache] removeObjectsForKeys:keysToRemove]; [self setAvSession:nil]; [super onMemoryWarning]; } > iOS memory warning stops sound, but does not send status to JS-client > - > > Key: CB-11513 > URL: https://issues.apache.org/jira/browse/CB-11513 > Project: Apache Cordova > Issue Type: Bug > Components: Plugin Media >Affects Versions: 3.6.3, 4.1.3, 6.1.0 > Environment: iOS 9.3 iPhone 6 >Reporter: Thomas K. > > If iOS issues a memory warning while playing a sound, all sounds are > terminated. However the ios/CDVSound.m plugin does not update the state of > its JS-clients, so the last state the Client knows is Media.MEDIA_RUNNING, > which is untrue after a memory warning. This results in incorrect clientside > status. > Problem: A user's software component may send pause() instead of play() > (toggle button) effectively rendering the sound unplayable without recovery. > This happened in our case. > Fix: Send a correct message to update the status at the JS-client to > Media.MEDIA_STOPPED or do not discard currently playing sounds. > https://github.com/apache/cordova-plugin-media/blob/master/src/ios/CDVSound.m#L814 > How to reproduce: Add 1 or 2 large animated GIFs with 200+ frames to the > UIWebView, this will consume 500MB quickly while playing the GIFs, or > simulate the memory warning using the iOS Simulator while playing a sound. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org