diff --git a/src/main/java/org/jboss/threads/ViewExecutor.java b/src/main/java/org/jboss/threads/ViewExecutor.java index 2d51af7..acbb71c 100644 --- a/src/main/java/org/jboss/threads/ViewExecutor.java +++ b/src/main/java/org/jboss/threads/ViewExecutor.java @@ -50,7 +50,7 @@ public static Builder builder(Executor delegate) { public static final class Builder { private final Executor delegate; - private short maxSize = 1; + private int maxSize = 1; private int queueLimit = Integer.MAX_VALUE; private Thread.UncaughtExceptionHandler handler = JBossExecutors.loggingExceptionHandler(); @@ -64,8 +64,7 @@ public int getMaxSize() { public Builder setMaxSize(final int maxSize) { Assert.checkMinimumParameter("maxSize", 1, maxSize); - Assert.checkMaximumParameter("maxSize", Short.MAX_VALUE, maxSize); - this.maxSize = (short) maxSize; + this.maxSize = maxSize; return this; }