diff --git a/activiti-cloud-query-service/activiti-cloud-services-query/activiti-cloud-services-query-rest/src/test/java/org/activiti/cloud/services/query/rest/ProcessInstanceControllerHelperIT.java b/activiti-cloud-query-service/activiti-cloud-services-query/activiti-cloud-services-query-rest/src/test/java/org/activiti/cloud/services/query/rest/ProcessInstanceControllerHelperIT.java index 6d1bfc72dc..86d58b2da8 100644 --- a/activiti-cloud-query-service/activiti-cloud-services-query/activiti-cloud-services-query-rest/src/test/java/org/activiti/cloud/services/query/rest/ProcessInstanceControllerHelperIT.java +++ b/activiti-cloud-query-service/activiti-cloud-services-query/activiti-cloud-services-query-rest/src/test/java/org/activiti/cloud/services/query/rest/ProcessInstanceControllerHelperIT.java @@ -125,7 +125,7 @@ public void shouldReturnAllProcessInstancesWithVariables() { .willReturn(true); given(securityManager.getAuthenticatedUserId()).willReturn("testuser"); - Set variables = createProcessVariables(processInstanceEntity, 8); + Set variables = createProcessVariables(8); List variableKeys = variables.stream().map(ProcessVariableEntity::getName).collect(Collectors.toList()); Predicate predicate = null; int pageSize = 30; @@ -190,7 +190,7 @@ private ProcessInstanceEntity buildSubprocessInstance(ProcessInstanceEntity pare return subprocessInstance; } - private Set createProcessVariables(ProcessInstanceEntity processInstanceEntity, int count) { + private Set createProcessVariables(int count) { Set variables = new HashSet<>(); for (int i = 0; i < count; i++) { ProcessVariableEntity variable = new ProcessVariableEntity(); diff --git a/activiti-cloud-query-service/activiti-cloud-starter-query/src/test/resources/swagger-expected.json b/activiti-cloud-query-service/activiti-cloud-starter-query/src/test/resources/swagger-expected.json index 8835a469e2..9c901971a1 100644 --- a/activiti-cloud-query-service/activiti-cloud-starter-query/src/test/resources/swagger-expected.json +++ b/activiti-cloud-query-service/activiti-cloud-starter-query/src/test/resources/swagger-expected.json @@ -199,12 +199,12 @@ "content": { "application/hal+json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_ProcessVariables" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_ProcessVariables" } }, "application/json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_ProcessVariables" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_ProcessVariables" } } } @@ -1787,12 +1787,12 @@ "content": { "application/hal+json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_ProcessVariables" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_ProcessVariables" } }, "application/json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_ProcessVariables" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_ProcessVariables" } } } @@ -2371,12 +2371,12 @@ "content": { "application/hal+json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_General" } }, "application/json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_General" } } } @@ -2476,12 +2476,12 @@ "content": { "application/hal+json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_ProcessVariables" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_ProcessVariables" } }, "application/json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_ProcessVariables" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_ProcessVariables" } } } @@ -3571,12 +3571,12 @@ "content": { "application/hal+json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_ProcessVariables" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_ProcessVariables" } }, "application/json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_ProcessVariables" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_ProcessVariables" } } } @@ -3645,12 +3645,12 @@ "content": { "application/hal+json": { "schema": { - "$ref": "#/components/schemas/EntryResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/EntryResponseContentQueryCloudProcessInstance_General" } }, "application/json": { "schema": { - "$ref": "#/components/schemas/EntryResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/EntryResponseContentQueryCloudProcessInstance_General" } } } @@ -4202,12 +4202,12 @@ "content": { "application/hal+json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_General" } }, "application/json": { "schema": { - "$ref": "#/components/schemas/ListResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/ListResponseContentQueryCloudProcessInstance_General" } } } @@ -5284,12 +5284,12 @@ "content": { "application/hal+json": { "schema": { - "$ref": "#/components/schemas/EntryResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/EntryResponseContentQueryCloudProcessInstance_General" } }, "application/json": { "schema": { - "$ref": "#/components/schemas/EntryResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/EntryResponseContentQueryCloudProcessInstance_General" } } } @@ -6624,11 +6624,11 @@ "processInstanceId": { "type": "string" }, - "taskVariable": { - "type": "boolean" - }, "taskId": { "type": "string" + }, + "taskVariable": { + "type": "boolean" } } }, @@ -6758,10 +6758,16 @@ "type": "string", "format": "date-time" }, - "processDefinitionId": { + "processInstanceId": { "type": "string" }, - "processInstanceId": { + "parentTaskId": { + "type": "string" + }, + "taskDefinitionKey": { + "type": "string" + }, + "processDefinitionId": { "type": "string" }, "candidateUsers": { @@ -6776,21 +6782,12 @@ "type": "string" } }, - "parentTaskId": { - "type": "string" - }, - "taskDefinitionKey": { - "type": "string" - }, - "formKey": { + "assignee": { "type": "string" }, "businessKey": { "type": "string" }, - "assignee": { - "type": "string" - }, "createdDate": { "type": "string", "format": "date-time" @@ -6806,6 +6803,9 @@ "completedBy": { "type": "string" }, + "formKey": { + "type": "string" + }, "description": { "type": "string" }, @@ -6916,10 +6916,50 @@ } } }, - "CloudProcessInstance_ProcessVariables": { - "title": "CloudProcessInstance_ProcessVariables", + "EntriesResponseContentQueryCloudProcessInstance_ProcessVariables": { + "title": "EntriesResponseContentQueryCloudProcessInstance_ProcessVariables", + "type": "object", + "properties": { + "entries": { + "type": "array", + "items": { + "$ref": "#/components/schemas/EntryResponseContentQueryCloudProcessInstance_ProcessVariables" + } + }, + "pagination": { + "$ref": "#/components/schemas/PaginationMetadata_ProcessVariables" + } + } + }, + "EntryResponseContentQueryCloudProcessInstance_ProcessVariables": { + "title": "EntryResponseContentQueryCloudProcessInstance_ProcessVariables", "type": "object", "properties": { + "entry": { + "$ref": "#/components/schemas/QueryCloudProcessInstance_ProcessVariables" + } + } + }, + "ListResponseContentQueryCloudProcessInstance_ProcessVariables": { + "title": "ListResponseContentQueryCloudProcessInstance_ProcessVariables", + "type": "object", + "properties": { + "list": { + "$ref": "#/components/schemas/EntriesResponseContentQueryCloudProcessInstance_ProcessVariables" + } + } + }, + "QueryCloudProcessInstance_ProcessVariables": { + "title": "QueryCloudProcessInstance_ProcessVariables", + "type": "object", + "properties": { + "subprocesses": { + "uniqueItems": true, + "type": "array", + "items": { + "$ref": "#/components/schemas/QueryCloudSubprocessInstance_ProcessVariables" + } + }, "serviceFullName": { "type": "string" }, @@ -6951,9 +6991,6 @@ "processDefinitionId": { "type": "string" }, - "businessKey": { - "type": "string" - }, "initiator": { "type": "string" }, @@ -6961,6 +6998,9 @@ "type": "string", "format": "date-time" }, + "businessKey": { + "type": "string" + }, "parentId": { "type": "string" }, @@ -6986,36 +7026,15 @@ } } }, - "EntriesResponseContentCloudProcessInstance_ProcessVariables": { - "title": "EntriesResponseContentCloudProcessInstance_ProcessVariables", + "QueryCloudSubprocessInstance_ProcessVariables": { + "title": "QueryCloudSubprocessInstance_ProcessVariables", "type": "object", "properties": { - "entries": { - "type": "array", - "items": { - "$ref": "#/components/schemas/EntryResponseContentCloudProcessInstance_ProcessVariables" - } + "id": { + "type": "string" }, - "pagination": { - "$ref": "#/components/schemas/PaginationMetadata_ProcessVariables" - } - } - }, - "EntryResponseContentCloudProcessInstance_ProcessVariables": { - "title": "EntryResponseContentCloudProcessInstance_ProcessVariables", - "type": "object", - "properties": { - "entry": { - "$ref": "#/components/schemas/CloudProcessInstance_ProcessVariables" - } - } - }, - "ListResponseContentCloudProcessInstance_ProcessVariables": { - "title": "ListResponseContentCloudProcessInstance_ProcessVariables", - "type": "object", - "properties": { - "list": { - "$ref": "#/components/schemas/EntriesResponseContentCloudProcessInstance_ProcessVariables" + "processDefinitionName": { + "type": "string" } } }, @@ -7099,11 +7118,11 @@ "processInstanceId": { "type": "string" }, - "taskVariable": { - "type": "boolean" - }, "taskId": { "type": "string" + }, + "taskVariable": { + "type": "boolean" } } }, @@ -7199,11 +7218,11 @@ "processInstanceId": { "type": "string" }, - "taskVariable": { - "type": "boolean" - }, "taskId": { "type": "string" + }, + "taskVariable": { + "type": "boolean" } } }, @@ -7284,10 +7303,16 @@ "type": "string", "format": "date-time" }, - "processDefinitionId": { + "processInstanceId": { "type": "string" }, - "processInstanceId": { + "parentTaskId": { + "type": "string" + }, + "taskDefinitionKey": { + "type": "string" + }, + "processDefinitionId": { "type": "string" }, "candidateUsers": { @@ -7302,21 +7327,12 @@ "type": "string" } }, - "parentTaskId": { - "type": "string" - }, - "taskDefinitionKey": { - "type": "string" - }, - "formKey": { + "assignee": { "type": "string" }, "businessKey": { "type": "string" }, - "assignee": { - "type": "string" - }, "createdDate": { "type": "string", "format": "date-time" @@ -7332,6 +7348,9 @@ "completedBy": { "type": "string" }, + "formKey": { + "type": "string" + }, "description": { "type": "string" }, @@ -7352,10 +7371,26 @@ } } }, - "CloudProcessInstance_General": { - "title": "CloudProcessInstance_General", + "EntryResponseContentQueryCloudProcessInstance_General": { + "title": "EntryResponseContentQueryCloudProcessInstance_General", + "type": "object", + "properties": { + "entry": { + "$ref": "#/components/schemas/QueryCloudProcessInstance_General" + } + } + }, + "QueryCloudProcessInstance_General": { + "title": "QueryCloudProcessInstance_General", "type": "object", "properties": { + "subprocesses": { + "uniqueItems": true, + "type": "array", + "items": { + "$ref": "#/components/schemas/QueryCloudSubprocessInstance_General" + } + }, "serviceFullName": { "type": "string" }, @@ -7387,9 +7422,6 @@ "processDefinitionId": { "type": "string" }, - "businessKey": { - "type": "string" - }, "initiator": { "type": "string" }, @@ -7397,6 +7429,9 @@ "type": "string", "format": "date-time" }, + "businessKey": { + "type": "string" + }, "parentId": { "type": "string" }, @@ -7422,23 +7457,26 @@ } } }, - "EntryResponseContentCloudProcessInstance_General": { - "title": "EntryResponseContentCloudProcessInstance_General", + "QueryCloudSubprocessInstance_General": { + "title": "QueryCloudSubprocessInstance_General", "type": "object", "properties": { - "entry": { - "$ref": "#/components/schemas/CloudProcessInstance_General" + "id": { + "type": "string" + }, + "processDefinitionName": { + "type": "string" } } }, - "EntriesResponseContentCloudProcessInstance_General": { - "title": "EntriesResponseContentCloudProcessInstance_General", + "EntriesResponseContentQueryCloudProcessInstance_General": { + "title": "EntriesResponseContentQueryCloudProcessInstance_General", "type": "object", "properties": { "entries": { "type": "array", "items": { - "$ref": "#/components/schemas/EntryResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/EntryResponseContentQueryCloudProcessInstance_General" } }, "pagination": { @@ -7446,12 +7484,12 @@ } } }, - "ListResponseContentCloudProcessInstance_General": { - "title": "ListResponseContentCloudProcessInstance_General", + "ListResponseContentQueryCloudProcessInstance_General": { + "title": "ListResponseContentQueryCloudProcessInstance_General", "type": "object", "properties": { "list": { - "$ref": "#/components/schemas/EntriesResponseContentCloudProcessInstance_General" + "$ref": "#/components/schemas/EntriesResponseContentQueryCloudProcessInstance_General" } } }, @@ -7672,10 +7710,10 @@ "executionId": { "type": "string" }, - "processDefinitionId": { + "processInstanceId": { "type": "string" }, - "processInstanceId": { + "processDefinitionId": { "type": "string" }, "elementId": { @@ -7771,9 +7809,6 @@ "type": "string", "format": "date-time" }, - "errorCode": { - "type": "string" - }, "status": { "type": "string", "enum": [ @@ -7782,9 +7817,15 @@ "INTEGRATION_ERROR_RECEIVED" ] }, + "errorCode": { + "type": "string" + }, "id": { "type": "string" }, + "processInstanceId": { + "type": "string" + }, "connectorType": { "type": "string" }, @@ -7803,15 +7844,9 @@ "processDefinitionId": { "type": "string" }, - "processInstanceId": { - "type": "string" - }, "clientType": { "type": "string" }, - "appVersion": { - "type": "string" - }, "businessKey": { "type": "string" }, @@ -7824,6 +7859,9 @@ "clientName": { "type": "string" }, + "appVersion": { + "type": "string" + }, "rootProcessInstanceId": { "type": "string" },