scrooge

A Thrift parser/generator

APACHE-2.0 License

Stars
789
Committers
221

Bot releases are hidden (Show)

scrooge - Scrooge 19.2.0

Published by finaglehelper over 5 years ago

No Changes

scrooge - Scrooge 19.1.0

Published by finaglehelper almost 6 years ago

  • Update asm, cglib, jmock dependencies 688cd29e
scrooge - Scrooge 18.12.0

Published by finaglehelper almost 6 years ago

18.12.0

  • scrooge-generator: Set a LocalContext value with the current Thrift method in the
    generated Java and Scala code such that the application Service[-R, +R] being executed has
    access to information about the current Thrift method being invoked. 09da3397
scrooge - Scrooge 18.11.0

Published by finaglehelper almost 6 years ago

  • scrooge-generator: Allow for Filter.TypeAgnostic filters to be applied to a generated
    Java Service via a new constructor that takes an additional argument of a Filter.TypeAgnostic.
    This filter is then applied per generated method service. 19c7d58b
scrooge - Scrooge 18.10.0

Published by finaglehelper almost 6 years ago

  • scrooge: Add type annotations to public members in generated code.
    5cad1005
scrooge - Scrooge 18.9.1

Published by finaglehelper about 6 years ago

  • scrooge: Finally remove maven.twttr.com as a dependency or plugin repository. With
    the update to a more recent libthrift dependency, this should no longer be necessary.
    44db8e16
scrooge - Scrooge 18.9.0

Published by finaglehelper about 6 years ago

18.9.0

New Features

  • scrooge-generator: Scala and Java generated Thrift exceptions now
    implement c.t.f.FailureFlags. This allows exceptions to carry
    Finagle metadata such as non-retryable. 438599b0
scrooge - Scrooge 18.8.0

Published by finaglehelper about 6 years ago

18.8.0

  • scrooge-core: Add interface for Scala generated Enum objects. c27d13ef

  • scrooge-core: Trait c.t.scrooge.ThriftService is now c.t.finagle.thrift.ThriftServiceMarker.
    Scrooge generated service objects now all inherit from c.t.finagle.thrift.ThriftService. Also,
    the AsClosableMethodName string was formerly part of c.t.finagle.thrift.ThriftService, but
    now is defined in the c.t.scrooge package object.
    125e955e

  • scrooge-generator: Thrift service objects now contain unsafeBuildFromMethods, which constructs
    a ReqRepServicePerEndpoint from a map of
    ThriftMethod -> ThriftMethod.ReqRepServicePerEndpointServiceType. It is unsafe because the
    types are not checked upon service construction, only when a request is attempted.
    125e955e

scrooge - Scrooge 18.7.0

Published by finaglehelper over 6 years ago

  • scrooge-adaptive: Turn the scrooge-adaptive back on as default in ScroogeRunner. 633e0f26
scrooge - Scrooge 18.6.0

Published by finaglehelper over 6 years ago

No Changes

scrooge - Scrooge 18.5.0

Published by finaglehelper over 6 years ago

  • scrooge-generator: Add support for construction_required fields in cocoa. 692a57ef

  • scrooge-generator: Add cocoa initializer for each field in union. 904f5981

  • scrooge-generator: Add support for empty struct in cocoa. 2c9dcde2

  • scrooge-generator: Fix setter bug for non-primitive type in cocoa. 04d654fc

  • scrooge-adaptive: Turn the scrooge-adaptive off as default in ScroogeRunner due to
    incompatibility with sbt > 1.0.2. 289dc650

scrooge - Scrooge 18.4.0

Published by finaglehelper over 6 years ago

  • scrooge-generator: Add support for construction_required fields. Add a validateNewInstance method
    to all generated scala companion objects. cbde3312

  • scrooge-core: Check for corruption in size meta field of container and throw
    an exception if size is found corrupted. 75392161

  • scrooge: Upgrade libthrift to 0.10.0. 997f2464

scrooge - Scrooge 18.3.0

Published by finaglehelper over 6 years ago

  • scrooge-generator: Add support for mutually recursive structs. 2a731bbc
scrooge - Scrooge 18.2.0

Published by finaglehelper over 6 years ago

  • scrooge-generator: Add asClosable method to ServicePerEndpoint and
    ReqRepServicePerEndpoint interfaces as well. 597864ac

  • scrooge-generator: Remove unused functionToService and serviceToFunction
    methods along with ServiceType and ReqRepServiceType type aliases in
    order to simplify code generation.

    NOTE: This functionality can be manually replicated by users if/when needed
    to convert between a Function1 and a Finagle Service. 2d25eb25

  • scrooge-generator: Scala generated client now has a asClosable method returns c.t.u.Closable,
    client now can be closed by calling client.asClosable.close. Note that asClosable won't be
    generated if it is also defined by the user. 1fa4f0c6

  • scrooge-generator: Renamed subclasses of com.twitter.scrooge.RichResponse:
    ProtocolExceptionResponse, SuccessfulResponse, and ThriftExceptionResponse.
    These case classes are for representing different response types and should be only
    used by the generated code. 2194e77d

scrooge - Scrooge 18.1.0

