<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 3, 2015 at 7:09 PM, Bob Arning <span dir="ltr">&lt;<a href="mailto:arning315@comcast.net" target="_blank">arning315@comcast.net</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF" text="#000000">
    <font face="Georgia">FWIW, my old stand-by is<br>
      <br>
      WACache allInstances do: [ :e | e reap].<br>
    </font><div><div><br></div></div></div></blockquote><div><br></div><div><br></div><div><div>Thanks Bob,</div><div><br></div><div>I just tried that and indeed, after doing that and a GC, it removed almost all garbage I have around and indeed, it called all the #unregistered of my sessions. </div><div>So.... OK, with such code I can at least force the GC of those (which is similar to the one I was doing: <b style="font-size:12.8000001907349px">WAApplication allInstances do: [ :each | each clear ].)</b>  , but... I still wonder, why my sessions are not &quot;reap&quot; automatically? Why they do not get the #unregistered automatically? From what I understand, they should, right?</div><div><br></div></div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div bgcolor="#FFFFFF" text="#000000"><div><div>
    <div>On 7/3/15 5:41 PM, Mariano Martinez
      Peck wrote:<br>
    </div>
    </div></div><blockquote type="cite"><div><div>
      <div dir="ltr">Hi guys,
        <div><br>
        </div>
        <div>I am having a hard time to see why my seaside sessions are
          not being GCed nor unregistered. </div>
        <div>First of all, when I register my app, I set a timeout. I
          even tried with 1 minute timeout:</div>
        <div><b><br>
          </b></div>
        <div><b>app cache expiryPolicy configuration at: #cacheTimeout
            put: 60</b></div>
        <div><br>
        </div>
        <div>I put a <b>halt in MySessionSubclass &gt;&gt;
            #unregistered</b> (which then calls super).</div>
        <div><br>
        </div>
        <div>I have seen many seaside things around:</div>
        <div><br>
        </div>
        <div>
          <div>WARenderVisitor instanceCount -&gt; 77.</div>
          <div>WAHtmlCanvas instanceCount -&gt; 1061.</div>
          <div>JQueryClass instanceCount -&gt; 13492.</div>
          <div>WACallbackRegistry instanceCount -&gt; 77.</div>
        </div>
        <div>MySessionSubclass -&gt; 12.</div>
        <div>.....</div>
        <div><br>
        </div>
        <div>As you can see, I have plenty of memory around callbacks
          registries, renders, visitors, sessions etc... If I try to see
          which sessions were expired:</div>
        <div><br>
        </div>
        <div>
          <div><b>MySessionSubclass allInstances select: [ :each | (each
              instVarNamed: &#39;parent&#39;) isNil ]   -&gt; #()  </b></div>
        </div>
        <div><br>
        </div>
        <div>The &#39;parent&#39; instVar there is because &quot;super unregistered&quot;
          does that and I don&#39;t know another way to check if a session
          is expired or not.</div>
        <div><br>
        </div>
        <div>Finally, the only way I have to get rid of everything is
          this way:</div>
        <div><br>
        </div>
        <div>
          <div><b>WAApplication allInstances do: [ :each | each clear ].</b><br>
          </div>
          <div><span style="white-space:pre-wrap"><br>
            </span></div>
          <div><span style="white-space:pre-wrap">But then, that
              clears all sessions...even the active ones which I don&#39;t
              want. <b>So.... how can I force the GC of all none
                expired sessions? And why my sessions are not receiving
                #unregistered ?</b></span></div>
        </div>
        <div><span style="white-space:pre-wrap"><b><br>
            </b></span></div>
        <div><span style="white-space:pre-wrap">Note also that in my
            example the instanceCount of MySessionSubclass is bigger
            than 10, because somewhere I read that Seaside would start
            cleaning sessions upon 10th. </span></div>
        <div><span style="white-space:pre-wrap"><br>
          </span></div>
        <div><span style="white-space:pre-wrap">So.... any idea?
            What am I doing wrong?</span></div>
        <div><span style="white-space:pre-wrap"><br>
          </span></div>
        <div><span style="white-space:pre-wrap">Thanks in advance, </span></div>
        <div><span style="white-space:pre-wrap"><br>
          </span></div>
        <div><br>
        </div>
        <div><br>
        </div>
        <div>
          <div><br>
          </div>
          -- <br>
          <div>Mariano<br>
            <a href="http://marianopeck.wordpress.com" target="_blank">http://marianopeck.wordpress.com</a><br>
          </div>
        </div>
      </div>
      <br>
      <fieldset></fieldset>
      <br>
      </div></div><pre>_______________________________________________
seaside mailing list
<a href="mailto:seaside@lists.squeakfoundation.org" target="_blank">seaside@lists.squeakfoundation.org</a>
<a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a>
</pre>
    </blockquote>
    <br>
  </div>

<br>_______________________________________________<br>
seaside mailing list<br>
<a href="mailto:seaside@lists.squeakfoundation.org" target="_blank">seaside@lists.squeakfoundation.org</a><br>
<a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" rel="noreferrer" target="_blank">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div>Mariano<br><a href="http://marianopeck.wordpress.com" target="_blank">http://marianopeck.wordpress.com</a><br></div>
</div></div>