[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16969831#comment-16969831 ] kailiu_dev edited comment on YARN-9940 at 11/8/19 6:15 AM: --- [~wilfreds] , you say right that hadoop 2.7.2 has been {color:#172b4d}EOL'ed{color}, but can you please help me review my my patch , check if can the code can {color:#172b4d}solving the issure, beause my company need hadoop 2.7.2。{color} *{color:#172b4d}in my code:{color}* for example , befor my change in hadoop 2.7.2: *sort node is:* synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } *but {color:#172b4d}completedContainer{color} is:* writeLock.lock(); . node.releaseContainer(container); writeLock.unlock(); *after change my code:* {color:#172b4d}completedContainer{color} is: writeLock.lock(); {color:#172b4d}if (continuousSchedulingEnabled) { {color} {color:#172b4d} synchronized (this) { {color} {color:#172b4d}node.releaseContainer(container); {color} {color:#172b4d} } }{color} {color:#172b4d}writeLock.unlock();{color} {color:#ff}so when releaseContainer , it should wait for geting schdule lock when sorting node;{color} {color:#ff}this is my simple example, the total code is in my patch.{color} {color:#172b4d}so above on you say "the method {color}{{FairScheduler.completedContainer()}}{color:#172b4d} method is already synchronised adding a synchronised block inside that will not help{color}", I can think that your meaning is that it is not helpful in hadoop2.9 beause of it has all used {color:#172b4d}writeLock/readLock,{color} but it is helpful in hadoop2.7.2 ? was (Author: kailiu_dev): [~wilfreds] , you say right that hadoop 2.7.2 has been {color:#172b4d}EOL'ed{color}, but can you please help me review my my patch , check if can the code can {color:#172b4d}solving the issure, beause my company need hadoop 2.7.2。{color} *{color:#172b4d}in my code:{color}* for example , befor my change in hadoop 2.7.2: *sort node is:* synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } *but {color:#172b4d}completedContainer{color} is:* writeLock.lock(); . node.releaseContainer(container); writeLock.unlock(); *after change my code:* {color:#172b4d}completedContainer{color} is: writeLock.lock(); {color:#172b4d}if (continuousSchedulingEnabled) { {color} {color:#172b4d} synchronized (this) { {color} {color:#172b4d}node.releaseContainer(container); {color} {color:#172b4d} } }{color} {color:#172b4d}writeLock.unlock();{color} {color:#ff}so when releaseContainer , it should wait for geting schdule lock when sorting node;{color} {color:#ff}this is my simple example, the total code is in my patch.{color} {color:#172b4d}so above on you say "the method {color}{{FairScheduler.completedContainer()}}{color:#172b4d} method is already synchronised adding a synchronised block inside that will not help{color}", I can think that your meaning is that it is not helpful in hadoop2.9 beause of it has all used {color:#172b4d}writeLock/readLock,{color} but it is helpful in hadoop2.7.2 ? > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Assignee: kailiu_dev >Priority: Major > Attachments: YARN-9940-branch-2.7.2.001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16969831#comment-16969831 ] kailiu_dev edited comment on YARN-9940 at 11/8/19 6:15 AM: --- [~wilfreds] , you say right that hadoop 2.7.2 has been {color:#172b4d}EOL'ed{color}, but can you please help me review my my patch , check if can the code can {color:#172b4d}solving the issure, beause my company need hadoop 2.7.2。{color} *{color:#172b4d}in my code:{color}* for example , befor my change in hadoop 2.7.2: *sort node is:* synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } *but {color:#172b4d}completedContainer{color} is:* writeLock.lock(); . node.releaseContainer(container); writeLock.unlock(); *after change my code:* {color:#172b4d}completedContainer{color} is: writeLock.lock(); {color:#172b4d}if (continuousSchedulingEnabled) { {color} {color:#172b4d} synchronized (this) { {color} {color:#172b4d}node.releaseContainer(container); {color} {color:#172b4d} } }{color} {color:#172b4d}writeLock.unlock();{color} {color:#ff}so when releaseContainer , it should wait for geting schdule lock when sorting node;{color} {color:#ff}this is my simple example, the total code is in my patch.{color} {color:#172b4d}so above on you say "the method {color}{{FairScheduler.completedContainer()}}{color:#172b4d} method is already synchronised adding a synchronised block inside that will not help{color}", I can think that your meaning is that it is not helpful in hadoop2.9 beause of it has all used {color:#172b4d}writeLock/readLock,{color} but it is helpful in hadoop2.7.2 ? was (Author: kailiu_dev): [~wilfreds] , you say right that hadoop 2.7.2 has been {color:#172b4d}EOL'ed{color}, but can you please help me review my my patch , check if can the code can {color:#172b4d}solving the issure, beause my company need hadoop 2.7.2。{color} *{color:#172b4d}in my code:{color}* for example , befor my change in hadoop 2.7.2: *sort node is:* synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } *but {color:#172b4d}completedContainer{color} is:* writeLock.lock(); . node.releaseContainer(container); writeLock.unlock(); *after change my code:* {color:#172b4d}completedContainer{color} is: writeLock.lock(); {color:#172b4d}if (continuousSchedulingEnabled) { {color} {color:#172b4d} synchronized (this) \{ {color} {color:#172b4d}node.releaseContainer(container); {color} {color:#172b4d} } }{color} {color:#172b4d}writeLock.unlock();{color} {color:#ff}so when releaseContainer , it should wait for geting schdule lock when sorting node;{color} {color:#ff}this is my simple example, the total code is in my patch.{color} {color:#172b4d}so above on you say "the method {color}{{FairScheduler.completedContainer()}}{color:#172b4d} method is already synchronised adding a synchronised block inside that will not help{color}", I can think that your meaning is that it is not helpful in hadoop2.9 beause of it has al used {color:#172b4d}writeLock/readLock,{color} but it is helpful in hadoop2.7.2 ? > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Assignee: kailiu_dev >Priority: Major > Attachments: YARN-9940-branch-2.7.2.001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16969831#comment-16969831 ] kailiu_dev edited comment on YARN-9940 at 11/8/19 4:56 AM: --- [~wilfreds] , you say right that hadoop 2.7.2 has been {color:#172b4d}EOL'ed{color}, but can you please help me review my my patch , check if can the code can {color:#172b4d}solving the issure, beause my company need hadoop 2.7.2。{color} *{color:#172b4d}in my code:{color}* for example , befor my change in hadoop 2.7.2: *sort node is:* synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } *but {color:#172b4d}completedContainer{color} is:* writeLock.lock(); . node.releaseContainer(container); writeLock.unlock(); *after change my code:* {color:#172b4d}completedContainer{color} is: writeLock.lock(); {color:#172b4d}if (continuousSchedulingEnabled) { {color} {color:#172b4d} synchronized (this) \{ {color} {color:#172b4d}node.releaseContainer(container); {color} {color:#172b4d} } }{color} {color:#172b4d}writeLock.unlock();{color} {color:#ff}so when releaseContainer , it should wait for geting schdule lock when sorting node;{color} {color:#ff}this is my simple example, the total code is in my patch.{color} {color:#172b4d}so above on you say "the method {color}{{FairScheduler.completedContainer()}}{color:#172b4d} method is already synchronised adding a synchronised block inside that will not help{color}", I can think that your meaning is that it is not helpful in hadoop2.9 beause of it has al used {color:#172b4d}writeLock/readLock,{color} but it is helpful in hadoop2.7.2 ? was (Author: kailiu_dev): [~wilfreds] , you say right that hadoop 2.7.2 has been {color:#172b4d}EOL'ed{color}, but can you please help me review my my patch , check if can the code can {color:#172b4d}solving the issure, beause my company need hadoop 2.7.2。{color} *{color:#172b4d}in my code:{color}* for example , befor my change in hadoop 2.7.2: *sort node is:* synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } *but {color:#172b4d}completedContainer{color} is:* writeLock.lock(); . node.releaseContainer(container); writeLock.unlock(); *after change my code:* {color:#172b4d}completedContainer{color} is: writeLock.lock(); {color:#172b4d}if (continuousSchedulingEnabled) { synchronized (this) \{ node.releaseContainer(container); } }{color} {color:#172b4d}writeLock.unlock();{color} {color:#ff}so when releaseContainer , it should wait for geting schdule lock when sorting node;{color} {color:#ff}this is my simple example, the total code is in my patch.{color} {color:#172b4d}so above on you say "the method {color}{{FairScheduler.completedContainer()}}{color:#172b4d} method is already synchronised adding a synchronised block inside that will not help{color}", I can think that your meaning is that it is not helpful in hadoop2.9 beause of it has al used {color:#172b4d}writeLock/readLock,{color} but it is helpful in hadoop2.7.2 ? > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Assignee: kailiu_dev >Priority: Major > Attachments: YARN-9940-branch-2.7.2.001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message was sent by Atlassian Jira (v8.3.4#803005)
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16969831#comment-16969831 ] kailiu_dev edited comment on YARN-9940 at 11/8/19 4:55 AM: --- [~wilfreds] , you say right that hadoop 2.7.2 has been {color:#172b4d}EOL'ed{color}, but can you please help me review my my patch , check if can the code can {color:#172b4d}solving the issure, beause my company need hadoop 2.7.2。{color} *{color:#172b4d}in my code:{color}* for example , befor my change in hadoop 2.7.2: *sort node is:* synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } *but {color:#172b4d}completedContainer{color} is:* writeLock.lock(); . node.releaseContainer(container); writeLock.unlock(); *after change my code:* {color:#172b4d}completedContainer{color} is: writeLock.lock(); {color:#172b4d}if (continuousSchedulingEnabled) { synchronized (this) \{ node.releaseContainer(container); } }{color} {color:#172b4d}writeLock.unlock();{color} {color:#ff}so when releaseContainer , it should wait for geting schdule lock when sorting node;{color} {color:#ff}this is my simple example, the total code is in my patch.{color} {color:#172b4d}so above on you say "the method {color}{{FairScheduler.completedContainer()}}{color:#172b4d} method is already synchronised adding a synchronised block inside that will not help{color}", I can think that your meaning is that it is not helpful in hadoop2.9 beause of it has al used {color:#172b4d}writeLock/readLock,{color} but it is helpful in hadoop2.7.2 ? was (Author: kailiu_dev): [~wilfreds] , you say right that hadoop 2.7.2 has been {color:#172b4d}EOL'ed{color}, but can you please help me review my my patch , check if can the code can {color:#172b4d}solving the issure, beause my company need hadoop 2.7.2。{color} *{color:#172b4d}in my code:{color}* for example , befor my change in hadoop 2.7.2: *sort node is:* synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } but {color:#172b4d}completedContainer{color} is: writeLock.lock(); . node.releaseContainer(container); writeLock.unlock(); *after change my code:* {color:#172b4d}{color:#172b4d}completedContainer{color} is:{color} {color:#172b4d}writeLock.lock();{color} {color:#172b4d}if (continuousSchedulingEnabled) { synchronized (this) { node.releaseContainer(container); } }{color} {color:#172b4d}writeLock.unlock();{color} {color:#FF}so when releaseContainer , it should wait for geting schdule lock when sorting node;{color} {color:#FF}this is my simple example, the total code is in my patch.{color} {color:#172b4d}so above on you say "t{color:#172b4d}he method {color}{{FairScheduler.completedContainer()}}{color:#172b4d} method is already synchronised adding a synchronised block inside that will not help{color}", I can think that your meaning is that it is not helpful in hadoop2.9 beause of it has al used {color:#172b4d}writeLock/readLock,{color} but it is helpful in hadoop2.7.2 ?{color} {color:#172b4d} {color} > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Assignee: kailiu_dev >Priority: Major > Attachments: YARN-9940-branch-2.7.2.001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message was sent by Atlassian Jira
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16969781#comment-16969781 ] kailiu_dev edited comment on YARN-9940 at 11/8/19 2:57 AM: --- Dear, [~wilfreds] , {color:#172b4d}thanks for your replay!{color} in YARN-8373{color:#172b4d}.{color} {color:#00}- synchronized (this) { + readLock.lock(); + try \{ nodeIdList = nodeTracker.sortedNodeList(nodeAvailableResourceComparator); + } finally \{ + readLock.unlock(); }{color} h3. *I think your meaning is that synchronized (this) is not same lock with the writeLock/readLock, so while sort the nodes may get exception '{color:#ff}Comparison method violates its general contract{color}' when some nodes'Available resources change , so we shoule have one lock ,our may same but my version is hadoop 2.7.2 and your hadoop version is above than 2.9 , the codes in hadoop 2.7.2 doesn't have nodeTracker, so my solution looks is not same with YARN-8373{color:#172b4d}.{color}.* was (Author: kailiu_dev): Dear, [~wilfreds] , {color:#172b4d}thanks for your replay!{color} in YARN-8373{color:#172b4d}.{color} {color:#00}- synchronized (this) { + readLock.lock(); + try { nodeIdList = nodeTracker.sortedNodeList(nodeAvailableResourceComparator); + } finally { + readLock.unlock(); }{color} h3. *I think your meaning is that synchronized (this) is not same lock with whith the writeLock/readLock, so while sort the nodes may get exception '{color:#FF}Comparison method violates its general contract{color}' when some nodes'Available resources change , so we shoule have one lock ,our may same but my version is hadoop 2.7.2, the codes in hadoop 2.7.2 doesn't have nodeTracker, so my solution looks is not same with YARN-8373{color:#172b4d}.{color}.* > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Assignee: kailiu_dev >Priority: Major > Attachments: YARN-9940-branch-2.7.2.001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16967348#comment-16967348 ] kailiu_dev edited comment on YARN-9940 at 11/5/19 9:20 AM: --- {color:#ff}YARN-8436 && YARN-9940 exception is same ,but my probleam is ablout continuous scheduling, that is about FSParentQueue{color} was (Author: kailiu_dev): {color:#FF}exception is same ,but my probleam is ablout continuous scheduling, that is about FSParentQueue{color} > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Priority: Major > Fix For: 2.7.2 > > Attachments: YARN-9940-branch-2.7.2.001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16966386#comment-16966386 ] kailiu_dev edited comment on YARN-9940 at 11/5/19 8:25 AM: --- h5. Dear [~zxu] [~snemeth] [~bibinchundatt] can you please help me review this code? this is a fixed code to avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract' in hadoop version-2.7.2 was (Author: kailiu_dev): h5. [~zxu] [~snemeth] can you please help me review this code? this is a fixed code to avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract' > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Priority: Major > Fix For: 2.7.2 > > Attachments: YARN-9940-branch-2.7.2.001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16966386#comment-16966386 ] kailiu_dev edited comment on YARN-9940 at 11/5/19 8:24 AM: --- h5. [~zxu] [~snemeth] can you please help me review this code? this is a fixed code to avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract' was (Author: kailiu_dev): [~zxu] [~snemeth] can you please help me review this code? > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Priority: Major > Fix For: 2.7.2 > > Attachments: YARN-9940-branch-2.7.2.001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16962833#comment-16962833 ] kailiu_dev edited comment on YARN-9940 at 11/4/19 2:57 AM: --- YARN-8436 May not be suitable for this issure. because : 1: this is a bug about Fair FairScheduler ContinuousSchedulingThread, may not same with about FSParentQueue 2: node maybe be deleted, and if use {color:#00}TreeSet{color} will occure this exception: {color:#ff}java.util.ConcurrentModificationException{color} {color:#ff} at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:909){color} so: the current core is needed: List nodeIdList = new ArrayList(nodes.keySet()); synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } 3: the other reason {color:#172b4d}not be suitable{color} to use {color:#00}TreeSet{color} is when: compare(NodeId n1, NodeId n2) if n1==n2 the resultList of TreeSet only keep one, this will not suitable for continuous schedule, beause some node will not be {color:#172b4d}schedule{color}d {color:#172b4d}4:{color} in YARN-9940, we hold the sechdule lock to avoid exception while sorting when some node'Available resources change 5: Comparison method violates its general is Caused by JDK, from jdk7, Sorting algorithm is replaced with "TimSsort", about the continuous scheduling of Fair sechdule , there you can use two solutions: {color:#ff} one is : you can see YARN-9940, patch{color} {color:#ff} two is: add jvm option: -Djava.util.Arrays.useLegacyMergeSort={color}{color:#d73a49}true{color} was (Author: kailiu_dev): YARN-8436 May not be suitable for this issure. because : 1: node maybe be deleted, and if use {color:#00}TreeSet{color} will occure this exception: {color:#FF}java.util.ConcurrentModificationException{color} {color:#FF} at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:909){color} so: the current core is needed: List nodeIdList = new ArrayList(nodes.keySet()); synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } 2: the other reason {color:#172b4d}not be suitable{color} to use {color:#00}TreeSet{color} is when: compare(NodeId n1, NodeId n2) if n1==n2 the resultList of TreeSet only keep one, this will not suitable for continuous schedule, beause some node will not be {color:#172b4d}schedule{color}d {color:#172b4d}3:{color} in YARN-9940, we hold the sechdule lock to avoid exception while sorting when some node'Available resources change 4: Comparison method violates its general is Caused by JDK, from jdk7, Sorting algorithm is replaced with "TimSsort", about the continuous scheduling of Fair sechdule , there you can use two solutions: {color:#FF} one is : you can see YARN-9940, patch{color} {color:#FF} two is: add jvm option: {color:#33}-Djava.util.Arrays.useLegacyMergeSort={color}{color:#d73a49}true{color}{color} > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Priority: Major > Attachments: YARN-9940.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16962888#comment-16962888 ] Bibin Chundatt edited comment on YARN-9940 at 10/30/19 2:04 PM: [~kailiu_dev] Apologies i thought issue is duplicate of YARN-8436 and you have closed based on that. Fixed and resolved state are set only if the changes has gone into 3.2.0. If tats is not the case we have to keep the issue open . Please refer : https://cwiki.apache.org/confluence/display/HADOOP/How+To+Contribute Reopening the issue was (Author: bibinchundatt): [~kailiu_dev] Apologies i thought issue is duplicate of YARN-8436 and you have close due to that. Fixed and resolved is only if the changes has gone into 3.2.0. Its that is not the case we have to keep the issue open. Please refer : https://cwiki.apache.org/confluence/display/HADOOP/How+To+Contribute Reopening the issue > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Priority: Major > Attachments: 0001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org
[jira] [Comment Edited] (YARN-9940) avoid continuous scheduling thread crashes while sorting nodes get 'Comparison method violates its general contract'
[ https://issues.apache.org/jira/browse/YARN-9940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16962833#comment-16962833 ] kailiu_dev edited comment on YARN-9940 at 10/30/19 9:15 AM: YARN-8436 May not be suitable for this issure. because : 1: node maybe be deleted, and if use {color:#00}TreeSet{color} will occure this exception: {color:#FF}java.util.ConcurrentModificationException{color} {color:#FF} at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:909){color} so: the current core is needed: List nodeIdList = new ArrayList(nodes.keySet()); synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } 2: the other reason {color:#172b4d}not be suitable{color} to use {color:#00}TreeSet{color} is when: compare(NodeId n1, NodeId n2) if n1==n2 the resultList of TreeSet only keep one, this will not suitable for continuous schedule, beause some node will not be {color:#172b4d}schedule{color}d {color:#172b4d}3:{color} in YARN-9940, we hold the sechdule lock to avoid exception while sorting when some node'Available resources change 4: Comparison method violates its general is Caused by JDK, from jdk7, Sorting algorithm is replaced with "TimSsort", about the continuous scheduling of Fair sechdule , there you can use two solutions: {color:#FF} one is : you can see YARN-9940, patch{color} {color:#FF} two is: add jvm option: {color:#33}-Djava.util.Arrays.useLegacyMergeSort={color}{color:#d73a49}true{color}{color} was (Author: kailiu_dev): YARN-8436 May not be suitable for this issure. because : 1: node maybe be deleted, and if use {color:#00}TreeSet{color} will occure this exception: java.util.ConcurrentModificationException at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:909) so: the current core is needed: List nodeIdList = new ArrayList(nodes.keySet()); synchronized (this) { Collections.sort(nodeIdList, nodeAvailableResourceComparator); } 2: the other reason {color:#172b4d}not be suitable{color} to use {color:#00}TreeSet{color} is when: compare(NodeId n1, NodeId n2) if n1==n2 {color:#172b4d}the result {color}{color:#172b4d}){color}{color:#007600} {color} if n1==n2 the result ) the resultList of TreeSet only keep one, this will not suitable for continuous schedule, beause some node will not be {color:#172b4d}schedule{color}d {color:#172b4d}3:{color} in YARN-9940, we hold the sechdule lock to avoid exception while sorting when some node'Available resources change * 4: Comparison method violates its general is Caused by JDK, from jdk7, Sorting algorithm is replaced with "TimSsort", about the continuous scheduling of Fair sechdule , there you can use two solutions: one is : you can see YARN-9940, patch two is: add jvm option: {color:#33}-Djava.util.Arrays.useLegacyMergeSort={color}{color:#d73a49}true{color} > avoid continuous scheduling thread crashes while sorting nodes get > 'Comparison method violates its general contract' > > > Key: YARN-9940 > URL: https://issues.apache.org/jira/browse/YARN-9940 > Project: Hadoop YARN > Issue Type: Bug > Components: fairscheduler >Affects Versions: 2.7.2 >Reporter: kailiu_dev >Priority: Major > Fix For: 3.2.0 > > Attachments: 0001.patch > > > 2019-10-16 09:14:51,215 ERROR > org.apache.hadoop.yarn.YarnUncaughtExceptionHandler: Thread > Thread[FairSchedulerContinuousScheduling,5,main] threw an Exception. > java.lang.IllegalArgumentException: Comparison method violates its general > contract! > at java.util.TimSort.mergeHi(TimSort.java:868) > at java.util.TimSort.mergeAt(TimSort.java:485) > at java.util.TimSort.mergeForceCollapse(TimSort.java:426) > at java.util.TimSort.sort(TimSort.java:223) > at java.util.TimSort.sort(TimSort.java:173) > at java.util.Arrays.sort(Arrays.java:659) > at java.util.Collections.sort(Collections.java:217) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler.continuousSchedulingAttempt(FairScheduler.java:1117) > at > org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.FairScheduler$ContinuousSchedulingThread.run(FairScheduler.java:296) -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org