Commit Graph

6166 Commits

Author SHA1 Message Date
David Mollitor
f8103c69ea THRIFT-5202: TNonblockingMultiFetchClient Use SLF4J Parameterized Logging
Client: java
Patch: David Mollitor

This closes #2137

Use SLF4J API to log full Exception details.  Use SLF4J parameterized logging instead of String format.
2020-05-20 09:26:36 -04:00
Jens Geyer
7de1f5d7f3 Added breaking change notice for "THRIFT-5138 Swift keywords may be used as identifiers if escaped" because it is labelled as such in JIRA 2020-05-20 00:55:10 +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
Jano Svitok
1edf32926d THRIFT-5125: Swift server does not work using present code
Client: Swift
Patch: Jano Svitok

This closes #2038
2020-05-20 00:28:58 +02:00
Jens Geyer
506e311c38 FIX: CI error at ./test/py/TestServer.py:178:26: F507 '...' % ... has 1 placeholder(s) but 6 substitution(s)
FIX: CI error at ./test/crossrunner/compat.py:11:21: E741 ambiguous variable name 'l'
Patch: Jens Geyer

This closes #2147
2020-05-19 00:00:29 +02:00
penenin
1ab096c80a
THRIFT-5185: Support for using WebSockets as a server transport
Client: cpp
2020-05-18 20:27:31 +01:00
Jens Geyer
dce229911c THRIFT-5210 further refactoring and performance optimizations
Client: netstd
Patch: Jens Geyer

This closes #2146
2020-05-17 22:34:10 +02:00
Philipp Hausmann
261de348fe THRIFT-5211 Handle incomplete reads correctly
Client: Haskell
Patch: Philipp Hausmann

This closes #2108

The read functions for handles promise to return *up* to the requested
number of bytes. This means in case we read less bytes, we should try
again to read some more bytes.
2020-05-17 14:44:59 +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
Mario Emmenlauer
ad3e440955 TSocketTransport.cs: Fixed a problem with initializing IPAddress
Client: netstd
Patch: Mario Emmenlauer

This closes #2140
2020-05-15 21:59:15 +02:00
Yuxuan 'fishy' Wang
be3f7321cf
Make TTransportException unwrappable on Go 1.13+
Client: go

Go 1.13 introduced a new, optional, hidden interface for error
implementations to make them unwrappable [1]. We currently already kind
of support that (via TTransportException.Err), so just add a new
function to make it Go 1.13+ compatible.

[1] https://pkg.go.dev/errors@go1.13?tab=doc#pkg-overview
2020-05-14 08:28:44 +01:00
zeshuai007
26e6c84cde Add testcase for compactprotocol(python)
Client: py
Patch: zeshuai007 <51382517@qq.com>

This closes #2129
2020-05-13 23:56:08 +02:00
Tim Heilig
64ac65ea7e THRIFT-5199: Fix infinite loop writing to closed TSocket in PHP
Client: php
Patch: Tim Heilig

This closes #2134
2020-05-13 23:49:24 +02:00
Mario Emmenlauer
55680af8fa
Update NodeJS to oldest supported version on Ubuntu Xenial 2020-05-11 21:58:48 +01:00
David Mollitor
47e9d8f13e THRIFT-5197: TSSLTransportFactory Do Not Wrap NOT_OPEN Exception Type for Client
Client: java
Patch: David Mollitor

This closes #2131

The class TSSLTransportFactory is wrapping TTransportExceptions, which have a particular "type,"
in a type-less TTransportException and therefore the Exception type is lost.
2020-05-11 10:30:17 -04:00
max ulidtko
9b9567b233 THRIFT-5186: Don't pass AI_ADDRCONFIG to getaddrinfo()
Client: cpp,pas,py
Patch: Max Ulidtko

This closes #2124

If a host doesn't have assigned IPv4 or IPv6 addresses, thrift communication
over localhost-only is impossible due to thrift library bug. It happens
when making getaddrinfo syscall with AI_ADDRCONFIG flag.

