8000 optimize: improve readability of the DesignerJsonTransformer class by MaoMaoandSnail · Pull Request #7316 · apache/incubator-seata · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

optimize: improve readability of the DesignerJsonTransformer class #7316

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

Open
wants to merge 5 commits into
base: 2.x
Choose a base branch
from

Conversation

MaoMaoandSnail
Copy link
Contributor
  • I have registered the PR changes.

Ⅰ. Describe what this PR did

Ⅱ. Does this pull request fix one issue?

Ⅲ. Why don't you add test cases (unit test/integration test)?

Ⅳ. Describe how to verify it

Ⅴ. Special notes for reviews

@slievrly
Copy link
Member

Error: /home/runner/work/incubator-seata/incubator-seata/saga/seata-saga-statelang/src/main/java/org/apache/seata/saga/statelang/parser/utils/DesignerJsonTransformer.java:152: 'lambda arguments' has incorrect indentation level 20, expected level should be 16. [Indentation]
Error: /home/runner/work/incubator-seata/incubator-seata/saga/seata-saga-statelang/src/main/java/org/apache/seata/saga/statelang/parser/utils/DesignerJsonTransformer.java:166: 'lambda arguments' has incorrect indentation level 20, expected level should be 16. [Indentation]

Copy link
codecov bot commented Apr 27, 2025

Codecov Report

Attention: Patch coverage is 80.00000% with 14 lines in your changes missing coverage. Please review.

Project coverage is 58.44%. Comparing base (152a7f9) to head (69279af).

Files with missing lines Patch % Lines
...tatelang/parser/utils/DesignerJsonTransformer.java 80.00% 5 Missing and 9 partials ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##                2.x    #7316      +/-   ##
============================================
+ Coverage     58.41%   58.44%   +0.02%     
  Complexity      535      535              
============================================
  Files          1272     1272              
  Lines         45853    45859       +6     
  Branches       5520     5518       -2     
============================================
+ Hits          26785    26801      +16     
+ Misses        16546    16541       -5     
+ Partials       2522     2517       -5     
Files with missing lines Coverage Δ
...tatelang/parser/utils/DesignerJsonTransformer.java 64.07% <80.00%> (+0.09%) ⬆️

... and 7 files with indirect coverage changes

Impacted file tree graph

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@slievrly slievrly added this to the 2.5.0 milestone Apr 28, 2025

transformNode(machineJsonObject, nodeMap, nodeObj);
}
for (Object node : nodes) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From the syntax is correct. However, in terms of business semantics, nodes are the basis of edges. Without nodes, there must be no edges.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe that nodes and edges only make sense in JSON when both are present; having only one of them is meaningless.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0