Skip to content

Commit

Permalink
for checkstyle
Browse files Browse the repository at this point in the history
  • Loading branch information
tuohai666 committed Jul 20, 2018
1 parent 9866b5b commit dc49530
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@

package io.shardingsphere.proxy.backend.common.jdbc.execute;

import io.netty.channel.EventLoopGroup;
import io.shardingsphere.core.merger.QueryResult;
import io.shardingsphere.proxy.backend.common.SQLExecuteEngine;
import io.shardingsphere.proxy.backend.common.jdbc.BackendConnection;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@ private EventLoopGroup createEventLoopGroup() {
}

private void groupsEpoll(final ServerBootstrap bootstrap) {
bossGroup = new EpollEventLoopGroup(1);
workerGroup = new EpollEventLoopGroup(ruleRegistry.getMaxWorkingThreads());
bootstrap.group(bossGroup, workerGroup)
.channel(EpollServerSocketChannel.class)
Expand All @@ -111,7 +110,6 @@ private void groupsEpoll(final ServerBootstrap bootstrap) {
}

private void groupsNio(final ServerBootstrap bootstrap) {
bossGroup = new NioEventLoopGroup(1);
workerGroup = new NioEventLoopGroup(ruleRegistry.getMaxWorkingThreads());
bootstrap.group(bossGroup, workerGroup)
.channel(NioServerSocketChannel.class)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ public final class ExecutorGroup {
* @return executor service
*/
public ExecutorService getExecutorService() {
return TransactionType.XA.equals(RuleRegistry.getInstance().getTransactionType()) ? ChannelThreadExecutorGroup.getInstance().get(channelId) : ExecutorContext.getInstance().getExecutorService();
return TransactionType.XA.equals(RuleRegistry.getInstance().getTransactionType()) ? ChannelThreadExecutorGroup.getInstance().get(channelId)
: ExecutorContext.getInstance().getExecutorService();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@
package io.shardingsphere.proxy.util;

import com.google.common.util.concurrent.MoreExecutors;
import io.netty.channel.EventLoopGroup;
import io.netty.channel.epoll.EpollEventLoopGroup;
import io.netty.channel.nio.NioEventLoopGroup;
import io.shardingsphere.proxy.config.RuleRegistry;
import lombok.Getter;

Expand All @@ -37,7 +34,7 @@ public final class ExecutorContext {
private static final ExecutorContext INSTANCE = new ExecutorContext();

@Getter
private final ExecutorService executorService = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(RuleRegistry.getInstance().getMaxWorkingThreads()));;
private final ExecutorService executorService = MoreExecutors.listeningDecorator(Executors.newFixedThreadPool(RuleRegistry.getInstance().getMaxWorkingThreads()));

/**
* Get executor context instance.
Expand Down

0 comments on commit dc49530

Please sign in to comment.