class DatabaseSetController {

    @RequestMapping(value = "/delete", method = RequestMethod.DELETE)
    public ServiceResult<String> delete(@Validated(DeleteDbSet.class) @RequestBody DatabaseSet dbset, @CurrentUser LoginUser user, Errors errors) throws Exception {
        ValidateResult validateRes = databaseSetService.validatePermision(user, errors)
                .addAssert(() -> databaseSetService.deleteCheck(dbset.getId()))
                .addAssert(() -> databaseSetService.deleteDataCenter(user, dbset))
                .addAssert(() -> databaseSetService.deleteDatabaseSet(dbset.getId()), message.db_message_update_operation_failed).validate();
        if (!validateRes.isValid()) {
            return ServiceResult.fail(validateRes.getSummarize());
        }
        return ServiceResult.success();
    }

}