Merge "Remove unused lifecycle parameters from perform_app_upload and perform_app_abort of kube_app methods"

This commit is contained in:
Zuul 2024-12-13 18:01:15 +00:00 committed by Gerrit Code Review
commit d4c5c7ab0e
3 changed files with 5 additions and 8 deletions

View File

@ -265,7 +265,6 @@ class KubeAppController(rest.RestController):
pecan.request.rpcapi.perform_app_upload(pecan.request.context,
new_app, tarfile_path,
lifecycle_hook_info=lifecycle_hook_info,
images=images)
return KubeApp.convert_with_links(new_app)
@ -430,7 +429,7 @@ class KubeAppController(rest.RestController):
lifecycle_hook_info.mode = constants.APP_LIFECYCLE_MODE_MANUAL
pecan.request.rpcapi.perform_app_abort(pecan.request.context,
db_app, lifecycle_hook_info=lifecycle_hook_info)
db_app)
return KubeApp.convert_with_links(db_app)
@cutils.synchronized(LOCK_NAME)

View File

@ -2060,7 +2060,7 @@ class AppOperator(object):
LOG.error("Application %s recover to version %s aborted!"
% (old_app.name, old_app.version))
def perform_app_upload(self, rpc_app, tarfile, lifecycle_hook_info_app_upload, images=False):
def perform_app_upload(self, rpc_app, tarfile, images=False):
"""Process application upload request
This method validates the application manifest. If Helm charts are
@ -2070,7 +2070,6 @@ class AppOperator(object):
:param rpc_app: application object in the RPC request
:param tarfile: location of application tarfile
:param lifecycle_hook_info_app_upload: LifecycleHookInfo object
:param images: save application images in the registry as part of app upload
"""
@ -3252,7 +3251,7 @@ class AppOperator(object):
app = AppOperator.Application(rpc_app)
return app.active
def perform_app_abort(self, rpc_app, lifecycle_hook_info_app_abort):
def perform_app_abort(self, rpc_app):
"""Process application abort request
This method retrieves the latest application status from the
@ -3262,7 +3261,6 @@ class AppOperator(object):
next opportunity.
:param rpc_app: application object in the RPC request
:param lifecycle_hook_info_app_abort: LifecycleHookInfo object
"""

View File

@ -17366,7 +17366,7 @@ class ConductorManager(service.PeriodicService):
"""
lifecycle_hook_info_app_upload.operation = constants.APP_UPLOAD_OP
self._app.perform_app_upload(rpc_app, tarfile, lifecycle_hook_info_app_upload, images)
self._app.perform_app_upload(rpc_app, tarfile, images)
self._app.load_application_metadata_from_file(rpc_app)
# Perform post upload operation actions
@ -17494,7 +17494,7 @@ class ConductorManager(service.PeriodicService):
"""
lifecycle_hook_info_app_abort.operation = constants.APP_ABORT_OP
return self._app.perform_app_abort(rpc_app, lifecycle_hook_info_app_abort)
return self._app.perform_app_abort(rpc_app)
def perform_app_delete(self, context, rpc_app, lifecycle_hook_info_app_delete):
"""Handling of application delete request (via AppOperator)