You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@yunikorn.apache.org by "Wilfred Spiegelenburg (Jira)" <ji...@apache.org> on 2022/12/07 03:43:00 UTC

[jira] [Resolved] (YUNIKORN-1445) partition cleanup: code refactor

     [ https://issues.apache.org/jira/browse/YUNIKORN-1445?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Wilfred Spiegelenburg resolved YUNIKORN-1445.
---------------------------------------------
    Fix Version/s: 1.2.0
       Resolution: Fixed

> partition cleanup: code refactor
> --------------------------------
>
>                 Key: YUNIKORN-1445
>                 URL: https://issues.apache.org/jira/browse/YUNIKORN-1445
>             Project: Apache YuniKorn
>          Issue Type: Improvement
>          Components: core - common
>            Reporter: Wilfred Spiegelenburg
>            Assignee: Wilfred Spiegelenburg
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 1.2.0
>
>
> Multiple issues:
> GetAppsInTerminatedState is dead code should be removed
> GetAppsByState, GetRejectedAppsByState & GetCompletedAppsByState: only called from cleanupExpiredApps with the expired state, and we only need the applicationID list (which is the key in the map) not the whole app.
> None of those 3 methods should be exported.
> cleanupExpiredApps: should only request the keys for the map and not the objects itself, removes accessing the application to get the ID during the iteration. Removes one indirection to get the ID and a possible race condition.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@yunikorn.apache.org
For additional commands, e-mail: dev-help@yunikorn.apache.org