Published by cacoco over 6 years ago

  • scrooge-generator: Update c.t.fingale.thrit.service.MethodPerEndpointBuilder
    to build MethodPerEndpoint types. Add new ThriftServiceBuilder for
    building the higher-kinded form from a ServicePerEndpoint. Users should
    prefer using the MethodPerEndpointBuilder. PHAB_ID=D127538

  • scrooge-generator: Add more metadata to generated java objects PHAB_ID=D122997
    Includes:

    • struct and field annotations from the idl files
    • which fields have default values
    • which field values of TType.STRING are actually binary fields
  • scrooge: Add support for scrooge.Request and scrooge.Response
    types in generated ThriftMethod code. PHAB_ID=D122767

scrooge - Scrooge 17.12.0

Published by isabelmartin almost 7 years ago

  • scrooge: Introduce scrooge.Request and scrooge.Response envelopes which
    are used in ReqRepServicePerEndpoint interfaces and associated code. The
    scrooge Request and Response allow for passing "header" information (via
    ThriftMux Message contexts) between clients and servers. For instance, a
    server can implement a ReqRepServicePerEndpoint, and set response headers
    along with a method response, e.g.,

    class MyService extends MyService.ReqRepServicePerEndpoint {
    
      def foo: Service[Request[Foo.Args], Response[Foo.SuccessType]] = {
        Service.mk[Request[Foo.Args], Response[Foo.SuccessType]] { request: Request[Foo.Args] =>
          val result = ... // computations
          Future
            .value(
              Response(
                headers = Map("myservice.foo.header" -> Seq(Buf.Utf8("value1"))),
                result)
        }
      }
    }
    

    This ServicePerEndpoint can then be served using ThriftMux:

    ThriftMux.server.serveIface(":9999", new MyService().toThriftService)
    

    These response headers will be transported as Mux#contexts to the client. If
    the client is using the client-side ReqRepServicePerEndpoint it will be able
    to read the headers from the returned Response directly. E.g.,

    val client = ThriftMux.client.reqRepServicePerEndpoint[MyService.ReqRepServicePerEndpoint]
    
    val response: Response[Foo.SuccessType] = Await.result(client.foo(..))
    
    if (response.headers.contains("myservice.foo.header")) {
      ...
    

    Users can also choose to wrap the ReqRepServicePerEndpoint with a MethodPerEndpoint
    via ThriftMux.client.reqRepMethodPerEndpoint(reqRepServicePerEndpoint) in order to
    deal with methods instead of services. See the scrooge documentation for more information.
    aa1fb0c0

scrooge - Scrooge 17.11.0

Published by mosesn almost 7 years ago

  • scrooge-generator: Deprecated some scala generated classes and use new ones
    FutureIface -> MethodPerEndpoint,
    MethodIface -> MethodPerEndpoint.apply(),
    MethodIfaceBuilder -> MethodPerEndpointBuilder,
    BaseServiceIface -> ServicePerEndpoint,
    ServiceIface -> ServicePerEndpoint,
    ServiceIfaceBuilder -> ServicePerEndpointBuilder.
    To construct a client use c.t.f.ThriftRichClient.servicePerEndpoint instead of
    newServiceIface, to convert ServicePerEndpoint to MethodPerEndpoint use
    c.t.f.ThriftRichClient.methodPerEndpoint instead of newMethodIface. 26f86b2b

  • scrooge-generator: (BREAKING API CHANGE) Change the java generator to no longer
    generate files with org.slf4j imports and remove limited usage of org.slf4j
    Logger in generated services. bf5364be

scrooge - Scrooge 17.10.0

Published by nepthar almost 7 years ago

  • From now on, release versions will be based on release date in the format of
    YY.MM.x where x is a patch number. 2645da60

  • scrooge-generator: For generated scala $FinagleService, moved per-endpoint statsFilter to the
    outermost of filter chain so it can capture all exceptions, added per-endpoint response
    classification in statsFilter. 853323dc

  • scrooge-generator: Generated scala $FinagleClient takes a RichClientParam for all
    configuration params, such as TProtocolFactory, ResponseClassifier, maxReusableBufferSize,
    and StatsReceiver, $FinagleService takes a RichServerParam. 8bdf36cb

scrooge - Scrooge 4.20.0

Published by kevinoliver about 7 years ago

Updated dependencies to Finagle 7.1.0 and Util 7.1.0

scrooge - Scrooge 4.19.0

Published by dschobel about 7 years ago

  • scrooge-generator: Generated scala/java code now is using serviceMap instead of functionMap
    for Finagle services' method implementation. PHAB_ID=D73619 for scala and
    PHAB_ID=D76129 for java

  • scrooge-generator: Generated Java code now is using c.t.s.TReusableBuffer to reduce
    object allocations. This in turn adds scrooge-core as dependency for generated
    java code. PHAB_ID=D60406

  • scrooge-generator: Support for thrift struct field doccomments for scala
    generated code RB_ID=918179

  • scrooge-generator: The MethodIface in generated Scala code implements
    FutureIface. It already "was" that type in practice but did not implement
    that trait. PHAB_ID=D67289

  • scrooge-generator: Generated Cocoa code now supports modular frameworks and
    removes some compiler warnings about implicit casts. PHAB_ID=D74200