Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Commits on Oct 15, 2015
  1. @roanta

    csl: bump lib versions

    roanta committed with jenkins
  2. @jcrossley

    finagle/finage-core: Make FailureAccrual markDeadFor use exponential …

    jcrossley committed with jenkins
    …backoff by default
    The default value for markDeadFor in FailureAccrualFactory is a constant,
    so frequently failing nodes are regularly reinstated after a timeout.
    FailureAccrualFactory uses jittered backoffs (starting at 5s, up to 300s)
    as the duration to mark dead for, if markDeadFor is not configured.
  3. @kevinoliver

    util-lint: Add lint package to flag questionable practices

    kevinoliver committed with jenkins
    There are a variety of best practices we can identify at runtime and
    use to help our users improve their service.
    Introduce a new util-lint module at com.twitter.util.lint which allows
    us to register `Rules` which when run can return 0 or more `Issues`.
    This commit adds a few rules:
     * Multiple `StatsReceivers` registered.
     * Large cumulative gauges.
     * Large number of requests to `StatsReceiver.{stat,counter,addGauge}`.
     * Duplicate names used for clients or servers.
    Users can visit /admin/lint with TwitterServer and see if there is
    anything they can improve with their service.
  4. Remove ex-employees from OWNERS files.

    Peter Schuller committed with jenkins
  5. @roanta

    finagle: add Hotel Urbano as an adopter

    roanta committed with jenkins
  6. [finagle-core, finagle-memcached] Add FixedInetResolver for clients o…

    Todd Segal committed with jenkins
    …r other resolvers that do not want to poll for DNS updates
    The InetResolver does not cache DNS lookups and polls every 5 seconds for updates per recent RB #735006. For certain scenarios this is not desireable as it can add hundreds of spurious lookups.
    -- The zk2 resolver deals with large serversets and does not want to relook up all entries on every membership change. In this case, we do not expect changes to be communicated via changing ip addresses but instead host name changes.
    -- The twemcached client uses a large fixed set of hosts serving different sections of the cache. These ip addresses should not be changing to indicate new servers in the set. Instead, it should change the hostnames.
    Allow clients to opt-into the "old" behavior of caching DNS lookups indefinitely. The zk2 resolver was already doing this. Promote the zk2 resolvers code to a new FixedInetResolver and have the twemclient builder specify its schema in its names.
  7. @roanta

    finagle-core: eagerly remove `Balancers` gauges on close

    roanta committed with jenkins
    Balancers can be re-constructed across the lifetime of a
    client via wily. Thus, it's important to cleanup exposed
    gauges when their context is closed in order to avoid avoid exposing
    noisy stats and occupying memory for longer than neccessary.
    Cleanup gauges exposed by the `Balancers` factory methods.
  8. @dschobel

    finagle-http: improve handling of oversized request payloads

    dschobel committed with jenkins
    Rather than returning a usable error status code on oversized request
    payloads our http codec implementation will throw an exception and
    forcibly close the offending client connection. This turns an
    application level error into a transport level failure which leaves
    clients guessing at what exactly went wrong.
    Related to this, finagle http servers will respond in the affirmative
    (100 CONTINUE) to clients seeking confirmation that a large payload
    is in fact allowed, moments before closing the client connection.
    Insert a pipeline handler before the chunk aggregator and before
    the ExpectContinue handler which fails fast on oversized requests
    and returns the correct error code.
    An actionable client side error code for oversized requests and no
    spurious 100 Continue responses to doomed client requests.
