Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue 408 fix, Memory leak was generated from Event #524

Open
wants to merge 18 commits into
base: master
Choose a base branch
from

Commits on Sep 11, 2018

  1. eventlet#408, fix for MemLeak on event exceptions

    changes event.py:
      - self._result and self._exc should not be class's static attributes
      - self._exc  should not store exception trace, instead if exception occurred True
      - self._exc  do not need to store exception trace, the same exception is called with the schedule_call_global for self._waiters timers
      - no need to throw self._exc on wait, it is thrown on the switch
    
      changes greenthread.py: (adjustments)
       - use of super for init inherited class
       - main method, try send, except send_exception and raise, and finally _resolve_links
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 11, 2018
    Configuration menu
    Copy the full SHA
    315c277 View commit details
    Browse the repository at this point in the history

Commits on Sep 12, 2018

  1. eventlet#408, Test for fix for MemLeak on event exceptions

    added test_no_mem_leaks to event_test.py
    added tox.ini dependencies objgraph==3.4.0
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    53f00cb View commit details
    Browse the repository at this point in the history
  2. eventlet#408, fix for MemLeak on event exceptions

    changes greenthread.py: (adjustments)
       - use of super for init inherited class
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    4e293eb View commit details
    Browse the repository at this point in the history
  3. eventlet#408, fix for MemLeak on event exceptions …

    changes event.py:
    
    self._result and self._exc should not be class's static attributes (the Values were passing between the different Event instances)
    self._exc is set back to None on last waiter has it's results (references kept them self, causing GC not to collect, Event has _exc and _exc has trace frames object in touched)
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    361210d View commit details
    Browse the repository at this point in the history
  4. Test for fix for MemLeak on event exceptions …

     - added test_no_mem_leaks to event_test.py
     - added tox.ini dependencies objgraph==3.4.0
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    99350ca View commit details
    Browse the repository at this point in the history
  5. eventlet#408, fix for MemLeak on event exceptions

     changes greenthread.py: (adjustments)
       - use of super for init inherited class
       - main method, _resolve_links finally
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    9dce8c2 View commit details
    Browse the repository at this point in the history
  6. eventlet#408, fix for MemLeak on event exceptions

    changes event.py:
      - self._result and self._exc should not be class's static attributes
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    454a897 View commit details
    Browse the repository at this point in the history
  7. Merge branch 'issue-408' of https://github.com/kashirin-alex/eventlet

    …into 408-event-memleak
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    
    # Conflicts:
    #	eventlet/event.py
    #	eventlet/greenthread.py
    #	tests/event_test.py
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    0291f64 View commit details
    Browse the repository at this point in the history
  8. eventlet#408, fix for MemLeak on event exceptions

    changes event.py:
     - self._exc should not store exception trace, instead if exception occurred self._exc=True (references kept them self, causing GC not to collect, Event has _exc and _exc has trace frames object in touched)
     - self._exc do not need to store exception trace, the same exception is called with the schedule_call_global for self._waiters timers
     - a wait on a triggered event is returning _results (without throw) None is exception/timeout
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    3a59e79 View commit details
    Browse the repository at this point in the history
  9. eventlet#408, fix for MemLeak on event exceptions

    changes event.py:
     - self._exc should not store exception trace, instead if exception occurred self._exc=True (references kept them self, causing GC not to collect, Event has _exc and _exc has trace frames object in touched)
     - self._exc do not need to store exception trace, the same exception is called with the schedule_call_global for self._waiters timers
     - a wait on a triggered event with sellf._exc will throw current (GreenletExit)
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    1b51236 View commit details
    Browse the repository at this point in the history
  10. eventlet#408, fix for MemLeak on event exceptions

    changes event.py:
     - self._exc should not store exception trace, instead if exception occurred self._exc=True (references kept them self, causing GC not to collect, Event has _exc and _exc has trace frames object in touched)
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    9888aa6 View commit details
    Browse the repository at this point in the history
  11. event_test, clear threads not del

    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    1d4cc2a View commit details
    Browse the repository at this point in the history
  12. event_test, version by sys.version_info.major and count obj refs prio…

    …r test use
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    98e07fd View commit details
    Browse the repository at this point in the history
  13. event_test, version by sys.version_info.major and count obj refs prio…

    …r test use
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    e0c12b6 View commit details
    Browse the repository at this point in the history
  14. event_test, version by sys.version_info.major and count obj refs prio…

    …r test use
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    a2c8e6d View commit details
    Browse the repository at this point in the history
  15. event_test, version by sys.version_info.major and count obj refs prio…

    …r test use
    
    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    b985825 View commit details
    Browse the repository at this point in the history
  16. event_test, some counting info with assert

    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    a55b2e9 View commit details
    Browse the repository at this point in the history
  17. event_test, some counting info with assert

    Signed-off-by: Kashirin Alex <kashirin.alex@gmail.com>
    kashirin-alex committed Sep 12, 2018
    Configuration menu
    Copy the full SHA
    0ee4c90 View commit details
    Browse the repository at this point in the history