Implement optimized compression for Java 11+
Using the fact that the Java Deflater/Inflater API now supports ByteBuffers as of Java 11, we can provide performance benefits equivalent to the Velocity 1.0.x native compression on servers running Java 11+ on non-macOS and non-Linux platforms (such as Windows).
This commit is contained in:
@@ -17,7 +17,7 @@ public class VelocityNettyThreadFactory implements ThreadFactory {
|
||||
|
||||
@Override
|
||||
public Thread newThread(Runnable r) {
|
||||
String name = String.format(nameFormat, threadNumber.incrementAndGet());
|
||||
String name = String.format(nameFormat, threadNumber.getAndIncrement());
|
||||
return new FastThreadLocalThread(r, name);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user