Search in sources :

Example 1 with PageRequest

use of com.webank.wedatasphere.qualitis.request.PageRequest in project Qualitis by WeBankFinTech.

the class RuleQueryController method query.

@POST
@Path("query")
@Produces(MediaType.APPLICATION_JSON)
@Consumes(MediaType.APPLICATION_JSON)
public GeneralResponse<?> query(RuleQueryRequest param, @Context HttpServletRequest request) {
    if (param == null) {
        param = new RuleQueryRequest();
    }
    // Get login user
    param.setUser(HttpUtils.getUserName(request));
    try {
        PageRequest pageRequest = new PageRequest();
        pageRequest.setPage(param.getPage());
        pageRequest.setSize(param.getSize());
        PageRequest.checkRequest(pageRequest);
        DataInfo<RuleQueryDataSource> results = new DataInfo<>();
        List<RuleQueryDataSource> ruleQueryDataSources = ruleQueryService.filter(pageRequest, param.getUser(), param.getCluster(), param.getDb(), param.getTable(), false);
        results.setContent(ruleQueryDataSources);
        List<RuleQueryDataSource> allRuleDataSource = ruleQueryService.filter(null, param.getUser(), param.getCluster(), param.getDb(), param.getTable(), true);
        results.setTotalCount(allRuleDataSource == null ? 0 : allRuleDataSource.size());
        LOG.info("[My DataSource] Query successfully. The number of results:{}", allRuleDataSource == null ? 0 : allRuleDataSource.size());
        return new GeneralResponse<>("200", "{&QUERY_SUCCESSFULLY}", results);
    } catch (Exception e) {
        LOG.error("[My DataSource] Query failed, internal error.", e);
        return new GeneralResponse<>("500", e.getMessage(), null);
    }
}
Also used : DataInfo(com.webank.wedatasphere.qualitis.metadata.response.DataInfo) GeneralResponse(com.webank.wedatasphere.qualitis.response.GeneralResponse) PageRequest(com.webank.wedatasphere.qualitis.request.PageRequest) RuleQueryRequest(com.webank.wedatasphere.qualitis.query.request.RuleQueryRequest) RuleQueryDataSource(com.webank.wedatasphere.qualitis.query.response.RuleQueryDataSource) MetaDataAcquireFailedException(com.webank.wedatasphere.qualitis.metadata.exception.MetaDataAcquireFailedException) UnExpectedRequestException(com.webank.wedatasphere.qualitis.exception.UnExpectedRequestException) Path(javax.ws.rs.Path) POST(javax.ws.rs.POST) Produces(javax.ws.rs.Produces) Consumes(javax.ws.rs.Consumes)

Example 2 with PageRequest

use of com.webank.wedatasphere.qualitis.request.PageRequest in project Qualitis by WeBankFinTech.

the class ApplicationServiceImpl method uploadDataSourceAnalysisResult.

