Just in time for the official start to summer 🏝 our June releases are here!
Finagle 18.6.0, Finatra 18.6.0, Scrooge 18.6.0, TwitterServer 18.6.0, and Util 18.6.0.
Runtime Behavior Changes:
finagle-core: By default, the deterministic aperture load balancer doesn’t expand based on the loadband. This is because the loadband is influenced by a degree of randomness, and this breaks the deterministic part of deterministic aperture and can lead to aggressive banding on backends. 3d84e297
finagle-http2: Unprocessed streams are retryable in case of GOAWAY. 2c89cb9e
New Features:
finagle-core: Add PropagateDeadlines Stack.Param to TimeoutFilter for
disabling propagation of deadlines to outbound requests.
8041fbb9
finagle-core: Add toString implementations to c.t.finagle.Service and
c.t.finagle.Filter. Update in Filter#andThen composition to expose a
useful toString for composed Filters and a composed Service (a Filter chain
with a terminal Service or ServiceFactory).
The default implementation for Filter and Service is getClass.getName. When
composing filters, the andThen composition method correctly tracks the composed
parts to produce a useful toString, e.g.,
package com.foo
import com.twitter.finagle.{Filter, Service}
import com.twitter.util.Future
class MyFilter1 extends Filter[Int, Int, Int, Int] {
def apply(request: Int, service: Service[Int, Int]): Future[Int] = ???
}
...
package com.foo
import com.twitter.finagle.{Filter, Service}
import com.twitter.util.Future
class MyFilter2 extends Filter[Int, Int, Int, Int] {
def apply(request: Int, service: Service[Int, Int]): Future[Int] = ???
}
val filters = (new MyFilter1).andThen(new MyFilter2)
filters.toString would emit the String “com.foo.MyFilter1.andThen(com.foo.MyFilter2)”
If a Service (or ServiceFactory) were then added:
import com.twitter.finagle.{Filter, Service}
import com.twitter.finagle.service.ConstantService
import com.twitter.util.Future
...
val svc: Service[Int, Int] = filters.andThen(new ConstantService[Int, Int](Future.value(2)))
Then, svc.toString would thus return the String:
“com.foo.MyFilter1.andThen(com.foo.MyFilter2).andThen(com.twitter.finagle.service.ConstantService(ConstFuture(2)))”
Filter implementations are permitted to override their toString implementations which would
replace the default of getClass.getName. 25474da1
finagle-core: Make Filter.TypeAgnostic an abstract class for Java usability.
6534e459
finagle-core: c.t.f.filter.NackAdmissionFilter is now public. 1855566d
finagle-core: Extended c.t.f.ssl.KeyCredentials and c.t.f.ssl.TrustCredentials to work
with javax.net.ssl.KeyManagerFactory and javax.net.ssl.TrustManagerFactory respectively.
c863ca0b
Breaking API Changes:
DeadlineFilter.Param(maxRejectFraction) to
DeadlineFilter.MaxRejectFraction(maxRejectFraction) to reduce confusion
when adding additional params.
cb6975afBug Fixes:
finagle-http2: StreamTransportFactory now marks itself as dead/closed when it runs out of
HTTP/2 stream IDs instead of stalling. This allows the connection to be closed/reestablished in
accordance with the spec c5554673
finagle-netty4: SslServerSessionVerifier is now supplied with the proper peer address
rather than Address.failing. 263e9786
finagle-thrift/thriftmux: Disabled client side per-endpoint stats by default for client
ServicePerEndpoint. It can be set via c.t.f.thrift.RichClientParam or a with-method
as Thrift{Mux}.client.withPerEndpointStats. 0f1ff3eb
finagle-netty4: Avoid NoClassDefFoundError if netty-transport-native-epoll is not available on the classpath. 940809af
Added:
finatra: Add HTTP route, Thrift method, and Filter information to the Library registry. e12fd996
finatra-inject/inject-logback: Add an c.t.inject.logback.AsyncAppender to
provide metrics about the underlying queue. 8fa73604
Changed:
inject-slf4j to inject-app
and inject-server. This allows code in the inject framework to be mostly useful in
environments where having the bridges on the classpath causes issues. 9e57decaFixed:
finatra-http: Fail startup for incorrect Controller callback functions. Controller route callback
functions that do not specify an input parameter or specify an incorrect input parameter should
fail server startup but were not correctly detected when building routes in the CallbackConverter.
The route building logic has been patched to correctly detect these routes which would fail at
runtime to ensure we fail fast at server startup (and can thus be caught by StartupTests).
7b983dc9
finatra-http: Change exceptions emitted from c.t.f.http.filter.HttpNackFilter to not extend
from HttpException and add a specific mapper over HttpNackException such that Nack
exceptions are handled distinctly from HttpExceptions and thus more specifically. Handling of
Nack exceptions should not be conflated with handling of the more generic HttpExceptions and
it should be clear if a new mapper is desired that it is specifically for changing how Nack
exceptions are handled. f95bf28f
New Features:
API Changes:
util-app: Allow users a way to override the argument parsing behavior in
c.t.app.App#nonExitingMain which was inlined. Users can override parseArgs
to define custom behavior. cf7860e5
util-core: Removed c.t.u.NonFatal, use scala.util.control.NonFatal
instead. 57533b34
util-class-preloader: This library has been removed since it deprecated. We no longer recommend that people do this. af41e634
Bug Fixes:
URLClassLoader#getURLs can
return null, failing LoadService from initializing properly
(see: https://github.com/google/guava/issues/2239). The URLClassLoader javadoc
is not clear if a null can be returned when calling URLClassLoader#getURLs and for
at least one application server, the default returned is null, thus we should be more
resilient against this possibility. Fixes Finagle #695. 3adca94aDeprecations:
New Features: