Bug 1404 - Ensure primary applications such as testpmd are properly cleaned up
Summary: Ensure primary applications such as testpmd are properly cleaned up
Status: IN_PROGRESS
Alias: None
Product: DPDK
Classification: Unclassified
Component: DTS (show other bugs)
Version: unspecified
Hardware: All All
: High critical
Target Milestone: ---
Assignee: Jeremy Spewock
URL:
Depends on:
Blocks:
 
Reported: 2024-03-19 19:47 CET by Jeremy Spewock
Modified: 2024-03-27 16:07 CET (History)
2 users (show)



Attachments

Description Jeremy Spewock 2024-03-19 19:47:53 CET
Right now we are relying on the garbage collector to clean up interactive shells after they fall out of scope, and this is fine for applications like a python shell where it doesn't really matter if we run multiple at once. However, some applications (such as primary applications in DPDK) cannot run if there is an instance of another specific application running. Because of this, we need to be able to guarantee that these critical applications close at certain times but the python garbage collector makes no guarantees for when it cleans up these objects. 

One of the ways to make this more explicit which is being looked into right now is a context manager. A context manager will help guarantee that when the application is needed in its context block, it will be running, but as soon as we exit the block (whether through exceptions being raised, reaching the end of the block, or anything that would take the code out of that scope) the application is properly cleaned up. This allows many more guarantees for when these critical applications are running and exactly when they close.
Comment 1 Jeremy Spewock 2024-03-27 16:07:26 CET
I've started work on this and have a patch that uses the context manager approach which I have just recently managed to get functional. A patch for this will hit the mailing list very early in the next release.

Note You need to log in before you can comment on or make changes to this bug.