class SetupDataBaseController {

    @RequestMapping(value = "tableConsistentCheck", method = RequestMethod.POST)
    public ServiceResult tableConsistentCheck(@RequestBody ConnectionRequest connectionRequest) {
        try {
            //if (setupDBService.initializeDatasourceXml(connectionRequest.getDb_address(), connectionRequest.getDb_port(), connectionRequest.getDb_user(), connectionRequest.getDb_password(), connectionRequest.getDb_catalog())) {
            boolean result = setupDBService.tableConsistent(connectionRequest.getDb_catalog());
            if (result) {
                return ServiceResult.success();
            }
            //}
            return ServiceResult.fail();
        } catch (Exception e) {
            log.error("SetupDBController.tableConsistentCheck : {}", StringUtil.getMessage(e));
            return ServiceResult.fail(StringUtil.getMessage(e));
        }
    }

}