Skip to content

Commit

Permalink
Use rss.rpc.server.type to judge whether Netty is enabled or not
Browse files Browse the repository at this point in the history
  • Loading branch information
rickyma committed Feb 21, 2024
1 parent d159181 commit d84cf09
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@

import org.apache.uniffle.common.ShuffleDataResult;
import org.apache.uniffle.common.ShufflePartitionedData;
import org.apache.uniffle.common.rpc.ServerType;
import org.apache.uniffle.common.rpc.StatusCode;
import org.apache.uniffle.common.util.Constants;
import org.apache.uniffle.common.util.JavaUtils;
Expand Down Expand Up @@ -83,7 +84,7 @@ public class ShuffleBufferManager {
protected Map<String, Map<Integer, AtomicLong>> shuffleSizeMap = JavaUtils.newConcurrentMap();

public ShuffleBufferManager(ShuffleServerConf conf, ShuffleFlushManager shuffleFlushManager) {
this.nettyServerEnabled = conf.get(ShuffleServerConf.NETTY_SERVER_PORT) >= 0;
this.nettyServerEnabled = conf.get(ShuffleServerConf.RPC_SERVER_TYPE) == ServerType.GRPC_NETTY;
long heapSize = Runtime.getRuntime().maxMemory();
this.capacity = conf.getSizeAsBytes(ShuffleServerConf.SERVER_BUFFER_CAPACITY);
if (this.capacity < 0) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ public void handleSendShuffleDataRequest(TransportClient client, SendShuffleData
+ appId
+ "], shuffleId["
+ shuffleId
+ "], probably due to the pre-allocated buffer has expired. "
+ "], probably because the pre-allocated buffer has expired. "
+ "Please increase the expiration time using "
+ ShuffleServerConf.SERVER_PRE_ALLOCATION_EXPIRED.key()
+ " in ShuffleServer's configuration";
Expand Down

0 comments on commit d84cf09

Please sign in to comment.