Commits on Oct 12, 2015
  1. @vkostyukov

    finagle-mux: Avoid synchronization on WindowedMax.get

    vkostyukov committed with jenkins
  2. @dschobel

    finagle-core: disable highres timer

    dschobel committed with jenkins
    Replace default highres timer instance with default hashwheel timer so that context is preserved.
  3. @jcrossley

    finagle/finagle-core:: Revived FailureAccrualFactory must satisfy a r…

    jcrossley committed with jenkins
    …equest before accepting more
    A service revived after failing can immediately accept many requests.
    It is more likely to fail these requests than a healthy service; it
    should be conservative after revival.
    After being revived, a FailureAccrualFactory enters a
    'probing' state wherein it must successfully satisfy a request before
    accepting more. If the request fails, it waits for the next 'markDeadFor'
  4. @kevinoliver

    finagle-core: RetryPolicy.tries now uses jittered backoffs

    kevinoliver committed with jenkins
    The simplest way of specifying a `RetryPolicy` via `ClientBuilder` is
    `ClientBuilder.retries` and this retry policy does not wait at all in
    between retries. This can have negative impacts on the downstream
    service should it already be struggling.
    Use a jittered backoff starting at 5 milliseconds and then using
    random backoff between 5 millis and 3x the previous backoff for the
    following retries. These backoffs are capped at 200 milliseconds.
    This is used by callers to `RetryPolicy.tries` which impacts
    `ClientBuilder.retries` and `RetryingService.tries`.
    `Backoff` was moved into its own file and adding some additional
    capabilities such as being able to specify a maximum for `linear`
    and `exponential` as well as introducing two new jittered backoffs,
    `exponentialJittered` and `decorrelatedJittered`.
    Better behaving clients should lead to more systemic resilience.
  5. @vkostyukov

    finagle: Remove finagle-swift

    vkostyukov committed with jenkins
  6. @amartinsn

    Adding to the list of adopters.

    amartinsn committed with jenkins
    Signed-off-by: Travis Brown <>
  7. @vkostyukov

    util-core: Remove deprecated methods on Time and Duration

    vkostyukov committed with jenkins
  8. @luciferous

    Rename finagle-httpx to finagle-http

    luciferous committed with jenkins
    Problem / Solution
    Rename finagle-httpx to finagle-http.
    USER_HOOK_ARGS=--i-am-evil -x .hooks/PRESUBMIT/validate-config-ini macaw-roi/.hooks/PRESUBMIT macaw-swift/.hooks/PRESUBMIT/check-swoop
  9. @roanta

    finagle-core: Remove weights from c.t.f.util.Ring

    roanta committed with jenkins
    We removed weights from the load balancer in a previous patch,
    but there are some residual references to weights that needed
    to be cleaned up.
    Remove weights from c.t.f.util.Ring which is used by aperture.
    This simplifies the construction of the aperture ring.
  10. @jjmmcc

    finagle.mux: make FailureDetector controllable via flags again

    jjmmcc committed with jenkins
    When FailureDetector.DarkModeConfig was made the default, it was done in a way that broke the ability to overwrite the default behavior via the `com.twitter.finagle.mux.sessionFailureDetector` flag (the flag simply doesn't do anything now).
    Added "dark" as a potential flag value, set that as the default, and switched the default `Param` value back to `GlobalFlagConfig`.  This keeps `DarkModeConfig` as the default, but allows the default to be changed.
  11. @dschobel

    make 2.11.7 the default scala version for csl OSS

    dschobel committed with jenkins
    Make 2.11.7 the default scala version for csl OSS and bump patch
    level of 2.10.
  12. @dschobel

    finagle-mux: fix flaky request draining test

    dschobel committed with jenkins
    Mux's ClientTest is asserting properties against a global log which
    picks up messages beyond the test events we want to inspect. This
    makes the test flaky.
    Rewrite based on metrics and a local SR instance.
  13. @nshkrob

    finagle-thrift: Fix thrift server construction for extended services

    nshkrob committed with jenkins
    Given a thrift service ExtendedEcho that extends service Echo, constructing a service with
    Thrift.serveIface(addr, new ExtendedEcho.FutureIface { ... } )
    produces an Echo server, i.e. a server that's not aware of ExtendedEcho's methods. The symptom is that the server throws 'TApplicationException: Invalid method name' when called with the methods from ExtendedEcho. The cause is a bug in reflection code (the constructor takes ExtendedEcho[Future], not ExtendedEcho$FutureIface).
    Use the correct class when searching for the constructor.
  14. @vkostyukov

    finagle: Remove finagle-stress

    vkostyukov committed with jenkins
    `finagle-stress` is pretty dead and should be removed.
    Remove `finagle-stress` and its the only one dependee (which is also pretty
    dead) - `caccie/cassie-stress`.
    1500 LOCs have been removed.
  15. @mosesn

    finagle-core: Stop recording transit latency and deadline budget for …

    mosesn committed with jenkins
    Finagle records transit latency for clients, but only servers
    care about it.
    Move the transit latency stat out of StatsFilter and into
    ServerStatsFilter. Handletime is also a server-specific stat,
    so moved that into ServerStatsFilter too, and deleted
    HandletimeFilter.  This has the added advantage of recording
    transit latency at the same time we do handletime, which is one
    of the earliest points.
    This review also handles some other miscellaneous cleanup,
    making no-allocation, testable, elapsed duration easier to use,
    adding tests for handletime, transit latency and deadline budget.
    Finagle services no longer export transit_latency_ms or
    deadline_budget_ms for clients.  It's not useful for clients,
    so it's safe to remove it.
  16. @nshkrob

    finagle: [docs, tiny] Fix newServiceIface usage in scaladoc

    nshkrob committed with jenkins
    newServiceIface takes a ServiceIface type param.
    Correct the usage in the comment.
  17. @nshkrob

    finagle-benchmark: Move the thrift out to work around the nested obje…

    nshkrob committed with jenkins
    …ct bug
    Due to, JMH doesn't work on scrooge-generated scala files after the service-per-endpoint patch.
    The problem is the triple-nested objects introduced in the service-per-endpoint Scrooge patch. E.g.
    object Hello {
      object Hi {
        object Args {}
    val args: Hello.Hi.Args = Hello.Hi.Args()
    println(args.getClass.getSimpleName) // throws InternalError: Malformed class name
    Work around the bug by moving thrift out of finagle-benchmark into a new sbt project finagle-benchmark-thrift.
    JMH only introspects classes in the current project, not the dependencies, so finagle-benchmark works.
    Alternative approach
    I've tried changing the outer 'object Hello' to a namespace. That doesn't work because it encloses implicit objects that must be in an enclosing object scope.
  18. [finagle-core, traffic] Allow libraries to configure defaults for Lat…

    Todd Segal committed with jenkins
    …encyCompensator. Add Twitter-Server-Internal override
    Libraries cannot configure default settings for the LatencyCompensator module in the finagle stack client.
    Add a `DefaultOverride` for the LatencyCompensator that can be set once per-process. If multiple callers attempt to set the override, the second caller will receive 'false' and it is up to the caller to determine how to handle failure.
  19. @adriancole

    Removes zipkin annotation.duration

    adriancole committed with jenkins
    The OpenZipkin project dropped support for Annotation.duration. This
    field was rarely used, and when used often incorrectly. Moreover, the
    zipkin query and web interfaces didn't support it. Dropping it
    implicitly fixed bugs and confusion around the topic. This happened in
    zipkin 1.9, and finagle-zipkin is the last trace instrumentation library
    left to adjust.
    See openzipkin/zipkin#717
    Signed-off-by: Daniel Schobel <>
  20. Make Zookeeper -client and -server usages explicit across source repo.

    Chris Chen committed with jenkins
    The current ZooKeeper jar is a monolithic artifact that contains client and
    server classes. In order to make client and server usages clearer and prep
    for a upcoming split of the artifact, we need to do some classification.
    Create placeholder zookeeper-client and zookeeper-server targets. Make those
    usages explicit in build targets.
    Dependencies are more clear, and it will be easier to introduce split artifacts.
  21. @dschobel

    finagle-core: ignore consistently failing tests

    dschobel committed with jenkins
Commits on Oct 5, 2015
  1. @vkostyukov

    finagle-mux: Optimize WindowedMax

    vkostyukov committed with jenkins
    `WindowedMax` which is used by our `ThresholdFailureDetector` creates small structs, `AgedLong`s,
    which have the unfortunate behavior of having medium lifetimes which is what the JVM's garbage
    collector wants to avoid.
    Allocate once. Use everywhere.
    Zero allocations for `add`. Slightly better peformance.
  2. @atollena

    Revert "finagle-serversets: Use FutureCache for pending getData calls"

    atollena committed with jenkins
    This seems to cause problems resolving the eventbus provisioning serverset
    (serverset!eventbus/prod/provisioning). I could reproduce by creating a tunnel to nest in atla.
  3. @roanta

    util-core: decommission scheduler clock stats

    roanta committed with jenkins
    The Scheduler clock stats were decommissioned as they only make
    sense relative to `wallTime` and the tracking error we have experienced
    in production between `wallTime` and `*Time` make it impossible to use
    them reliably. It is not worth the performance and code complexity
    to support them.
  4. @tw-ngreen

    finagle-serversets: Use FutureCache for pending getData calls

    tw-ngreen committed with jenkins
    We were not caching futures for calls to getData, thus we
    sometimes called getData redundantly for the same node, wasting
    effort and allocations.
    Properly cache futures for getData calls. Use util-cache's
    LoadingFutureCache. Also simplified the code to make it
    easier to reason about.
    We don't call getData redundantly, we allocated less memory
    when fetching serversets.
  5. @luciferous

    Privatize Netty types in DefaultTimer and TimerFromNettyTimer

    luciferous committed with jenkins
    DefaultTimer and TimerFromNettyTimer leak org.jboss.netty.util.Timer.
    Rename TimerFromNettyTimer to HashedWheelTimer, make them private to
    finagle and provide compatible generic constructors. To migrate, users
    should be able to pass the same parameters used to construct the Netty
    HashedWheelTimer directly into Finagle HashedWheelTimer.
        val timer = new TimerFromNettyTimer(
          new netty.HashedWheelTimer(tickDuration, TimeUnit.MILLISECONDS))
        val timer = finagle.HashedWheelTimer(tickDuration.milliseconds)
  6. @dschobel

    finagle-core: add netty3 owners file

    dschobel committed with jenkins
Something went wrong with that request. Please try again.