You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2022/06/18 08:07:41 UTC
[GitHub] [flink] shba24 opened a new pull request, #20014: [FLINK-26979][table-planner] Correct the race condition on transformation node id
shba24 opened a new pull request, #20014:
URL: https://github.com/apache/flink/pull/20014
## What is the purpose of the change
Fix the race condition on node id of transformation when test execution happens in parallel
## Brief change log
- *Correct the race condition on transformation node id*
## Verifying this change
This change is already covered by existing tests, such as *JsonFunctionsITCase.test*.
- *Added AtomicInteger to handle the race condition on the creation of node id*
## Does this pull request potentially affect one of the following parts:
- Dependencies (does it add or upgrade a dependency): (no)
- The public API, i.e., is any changed class annotated with `@Public(Evolving)`: (no)
- The serializers: (no)
- The runtime per-record code paths (performance sensitive): (no)
- Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: (no)
- The S3 file system connector: (no)
## Documentation
- Does this pull request introduce a new feature? (no)
- If yes, how is the feature documented? (not applicable)
--
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: issues-unsubscribe@flink.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [flink] zentol merged pull request #20014: [FLINK-26979][table-planner] Correct the race condition on transformation node id
Posted by GitBox <gi...@apache.org>.
zentol merged PR #20014:
URL: https://github.com/apache/flink/pull/20014
--
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: issues-unsubscribe@flink.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [flink] MartijnVisser commented on a diff in pull request #20014: [FLINK-26979][table-planner] Correct the race condition on transformation node id
Posted by GitBox <gi...@apache.org>.
MartijnVisser commented on code in PR #20014:
URL: https://github.com/apache/flink/pull/20014#discussion_r913466628
##########
flink-core/src/main/java/org/apache/flink/api/dag/Transformation.java:
##########
@@ -108,11 +109,10 @@
public static final int UPPER_BOUND_MAX_PARALLELISM = 1 << 15;
// This is used to assign a unique ID to every Transformation
- protected static Integer idCounter = 0;
+ protected static final AtomicInteger ID_COUNTER = new AtomicInteger(0);
Review Comment:
Any update on this @shba24 ?
--
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: issues-unsubscribe@flink.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [flink] shba24 commented on a diff in pull request #20014: [FLINK-26979][table-planner] Correct the race condition on transformation node id
Posted by GitBox <gi...@apache.org>.
shba24 commented on code in PR #20014:
URL: https://github.com/apache/flink/pull/20014#discussion_r902194132
##########
flink-core/src/main/java/org/apache/flink/api/dag/Transformation.java:
##########
@@ -108,11 +109,10 @@
public static final int UPPER_BOUND_MAX_PARALLELISM = 1 << 15;
// This is used to assign a unique ID to every Transformation
- protected static Integer idCounter = 0;
+ protected static final AtomicInteger ID_COUNTER = new AtomicInteger(0);
Review Comment:
I can try to write a test which can try to reproduce the race condition. But it's not always a certainty that this will occur. But anyways, I will try to write a unit test for this.
--
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: issues-unsubscribe@flink.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [flink] flinkbot commented on pull request #20014: [FLINK-26979][table-planner] Correct the race condition on transformation node id
Posted by GitBox <gi...@apache.org>.
flinkbot commented on PR #20014:
URL: https://github.com/apache/flink/pull/20014#issuecomment-1159393589
<!--
Meta data
{
"version" : 1,
"metaDataEntries" : [ {
"hash" : "413ff339da9dbcad6329da5134c27fbbf7bc05bb",
"status" : "UNKNOWN",
"url" : "TBD",
"triggerID" : "413ff339da9dbcad6329da5134c27fbbf7bc05bb",
"triggerType" : "PUSH"
} ]
}-->
## CI report:
* 413ff339da9dbcad6329da5134c27fbbf7bc05bb UNKNOWN
<details>
<summary>Bot commands</summary>
The @flinkbot bot supports the following commands:
- `@flinkbot run azure` re-run the last Azure build
</details>
--
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: issues-unsubscribe@flink.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [flink] xuyangzhong commented on a diff in pull request #20014: [FLINK-26979][table-planner] Correct the race condition on transformation node id
Posted by GitBox <gi...@apache.org>.
xuyangzhong commented on code in PR #20014:
URL: https://github.com/apache/flink/pull/20014#discussion_r901792710
##########
flink-core/src/main/java/org/apache/flink/api/dag/Transformation.java:
##########
@@ -108,11 +109,10 @@
public static final int UPPER_BOUND_MAX_PARALLELISM = 1 << 15;
// This is used to assign a unique ID to every Transformation
- protected static Integer idCounter = 0;
+ protected static final AtomicInteger ID_COUNTER = new AtomicInteger(0);
Review Comment:
nit: does this pr needs a test case with multi threads?
--
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: issues-unsubscribe@flink.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [flink] zentol commented on a diff in pull request #20014: [FLINK-26979][table-planner] Correct the race condition on transformation node id
Posted by GitBox <gi...@apache.org>.
zentol commented on code in PR #20014:
URL: https://github.com/apache/flink/pull/20014#discussion_r913542129
##########
flink-core/src/main/java/org/apache/flink/api/dag/Transformation.java:
##########
@@ -108,11 +109,10 @@
public static final int UPPER_BOUND_MAX_PARALLELISM = 1 << 15;
// This is used to assign a unique ID to every Transformation
- protected static Integer idCounter = 0;
+ protected static final AtomicInteger ID_COUNTER = new AtomicInteger(0);
Review Comment:
I will finalize this PR.
--
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: issues-unsubscribe@flink.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org