You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@uniffle.apache.org by "kaijchen (via GitHub)" <gi...@apache.org> on 2023/02/17 09:22:01 UTC
[GitHub] [incubator-uniffle] kaijchen opened a new pull request, #623: [MINOR] refactor: address unchecked conversions
kaijchen opened a new pull request, #623:
URL: https://github.com/apache/incubator-uniffle/pull/623
### What changes were proposed in this pull request?
Fix or supress some unchecked conventions.
### Why are the changes needed?
Improve code quality and make the build log cleaner.
### Does this PR introduce _any_ user-facing change?
No.
### How was this patch tested?
CI.
--
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@uniffle.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org
[GitHub] [incubator-uniffle] kaijchen merged pull request #623: [MINOR] refactor: address unchecked conversions
Posted by "kaijchen (via GitHub)" <gi...@apache.org>.
kaijchen merged PR #623:
URL: https://github.com/apache/incubator-uniffle/pull/623
--
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@uniffle.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org
[GitHub] [incubator-uniffle] kaijchen commented on pull request #623: [MINOR] refactor: address unchecked conversions
Posted by "kaijchen (via GitHub)" <gi...@apache.org>.
kaijchen commented on PR #623:
URL: https://github.com/apache/incubator-uniffle/pull/623#issuecomment-1438084449
> is a linter to enforce this?
I don't know.
--
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@uniffle.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org
[GitHub] [incubator-uniffle] kaijchen commented on pull request #623: [MINOR] refactor: address unchecked conversions
Posted by "kaijchen (via GitHub)" <gi...@apache.org>.
kaijchen commented on PR #623:
URL: https://github.com/apache/incubator-uniffle/pull/623#issuecomment-1439541950
Thanks @advancedxy for the review.
--
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@uniffle.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org
[GitHub] [incubator-uniffle] kaijchen commented on a diff in pull request #623: [MINOR] refactor: address unchecked conversions
Posted by "kaijchen (via GitHub)" <gi...@apache.org>.
kaijchen commented on code in PR #623:
URL: https://github.com/apache/incubator-uniffle/pull/623#discussion_r1109778153
##########
client-spark/spark2/src/main/java/org/apache/spark/shuffle/RssShuffleManager.java:
##########
@@ -93,7 +93,7 @@ public class RssShuffleManager implements ShuffleManager {
private final String user;
private final String uuid;
private ThreadPoolExecutor threadPoolExecutor;
- private EventLoop eventLoop = new EventLoop<AddBlockEvent>("ShuffleDataQueue") {
+ private EventLoop<AddBlockEvent> eventLoop = new EventLoop<AddBlockEvent>("ShuffleDataQueue") {
Review Comment:
Can't
--
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@uniffle.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org
[GitHub] [incubator-uniffle] advancedxy commented on a diff in pull request #623: [MINOR] refactor: address unchecked conversions
Posted by "advancedxy (via GitHub)" <gi...@apache.org>.
advancedxy commented on code in PR #623:
URL: https://github.com/apache/incubator-uniffle/pull/623#discussion_r1109762936
##########
client-spark/spark2/src/main/java/org/apache/spark/shuffle/RssShuffleManager.java:
##########
@@ -93,7 +93,7 @@ public class RssShuffleManager implements ShuffleManager {
private final String user;
private final String uuid;
private ThreadPoolExecutor threadPoolExecutor;
- private EventLoop eventLoop = new EventLoop<AddBlockEvent>("ShuffleDataQueue") {
+ private EventLoop<AddBlockEvent> eventLoop = new EventLoop<AddBlockEvent>("ShuffleDataQueue") {
Review Comment:
`EventLoop<>` is preferred
##########
client-spark/spark3/src/main/java/org/apache/spark/shuffle/RssShuffleManager.java:
##########
@@ -102,8 +102,8 @@ public class RssShuffleManager implements ShuffleManager {
private String user;
private String uuid;
private Set<String> failedTaskIds = Sets.newConcurrentHashSet();
- private final EventLoop eventLoop;
- private final EventLoop defaultEventLoop = new EventLoop<AddBlockEvent>("ShuffleDataQueue") {
+ private final EventLoop<AddBlockEvent> eventLoop;
+ private final EventLoop<AddBlockEvent> defaultEventLoop = new EventLoop<AddBlockEvent>("ShuffleDataQueue") {
Review Comment:
ditto
--
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@uniffle.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org
[GitHub] [incubator-uniffle] kaijchen commented on a diff in pull request #623: [MINOR] refactor: address unchecked conversions
Posted by "kaijchen (via GitHub)" <gi...@apache.org>.
kaijchen commented on code in PR #623:
URL: https://github.com/apache/incubator-uniffle/pull/623#discussion_r1109509745
##########
client-mr/src/main/java/org/apache/hadoop/mapreduce/task/reduce/RssRemoteMergeManagerImpl.java:
##########
@@ -286,7 +286,7 @@ private RawKeyValueIterator finalMerge() throws IOException {
(RawComparator<K>)jobConf.getOutputKeyComparator();
// We will only merge sort once time
return Merger.merge(jobConf, remoteFS, keyClass, valueClass, codec,
- onHDFSMapOutputs.toArray(new Path[onHDFSMapOutputs.size()]), true, Integer.MAX_VALUE,
+ onHDFSMapOutputs.toArray(new Path[0]), true, Integer.MAX_VALUE,
Review Comment:
```suggestion
onHDFSMapOutputs.toArray(new Path[onHDFSMapOutputs.size()]), true, Integer.MAX_VALUE,
```
##########
client-mr/src/test/java/org/apache/hadoop/mapred/SortWriteBufferManagerTest.java:
##########
@@ -258,7 +261,7 @@ public void testWriteNormal() throws Exception {
assertTrue(manager.getWaitSendBuffers().isEmpty());
}
- class MockShuffleWriteClient implements ShuffleWriteClient {
+ static class MockShuffleWriteClient implements ShuffleWriteClient {
Review Comment:
```suggestion
class MockShuffleWriteClient implements ShuffleWriteClient {
```
##########
integration-test/spark3/src/test/java/org/apache/uniffle/test/GetShuffleReportForMultiPartTest.java:
##########
@@ -218,10 +218,10 @@ public <K, C> ShuffleReader<K, C> getReaderImpl(
ShuffleReadMetricsReporter metrics,
Roaring64NavigableMap taskIdBitmap) {
int shuffleId = handle.shuffleId();
- RssShuffleHandle rssShuffleHandle = (RssShuffleHandle) handle;
+ RssShuffleHandle<?, ?, ?> rssShuffleHandle = (RssShuffleHandle<?, ?, ?>) handle;
Map<Integer, List<ShuffleServerInfo>> allPartitionToServers = rssShuffleHandle.getPartitionToServers();
int partitionNum = (int) allPartitionToServers.entrySet().stream()
- .filter(x -> x.getKey() >= startPartition && x.getKey() < endPartition).count();
+ .filter(x -> x.getKey() >= startPartition && x.getKey() < endPartition).count();
Review Comment:
```suggestion
.filter(x -> x.getKey() >= startPartition && x.getKey() < endPartition).count();
```
--
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@uniffle.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@uniffle.apache.org
For additional commands, e-mail: issues-help@uniffle.apache.org