Commit Graph

1690 Commits

Author SHA1 Message Date
Yuxuan 'fishy' Wang
4db7a0af13 THRIFT-5240: Do connectivity check in Go server
Client: go

In compiler generated TProcessorFunction implementations, add a
goroutine after read the request to do connectivity check on the input
transport. If the transport is no longer open, cancel the context object
passed into the handler implementation.

Also define ErrAbandonRequest error, to help TSimpleServer closing
client connections that's already closed on the other end.
2020-07-01 11:50:44 -07:00
wangyunjian
86cc6f095c THRIFT-5144: Fix memory leak when generate deserialize list element
Client: c_glib
Patch: wangyunjian

This closes #2064

Signed-off-by: wangyunjian <wangyunjian@huawei.com>
2020-06-27 15:25:06 +02:00
Jens Geyer
6e16c2bc54 THRIFT-5238 GetHashCode can throw NullReferenceException
Client: netstd
Patch: Jens Geyer

This closes #2187
2020-06-25 22:00:52 +02:00
Emmanuel Brard
283410126c THRIFT-2087 Python compiler replace non utf-8 char with default
Client: py
Patch: Emmanuel Brard

This closes #2184
2020-06-22 22:50:45 +02:00
Duru Can Celasun
bcae3bb52f
THRIFT-5233: Handle I/O timeouts in go library (#2181)
Client: go

As discussed in the JIRA ticket, this commit changes how we handle I/O
timeouts in the go library.

This is a breaking change that adds context to all Read*, Write*, and
Skip functions to TProtocol, along with the compiler change to support
that, and also adds context to TStandardClient.Recv, TDeserializer,
TStruct, and a few others.

Along with the function signature changes, this commit also implements
context cancellation check in the following TProtocol's ReadMessageBegin
implementations:

- TBinaryProtocol
- TCompactProtocol
- THeaderProtocol

In those ReadMessageBegin implementations, if the passed in context
object has a deadline attached, it will keep retrying the I/O timeout
errors, until the deadline on the context object passed. They won't
retry I/O timeout errors if the passed in context does not have a
deadline attached (still return on the first error).
2020-06-18 22:09:33 +01:00
Jens Geyer
1bed620c5f THRIFT-5235 Add property setter for isset flags
Client: delphi
Patch: Jens Geyer
2020-06-18 11:22:33 +02:00
Phil Price
7db2d0fa46 THRIFT-5234 Fix a number of js/ts generation issues
Client: js/ts
Patch: Phil Price
2020-06-18 00:37:40 +02:00
Jens Geyer
210202e65c THRIFT-5229 Deprecate as3 support
Client: as3
Patch: Jens Geyer

This closes #2182
2020-06-16 22:04:23 +02:00
Yuxuan 'fishy' Wang
e79f764f09 THRIFT-5233: Handle I/O timeouts in go library
Client: go

As discussed in the JIRA ticket, this commit changes how we handle I/O
timeouts in the go library.

This is a breaking change that adds context to all Read*, Write*, and
Skip functions to TProtocol, along with the compiler change to support
that, and also adds context to TStandardClient.Recv, TDeserializer,
TStruct, and a few others.

Along with the function signature changes, this commit also implements
context cancellation check in the following TProtocol's ReadMessageBegin
implementations:

- TBinaryProtocol
- TCompactProtocol
- THeaderProtocol

In those ReadMessageBegin implementations, if the passed in context
object has a deadline attached, it will keep retrying the I/O timeout
errors, until the deadline on the context object passed. They won't
retry I/O timeout errors if the passed in context does not have a
deadline attached (still return on the first error).
2020-06-15 13:28:38 -07:00
zeshuai007
26681fbdb7 THRIFT-5225: Use nullptr instead of NULL
Patch: Zezeng Wang

This closes #2168
2020-06-14 14:17:11 +02:00
Stanislav Markevic
3f78c70bbb THRIFT-5082 Add a Class reference for PHP enum $_TSPEC
Client: php
Patch: Stanislav Markevic

This closes #2000
2020-06-09 23:23:02 +02:00
zeshuai007
0acf23b7cf THRIFT-5200 Thrift compiler will generate incorrect code when add 'cob_style' option
Client: cpp
Patch: Zezeng Wang

This closes #2144
2020-06-04 21:43:30 +02:00
Jens Geyer
b559359b0b THRIFT-5220 DeepCopy() extension methods not generated when the IDL contains no service
Client: netstd
Patch: Jens Geyer
2020-05-28 21:32:34 +02:00
Jens Geyer
affea7bee4 THRIFT-5216 generate DeepCopy methods
Client: netstd
Patch: Jens Geyer

This closes #2155
2020-05-27 01:32:14 +02:00
Jano Svitok
4fd001c878 THRIFT-5138 Swift keywords may be used as identifiers if escaped
Client: Swift
Patch: Jano Svitok

This closes #2059
2020-05-20 00:48:35 +02:00
Jano Svitok
a082592d43 THRIFT-5128 Swift TFramedTransport does not work using present code
Client: Swift
Patch: Jano Svitok

This closes #2047
2020-05-20 00:39:49 +02:00
zeshuai007
53239655b7 THRIFT-3622 Fix deprecated uses of std::auto_ptr
Client: cpp
Patch: zeshuai007 <51382517@qq.com>

This closes #2135
2020-05-15 22:22:48 +02:00
Jens Geyer
abc2ec6096 THRIFT-5198 Fix certain Visual Studio hints in generated netstd code
Client: netstd
Patch: Jens Geyer

This closes #2133
2020-05-08 09:14:26 +02:00
Zezeng Wang
371d92f159
THRIFT-5179: Fix generated code for struct's named "a" or "b"
Client: cpp
2020-04-28 07:23:15 +01:00
penenin
52655cec79
THRIFT-5159: Fix runtime ReferenceError in generated code
Client: nodejs
2020-04-27 16:19:55 +01:00
Mario Emmenlauer
5ef8e3ec2a
Remove boost from compiler test, delete unused bincat.sh 2020-04-24 15:34:02 +01:00
Alexander Edge
b4711a6178
Swift 5.1 support
Use stdlib Result instead of TAsyncResult

Fix: deprecations for `withUnsafeBytes`

Bump CI job Xcode version

Hash (into)

Co-authored-by: Sophie Lambrakis <SLambrakis@users.noreply.github.com>
Co-authored-by: Alexander Edge <alex@alexedge.co.uk>
2020-04-24 14:43:03 +01:00
Mario Emmenlauer
93171d2482 THRIFT-5109 Misc Cmake build improvements
Patch: Mario Emmenlauer

This closes #2094
2020-04-22 21:17:33 +02:00
zeshuai007
57c2507208 THRIFT-5168 Useless generated code when .thrift file only has service type
Client: cpp
Patch: zeshuai007 <51382517@qq.com>

This closes #2095
2020-04-21 23:29:14 +02:00
gzuykov
f44b6ee8db Modify autogenerated message for Go to standard to match the expectations of some tools
Client: Go
Patch: gzuykov

This closes #2096
2020-04-09 21:41:57 +02:00
Mikail Bagishov
7e90252af6
THRIFT-4764: Use new syntax for clippy skipping
Client: rs
2020-03-28 10:11:37 -04:00
Jens Geyer
11fc716a20 THRIFT-5154 Generate interface IDs (IID) for Windows platforms
Client: Delphi
Patch: Jens Geyer

This closes #2072
2020-03-28 13:56:49 +01:00
zeshuai007
24ab31fc57 THRIFT-5067 Invalid generated Cpp code from valid Thrift IDL with dots in file names for nested namespaces
Client: cpp
Patch: zeshuai007 <51382517@qq.com>

This closes #2060
2020-03-22 14:12:21 +01:00
Jens Geyer
1b7b00cde9 CI broken, reverting following PRs
reverted https://github.com/apache/thrift/pull/2025
reverted https://github.com/apache/thrift/pull/2026
Reverted https://github.com/apache/thrift/pull/2021
2020-02-28 19:20:27 +01:00
Jens Geyer
56700e469d THRIFT-4982 Remove deprecated C# bindings from the code base
Client: csharp
Patch: Jens Geyer

This closes #2027
2020-02-28 19:18:34 +01:00
Mario Emmenlauer
61d502075b THRIFT-5109 Misc Cmake build improvements
Patch: Mario Emmenlauer

This closes #2026
This closes #2025
This closes #2021
2020-02-23 14:51:48 +01:00
Jeffrey Han
7b712f42d7 THRIFT-5106: Fix various Lua library and compiler issues
Client: lua
Patch: Jeffrey Han

This closes #2014
2020-02-21 21:08:19 +01:00
Jens Geyer
222362cc70 THRIFT-5095 ToString() should print entire structure, not just the top-level data
Client: netstd
Patch: Jens Geyer

This closes #2009
2020-02-16 13:19:43 +01:00
Jens Geyer
bb5f7ec6b0 THRIFT-5091 Netstd generator produces uncompileable code for struct names ending with "_result" or "_args"
Client: netstd
Patch: Jens Geyer

THis closes #2006
2020-02-14 09:15:17 +01:00
Homarechan
ded326101a THRIFT-5072 Fix data type generation.
Client: hs
Patch: Homarechan <tikuwakunn@icloud.com>

This closes #1974
2020-02-06 23:21:02 +01:00
Gaurav Singh
7d30e2c0b6 (no ticket) catch exception by ref
Patch: Gaurav Singh

This closes #1998
2020-02-06 23:10:08 +01:00
David Mollitor
e8f82da45e THRIFT-5016 Do Not Check 'other' For Null in Equals
Client: Java
Patch: David Mollitor

This closes #1937
2020-01-28 22:53:58 +01:00
belugabehr
44d8cc6b43 THRIFT-5014: Do Direct Comparison on Raw Values Instead of Objects
Client: java

This closes #1935.
2019-12-14 09:33:37 +00:00
Duru Can Celasun
b374ce3555
THRIFT-5046: Better struct tag overrides
Custom go.tag in an IDL no longer removes the existing "db" and "json"
tags but can override them.

This allows us to change default tags in the future without affecting
user defined ones.

Client: go

This closes #1963.
2019-12-13 13:10:23 +00:00
belugabehr
418d88b447 THRIFT-5013: Replace NullPointerException with RequireNonNull
Co-Authored-By: Christopher Tubbs <ctubbsii@apache.org>

Client: java

This closes #1934.
2019-12-13 09:13:12 +00:00
Elvis Pranskevichus
9c43962da8 Revert "Revert "THRIFT-4002: Make generated exception classes immutable by default""
This reverts commit 1234ddf8a5.
2019-12-12 13:50:42 +00:00
D. Can Celasun
1234ddf8a5
Revert "THRIFT-4002: Make generated exception classes immutable by default"
This reverts commit b40f5c227f.
2019-12-10 22:13:06 +00:00
Elvis Pranskevichus
b40f5c227f
THRIFT-4002: Make generated exception classes immutable by default
Currently, the generated exception classes are not hashable under
Python 3 because of the generated `__eq__` method.  Exception objects
are generally expected to be hashable by the Python standard library.
Post-construction mutation of an exception object seems like a very
unlikely case, so enable hashing for all exceptions by making them
immutable by default.  This also adds a way to opt-out of immutability
by setting the `python.immutable` annotation to `"false"`.
2019-12-10 20:44:24 +00:00
Jens Geyer
e780855d33 THRIFT-5044 Improve serialization support for TApplicationExceptions and custom exceptions
Client: Delphi
Patch: Jens Geyer

This closes #1960
2019-12-05 09:03:10 +01:00
kahotv
1e049101c5 Generate comments for the output cpp file
Client: cpp
Patch: kahotv <root@kaho.tv>

This closes #1954
2019-12-03 23:02:15 +01:00
Paulo Neves
4266faef0e THRIFT-5032 netstd: Use PascalCase for Properties.
Client: netstd
Patch: Paulo Neves

This closes #1949
2019-11-28 21:34:32 +01:00
Duru Can Celasun
f4475ff76f
THRIFT-5019: Duplicate imports from multiple includes from a namespace
If a thrift file includes two files from the same namespace into a
separate file, the generated Go code has duplicate imports for that
namespace. This fixes that.

Client: go
2019-11-20 15:31:35 +00:00
John Boiles
59694a796f THRIFT-5002: Fix argument containers for inherited functions
Fix a bug where remote.go client fails to compile when services 
extend other services and the parent service has a function that 
needs a container for its arguments.

Client:go

This closes #1925.
2019-11-09 19:22:26 +00:00
David Furey
b1d4b3afcc THRIFT-4989: Fix run time exception when using Swift TCompactProtocol
Client: Swift
Patch: David Furey

This closes #1908

Sort TStruct members by key before generating class properties so that Swift Thrift lib can use delta encoding for CompactProtocol.
2019-11-02 15:02:54 +01:00
Jens Geyer
3f3567a114 THRIFT-4981 Remove deprecated netcore bindings from the code base
Client: netcore
Patch: Jens Geyer

This closes #1901
2019-10-20 16:21:29 +02:00