Flex strings never cleared from the memory

I have this weird problem for a while and try to solve it to look up on the net for proper solution but still I am clueless.
When I check my application's memory usage with flex profiler (4.6) the portion of String keep increasing and eventually reach the point of crash.
And I pin pointed where this increasing occurs from my application's source code.
It is the local string variable that I passed to Json.decode(). It never cleared.
All the instance of the json string that I got from the socket server remains in the memory til app crashes even if profiler says there is 0 path to the String.
I don't know how to clear these Strings. It only keeps growing.
Please help me. I have been struggled with this for a week now.
Thanks for any support in advance.
![enter image description here][1]
portion of my source code that I think the source of the leak is as following.
   protected function evtserverReseved(event:ProgressEvent):void{
      var tmpArr:ByteArray = new ByteArray();
    var tempByteArray:ByteArray = new ByteArray();
    socEvtServer.readBytes(tmpArr, 0, socEvtServer.bytesAvailable);
     tempByteArray.writeBytes(leftOverMessageNotify, 0, leftOverMessageNotify.length);
    tempByteArray.writeBytes(tmpArr, 0, tmpArr.length);
    leftOverMessageNotify = new ByteArray();
    parseByteArray(tempByteArray); 
   private function parseByteArray(rawArray:ByteArray):void{
    if(( rawArray[0] == 0x30 || rawArray[0] == 0x31 ) && rawArray[1] == 0x00 ){
     var log:String = "";
     for(var i:int=0; i<16; i++){
      if(rawArray[i]==0){
      }else{
       log += rawArray[i]-48;
     sizeOfFullListNotify = uint(log);
     commonFunction.printLog("Event Server eventNotify sizeOfFullListNotify=" + sizeOfFullListNotify);
     rawArray.position = 16;
    var tempIdx:uint = rawArray.position;
    var tempLength:uint = rawArray.length;
    if(sizeOfFullListNotify <= tempLength - tempIdx){
     var tempArray:ByteArray = new ByteArray();
     var tempLeftOver:ByteArray = new ByteArray();
     var j:uint;
     for(j=0; j <sizeOfFullListNotify ; j++){
      tempArray[j] = rawArray[j+tempIdx];
     var euckrString:Object = tempArray.readMultiByte( tempArray.length,"euc-kr").replace(" ","").replace("\n","");
     //commonFunction.printLog("Total memory=" + flash.system.System.totalMemory +", Free memory=" + flash.system.System.freeMemory + ", Event Server eventNotify JSON 수신 data size=" +euckrString.toString().length+ ", body=" + euckrString.toString() );
      var ob:Object = com.adobe.serialization.json.JSON.decode(euckrString.toString());
     commonFunction.printLog("Total memory=" + flash.system.System.totalMemory +", Free memory=" + flash.system.System.freeMemory + ", Event Server eventNotify JSON data size=" +euckrString.length+ ", body=" + euckrString );
       if(ob.method != null){
      //gridBox.DT_HOUSE.addItemAt(ob,0);
      gridBox.DT_HOUSE.push(ob);
      totlaReceivedList++;
     }else if(!(ob.result is String)){
      //confirm for registerEventNotify
      commonFunction.printLog("confirm for registerEventNotify");
     if(sizeOfFullListNotify < tempLength - tempIdx){
      for(var k:uint=0; k <tempLength-tempIdx-sizeOfFullListNotify ; k++){
       tempLeftOver[k] = rawArray[k+j+tempIdx];
      parseByteArray(tempLeftOver);
     }else{
      //leftOverMessageNotify = new ByteArray();
    }else{
     //leftOverMessageNotify = rawArray;
     for(var i:int = 0 ; i<rawArray.length ; i++){
      leftOverMessageNotify[i] = rawArray[i];
     rawArray = null;
var euckrString:Object(String) is the portion that never cleared from the memory.
It keeps stacking till crashes.

viseur has already been removed.
you can always use:
if(viseur&&viseur.stage){
viseur.parent.removeChild(viseur);

Similar Messages

  • My ipad shows capacity 13.6GB, available 0 bytes. Can I clear some items from the memory to increase the avaavailable memory?

    my ipad shows capacity 13.6 GB, available 0 bytes. Can I clear some items from the memory to increase the available memory?
    Getting message "storage almost full"

    One usually large user of storage space is photos and videos. You could import them to a computer and then delete them from the iPad: Import photos and videos from your iPhone, iPad, or iPod touch to your Mac or Windows PC - Apple Support
    You can also go to Settings > General > Usage and click on "Manage Storage" (in the Storage section, not the iCloud section) and that will show what is using the storage and may help you decide if you want to delete some apps or something else.

  • Oracle.oc4j.sql.managedconnectionimpl objects are not cleared from the JVM

    One of our customer is facing the outofmemory issue, when they connect many users and they go ideal for some times, without doing any operation on the server and when they come back and connect they get Out of memory issue.
    For that i just profiled my application and i can see the following objects never get cleared from the JVM.. Following objects not GC.
    oracle.oc4j.sql.spi.managedconnectionimpl
    oracle.oc4j.sql.xa.iccxaconnection
    oracle.oc4j.sql.spi.connectionrequestinfoimpl
    oracle.oc4j.sql.managedconnectionimpl
    oracle.oc4j.sql.spi.Txstate
    oracle.jdbc.driver.logicconnections
    We do have a pooling timer running at the back end.
    Please suggest is there any why i can make these connections Garbage collected when they are not in use? is there any setting for in oc4j for that?
    Thank you

    One of our customer is facing the outofmemory issue, when they connect many users and they go ideal for some times, without doing any operation on the server and when they come back and connect they get Out of memory issue.
    For that i just profiled my application and i can see the following objects never get cleared from the JVM.. Following objects not GC.
    oracle.oc4j.sql.spi.managedconnectionimpl
    oracle.oc4j.sql.xa.iccxaconnection
    oracle.oc4j.sql.spi.connectionrequestinfoimpl
    oracle.oc4j.sql.managedconnectionimpl
    oracle.oc4j.sql.spi.Txstate
    oracle.jdbc.driver.logicconnections
    We do have a pooling timer running at the back end.
    Please suggest is there any why i can make these connections Garbage collected when they are not in use? is there any setting for in oc4j for that?
    Thank you

  • This exception is never thrown from the try statement body

    try {
                   SimpleFileReader.openFileForReading("fileName.text");
              } catch (FileNotFoundException fnfe) {
                   System.out.println("");
              }This is part of a method, if that helps. In Eclipse I get the error message "Unreachable catch block for FileNotFoundException. This exception is never thrown from the try statement body." I saw another post similar to this one, but it's not quite clear what the solution is. Could anyone clarify for a beginner?
    Thanks

    It actually does if the file it's opening is not really a text file, or if it's read-protected. Or is that where I'm going wrong? I'm just trying to open the file's name(already in the field) and know that it is .text or will return the error.
    Edited by: meme_kun_345k on Jan 15, 2008 7:18 PM

  • Why am I being billed for equipment that never worked from the get go, and that your representatives admitted never connected to the computer on your end?

    In September my husband and I were planning a cross country move and we thought that having a Jet Pack to go on line with while we were traveling would be a good idea. When we ordered it we told the representative that we did not need it until the 1st of Oct. as that was when we would be leaving. It arrived on our door on Sept 9th with the instructions to be sure and activate it within 2 weeks or we would lose the line. On the 19th we called in the activation and everything appeared fine. We hit the road on the 1st and Nothing, Na-Da, Zip, Zilch .... The equipment never worked from the get go! We called Verizon from the road on the 4th of Oct. to find out what was going on and the representative told us that the problem was with the computer on Verizon's end. We shut the equipment off for the rest of our trip and called for a refund on the 13th of Oct. We spoke to a representative named Juan, who again confirmed that it was Verizon's computer that had been the problem,  and we were assured that all fee's associated with the Jet Pack would be waived as the equipment never worked in the 1st place. He told us all we needed to do was return the broken equipment and that he would send us a return label. We received the return label and sent the equipment back on the 22nd of Oct. On our next bill no credits of any kind had been applied? We promptly picked up the phone and called Verizon again, on Oct 31st,  to find out what was going on? This time we spoke to Lou Ann. After about an hour and a half she finally managed to remove the fee's, or so we thought, and we hung up satisfied. On 11/5 our Nov. bill arrived again with no credits of any kind. We thought maybe the billing cycle hadn't had time to catch up with our most recent conversation so we called just to verify. This time we spoke to Moncheria. She did not understand what had happened and had to reenter the same refund that Lou Ann had earlier. Again another hour and a half on the phone. Today,11/28, we received our most recent bill and again no credits of any kind??? We picked up the phone and called again. This time we explained to Christian, (the above story), and she put us on the phone with her supervisor Carson. Carson proceeded to tell us that ALL of the previous representatives we had spoken to were wrong and that since we had not returned the equipment within 14 days of receiving it that we were beyond the limits of the refund policy, (which means we would have had to return it before we left on our trip), and the best she could do was offer us coupons for the future to offset THEIR mistake! No thank you I will keep my cash in my pocket!
    1st of all we ordered it for the 1st of Oct. not for 9th of Sept.
    Secondly we were told to be sure and activate it within 14 days or we would lose the line, never any mention of a refund time limit. (Who buys stuff anticipating an immediate refund?)
    And 3d THE EQUIPMENT NEVER WORKED IN THE 1ST PLACE!!
    Now Verizon is asking for $343.34 in fee's for something that never worked in the 1st place!! This is ridiculous and those fee's are defiantly under dispute! The way I see it trying to hold me to a contract that Verizon breached by sending out faulty equipment is just wrong! 

    Your issue has been escalated to a Verizon agent. Please go to your profile page for the forum, and look in the middle, right at the top where you will find an area titled "My Support Cases".  You can reach your profile page by clicking on your name beside your post, or at the top left of this page underneath the title of the board.
    Under “My Support Cases” you will find a link to the private board where you and the agent may exchange information.  This should be checked on a frequent basis  as the agent may be waiting for information from you before they can proceed with any actions. Please keep all correspondence regarding your issue in the private support portal.
    If a forum member gives an answer you like, give them the Kudos they deserve. If a member gives you the answer to your question, mark the answer that solved your issue as the accepted solution.

  • How do you remove back up data from the memory storage? my storage data states that i have over 80gb of data used for back ups and i dont know why as i use a external hard drive as a time machine .now my 250gb flash storage is nearly full

    how do you remove back up data from the memory storage? my storage data states that i have over 80gb of data used for back ups and i dont know why as i use a external hard drive as a time machine .now my 250gb flash storage is nearly full.. HELP!

    When Time Machine backs up a portable Mac, some of the free space will be used to make local snapshots, which are backup copies of recently deleted files. The space occupied by local snapshots is reported as available by the Finder, and should be considered as such. In the Storage display of System Information, local snapshots are shown as  Backups. The snapshots are automatically deleted when they expire or when free space falls below a certain level. You ordinarily don't need to, and should not, delete local snapshots yourself. If you followed bad advice to disable local snapshots by running a shell command, you may have ended up with a lot of data in the Other category. Ask for instructions in that case.
    See this support article for some simple ways to free up storage space.

  • Is there a way to view the web history after it's been cleared from the history tab?

    Is there a way to view the web history after it's been cleared from the history tab?

    Yes.

  • I connected a digital camera memory chip with approximately 100 photos on it. The photos showed up in iPhoto. I believe I deleted the photos from the memory chip before importing them. Is there any way I can get the photos back?

    I connected a digital camera memory chip with approximately 100 photos on it to import into iPhoto. The photos showed up in iPhoto. I believe I deleted the photos from the memory chip before importing them to iPhoto. Is there any way I can get the photos back?

    Terence, thanks that site is a gem...have to explore it more fully at home as it drove security here crazy
    Looks like just the ticket for saving mistakes.

  • Why can't I transfer my photos from the memory card to my computer.

    I have an HP 5510 and can't see where I can download photos from the memory card to my computer. The printer only lets me view the photos or print them, but I want to store them on my computer. How do i do that?

    I'm wondering the same thing...  Do I need to connect the printer via the usb cable?  Help Please.

  • I viewed photos  from the memory card of my camera without importing them to my mac air but on the next day I realized that I Lost my memory card. Is there a chance that my mac air took a back up of these photos ? Please say yes and guide me pls

    I viewed photos  from the memory card of my camera without importing them to my mac air but on the next day I realized that I Lost my memory card. Is there a chance that my mac air took a back up of these photos ? Please say yes and guide me through the steps to recover them. I need URGENT HELP please

    If you didn't import them to Photos or copy them to the hard drive there will be no way to recover them. 
    How did you view them?

  • Why isn't my last import saving? I can import the pictures from the memory card, but if I close out iPhoto the just "imported photos" are nowhere to be found.  Please help

    Why isn't my last import saving? I can import the pictures from the memory card, but if I close out iPhoto the just "imported photos" are nowhere to be found.  Please help

    Option 1
    Back Up and try rebuild the library: hold down the command and option (or alt) keys while launching iPhoto. Use the resulting dialogue to rebuild. Choose to Rebuild iPhoto Library Database from automatic backup.
    If that fails:
    Option 2
    Download iPhoto Library Manager and use its rebuild function. This will create a new library based on data in the albumdata.xml file. Not everything will be brought over - no slideshows, books or calendars, for instance - but it should get all your albums and keywords back.
    Because this process creates an entirely new library and leaves your old one untouched, it is non-destructive, and if you're not happy with the results you can simply return to your old one. .
    Regards
    TD

  • I know this is supposedly not possible, but I need to retrieve a specific voicemail from my iPhone which was also "cleared" from the Deleted Messages box. Any suggestions?

    I know this is supposedly not possible, but I need to retrieve a specific voicemail from my iPhone which was also "cleared" from the Deleted Messages box. Any suggestions?
    This is highly important. I know the number from which the voicemail arrived, but have not been able to figure out how to retrieve it. I accidentally had the voicemail in the Deleted Messages folder, and then Cleared this folder. If there is any possible way I might be able to retrieve this message, even if there is a cost associated with it, please help me.
    Thank you.

    I think you maybe able to restore from backup if that voicemail was included in the backup. http://support.apple.com/kb/HT1766

  • Mera, (this has always been sucessful) however the pictures would not download, and appear to be encrypted and unable to view.  This also erased the pictures from the memory card. Help?

    I tried to download my pictures with my memory card from my camera (this has always been sucessful) however the pictures would not download, and appear to be encrypted and unable to view, also not saved in my 'Iphotos'  This also erased the pictures from the memory card. Help.....anyway of retrieving them?

    With the amount of information you've provided it's impossible to offer a potential solution.  We can't see your computer so we need to know the details of your problem and setup, i.e.:
    what version of iPhoto are you using?
    what system version are you running?
    did you get a message when trying to import from the memory card?
    did you use a card reader?
    what was you exact workflow for attempting the import?
    what fixes have you tried?
    where is your library located?
    did you apply any updates or upgrades just prior to the problem occurring?
    are you running a "managed" or "referenced" library? See image below:
    what type of Mac?
    how much free space on your boot drive?
    OT

  • How to acquire data from the memory of multimeter

    I am a beginner of Labview. I don't know how to acquire data from the memory of multimeter.
    I read some examples about DAQ, but it seems not similar to my case. I can't use DAQ in my computer, as I don't have DAQ board.
    Could anybody give me some guide? Similar examples would be great.
    Solved!
    Go to Solution.

    Confirm that you have the VISA Run Time Engine on the target machine. If you do not have it installed, you can install the VISA Run Time Engine from ni.com.
    Error -1073807346 Using VISA When Running LabVIEW Executable On Target Computer
    Message Edited by Mathan on 10-12-2009 07:11 AM

  • I tried to download my photos from the memory card to my computer but I got an error message of  " file not found ". What would cause this ?

    When I inserted my memory card from the camera into the computer it opened the Adobe window. I clicked on the get photos icon and the process of downloading to the computer began as usual. But when it was complete an error message came up No file found. Now I cannot open anything to view any of my previous photos. How do I fix this ?

    The Camera Connection Kit works with SD cards, not Memory Sticks.
    Maybe you can find an MS to SD adapter, or use the USB connection with the USB cable that came with the camera.

Maybe you are looking for