njnu-seafish commented on PR #18444:
URL: 
https://github.com/apache/dolphinscheduler/pull/18444#issuecomment-5251055256

   > ### The DTO removes more response properties than the documented five
   > `WorkflowInstanceQueryDTO`
   > 
   > The affected endpoints previously returned `WorkflowInstance`. Replacing 
it with this DTO removes not only `commandParam`, `globalParams`, `historyCmd`, 
`varPool`, and `stateHistory`, but also properties such as `stateDescList`, 
`workflowDefinition`, `dagData`, `queue`, `locations`, and 
`dependenceScheduleTimes`, as well as the public getter-derived 
`cmdTypeIfComplement` and `complementData` properties.
   > 
   > Therefore, the actual incompatible response change is broader than what 
the upgrade document and DTO documentation describe. In particular, the 
complement-related properties can contain meaningful values for complement-data 
executions.
   > 
   > Please either preserve all non-targeted response properties or document 
the complete set of removed properties. The regression tests should serialize 
an actual controller response and assert its JSON shape; the current 
reflection-only tests do not verify the public API response.
   > 
   > ### Declare the DTO type on the primary list endpoint
   > `WorkflowInstanceController.queryWorkflowInstanceList`
   > 
   > The service now returns `Result<PageInfo<WorkflowInstanceQueryDTO>>`, but 
the controller still declares the endpoint response as raw `Result`. 
Consequently, the generated OpenAPI contract cannot expose the new paginated 
DTO schema, unlike the updated top-N and trigger endpoints.
   > 
   > Please change the controller return type to 
`Result<PageInfo<WorkflowInstanceQueryDTO>>` and cover the endpoint with a 
MockMvc response assertion.
   
   All 13 removed properties have been documented (previously only 5 were 
listed).
   
   Three categories:
   5 heavy DB fields: commandParam, globalParams, historyCmd, varPool, 
stateHistory — intentionally omitted from listSql
   6 transient fields: stateDescList, workflowDefinition, dagData, queue, 
locations, dependenceScheduleTimes — always null in list responses
   2 derived getters: cmdTypeIfComplement, complementData — redundant with 
commandType which is retained in the DTO
   
   Regarding complement properties: The frontend identifies complement-data 
instances via row.commandType === 'COMPLEMENT_DATA', not 
cmdTypeIfComplement/complementData. Since commandType is preserved, the 
frontend is unaffected.
   
   Changes made:
   DTO Javadoc — full 13-property removal list
   incompatible.md (EN & ZH) — all 13 properties with categories and affected 
endpoints
   Test — JSON serialization shape assertion against actual MockMvc response


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to