Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[INLONG-2759][Manager] Fix InlongGroup object deletion and modification exception #2762

Closed

Conversation

Greedyu
Copy link
Contributor

@Greedyu Greedyu commented Feb 26, 2022

Title Name: [INLONG-2759][INLONG-2760][Manager] Fix InlongGroup object deletion and modification exception

Fixes #2759 Manager module
First of all, the reason is that the GroupState.forCode() function has passed a null value. The reason is that the request object InlongGroupRequest does not add the annotation @ApiModelProperty() to the status field, which has been fixed here.

But there is still a problem with retesting with annotations, because the front-end page does not pass in the status parameter.
image

Then continue to use the postman tool to form the status parameter for testing. A new problem has arisen: Current state=wait_submit is not allowed to transfer to state=wait_submit
image

This is because there is no conversion from GROUP_WAIT_SUBMIT to GROUP_WAIT_SUBMIT in the status transition. The above scenario should be missed here, so I fixed it and tested it again through the post. Finally verified successfully

image

Finally, the front-end Dashborad module needs to be repaired and the status parameter added.

Fixes #2760
Because the deletion actually calls the groupProcessOperation.deleteProcess() function, the InlongGroupRequest queried according to the id does not change the state. In the inner layer, the groupService.update(groupInfo, username) method is actually executed first. equivalent to the original state of transformation
image

After repairing and testing again, the interface can return successfully
image

… 100

2. Add the annotation @ApiModelProperty to the status field of the InlongGroupRequest object to receive front-end parameters for state switching verification
3. The InlongGroupProcessOperation deleteProcess() function adds the delete state 40, otherwise the state verification will fail when the subsequent inner layer calls the groupService.update() method
@healchow
Copy link
Member

It is not recommended to associate 2 or more issues in one PR.

@Greedyu
Copy link
Contributor Author

Greedyu commented Feb 27, 2022

It is not recommended to associate 2 or more issues in one PR. Separate two request pull commits
#2769 #2770

@Greedyu Greedyu closed this Feb 27, 2022
@Greedyu Greedyu deleted the bugfix-InlongGroupController_update branch May 7, 2022 03:40
@healchow healchow added this to the 1.1.0 milestone May 8, 2022
@healchow healchow changed the title [INLONG-2759][INLONG-2760][Manager] Fix InlongGroup object deletion and modification exception [INLONG-2759][Manager] Fix InlongGroup object deletion and modification exception May 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants