def run()

in backend/bms_app/services/operations/wave.py [0:0]


    def run(self, wave_id, db_ids=None):
        wave = Wave.query.with_for_update().get(wave_id)
        self._validate_wave_status(wave)

        db_mappings_objects = get_wave_db_mappings_objects(
            wave_id=wave_id,
            db_ids=db_ids,
            filter_deployable=self.FILTER_DEPLOYABLE_DBS_ONLY
        )
        self._validate_db_mappings_objects(db_mappings_objects)

        self._set_wave_status_running(wave)

        operation = self._create_operation_model(wave_id)

        self._log(operation, db_mappings_objects)

        self._create_operation_details_models(operation, db_mappings_objects)

        try:
            self._start_pre_deployment(
                wave,
                operation,
                db_mappings_objects
            )
        except Exception as e:
            print(e)
            logger.exception(
                'error starting %s %s', operation.operation_type.value, wave_id
            )
            self._handle_pre_deployment_failure(operation)

        self._post_operation_action(db_mappings_objects)

        db.session.commit()