From man getaddrinfo(3):
If  hints.ai_flags  includes  the  AI_ADDRCONFIG  flag,  then  IPv4  addresses
are returned in the list pointed to by res only if the local system has at least
one IPv4 address configured, and IPv6 addresses are returned only if the local
system has at least one IPv6 address configured.  The loopback address is not
considered for this case as valid as a configured address.

Upstream bug with AI_ADDRCONFIG ai_flags was fixed for cpp library and win32
platform only. See https://issues.apache.org/jira/browse/THRIFT-2539

Patch based on Thrift 0.13.0, commit cecee50308.
2020-05-08 09:23:47 +02:00
zeshuai007
bbc5e06a2e Supplement TZlibTransport.py testcase
Client: py
Patch: zeshuai007 <51382517@qq.com>

This closes #2132
2020-05-08 09:18:46 +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
Yuxuan 'fishy' Wang
0c173bf9e0
THRIFT-5164: Small cleanup on example code
Client: go

Godoc requires at least one other exported type/function to render the
whole example file in the example, so export
simpleProcessorLoggingMiddleware to make the example of
ProcessorMiddleware more helpful.

Currently it's rendered in a not very helpful way:
https://pkg.go.dev/github.com/apache/thrift@v0.13.1-0.20200430141240-5cffef964a08/lib/go/thrift?tab=doc#example-ProcessorMiddleware

Compare to the client middleware example rendering:
https://pkg.go.dev/github.com/apache/thrift@v0.13.1-0.20200430141240-5cffef964a08/lib/go/thrift?tab=doc#example-ClientMiddleware

While I'm here, also update CHANGES.md to mention ClientMiddleware.

[skip ci]
2020-05-01 07:49:29 +01:00
Duru Can Celasun
48730688fb
Update PR template
Clarify that [skip ci] needs to be in the commit message, not the PR text.
2020-04-30 17:00:24 +01:00
Andrew Boyle
5cffef964a
THRIFT-5164: Add middleware framework for Go clients
This commit adds a simple middleware framework for Go clients.

It provides:

 * A `ClientMiddleware` function interface used to define the actual middleware
 * `WrapClient`, the function that you use to wrap a `TClient` in a list of middleware
 * A helper `WrappedTClient` struct to help with developing middleware

Client: go
2020-04-30 15:12:40 +01:00
Jens Geyer
9c75797346 Configure Gitbox: It's notifications, not github [skip ci] 2020-04-28 22:42:55 +02:00
Jens Geyer
809403d544 Configure Gitbox [skip ci] 2020-04-28 22:36:36 +02:00
Zezeng Wang
39381695eb
Add file and memory buffer tests for Python
Client: py
2020-04-28 07:24:58 +01: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
Jens Geyer
8746291342 THRIFT-5188 Occasional ERROR_INSUFFICIENT_BUFFER at WinHttpQueryHeaders()
Client: Delphi
Patch: Jens Geyer
2020-04-27 22:56:21 +02:00
Andrew Boyle
00c039adeb
THRIFT-5164: Add middleware framework for Go servers
This commit adds a simple middleware framework for Go servers.

It provides:

 * A `ProcessorMiddleware` function interface used to define the actual middleware
 * `WrapProcessor`, the function that you use to wrap a `TProcessor` in a list of middleware
 * A helper `WrappedTProcessorFunction` struct to help with developing middleware

This is a breaking change for any custom implementations of the `TProcessor`
interface, but does not effect the code generated by compiling Thrift files. It
adds two functions to the interface that are a part of the generated `TProcessor`
code, but were not defined in the interface explicitly.
2020-04-27 19:32:24 +01:00
penenin
52655cec79
THRIFT-5159: Fix runtime ReferenceError in generated code
Client: nodejs
2020-04-27 16:19:55 +01:00
penenin
7c4bdf9914
THRIFT-5184: Fix header check for WebSocket connections
When establishing a WebSocket connection, Firefox sends Connection: keep-alive, Upgrade instead of just Connection: Upgrade. Check to see if Upgrade is in the header instead of checking to see if it is the entire header value.

Client: d
2020-04-27 09:11:47 +01:00
Zezeng Wang
c3728122d2
Supplement TBinaryprotocol module testcase
Client: py
2020-04-27 08:48:19 +01:00
Zezeng Wang
b416ffa72d
Mention Qt in README
[skip ci]
2020-04-27 08:18:26 +01:00
Jano Svitok
3127e4abd9
THRIFT-5150: Fix compilation with Swift 5.2
- (OS X and Linux) type 'TSet<Element>' does not conform to protocol 'Collection'
- (Linux only) kCFSocketCloseOnInvalidate has Int type

Client: swift
2020-04-27 08:12:42 +01:00
zeshuai007
b83ae2cedf supplementary testcase for TJSONProtocol
Client: py
Patch: zeshuai007 <51382517@qq.com>

This closes #2113
2020-04-26 13:29:48 +02:00
Dmitry Maluka
b94c166385 THRIFT-5177: getaddrinfo() should not be used for Unix sockets
Client: cpp
Patch: Dmitry Maluka

This closes #2102
2020-04-26 13:25:08 +02:00
Mario Emmenlauer
2d2df9e892
Allow wrapping TTransportFactory into a TZlibTransportFactory
Client: cpp
2020-04-24 17:02:18 +01:00
Mario Emmenlauer
5ef8e3ec2a
Remove boost from compiler test, delete unused bincat.sh 2020-04-24 15:34:02 +01:00
Mario Emmenlauer
25f81d11c2
Rework NodeJS / Javascript consistency
Client: js

* Re-worked consistency of browser.js and index.js in lib/nodejs

* Wrap non-standard V8 method 'Error.captureStackTrace()'
2020-04-24 14:45:05 +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
04574379a4
TOutput: Add further parsers for errno-to-string conversion for Windows 2020-04-24 10:44:41 +01:00
Mario Emmenlauer
802793638b
THRIFT-4282: Disabled StressTestNonBlocking on Windows 2020-04-24 07:51:37 +01:00
Mario Emmenlauer
ed0bad3430
Add isOpen() to TServerTransport
Client: cpp
2020-04-24 07:50:43 +01:00
Yuxuan 'fishy' Wang
e98ba9cb84
THRIFT-5183: Don't try to read next frame in THeaderTransport.Read
Trying to read the next frame will likely cause the Read call blocking
indefinitely and eventually lead to timeout. See the JIRA ticket for
more context.

Client: go
2020-04-24 07:39:04 +01:00
Kengo Seki
d5a9bf2b30
THRIFT-5171: Fix maven-ant-tasks to use HTTPS instead of HTTP
Client: js, json
2020-04-23 21:58:00 +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
Mario Emmenlauer
6064696ae0 lib/js/Gruntfile.js: Generalized to add some level of Windows CMD support (not complete yet) 2020-04-22 21:15:14 +02:00
Mario Emmenlauer
df2f5d2cf3 THRIFT-5178: Add constructor with default host to THttpClient
Client: cpp
Patch: Mario Emmenlauer

This closes #2105

The new default host is localhost. Also, the new default path is /service. This works around issue THRIFT-5180 where a path is required for the THttpTransport in Unix domain sockets.
2020-04-21 23:37:28 +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
gaganso
dd7e11798b Removed a duplicate line + Fixed typo in the comments of lib/cpp/src/thrift/concurrency/Thread.h
Client: cpp
Patch: gaganso <gagan.somashekar@gmail.com>

This closes #2104
2020-04-20 23:32:52 +02:00
zeshuai007
35a3942e70 Update libthrift.vcxproj and libthrift.vcxproj.filters: remove xxxThreadFactory.h file which has been removed
Client: cpp
Patch: zeshuai007 <51382517@qq.com>

This closes #2100
2020-04-20 23:30:21 +02:00