@ -34,11 +34,11 @@ import static org.apache.dolphinscheduler.api.enums.Status.SWITCH_PROCESS_DEFINI
import static org.apache.dolphinscheduler.api.enums.Status.UPDATE_PROCESS_DEFINITION_ERROR ;
import static org.apache.dolphinscheduler.api.enums.Status.VERIFY_PROCESS_DEFINITION_NAME_UNIQUE_ERROR ;
import org.apache.dolphinscheduler.api.aspect.AccessLogAnnotation ;
import org.apache.dolphinscheduler.api.enums.Status ;
import org.apache.dolphinscheduler.api.exceptions.ApiException ;
import org.apache.dolphinscheduler.api.service.ProcessDefinitionService ;
import org.apache.dolphinscheduler.api.service.ProcessDefinitionVersionService ;
import org.apache.dolphinscheduler.api.utils.RegexUtils ;
import org.apache.dolphinscheduler.api.utils.Result ;
import org.apache.dolphinscheduler.common.Constants ;
import org.apache.dolphinscheduler.common.enums.ReleaseState ;
@ -116,6 +116,7 @@ public class ProcessDefinitionController extends BaseController {
@PostMapping ( value = "/save" )
@ResponseStatus ( HttpStatus . CREATED )
@ApiException ( CREATE_PROCESS_DEFINITION )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result createProcessDefinition ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( value = "name" , required = true ) String name ,
@ -124,15 +125,6 @@ public class ProcessDefinitionController extends BaseController {
@RequestParam ( value = "connects" , required = true ) String connects ,
@RequestParam ( value = "description" , required = false ) String description ) throws JsonProcessingException {
logger . info ( "login user {}, create process definition, project name: {}, process definition name: {}, "
+ "process_definition_json: {}, desc: {} locations:{}, connects:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( name ) ,
RegexUtils . escapeNRT ( json ) ,
RegexUtils . escapeNRT ( description ) ,
RegexUtils . escapeNRT ( locations ) ,
RegexUtils . escapeNRT ( connects ) ) ;
Map < String , Object > result = processDefinitionService . createProcessDefinition ( loginUser , projectName , name , json ,
description , locations , connects ) ;
return returnDataList ( result ) ;
@ -155,15 +147,11 @@ public class ProcessDefinitionController extends BaseController {
@PostMapping ( value = "/copy" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( BATCH_COPY_PROCESS_DEFINITION_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result copyProcessDefinition ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( value = "processDefinitionIds" , required = true ) String processDefinitionIds ,
@RequestParam ( value = "targetProjectId" , required = true ) int targetProjectId ) {
logger . info ( "batch copy process definition, login user:{}, project name:{}, process definition ids:{},target project id:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( processDefinitionIds ) ,
RegexUtils . escapeNRT ( String . valueOf ( targetProjectId ) ) ) ;
return returnDataList (
processDefinitionService . batchCopyProcessDefinition ( loginUser , projectName , processDefinitionIds , targetProjectId ) ) ;
@ -186,16 +174,11 @@ public class ProcessDefinitionController extends BaseController {
@PostMapping ( value = "/move" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( BATCH_MOVE_PROCESS_DEFINITION_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result moveProcessDefinition ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( value = "processDefinitionIds" , required = true ) String processDefinitionIds ,
@RequestParam ( value = "targetProjectId" , required = true ) int targetProjectId ) {
logger . info ( "batch move process definition, login user:{}, project name:{}, process definition ids:{},target project id:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( processDefinitionIds ) ,
RegexUtils . escapeNRT ( String . valueOf ( targetProjectId ) ) ) ;
return returnDataList (
processDefinitionService . batchMoveProcessDefinition ( loginUser , projectName , processDefinitionIds , targetProjectId ) ) ;
}
@ -215,13 +198,11 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/verify-name" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( VERIFY_PROCESS_DEFINITION_NAME_UNIQUE_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result verifyProcessDefinitionName ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( value = "name" , required = true ) String name ) {
logger . info ( "verify process definition name unique, user:{}, project name:{}, process definition name:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( name ) ) ;
Map < String , Object > result = processDefinitionService . verifyProcessDefinitionName ( loginUser , projectName , name ) ;
return returnDataList ( result ) ;
}
@ -253,6 +234,7 @@ public class ProcessDefinitionController extends BaseController {
@PostMapping ( value = "/update" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( UPDATE_PROCESS_DEFINITION_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result updateProcessDefinition ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( value = "name" , required = true ) String name ,
@ -263,16 +245,6 @@ public class ProcessDefinitionController extends BaseController {
@RequestParam ( value = "description" , required = false ) String description ,
@RequestParam ( value = "releaseState" , required = false , defaultValue = "OFFLINE" ) ReleaseState releaseState ) {
logger . info ( "login user {}, update process define, project name: {}, process define name: {},"
+ "process_definition_json: {}, desc: {}, locations:{}, connects:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( name ) ,
RegexUtils . escapeNRT ( processDefinitionJson ) ,
RegexUtils . escapeNRT ( description ) ,
RegexUtils . escapeNRT ( locations ) ,
RegexUtils . escapeNRT ( connects ) ) ;
Map < String , Object > result = processDefinitionService . updateProcessDefinition ( loginUser , projectName , id , name ,
processDefinitionJson , description , locations , connects ) ;
// If the update fails, the result will be returned directly
@ -306,19 +278,13 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/versions" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( QUERY_PROCESS_DEFINITION_VERSIONS_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result queryProcessDefinitionVersions ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( value = "pageNo" ) int pageNo ,
@RequestParam ( value = "pageSize" ) int pageSize ,
@RequestParam ( value = "processDefinitionId" ) int processDefinitionId ) {
logger . info ( "query process definition versions, login user {}, project name: {}, process define id: {}, list paging, pageNo: {}, pageSize: {}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
processDefinitionId ,
pageNo ,
pageSize ) ;
Map < String , Object > result = checkPageParams ( pageNo , pageSize ) ;
if ( result . get ( Constants . STATUS ) ! = Status . SUCCESS ) {
return returnDataListPaging ( result ) ;
@ -345,15 +311,11 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/version/switch" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( SWITCH_PROCESS_DEFINITION_VERSION_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result switchProcessDefinitionVersion ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( value = "processDefinitionId" ) int processDefinitionId ,
@RequestParam ( value = "version" ) long version ) {
logger . info ( "switch certain process definition version, login user {}, project name:{}, process definition id:{}, version:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
processDefinitionId ,
version ) ;
Map < String , Object > result = processDefinitionService . switchProcessDefinitionVersion ( loginUser , projectName
, processDefinitionId , version ) ;
return returnDataList ( result ) ;
@ -376,15 +338,11 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/version/delete" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( DELETE_PROCESS_DEFINITION_VERSION_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result deleteProcessDefinitionVersion ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( value = "processDefinitionId" ) int processDefinitionId ,
@RequestParam ( value = "version" ) long version ) {
logger . info ( "delete the certain process definition version by version and process definition id, login user {}, project name:{}, process definition id:{}, version:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
processDefinitionId ,
version ) ;
Map < String , Object > result = processDefinitionVersionService . deleteByProcessDefinitionIdAndVersion ( loginUser , projectName , processDefinitionId , version ) ;
return returnDataList ( result ) ;
}
@ -407,15 +365,12 @@ public class ProcessDefinitionController extends BaseController {
@PostMapping ( value = "/release" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( RELEASE_PROCESS_DEFINITION_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result releaseProcessDefinition ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( value = "processId" , required = true ) int processId ,
@RequestParam ( value = "releaseState" , required = true ) ReleaseState releaseState ) {
logger . info ( "login user {}, release process definition, project name: {}, release state: {}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
releaseState ) ;
Map < String , Object > result = processDefinitionService . releaseProcessDefinition ( loginUser , projectName , processId , releaseState ) ;
return returnDataList ( result ) ;
}
@ -435,14 +390,11 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/select-by-id" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( QUERY_DATAIL_OF_PROCESS_DEFINITION_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result queryProcessDefinitionById ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( "processId" ) Integer processId ) {
logger . info ( "query detail of process definition, login user:{}, project name:{}, process definition id:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
processId ) ;
@RequestParam ( "processId" ) Integer processId
) {
Map < String , Object > result = processDefinitionService . queryProcessDefinitionById ( loginUser , projectName , processId ) ;
return returnDataList ( result ) ;
}
@ -462,14 +414,11 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/select-by-name" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( QUERY_DATAIL_OF_PROCESS_DEFINITION_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result < ProcessDefinition > queryProcessDefinitionByName ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( "processDefinitionName" ) String processDefinitionName ) {
logger . info ( "query detail of process definition by name, login user:{}, project name:{}, process definition id:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( processDefinitionName ) ) ;
Map < String , Object > result = processDefinitionService . queryProcessDefinitionByName ( loginUser , projectName , processDefinitionName ) ;
return returnDataList ( result ) ;
}
@ -485,12 +434,10 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/list" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( QUERY_PROCESS_DEFINITION_LIST )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result queryProcessDefinitionList ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ) {
logger . info ( "query process definition list, login user:{}, project name:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ) ;
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName
) {
Map < String , Object > result = processDefinitionService . queryProcessDefinitionList ( loginUser , projectName ) ;
return returnDataList ( result ) ;
}
@ -516,6 +463,7 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/list-paging" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( QUERY_PROCESS_DEFINITION_LIST_PAGING_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result queryProcessDefinitionListPaging ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( "pageNo" ) Integer pageNo ,
@ -523,12 +471,6 @@ public class ProcessDefinitionController extends BaseController {
@RequestParam ( value = "userId" , required = false , defaultValue = "0" ) Integer userId ,
@RequestParam ( "pageSize" ) Integer pageSize ) {
logger . info ( "query process definition list paging, login user:{}, project name:{}, searchVal:{}, userId:{}, pageSize:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( searchVal ) ,
userId ,
pageSize ) ;
Map < String , Object > result = checkPageParams ( pageNo , pageSize ) ;
if ( result . get ( Constants . STATUS ) ! = Status . SUCCESS ) {
return returnDataListPaging ( result ) ;
@ -555,16 +497,12 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/view-tree" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( ENCAPSULATION_TREEVIEW_STRUCTURE_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result viewTree ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( "processId" ) Integer id ,
@RequestParam ( "limit" ) Integer limit ) throws Exception {
logger . info ( "encapsulation tree view structure, login user:{}, project name:{}, processId:{}, limit:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
id ,
limit ) ;
Map < String , Object > result = processDefinitionService . viewTree ( id , limit ) ;
return returnDataList ( result ) ;
}
@ -584,15 +522,12 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "gen-task-list" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( GET_TASKS_LIST_BY_PROCESS_DEFINITION_ID_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result getNodeListByDefinitionId (
@ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( "processDefinitionId" ) Integer processDefinitionId ) throws Exception {
logger . info ( "query task node name list by definitionId, login user:{}, project name:{}, id : {}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
processDefinitionId ) ;
Map < String , Object > result = processDefinitionService . getTaskNodeListByDefinitionId ( processDefinitionId ) ;
return returnDataList ( result ) ;
}
@ -612,15 +547,12 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "get-task-list" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( GET_TASKS_LIST_BY_PROCESS_DEFINITION_ID_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result getNodeListByDefinitionIdList (
@ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( "processDefinitionIdList" ) String processDefinitionIdList ) {
logger . info ( "query task node name list by definitionId list, login user:{}, project name:{}, id list: {}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( processDefinitionIdList ) ) ;
Map < String , Object > result = processDefinitionService . getTaskNodeListByDefinitionIdList ( processDefinitionIdList ) ;
return returnDataList ( result ) ;
}
@ -640,15 +572,12 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/delete" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( DELETE_PROCESS_DEFINE_BY_ID_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result deleteProcessDefinitionById ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( "processDefinitionId" ) Integer processDefinitionId
) {
logger . info ( "delete process definition by id, login user:{}, project name:{}, process definition id:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
processDefinitionId ) ;
Map < String , Object > result = processDefinitionService . deleteProcessDefinitionById ( loginUser , projectName , processDefinitionId ) ;
return returnDataList ( result ) ;
}
@ -668,15 +597,12 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/batch-delete" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( BATCH_DELETE_PROCESS_DEFINE_BY_IDS_ERROR )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result batchDeleteProcessDefinitionByIds ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( "processDefinitionIds" ) String processDefinitionIds
) {
logger . info ( "delete process definition by ids, login user:{}, project name:{}, process definition ids:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( processDefinitionIds ) ) ;
Map < String , Object > result = new HashMap < > ( ) ;
List < String > deleteFailedIdList = new ArrayList < > ( ) ;
if ( StringUtils . isNotEmpty ( processDefinitionIds ) ) {
@ -720,16 +646,13 @@ public class ProcessDefinitionController extends BaseController {
} )
@GetMapping ( value = "/export" )
@ResponseBody
@AccessLogAnnotation ( ignoreRequestArgs = { "loginUser" , "response" } )
public void batchExportProcessDefinitionByIds ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@ApiParam ( name = "projectName" , value = "PROJECT_NAME" , required = true ) @PathVariable String projectName ,
@RequestParam ( "processDefinitionIds" ) String processDefinitionIds ,
HttpServletResponse response ) {
try {
logger . info ( "batch export process definition by ids, login user:{}, project name:{}, process definition ids:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
RegexUtils . escapeNRT ( projectName ) ,
RegexUtils . escapeNRT ( processDefinitionIds ) ) ;
processDefinitionService . batchExportProcessDefinitionByIds ( loginUser , projectName , processDefinitionIds , response ) ;
} catch ( Exception e ) {
logger . error ( Status . BATCH_EXPORT_PROCESS_DEFINE_BY_IDS_ERROR . getMsg ( ) , e ) ;
@ -747,12 +670,10 @@ public class ProcessDefinitionController extends BaseController {
@GetMapping ( value = "/queryProcessDefinitionAllByProjectId" )
@ResponseStatus ( HttpStatus . OK )
@ApiException ( QUERY_PROCESS_DEFINITION_LIST )
@AccessLogAnnotation ( ignoreRequestArgs = "loginUser" )
public Result queryProcessDefinitionAllByProjectId ( @ApiIgnore @RequestAttribute ( value = Constants . SESSION_USER ) User loginUser ,
@RequestParam ( "projectId" ) Integer projectId ) {
logger . info ( "query process definition list, login user:{}, project id:{}" ,
RegexUtils . escapeNRT ( loginUser . getUserName ( ) ) ,
projectId ) ;
Map < String , Object > result = processDefinitionService . queryProcessDefinitionAllByProjectId ( projectId ) ;
return returnDataList ( result ) ;
}