@Override
public GeneralResponse<?> uploadDataSourceAnalysisResult(UploadResultRequest request) throws UnExpectedRequestException, IOException {
    // Login user permission.
    Long userId = HttpUtils.getUserId(httpServletRequest);
    User user = userDao.findById(userId);
    if (user == null) {
        throw new UnExpectedRequestException("User {&DOES_NOT_EXIST}");
    }
    UploadResultRequest.checkRequest(request);
    List<ApplicationClusterResponse> responses = (List<ApplicationClusterResponse>) getDataSource(new PageRequest(0, Integer.MAX_VALUE)).getData();
    List<String> tables = responses.stream().filter(cluster -> cluster.getClusterName().equals(request.getClusterName())).map(ApplicationClusterResponse::getDatabase).flatMap(database -> database.stream()).filter(databaseResponse -> databaseResponse.getDatabaseName().equals(request.getDatabaseName())).map(ApplicationDatabaseResponse::getTable).flatMap(table -> table.stream()).distinct().collect(Collectors.toList());
    if (StringUtils.isNotBlank(request.getTableName())) {
        tables.clear();
        tables.add(request.getTableName());
    }
    LOGGER.info("Start to write excel");
    StringBuffer fileName = new StringBuffer();
    fileName.append(linkisConfig.getUploadTmpPath()).append(File.separator).append(user.getUserName()).append("_").append(request.getClusterName()).append("_").append(request.getDatabaseName()).append("_").append(UUID.randomUUID().toString()).append(ExcelTypeEnum.XLSX.getValue());
    File tmpFile = new File(fileName.toString());
    writeExcelFile(tmpFile, tables, request);
    // Upload to HDFS
    ClusterInfo clusterInfo = clusterInfoDao.findByClusterName(request.getClusterName());
    if (clusterInfo == null) {
        throw new UnExpectedRequestException("Cluster info " + "[" + request.getClusterName() + "]" + "{&DOES_NOT_EXIST}");
    }
    // send request to get dbs
    String url = UriBuilder.fromUri(clusterInfo.getLinkisAddress()).path(linkisConfig.getPrefix()).path(linkisConfig.getUpload()).toString();
    CloseableHttpClient httpclient = HttpClients.createDefault();
    HttpPost httppost = new HttpPost(url);
    MultipartEntityBuilder multipartEntityBuilder = MultipartEntityBuilder.create();
    multipartEntityBuilder.setContentType(ContentType.MULTIPART_FORM_DATA);
    multipartEntityBuilder.setCharset(Charset.forName("UTF-8"));
    if (clusterInfo.getClusterType().endsWith(LINKIS_ONE_VERSION)) {
        multipartEntityBuilder.addTextBody("path", linkisConfig.getUploadPrefix() + LINKIS_ONE_UPLOAD_PREFIX + request.getHdfsPath());
    } else {
        multipartEntityBuilder.addTextBody("path", linkisConfig.getUploadPrefix() + request.getHdfsPath());
    }
    multipartEntityBuilder.addBinaryBody("file", tmpFile);
    httppost.addHeader("Token-User", user.getUserName());
    httppost.addHeader("Token-Code", clusterInfo.getLinkisToken());
    httppost.setEntity(multipartEntityBuilder.build());
    CloseableHttpResponse response = null;
    try {
        response = httpclient.execute(httppost);
    } catch (IOException e) {
        throw new UnExpectedRequestException("{&FAILED_TO_CALL_UPLOAD_API}");
    }
    int code = response.getStatusLine().getStatusCode();
    response.close();
    if (code != HttpStatus.SC_OK) {
        throw new UnExpectedRequestException("{&FAILED_TO_CALL_UPLOAD_API}");
    }
    boolean tmpDeleteFlag = tmpFile.delete();
    LOGGER.info("Delete tmp excel: " + tmpDeleteFlag);
    return new GeneralResponse<>(code + "", "{&SUCCESS_TO_UPLOAD_ANALYSIS_EXCEL}", code);
}
Also used : HttpPost(org.apache.http.client.methods.HttpPost) AlarmConfigStatusEnum(com.webank.wedatasphere.qualitis.constant.AlarmConfigStatusEnum) StringUtils(org.apache.commons.lang.StringUtils) LinkisConfig(com.webank.wedatasphere.qualitis.config.LinkisConfig) LoggerFactory(org.slf4j.LoggerFactory) HttpStatus(org.apache.http.HttpStatus) Autowired(org.springframework.beans.factory.annotation.Autowired) Application(com.webank.wedatasphere.qualitis.entity.Application) ProjectUserDao(com.webank.wedatasphere.qualitis.project.dao.ProjectUserDao) ApplicationDatabaseResponse(com.webank.wedatasphere.qualitis.response.ApplicationDatabaseResponse) GeneralResponse(com.webank.wedatasphere.qualitis.response.GeneralResponse) ClusterInfoDao(com.webank.wedatasphere.qualitis.dao.ClusterInfoDao) FilterDataSourceRequest(com.webank.wedatasphere.qualitis.request.FilterDataSourceRequest) HttpUtils(com.webank.wedatasphere.qualitis.util.HttpUtils) Task(com.webank.wedatasphere.qualitis.entity.Task) TaskRuleAlarmConfig(com.webank.wedatasphere.qualitis.entity.TaskRuleAlarmConfig) Map(java.util.Map) ApplicationClusterResponse(com.webank.wedatasphere.qualitis.response.ApplicationClusterResponse) UriBuilder(javax.ws.rs.core.UriBuilder) GetAllResponse(com.webank.wedatasphere.qualitis.response.GetAllResponse) Path(java.nio.file.Path) RestTemplate(org.springframework.web.client.RestTemplate) Context(javax.ws.rs.core.Context) MultipartEntityBuilder(org.apache.http.entity.mime.MultipartEntityBuilder) PageRequest(com.webank.wedatasphere.qualitis.request.PageRequest) UploadResultRequest(com.webank.wedatasphere.qualitis.request.UploadResultRequest) FilterAdvanceRequest(com.webank.wedatasphere.qualitis.request.FilterAdvanceRequest) ContentType(org.apache.http.entity.ContentType) UUID(java.util.UUID) Collectors(java.util.stream.Collectors) FileNotFoundException(java.io.FileNotFoundException) TaskRuleSimpleDao(com.webank.wedatasphere.qualitis.dao.TaskRuleSimpleDao) ExcelTypeEnum(com.alibaba.excel.support.ExcelTypeEnum) List(java.util.List) Sheet(com.alibaba.excel.metadata.Sheet) ClusterInfo(com.webank.wedatasphere.qualitis.entity.ClusterInfo) MetaDataClient(com.webank.wedatasphere.qualitis.metadata.client.MetaDataClient) UnExpectedRequestException(com.webank.wedatasphere.qualitis.exception.UnExpectedRequestException) HttpClients(org.apache.http.impl.client.HttpClients) BeanUtils(org.springframework.beans.BeanUtils) TaskStatusEnum(com.webank.wedatasphere.qualitis.constant.TaskStatusEnum) ApplicationResponse(com.webank.wedatasphere.qualitis.response.ApplicationResponse) HashMap(java.util.HashMap) FilterProjectRequest(com.webank.wedatasphere.qualitis.request.FilterProjectRequest) FilterStatusRequest(com.webank.wedatasphere.qualitis.request.FilterStatusRequest) ProjectDao(com.webank.wedatasphere.qualitis.project.dao.ProjectDao) ArrayList(java.util.ArrayList) ExcelWriter(com.alibaba.excel.ExcelWriter) HttpServletRequest(javax.servlet.http.HttpServletRequest) User(com.webank.wedatasphere.qualitis.entity.User) CheckTemplateEnum(com.webank.wedatasphere.qualitis.rule.constant.CheckTemplateEnum) Charset(java.nio.charset.Charset) TaskDao(com.webank.wedatasphere.qualitis.dao.TaskDao) CloseableHttpResponse(org.apache.http.client.methods.CloseableHttpResponse) Service(org.springframework.stereotype.Service) ApplicationStatusEnum(com.webank.wedatasphere.qualitis.constant.ApplicationStatusEnum) CompareTypeEnum(com.webank.wedatasphere.qualitis.rule.constant.CompareTypeEnum) ApplicationService(com.webank.wedatasphere.qualitis.service.ApplicationService) TaskResult(com.webank.wedatasphere.qualitis.entity.TaskResult) OutputStream(java.io.OutputStream) CloseableHttpClient(org.apache.http.impl.client.CloseableHttpClient) Logger(org.slf4j.Logger) Files(java.nio.file.Files) RuleMetric(com.webank.wedatasphere.qualitis.entity.RuleMetric) TaskDataSourceDao(com.webank.wedatasphere.qualitis.dao.TaskDataSourceDao) ExcelResult(com.webank.wedatasphere.qualitis.excel.ExcelResult) FileOutputStream(java.io.FileOutputStream) IOException(java.io.IOException) File(java.io.File) TaskRuleSimple(com.webank.wedatasphere.qualitis.entity.TaskRuleSimple) ExcelSheetName(com.webank.wedatasphere.qualitis.project.constant.ExcelSheetName) Paths(java.nio.file.Paths) ApplicationDao(com.webank.wedatasphere.qualitis.dao.ApplicationDao) UserDao(com.webank.wedatasphere.qualitis.dao.UserDao) TaskResultDao(com.webank.wedatasphere.qualitis.dao.TaskResultDao) TaskDataSource(com.webank.wedatasphere.qualitis.entity.TaskDataSource) UnExpectedRequestException(com.webank.wedatasphere.qualitis.exception.UnExpectedRequestException) CloseableHttpClient(org.apache.http.impl.client.CloseableHttpClient) HttpPost(org.apache.http.client.methods.HttpPost) User(com.webank.wedatasphere.qualitis.entity.User) MultipartEntityBuilder(org.apache.http.entity.mime.MultipartEntityBuilder) ApplicationClusterResponse(com.webank.wedatasphere.qualitis.response.ApplicationClusterResponse) IOException(java.io.IOException) GeneralResponse(com.webank.wedatasphere.qualitis.response.GeneralResponse) PageRequest(com.webank.wedatasphere.qualitis.request.PageRequest) ClusterInfo(com.webank.wedatasphere.qualitis.entity.ClusterInfo) CloseableHttpResponse(org.apache.http.client.methods.CloseableHttpResponse) List(java.util.List) ArrayList(java.util.ArrayList) File(java.io.File)

Example 3 with PageRequest

use of com.webank.wedatasphere.qualitis.request.PageRequest in project Qualitis by WeBankFinTech.

the class RuleMetricServiceImpl method download.

@Override
public GeneralResponse<?> download(DownloadRuleMetricRequest request, HttpServletResponse response) throws UnExpectedRequestException, IOException, WriteExcelException, PermissionDeniedRequestException {
    // Check rule metric IDs permission.
    PageRequest pageRequest = new PageRequest(0, Integer.MAX_VALUE);
    List<RuleMetricResponse> ownRuleMetric = getAllRuleMetric(pageRequest).getData().getData().stream().collect(Collectors.toList());
    if (ownRuleMetric.size() <= 0 || ownRuleMetric.size() >= MAX_RULE_METRIC_COUNT) {
        throw new UnExpectedRequestException("The number of metrics is illegal");
    }
    List<Long> downloadIds = request.getRuleMetricIds();
    List<Long> ownIds = ownRuleMetric.stream().map(RuleMetricResponse::getId).collect(Collectors.toList());
    if (ownIds.containsAll(downloadIds)) {
        List<RuleMetricResponse> downloadRuleMetric = ownRuleMetric.stream().filter(ruleMetricResponse -> downloadIds.contains(ruleMetricResponse.getId())).collect(Collectors.toList());
        List<ExcelRuleMetric> excelRuleMetrics = new ArrayList<>(downloadRuleMetric.size());
        for (RuleMetricResponse ruleMetricResponse : downloadRuleMetric) {
            ExcelRuleMetric excelRuleMetric = new ExcelRuleMetric();
            excelRuleMetric.setName(ruleMetricResponse.getName());
            excelRuleMetric.setChName(ruleMetricResponse.getCnName());
            excelRuleMetric.setMetricDesc(ruleMetricResponse.getMetricDesc());
            int bussCode = ruleMetricResponse.getBussCode();
            excelRuleMetric.setDimension(bussCode + "");
            if (RuleMetricBussCodeEnum.SUBSYSTEM.getCode().equals(bussCode)) {
                excelRuleMetric.setFullCnName(ruleMetricResponse.getFullCnName());
                excelRuleMetric.setSubSystemName(ruleMetricResponse.getSubSystemName());
                excelRuleMetric.setSubSystemId(String.valueOf(ruleMetricResponse.getSubSystemId()));
            } else if (RuleMetricBussCodeEnum.PRODUCT.getCode().equals(bussCode)) {
                excelRuleMetric.setProductId(ruleMetricResponse.getProductId());
                excelRuleMetric.setProductName(ruleMetricResponse.getProductName());
            } else if (RuleMetricBussCodeEnum.CUSTOM.getCode().equals(bussCode)) {
                excelRuleMetric.setBussCustom(ruleMetricResponse.getBussCustom());
            }
            excelRuleMetric.setFrequency(String.valueOf(ruleMetricResponse.getFrequency()));
            excelRuleMetric.setDevDepartmentName(ruleMetricResponse.getDevDepartmentName());
            excelRuleMetric.setOpsDepartmentName(ruleMetricResponse.getOpsDepartmentName());
            excelRuleMetric.setDepartmentCode(ruleMetricResponse.getDepartmentCode());
            excelRuleMetric.setDepartmentName(ruleMetricResponse.getDepartmentName());
            excelRuleMetric.setAvailable(ruleMetricResponse.getAvailable());
            excelRuleMetric.setEnCode(ruleMetricResponse.getEnCode());
            excelRuleMetric.setType(ruleMetricResponse.getType());
            excelRuleMetrics.add(excelRuleMetric);
        }
        String fileName = "batch_metrics_export_" + FILE_DATE_FORMATTER.format(new Date());
        fileName = URLEncoder.encode(fileName, "UTF-8");
        response.setContentType("application/octet-stream");
        response.addHeader("Content-Disposition", "attachment;filename*=UTF-8''" + fileName);
        response.addHeader("Access-Control-Expose-Headers", "Content-Disposition");
        OutputStream outputStream = response.getOutputStream();
        writeExcelToOutput(excelRuleMetrics, outputStream);
        outputStream.flush();
    } else {
        throw new PermissionDeniedRequestException("HAS_NO_PERMISSION_TO_ACCESS", 403);
    }
    LOGGER.info("Succeed to download all rule metrics in type of excel");
    return null;
}
Also used : StringUtils(org.apache.commons.lang.StringUtils) FormDataContentDisposition(org.glassfish.jersey.media.multipart.FormDataContentDisposition) Date(java.util.Date) LoggerFactory(org.slf4j.LoggerFactory) Autowired(org.springframework.beans.factory.annotation.Autowired) PermissionDeniedRequestException(com.webank.wedatasphere.qualitis.exception.PermissionDeniedRequestException) HiveRuleDetail(com.webank.wedatasphere.qualitis.project.response.HiveRuleDetail) RuleMetricValueResponse(com.webank.wedatasphere.qualitis.response.RuleMetricValueResponse) GeneralResponse(com.webank.wedatasphere.qualitis.response.GeneralResponse) AlarmConfig(com.webank.wedatasphere.qualitis.rule.entity.AlarmConfig) RuleMetricDao(com.webank.wedatasphere.qualitis.dao.RuleMetricDao) HttpUtils(com.webank.wedatasphere.qualitis.util.HttpUtils) GetAllResponse(com.webank.wedatasphere.qualitis.response.GetAllResponse) RuleMetricBussCodeEnum(com.webank.wedatasphere.qualitis.constant.RuleMetricBussCodeEnum) Context(javax.ws.rs.core.Context) ExcelReader(com.alibaba.excel.ExcelReader) PageRequest(com.webank.wedatasphere.qualitis.request.PageRequest) ModifyRuleMetricRequest(com.webank.wedatasphere.qualitis.request.ModifyRuleMetricRequest) Department(com.webank.wedatasphere.qualitis.entity.Department) Set(java.util.Set) RuleMetricDepartmentUser(com.webank.wedatasphere.qualitis.entity.RuleMetricDepartmentUser) Collectors(java.util.stream.Collectors) ExecutionManagerImpl(com.webank.wedatasphere.qualitis.submitter.impl.ExecutionManagerImpl) ExcelTypeEnum(com.alibaba.excel.support.ExcelTypeEnum) List(java.util.List) RuleMetricResponse(com.webank.wedatasphere.qualitis.response.RuleMetricResponse) Sheet(com.alibaba.excel.metadata.Sheet) CommonChecker(com.webank.wedatasphere.qualitis.project.request.CommonChecker) UnExpectedRequestException(com.webank.wedatasphere.qualitis.exception.UnExpectedRequestException) RoleDefaultTypeEnum(com.webank.wedatasphere.qualitis.rule.constant.RoleDefaultTypeEnum) UserRole(com.webank.wedatasphere.qualitis.entity.UserRole) FastDateFormat(org.apache.commons.lang.time.FastDateFormat) RuleMetricTypeConfigDao(com.webank.wedatasphere.qualitis.dao.RuleMetricTypeConfigDao) RuleMetricQueryRequest(com.webank.wedatasphere.qualitis.request.RuleMetricQueryRequest) UserRoleDao(com.webank.wedatasphere.qualitis.dao.UserRoleDao) Rule(com.webank.wedatasphere.qualitis.rule.entity.Rule) ArrayList(java.util.ArrayList) ExcelWriter(com.alibaba.excel.ExcelWriter) RuleMetricConditionResponse(com.webank.wedatasphere.qualitis.response.RuleMetricConditionResponse) RuleMetricLevelEnum(com.webank.wedatasphere.qualitis.constant.RuleMetricLevelEnum) HttpServletRequest(javax.servlet.http.HttpServletRequest) User(com.webank.wedatasphere.qualitis.entity.User) ExcelRuleMetricListener(com.webank.wedatasphere.qualitis.excel.ExcelRuleMetricListener) ExcelRuleMetric(com.webank.wedatasphere.qualitis.project.excel.ExcelRuleMetric) CollectionUtils(org.apache.commons.collections.CollectionUtils) Propagation(org.springframework.transaction.annotation.Propagation) Service(org.springframework.stereotype.Service) RuleMetricService(com.webank.wedatasphere.qualitis.service.RuleMetricService) TaskResult(com.webank.wedatasphere.qualitis.entity.TaskResult) DownloadRuleMetricRequest(com.webank.wedatasphere.qualitis.request.DownloadRuleMetricRequest) RoleService(com.webank.wedatasphere.qualitis.service.RoleService) OutputStream(java.io.OutputStream) Logger(org.slf4j.Logger) RuleMetric(com.webank.wedatasphere.qualitis.entity.RuleMetric) HttpServletResponse(javax.servlet.http.HttpServletResponse) RuleMetricTypeConfig(com.webank.wedatasphere.qualitis.entity.RuleMetricTypeConfig) IOException(java.io.IOException) AddRuleMetricRequest(com.webank.wedatasphere.qualitis.request.AddRuleMetricRequest) DataInfo(com.webank.wedatasphere.qualitis.metadata.response.DataInfo) URLEncoder(java.net.URLEncoder) ExcelSheetName(com.webank.wedatasphere.qualitis.project.constant.ExcelSheetName) RuleDao(com.webank.wedatasphere.qualitis.rule.dao.RuleDao) RuleMetricDepartmentUserDao(com.webank.wedatasphere.qualitis.dao.RuleMetricDepartmentUserDao) UserDao(com.webank.wedatasphere.qualitis.dao.UserDao) TaskResultDao(com.webank.wedatasphere.qualitis.dao.TaskResultDao) WriteExcelException(com.webank.wedatasphere.qualitis.rule.exception.WriteExcelException) InputStream(java.io.InputStream) Transactional(org.springframework.transaction.annotation.Transactional) ExcelRuleMetric(com.webank.wedatasphere.qualitis.project.excel.ExcelRuleMetric) UnExpectedRequestException(com.webank.wedatasphere.qualitis.exception.UnExpectedRequestException) PermissionDeniedRequestException(com.webank.wedatasphere.qualitis.exception.PermissionDeniedRequestException) OutputStream(java.io.OutputStream) ArrayList(java.util.ArrayList) Date(java.util.Date) RuleMetricResponse(com.webank.wedatasphere.qualitis.response.RuleMetricResponse) PageRequest(com.webank.wedatasphere.qualitis.request.PageRequest)

