Releases: twitter/scrooge
Scrooge 18.5.0
-
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 18.4.0
-
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 18.3.0
- scrooge-generator: Add support for mutually recursive structs. 2a731bbc
Scrooge 18.2.0
-
scrooge-generator: Add
asClosable
method toServicePerEndpoint
and
ReqRepServicePerEndpoint
interfaces as well. 597864ac -
scrooge-generator: Remove unused
functionToService
andserviceToFunction
methods along withServiceType
andReqRepServiceType
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 FinagleService
. 2d25eb25 -
scrooge-generator: Scala generated client now has a asClosable method returns c.t.u.Closable,
client now can be closed by callingclient.asClosable.close
. Note thatasClosable
won't be
generated if it is also defined by the user. 1fa4f0c6 -
scrooge-generator: Renamed subclasses of
com.twitter.scrooge.RichResponse
:
ProtocolExceptionResponse
,SuccessfulResponse
, andThriftExceptionResponse
.
These case classes are for representing different response types and should be only
used by the generated code. 2194e77d
Scrooge 18.1.0
-
scrooge-generator: Update
c.t.fingale.thrit.service.MethodPerEndpointBuilder
to buildMethodPerEndpoint
types. Add newThriftServiceBuilder
for
building the higher-kinded form from aServicePerEndpoint
. Users should
prefer using theMethodPerEndpointBuilder
.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
andscrooge.Response
types in generatedThriftMethod
code.PHAB_ID=D122767
Scrooge 17.12.0
-
scrooge: Introduce
scrooge.Request
andscrooge.Response
envelopes which
are used inReqRepServicePerEndpoint
interfaces and associated code. The
scroogeRequest
andResponse
allow for passing "header" information (via
ThriftMux Message contexts) between clients and servers. For instance, a
server can implement aReqRepServicePerEndpoint
, 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 usingThriftMux
: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-sideReqRepServicePerEndpoint
it will be able
to read the headers from the returnedResponse
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 aMethodPerEndpoint
viaThriftMux.client.reqRepMethodPerEndpoint(reqRepServicePerEndpoint)
in order to
deal with methods instead of services. See the scrooge documentation for more information.
aa1fb0c0
Scrooge 17.11.0
-
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 usec.t.f.ThriftRichClient.servicePerEndpoint
instead of
newServiceIface
, to convertServicePerEndpoint
toMethodPerEndpoint
use
c.t.f.ThriftRichClient.methodPerEndpoint
instead ofnewMethodIface
. 26f86b2b -
scrooge-generator: (BREAKING API CHANGE) Change the java generator to no longer
generate files withorg.slf4j
imports and remove limited usage oforg.slf4j
Logger in generated services. bf5364be
Scrooge 17.10.0
-
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 asTProtocolFactory
,ResponseClassifier
,maxReusableBufferSize
,
andStatsReceiver
, $FinagleService takes aRichServerParam
. 8bdf36cb
Scrooge 4.20.0
Updated dependencies to Finagle 7.1.0 and Util 7.1.0
Scrooge 4.19.0
-
scrooge-generator: Generated scala/java code now is using
serviceMap
instead offunctionMap
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 addsscrooge-core
as dependency for generated
java code.PHAB_ID=D60406
-
scrooge-generator: Support for thrift struct field doccomments for scala
generated codeRB_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