Finagle v7.0.0 Release Notes
-
๐ New Features
* ๐ง finagle-core: A `StackClient` can be configured with a `c.t.u.tunable.Tunable` request timeout using `.withRequestTimeout(tunable)`; this facilitates changing the timeout at runtime, without server restart. See https://twitter.github.io/finagle/guide/Configuration.html#tunables for details. ``PHAB_ID=D80751``. * finagle-core: `SslClientSessionVerifier` and `SslServerSessionVerifier` have been added as `Stack` params for executing custom SSL/TLS `Session` verification logic on the establishment of an SSL/TLS `Session`. ``PHAB_ID=D63256`` * finagle-core: `tls` methods which take an `SslClientSessionVerifier` have been added to `ClientBuilder` and `ClientTransportParams` (withTransport.tls). `tls` methods which take an `SslServerSessionVerifier` have been added to `ServerBuilder` and `ServerTransportParams` (withTransport.tls). ``PHAB_ID=D68645`` * 0๏ธโฃ finagle-core: Timer tasks submitted to the `c.t.f.util.DefaultTimer` can have their execution time monitored. Slow executing tasks may result in a log message at level WARN and a counter of slow tasks is kept under `finagle/timer/slow`. This can be enabled using the global flag `c.t.f.util.defaultTimerProbeSlowTasks` and the maximum allowed runtime and minimum duration between log messages can be tuned using the global flags `c.t.f.util.defaultTimerSlowTaskMaxRuntime`, and `c.t.f.util.defaultTimerSlowTaskLogMinInterval`, respectively. ``PHAB_ID=D70279`` * ๐ finagle-core: The JVM metrics for GC, allocations, memory, and more have moved here from TwitterServer. See the new JVM section in the user guide for details: https://twitter.github.io/finagle/guide/Metrics.html ``PHAB_ID=D80883`` * finagle-http, finagle-thriftmux: `MethodBuilder` has been promoted out of experimental. `MethodBuilder` is a collection of APIs for client configuration at a higher level than the Finagle 6 APIs while improving upon the deprecated `ClientBuilder`. See the user guide for details: https://twitter.github.io/finagle/guide/MethodBuilder.html ``PHAB_ID=D60032`` * finagle-http: add `withNoAutomaticContinue` api to disable automatically sending 100 CONTINUE responses. ``PHAB_ID=D80017`` * finagle-http: The nack related logic in the `c.t.f.h.c.HttpClientDispatcher` has been moved into a filter, `c.t.f.h.f.ClientNackFilter` which has been added to the client stack and can now be removed based on its `Stack.Role`. ``PHAB_ID=D78902`` * ๐ finagle-init: Introduce a module to support service-loading initialization code. ``PHAB_ID=D75950`` * ๐ finagle-memcached: Added support for partitioned backends in finagle client. Introducing the new PartitioningService (``PHAB_ID=D75143``), KetamaPartitioningService (``PHAB_ID=D77499``) and MemcachedPartitioningService (``PHAB_ID=D78927``), which provide this support at different levels of abstraction. The c.t.f.Memcached util, that is used for creating new memcached clients, now creates a new partitioning client that utilizes these new services for the Memcached protocol. The new memcached client can be enabled by setting the toggle "com.twitter.finagle.memcached.UsePartitioningMemcachedClient" to 1.0. ``PHAB_ID=D80352`` * 0๏ธโฃ finagle-mux: Default to new more efficient decoder. ``PHAB_ID=D80225`` * ๐ finagle-mysql: `IsolationLevel` support was added with `Transactions.transactionWithIsolation` method, so the default level can be overridden at the transaction level. ``PHAB_ID=D68944`` * ๐ finagle-mysql: Add support for unsigned integers. When enabled, unsigned integers that do not fit into the existing signed representation are widened. For example an unsigned Int32 is represented as a Java Long, etc. Because this changes the `c.t.f.mysql.Value` variant returned by the row, it is disabled by default and must be enabled with the param `c.t.f.Mysql.param.UnsignedColumns`. ``PHAB_ID=D78721`` * 0๏ธโฃ finagle-netty4: Adds support for passing a chain file to the default TLS implementation. ``PHAB_ID=D59531`` * 0๏ธโฃ finagle-netty4: Netty 4 transports now use pooled allocators by default. ``PHAB_ID=D75014`` * finagle-netty4: `KeyCredentials.CertKeyAndChain` is now available to use with `Netty4ServerEngineFactory`. ``PHAB_ID=D80494`` * 0๏ธโฃ finagle-netty4: `c.t.f.netty4.trackReferenceLeaks` is now a CLI flag (default: disabled) rather than a toggle. ``PHAB_ID=D80654`` * finagle-stats: Metrics now report verbosity levels via `MetricsView.verbosity`. ``PHAB_ID=D78150`` * 0๏ธโฃ finagle-stats: `JsonExporter` now respects verbosity levels (current default behavior is to keep exporting "debug" metrics). Adjust `com.twitter.finagle.stats.verbose` tunable whitelist to change it. ``PHAB_ID=D79571`` * finagle-tunable: `StandardTunableMap` is now public. Users can access file-based, in-memory, and service-loaded tunable values using the map. See https://twitter.github.io/finagle/guide/Configuration.html#tunables for details. ``PHAB_ID=D80751``. * finagle: Changed dependencies of Netty from 4.1.10 to 4.1.12. ``PHAB_ID=D60438`` ๐ Bug Fixes ~~~~~~~~~ * finagle-mysql: Fix decoding error for medium length integers. ``PHAB_ID=D78505`` ๐ฅ Breaking API Changes
finagle: Finagle is now decoupled from Netty 3. Depend on
finagle-netty3
explicitly if needed.PHAB_ID=D65268
๐จ finagle-base-http: The HTTP message model has been refactored to remove backing Netty 3 types. Additionally, the
Request
andResponse
classes now have private constructors to enforce a more appropriate inheritance model:Request.Proxy
andResponse.Proxy
are now the point of entry for extending the HTTP model types. Along with the model changes the InputStream generated.getInputStream()
method of HTTP messages no longer consumes the messages body.PHAB_ID=D74519
finagle-core: The Framer type has been transformed into a specialized version of a more generic abstraction, Decoder[T].
PHAB_ID=D59495
finagle-core: Replace the
c.t.f.context.RemoteInfo.Available
constructor which takesClientId
in favor of a version takingString
.ClientId
is Twitter's Thrift specific concept and this should be more generic.PHAB_ID=D60136
๐ finagle-core: Remove the ability to set a global address sort. This is no longer necessary as setting this per client is sufficient.
PHAB_ID=D60698
๐ finagle-core: Remove global flag
com.twitter.finagle.tracing.debugTrace
. This functionality is better suited as a concreteTracer
implementation instead of mixed into the generic code.PHAB_ID=D63252
finagle-core:
PHAB_ID=D63526
ClientBuilder.codec
andServerBuilder.codec
have been removed. Use.stack
instead.ClientBuilder.channelFactory
andServerBuilder.channelFactory
have been removed. Use.stack
instead.
finagle-core: LoadBalancerFactory now takes
Stack.Params
which allows a client to more easily pass in the stack context.PHAB_ID=D73129
finagle-memcached: Add
c.t.util.Closable
trait toc.t.f.memcached.BaseClient
.PHAB_ID=D63970
finagle-mysql: A number of implementation details were made private such as specific
Row
implementations andResultSet
builder functions that consume raw packets.PHAB_ID=D78721
finagle-netty4-http: HTTP/1.1 implementation based on Netty 4 is no longer experimental and is moved out of the
exp
package.PHAB_ID=D80181
๐ finagle-serversets: Remove
ZkMetaData.AddressOrdering
, it is no longer used.
PHAB_ID=D60698
`finagle-stats:
c.t.f.stats.MetricsStatsReceiver
no longer has constructor variants which take ac.t.u.events.Sink
as util-events is now deprecated.PHAB_ID=D64437
๐ finagle-thrift: The Netty3 thrift implementation has been removed.
PHAB_ID=D63670
finagle-zipkin-core:
c.t.f.zipkin.core.SamplingTracer
no longer has constructor which takes ac.t.u.events.Sink
as util-events is now deprecated.PHAB_ID=D64437
finagle-zipkin: Zipkin Tracer now exports only three counters:
requests
,failures
,success
.PHAB_ID=D71965
โ Runtime Behavior Changes
* finagle-core: The `AsyncSemaphore` which sequences dispatches in `GenSerialClientDispatcher` is now failed with a retryable `Failure` so that the retry logic knows that requests that which failed to acquire the semaphore are safe to retry. ``PHAB_ID=D78904`` * finagle-http: `serverErrorsAsFailuresV2` toggle is turned into a flag `serverErrorsAsFailures`. ``PHAB_ID=D73265`` * finagle-http: Dispatcher stats are now exported under the client scope like all other client stats.``PHAB_ID=D72265`` * finagle-http: It's now possible to send a response from the HTTP server that has a Content-Length header so long as the 'Transfer-Encoding: chunked' isn't set on the response. ``PHAB_ID=D80087`` * finagle-http: Non-streaming servers strip 'expect' headers when a 100 CONTINUE response is sent. ``PHAB_ID=D80017`` * finagle-serversets: `Stabilizer` is no longer exporting `pending_tasks` and `deviation_ms` stats. See `notify_ms` instead. ``PHAB_ID=D65571`` * finagle-stats, finagle-zipkin-core: No longer publishing `c.t.u.events` as util-events is now deprecated. ``PHAB_ID=D64437`` * finagle-stats: No longer backed by commons metrics, now its own thing. ``PHAB_ID=D73497`` * 0๏ธโฃ finagle-netty4: Unset Netty's default timeout (10 seconds) for SSL handshake on clients. Use `.withSession.acquisitionTimeout` instead. ``PHAB_ID=D78500``