Example 4 with PageRequest

use of com.webank.wedatasphere.qualitis.request.PageRequest in project Qualitis by WeBankFinTech.

the class ProjectUserController method getUser.

@GET
@Path("/user")
@Produces(MediaType.APPLICATION_JSON)
@Consumes(MediaType.APPLICATION_JSON)
public GeneralResponse<?> getUser(@Context HttpServletRequest httpServletRequest) throws UnExpectedRequestException {
    try {
        Long userId = HttpUtils.getUserId(httpServletRequest);
        PageRequest pageRequest = new PageRequest(0, Integer.MAX_VALUE);
        return projectUserService.getAllUsers(pageRequest, userId);
    } catch (UnExpectedRequestException e) {
        LOGGER.error(e.getMessage(), e);
        throw e;
    } catch (Exception e) {
        LOGGER.error("Failed to find users, caused by system error: {}", e.getMessage());
        return new GeneralResponse<>("500", "{&FAILED_TO_FIND_ALL_USERS}", null);
    }
}
Also used : UnExpectedRequestException(com.webank.wedatasphere.qualitis.exception.UnExpectedRequestException) PageRequest(com.webank.wedatasphere.qualitis.request.PageRequest) PermissionDeniedRequestException(com.webank.wedatasphere.qualitis.exception.PermissionDeniedRequestException) UnExpectedRequestException(com.webank.wedatasphere.qualitis.exception.UnExpectedRequestException) Path(javax.ws.rs.Path) Produces(javax.ws.rs.Produces) Consumes(javax.ws.rs.Consumes) GET(javax.ws.rs.GET)

Aggregations

UnExpectedRequestException (com.webank.wedatasphere.qualitis.exception.UnExpectedRequestException)4 PageRequest (com.webank.wedatasphere.qualitis.request.PageRequest)4 GeneralResponse (com.webank.wedatasphere.qualitis.response.GeneralResponse)3 ExcelWriter (com.alibaba.excel.ExcelWriter)2 Sheet (com.alibaba.excel.metadata.Sheet)2 ExcelTypeEnum (com.alibaba.excel.support.ExcelTypeEnum)2 TaskResultDao (com.webank.wedatasphere.qualitis.dao.TaskResultDao)2 UserDao (com.webank.wedatasphere.qualitis.dao.UserDao)2 RuleMetric (com.webank.wedatasphere.qualitis.entity.RuleMetric)2 TaskResult (com.webank.wedatasphere.qualitis.entity.TaskResult)2 User (com.webank.wedatasphere.qualitis.entity.User)2 PermissionDeniedRequestException (com.webank.wedatasphere.qualitis.exception.PermissionDeniedRequestException)2 ExcelSheetName (com.webank.wedatasphere.qualitis.project.constant.ExcelSheetName)2 GetAllResponse (com.webank.wedatasphere.qualitis.response.GetAllResponse)2 HttpUtils (com.webank.wedatasphere.qualitis.util.HttpUtils)2 IOException (java.io.IOException)2 OutputStream (java.io.OutputStream)2 ArrayList (java.util.ArrayList)2 List (java.util.List)2 Collectors (java.util.stream.Collectors)2