From 011eb22e32eea4a3220dcea6fd63f608e682ba2c Mon Sep 17 00:00:00 2001 From: Orion Poplawski Date: Wed, 17 Feb 2021 07:52:49 -0700 Subject: [PATCH 01/14] THRIFT-5350 char is unsigned on non-x86 arches, use signed char to avoid compiler warning about always true comparisons Patch: Orion Poplawski This closes #2331 --- compiler/cpp/src/thrift/generate/t_delphi_generator.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/cpp/src/thrift/generate/t_delphi_generator.cc b/compiler/cpp/src/thrift/generate/t_delphi_generator.cc index d3ad76a32..eac46a6c7 100644 --- a/compiler/cpp/src/thrift/generate/t_delphi_generator.cc +++ b/compiler/cpp/src/thrift/generate/t_delphi_generator.cc @@ -1062,7 +1062,7 @@ std::string t_delphi_generator::make_pascal_string_literal(std::string value) { } result << "'"; - for (char const &c: value) { + for (signed char const c: value) { if( (c >= 0) && (c < 32)) { // convert ctrl chars, but leave UTF-8 alone result << "#" << (int)c; } else if (c == '\'') { From 2c0f932301231c8d9996dc21c183c586e0a80d08 Mon Sep 17 00:00:00 2001 From: Jens Geyer Date: Sat, 13 Feb 2021 15:05:28 +0100 Subject: [PATCH 02/14] THRIFT-5347 Deprecate Haskell bindings Client: hs Patch: Jens Geyer --- compiler/cpp/src/thrift/generate/t_generator.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/compiler/cpp/src/thrift/generate/t_generator.cc b/compiler/cpp/src/thrift/generate/t_generator.cc index 3059fb141..d87af89c5 100644 --- a/compiler/cpp/src/thrift/generate/t_generator.cc +++ b/compiler/cpp/src/thrift/generate/t_generator.cc @@ -240,6 +240,9 @@ t_generator* t_generator_registry::get_generator(t_program* program, else if (language == "as3") { pwarning(1, "The '%s' target is deprecated and will be removed in future Thrift versions.", language.c_str()); } + else if (language == "hs") { + pwarning(1, "The '%s' target is deprecated and will be removed in future Thrift versions.", language.c_str()); + } if (iter == the_map.end()) { return nullptr; From cee3ddb0e0a18d0aa1a1f5b06e643604c5c4ee86 Mon Sep 17 00:00:00 2001 From: Neil Williams Date: Tue, 16 Feb 2021 15:12:15 -0800 Subject: [PATCH 03/14] THRIFT-5352: Fix construction of Py exceptions with no fields Client: py When no fields are present, we don't get the special constructor that uses __setattr__ to avoid these checks. So the default constructor sets message normally and triggers the anti-mutation tripwires. --- lib/py/src/Thrift.py | 2 +- test/DebugProtoTest.thrift | 2 ++ test/py/TestFrozen.py | 5 ++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/py/src/Thrift.py b/lib/py/src/Thrift.py index ef655ea55..81fe8cf33 100644 --- a/lib/py/src/Thrift.py +++ b/lib/py/src/Thrift.py @@ -90,7 +90,7 @@ class TException(Exception): def __init__(self, message=None): Exception.__init__(self, message) - self.message = message + super(TException, self).__setattr__("message", message) class TApplicationException(TException): diff --git a/test/DebugProtoTest.thrift b/test/DebugProtoTest.thrift index 1ab0f6aea..5d0face4b 100644 --- a/test/DebugProtoTest.thrift +++ b/test/DebugProtoTest.thrift @@ -245,6 +245,8 @@ exception MutableException { 1: string msg; } (python.immutable = "false") +exception ExceptionWithoutFields {} + service ServiceForExceptionWithAMap { void methodThatThrowsAnException() throws (1: ExceptionWithAMap xwamap); } diff --git a/test/py/TestFrozen.py b/test/py/TestFrozen.py index ce7425f88..f859398dc 100755 --- a/test/py/TestFrozen.py +++ b/test/py/TestFrozen.py @@ -21,7 +21,7 @@ from DebugProtoTest import Srv from DebugProtoTest.ttypes import CompactProtoTestStruct, Empty, Wrapper -from DebugProtoTest.ttypes import ExceptionWithAMap, MutableException +from DebugProtoTest.ttypes import ExceptionWithAMap, MutableException, ExceptionWithoutFields from thrift.Thrift import TFrozenDict from thrift.transport import TTransport from thrift.protocol import TBinaryProtocol, TCompactProtocol @@ -104,6 +104,9 @@ class TestFrozenBase(unittest.TestCase): mutexc.msg = 'bar' self.assertEqual(mutexc.msg, 'bar') + def test_frozen_exception_with_no_fields(self): + ExceptionWithoutFields() + def test_frozen_exception_serialization(self): result = Srv.declaredExceptionMethod_result( xwamap=ExceptionWithAMap(blah="error")) From abb8fa8c44caaa0e46038f7a0840e559cd3b51be Mon Sep 17 00:00:00 2001 From: Yuxuan 'fishy' Wang Date: Wed, 17 Feb 2021 12:58:40 -0800 Subject: [PATCH 04/14] THRIFT-4914: Fix name redeclaration bug in compiled go code Client: go This fixes the bug reported in https://github.com/apache/thrift/pull/2315#discussion_r577919697. --- .../cpp/src/thrift/generate/t_go_generator.cc | 17 +++++++++-------- test/ThriftTest.thrift | 14 ++++++++++++++ 2 files changed, 23 insertions(+), 8 deletions(-) diff --git a/compiler/cpp/src/thrift/generate/t_go_generator.cc b/compiler/cpp/src/thrift/generate/t_go_generator.cc index d9f9d51c5..2cef11f34 100644 --- a/compiler/cpp/src/thrift/generate/t_go_generator.cc +++ b/compiler/cpp/src/thrift/generate/t_go_generator.cc @@ -2170,14 +2170,15 @@ void t_go_generator::generate_service_client(t_service* tservice) { } if (!(*f_iter)->is_oneway()) { + std::string metaName = tmp("_meta"); std::string resultName = tmp("_result"); std::string resultType = publicize(method + "_result", true); f_types_ << indent() << "var " << resultName << " " << resultType << endl; - f_types_ << indent() << "var meta thrift.ResponseMeta" << endl; - f_types_ << indent() << "meta, err = p.Client_().Call(ctx, \"" + f_types_ << indent() << "var " << metaName << " thrift.ResponseMeta" << endl; + f_types_ << indent() << metaName << ", _err = p.Client_().Call(ctx, \"" << method << "\", &" << argsName << ", &" << resultName << ")" << endl; - f_types_ << indent() << "p.SetLastResponseMeta_(meta)" << endl; - f_types_ << indent() << "if err != nil {" << endl; + f_types_ << indent() << "p.SetLastResponseMeta_(" << metaName << ")" << endl; + f_types_ << indent() << "if _err != nil {" << endl; indent_up(); f_types_ << indent() << "return" << endl; @@ -2199,7 +2200,7 @@ void t_go_generator::generate_service_client(t_service* tservice) { indent_up(); if (!(*f_iter)->get_returntype()->is_void()) { - f_types_ << indent() << "return r, " << field << endl; + f_types_ << indent() << "return _r, " << field << endl; } else { f_types_ << indent() << "return "<< field << endl; } @@ -2222,7 +2223,7 @@ void t_go_generator::generate_service_client(t_service* tservice) { f_types_ << indent() << "p.SetLastResponseMeta_(thrift.ResponseMeta{})" << endl; // TODO: would be nice to not to duplicate the call generation f_types_ << indent() << "if _, err := p.Client_().Call(ctx, \"" - << method << "\", &"<< argsName << ", nil); err != nil {" << endl; + << method << "\", &" << argsName << ", nil); err != nil {" << endl; indent_up(); f_types_ << indent() << "return err" << endl; @@ -3787,7 +3788,7 @@ string t_go_generator::function_signature_if(t_function* tfunction, string prefi string errs = argument_list(exceptions); if (!ret->is_void()) { - signature += "r " + type_to_go_type(ret); + signature += "_r " + type_to_go_type(ret); if (addError || errs.size() == 0) { signature += ", "; @@ -3795,7 +3796,7 @@ string t_go_generator::function_signature_if(t_function* tfunction, string prefi } if (addError) { - signature += "err error"; + signature += "_err error"; } signature += ")"; diff --git a/test/ThriftTest.thrift b/test/ThriftTest.thrift index ac49aee01..c88187c54 100644 --- a/test/ThriftTest.thrift +++ b/test/ThriftTest.thrift @@ -411,3 +411,17 @@ struct StructB { struct OptionalSetDefaultTest { 1: optional set with_default = [ "test" ] } + +service ConflictingNamesTest { + /** + * Use some names that could conflict with the compiler code as args + * to make sure that the compiler handled them correctly. + */ + void testNameConflicts( + // 1: string args, // args is already a reserved keyword in thrift compiler + // 2: string result, // result will cause problems in compiled netstd code + 3: string meta, + 4: string r, + 5: string err, + ) +} From bb8fec7930a3a6789d0b9602412ee57a56ad551c Mon Sep 17 00:00:00 2001 From: Yuxuan 'fishy' Wang Date: Thu, 18 Feb 2021 09:09:20 -0800 Subject: [PATCH 05/14] Move ConflictingNamesTest to lib/go/test Client: go Also add missing copyright header for files added in https://github.com/apache/thrift/pull/2307. --- lib/go/test/ConflictArgNamesTest.thrift | 32 ++++++++++++++++++++ lib/go/test/EqualsTest.thrift | 21 ++++++++++++- lib/go/test/Makefile.am | 9 ++++-- lib/go/test/tests/conflict_arg_names_test.go | 27 +++++++++++++++++ lib/go/test/tests/equals_test.go | 19 ++++++++++++ test/ThriftTest.thrift | 14 --------- 6 files changed, 105 insertions(+), 17 deletions(-) create mode 100644 lib/go/test/ConflictArgNamesTest.thrift create mode 100644 lib/go/test/tests/conflict_arg_names_test.go diff --git a/lib/go/test/ConflictArgNamesTest.thrift b/lib/go/test/ConflictArgNamesTest.thrift new file mode 100644 index 000000000..11323ecaf --- /dev/null +++ b/lib/go/test/ConflictArgNamesTest.thrift @@ -0,0 +1,32 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +service ConflictArgNamesTest { + /** + * Use some names that could conflict with the compiler code as args + * to make sure that the compiler handled them correctly. + */ + void testNameConflicts( + // 1: string args, // args is already a reserved keyword in thrift compiler + 2: string result, + 3: string meta, + 4: string r, + 5: string err, + ) +} diff --git a/lib/go/test/EqualsTest.thrift b/lib/go/test/EqualsTest.thrift index c699232b4..57ce131ec 100644 --- a/lib/go/test/EqualsTest.thrift +++ b/lib/go/test/EqualsTest.thrift @@ -1,3 +1,22 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + typedef i8 mybyte typedef string mystr typedef binary mybin @@ -106,4 +125,4 @@ struct MapEqualsFoo { 18: optional map OptInt64MyByteMapFoo, 19: map MyByteInt64MapFoo, 20: optional map OptMyByteInt64MapFoo, -} \ No newline at end of file +} diff --git a/lib/go/test/Makefile.am b/lib/go/test/Makefile.am index 2f748c6fa..4be652ed6 100644 --- a/lib/go/test/Makefile.am +++ b/lib/go/test/Makefile.am @@ -46,7 +46,9 @@ gopath: $(THRIFT) $(THRIFTTEST) \ ConflictNamespaceTestD.thrift \ ConflictNamespaceTestSuperThing.thrift \ ConflictNamespaceServiceTest.thrift \ - DuplicateImportsTest.thrift + DuplicateImportsTest.thrift \ + EqualsTest.thrift \ + ConflictArgNamesTest.thrift mkdir -p gopath/src grep -v list.*map.*list.*map $(THRIFTTEST) | grep -v 'set' > ThriftTest.thrift $(THRIFT) $(THRIFTARGS) -r IncludesTest.thrift @@ -74,6 +76,7 @@ gopath: $(THRIFT) $(THRIFTTEST) \ $(THRIFT) $(THRIFTARGS) ConflictNamespaceServiceTest.thrift $(THRIFT) $(THRIFTARGS) -r DuplicateImportsTest.thrift $(THRIFT) $(THRIFTARGS) EqualsTest.thrift + $(THRIFT) $(THRIFTARGS) ConflictArgNamesTest.thrift GOPATH=`pwd`/gopath $(GO) get github.com/golang/mock/gomock || true sed -i 's/\"context\"/\"golang.org\/x\/net\/context\"/g' gopath/src/github.com/golang/mock/gomock/controller.go || true GOPATH=`pwd`/gopath $(GO) get github.com/golang/mock/gomock @@ -99,7 +102,8 @@ check: gopath conflict/context/conflict_service-remote \ servicestest/container_test-remote \ duplicateimportstest \ - equalstest + equalstest \ + conflictargnamestest GOPATH=`pwd`/gopath $(GO) test thrift tests dontexportrwtest clean-local: @@ -113,6 +117,7 @@ EXTRA_DIST = \ tests \ common \ BinaryKeyTest.thrift \ + ConflictArgNamesTest.thrift \ ConflictNamespaceServiceTest.thrift \ ConflictNamespaceTestA.thrift \ ConflictNamespaceTestB.thrift \ diff --git a/lib/go/test/tests/conflict_arg_names_test.go b/lib/go/test/tests/conflict_arg_names_test.go new file mode 100644 index 000000000..92791517e --- /dev/null +++ b/lib/go/test/tests/conflict_arg_names_test.go @@ -0,0 +1,27 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package tests + +import ( + "conflictargnamestest" +) + +// We just want to make sure that the conflictargnamestest package compiles. +var _ = conflictargnamestest.GoUnusedProtection__ diff --git a/lib/go/test/tests/equals_test.go b/lib/go/test/tests/equals_test.go index 3489efa0d..deecb77ee 100644 --- a/lib/go/test/tests/equals_test.go +++ b/lib/go/test/tests/equals_test.go @@ -1,3 +1,22 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + package tests import ( diff --git a/test/ThriftTest.thrift b/test/ThriftTest.thrift index c88187c54..ac49aee01 100644 --- a/test/ThriftTest.thrift +++ b/test/ThriftTest.thrift @@ -411,17 +411,3 @@ struct StructB { struct OptionalSetDefaultTest { 1: optional set with_default = [ "test" ] } - -service ConflictingNamesTest { - /** - * Use some names that could conflict with the compiler code as args - * to make sure that the compiler handled them correctly. - */ - void testNameConflicts( - // 1: string args, // args is already a reserved keyword in thrift compiler - // 2: string result, // result will cause problems in compiled netstd code - 3: string meta, - 4: string r, - 5: string err, - ) -} From e89b3e11eed32ac7aa34d566ee1a8f45710a270b Mon Sep 17 00:00:00 2001 From: Yuxuan 'fishy' Wang Date: Thu, 18 Feb 2021 11:52:27 -0800 Subject: [PATCH 06/14] THRIFT-5353: Fix import dedup without explicit go namespace Client: go When a thrift file includes 2 or more other thrift files, and those included thrift files do not have explicit go namespaces defined, the current import dedup logic would wrongly use their empty namespace and skip the second one, while the real import namespace should be inferred from the filename. --- compiler/cpp/src/thrift/generate/t_go_generator.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/compiler/cpp/src/thrift/generate/t_go_generator.cc b/compiler/cpp/src/thrift/generate/t_go_generator.cc index 2cef11f34..8d25d48b5 100644 --- a/compiler/cpp/src/thrift/generate/t_go_generator.cc +++ b/compiler/cpp/src/thrift/generate/t_go_generator.cc @@ -787,14 +787,15 @@ void t_go_generator::init_generator() { string t_go_generator::render_included_programs(string& unused_prot) { const vector& includes = program_->get_includes(); string result = ""; - string local_namespace = program_->get_namespace("go"); + string local_namespace = get_real_go_module(program_); std::set included; for (auto include : includes) { - if (!local_namespace.empty() && local_namespace == include->get_namespace("go")) { + std::string includeModule = get_real_go_module(include); + if (!local_namespace.empty() && local_namespace == includeModule) { continue; } - if (!included.insert(include->get_namespace("go")).second) { + if (!included.insert(includeModule).second) { continue; } From 13f9e9e86471b45189eb40ca00fdb5a2a7fa0f26 Mon Sep 17 00:00:00 2001 From: Jens Geyer Date: Wed, 24 Feb 2021 20:39:24 +0100 Subject: [PATCH 07/14] fix nullptr exception in publishing.gradle --- lib/java/gradle/publishing.gradle | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/java/gradle/publishing.gradle b/lib/java/gradle/publishing.gradle index 029bff93d..481fcbc69 100644 --- a/lib/java/gradle/publishing.gradle +++ b/lib/java/gradle/publishing.gradle @@ -86,8 +86,10 @@ def configurePom(pom) { pom.whenConfigured { // Fixup the scope for servlet-api to be 'provided' instead of 'compile' dependencies.find { dep -> dep.groupId == 'javax.servlet' && dep.artifactId == 'servlet-api' }.with { - // it.optional = true - it.scope = 'provided' + if(it != null) { + // it.optional = true + it.scope = 'provided' + } } } } From 4a8b0f9ecc06356639ed538324c5dd0f9936d757 Mon Sep 17 00:00:00 2001 From: Jens Geyer Date: Wed, 24 Feb 2021 23:05:04 +0100 Subject: [PATCH 08/14] fix to publish haxelib --- lib/haxe/haxelib.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/haxe/haxelib.json b/lib/haxe/haxelib.json index d0e437ba3..894b748ff 100644 --- a/lib/haxe/haxelib.json +++ b/lib/haxe/haxelib.json @@ -6,7 +6,7 @@ "description": "Haxe bindings for the Apache Thrift RPC and serialization framework", "version": "0.14.0", "releasenote": "Licensed under Apache License, Version 2.0. The Apache Thrift compiler needs to be installed separately.", - "contributors": ["Apache Software Foundation (ASF)"], + "contributors": ["ApacheThrift"], "dependencies": { }, "classPath": "src" } From 65fb49bb41f852375b278c9057d52c9472f0cb3a Mon Sep 17 00:00:00 2001 From: "James Z.M. Gao" Date: Wed, 6 Jan 2021 11:51:41 +0800 Subject: [PATCH 09/14] THRIFT-5334 change version of thrift-maven-plugin to 0.14.0 Client: Java Patch: James Z.M. Gao --- build/veralign.sh | 15 ++++++++++++++- contrib/thrift-maven-plugin/pom.xml | 2 +- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/build/veralign.sh b/build/veralign.sh index 422da8507..9a0d88340 100755 --- a/build/veralign.sh +++ b/build/veralign.sh @@ -57,6 +57,7 @@ FILES[configure.ac]=configureReplace FILES[contrib/Rebus/Properties/AssemblyInfo.cs]=simpleReplace FILES[contrib/thrift.spec]=simpleReplace FILES[contrib/zeromq/csharp/AssemblyInfo.cs]=simpleReplace +FILES[contrib/thrift-maven-plugin/pom.xml]=pomReplace FILES[doc/specs/idl.md]=simpleReplace FILES[lib/as3/gradle.properties]=simpleReplace FILES[lib/d/src/thrift/base.d]=simpleReplace @@ -154,7 +155,7 @@ validateVersion "${NEWVERSION}" || exit $? # function escapeVersion { - echo "$(echo $1 | sed 's/\./\\./g' | sed 's/\[/\\\[/g' | sed 's/\]/\\\]/g')" + echo "$(echo "$1" | sed 's/\./\\./g' | sed 's/\[/\\\[/g' | sed 's/\]/\\\]/g')" } # Set up verbose hilighting if running interactive @@ -237,6 +238,18 @@ function pubspecReplace replace "$1" "version: ${OLDVERSION}" "version: ${NEWVERSION}" } +# +# pomReplace: replace a specific version field in a maven pom file +# must be a top level "version" field in the xml structure +# \param $1 filename to do replacements on +# \returns 0 on success +# + +function pomReplace +{ + replace "$1" "^ ${OLDVERSION}<\/version>" " ${NEWVERSION}<\/version>" +} + # # replace: replace occurrences of one string with another # the file specified must contain the old string at least once diff --git a/contrib/thrift-maven-plugin/pom.xml b/contrib/thrift-maven-plugin/pom.xml index b18162257..064f0cc41 100644 --- a/contrib/thrift-maven-plugin/pom.xml +++ b/contrib/thrift-maven-plugin/pom.xml @@ -32,7 +32,7 @@ thrift-maven-plugin maven-plugin thrift-maven-plugin - 1.0.0 + 0.14.0 1.8 From 65291dac391080d8aa8188ea62f428f4398425cc Mon Sep 17 00:00:00 2001 From: Jens Geyer Date: Tue, 2 Mar 2021 21:02:34 +0100 Subject: [PATCH 10/14] version 0.14.1 --- ApacheThrift.nuspec | 8 ++++---- CMakeLists.txt | 2 +- Thrift.podspec | 4 ++-- appveyor.yml | 2 +- bower.json | 2 +- build/veralign.sh | 6 ------ compiler/cpp/src/thrift/version.h | 2 +- configure.ac | 2 +- contrib/Rebus/Properties/AssemblyInfo.cs | 4 ++-- contrib/thrift-maven-plugin/pom.xml | 2 +- contrib/thrift.spec | 2 +- contrib/zeromq/csharp/AssemblyInfo.cs | 2 +- debian/changelog | 6 ++++++ doap.rdf | 5 +++++ doc/specs/idl.md | 2 +- lib/as3/gradle.properties | 2 +- lib/d/src/thrift/base.d | 2 +- lib/dart/pubspec.yaml | 2 +- lib/delphi/src/Thrift.pas | 2 +- lib/erl/src/thrift.app.src | 2 +- lib/haxe/haxelib.json | 2 +- lib/hs/thrift.cabal | 2 +- lib/java/gradle.properties | 2 +- lib/js/package-lock.json | 2 +- lib/js/package.json | 2 +- lib/js/src/thrift.js | 2 +- lib/lua/Thrift.lua | 2 +- lib/netstd/Thrift/Properties/AssemblyInfo.cs | 4 ++-- lib/netstd/Thrift/Thrift.csproj | 6 +++--- lib/ocaml/_oasis | 2 +- lib/perl/lib/Thrift.pm | 2 +- lib/py/setup.py | 2 +- lib/rb/thrift.gemspec | 2 +- lib/rs/Cargo.toml | 2 +- lib/st/package.xml | 2 +- lib/swift/Sources/Thrift.swift | 2 +- lib/swift/Tests/ThriftTests/ThriftTests.swift | 2 +- lib/ts/package-lock.json | 2 +- lib/ts/package.json | 2 +- package-lock.json | 2 +- package.json | 2 +- sonar-project.properties | 6 +++--- test/dart/test_client/pubspec.yaml | 2 +- test/erl/src/thrift_test.app.src | 2 +- tutorial/dart/client/pubspec.yaml | 2 +- tutorial/dart/console_client/pubspec.yaml | 2 +- tutorial/dart/server/pubspec.yaml | 2 +- tutorial/delphi/DelphiClient/DelphiClient.dproj | 4 ++-- tutorial/delphi/DelphiServer/DelphiServer.dproj | 4 ++-- tutorial/hs/ThriftTutorial.cabal | 2 +- tutorial/ocaml/_oasis | 2 +- 51 files changed, 71 insertions(+), 66 deletions(-) diff --git a/ApacheThrift.nuspec b/ApacheThrift.nuspec index 61caf5753..54c5af368 100644 --- a/ApacheThrift.nuspec +++ b/ApacheThrift.nuspec @@ -19,14 +19,14 @@ the "Thrift" project. 2. nuget setApiKey 3. nuget pack ApacheThrift.nuspec -Symbols -SymbolPackageFormat snupkg - 4. nuget push ApacheThrift.0.14.0.nupkg -Source https://api.nuget.org/v3/index.json + 4. nuget push ApacheThrift.0.14.1.nupkg -Source https://api.nuget.org/v3/index.json --> ApacheThrift - 0.14.0 - Apache Thrift 0.14.0 + 0.14.1 + Apache Thrift 0.14.1 Apache Thrift Developers Apache Software Foundation Apache-2.0 @@ -36,7 +36,7 @@ Contains runtime libraries from lib/netstd for netstandard2.0 framework development. - + Apache Thrift RPC diff --git a/CMakeLists.txt b/CMakeLists.txt index 127ceaf26..602d9ea73 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -28,7 +28,7 @@ endif() # PACKAGE_VERSION is used by cpack scripts currently # Both thrift_VERSION and PACKAGE_VERSION should be the same for now -set(thrift_VERSION "0.14.0") +set(thrift_VERSION "0.14.1") set(PACKAGE_VERSION ${thrift_VERSION}) project("thrift" VERSION ${PACKAGE_VERSION}) diff --git a/Thrift.podspec b/Thrift.podspec index 46de2b405..fefbc0dae 100644 --- a/Thrift.podspec +++ b/Thrift.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'Thrift' - s.version = '0.14.0' + s.version = '0.14.1' s.summary = "Apache Thrift is a lightweight, language-independent software stack with an associated code generation mechanism for RPC." s.description = <<-DESC The Apache Thrift scalable cross-language software framework for networked services development combines a software stack with a code generation engine to build services that work efficiently and seamlessly between many programming languages. @@ -10,6 +10,6 @@ The Apache Thrift scalable cross-language software framework for networked servi s.author = { 'Apache Thrift Developers' => 'dev@thrift.apache.org' } s.ios.deployment_target = '9.0' s.osx.deployment_target = '10.10' - s.source = { :git => 'https://github.com/apache/thrift.git', :tag => 'v0.14.0' } + s.source = { :git => 'https://github.com/apache/thrift.git', :tag => 'v0.14.1' } s.source_files = 'lib/swift/Sources/*.swift' end diff --git a/appveyor.yml b/appveyor.yml index 96fe30cf3..e60a46319 100755 --- a/appveyor.yml +++ b/appveyor.yml @@ -19,7 +19,7 @@ # build Apache Thrift on AppVeyor - https://ci.appveyor.com -version: '0.14.0.{build}' +version: '0.14.1.{build}' shallow_clone: true diff --git a/bower.json b/bower.json index 68f2c8d2c..a9fa0add4 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.0", + "version": "0.14.1", "homepage": "https://github.com/apache/thrift.git", "authors": [ "Apache Thrift " diff --git a/build/veralign.sh b/build/veralign.sh index 9a0d88340..9f51f2242 100755 --- a/build/veralign.sh +++ b/build/veralign.sh @@ -71,7 +71,6 @@ FILES[lib/js/package-lock.json]=jsonReplace FILES[lib/js/package.json]=jsonReplace FILES[lib/js/src/thrift.js]=simpleReplace FILES[lib/lua/Thrift.lua]=simpleReplace -FILES[lib/netstd/Tests/Thrift.PublicInterfaces.Compile.Tests/Properties/AssemblyInfo.cs]=simpleReplace FILES[lib/netstd/Thrift/Properties/AssemblyInfo.cs]=simpleReplace FILES[lib/netstd/Thrift/Properties/AssemblyInfo.cs]=simpleReplace FILES[lib/netstd/Thrift/Thrift.csproj]=simpleReplace @@ -90,8 +89,6 @@ FILES[package.json]=jsonReplace FILES[sonar-project.properties]=simpleReplace FILES[test/dart/test_client/pubspec.yaml]=pubspecReplace FILES[test/erl/src/thrift_test.app.src]=simpleReplace -FILES[test/netstd/Client/Properties/AssemblyInfo.cs]=simpleReplace -FILES[test/netstd/Server/Properties/AssemblyInfo.cs]=simpleReplace FILES[Thrift.podspec]=simpleReplace FILES[tutorial/dart/client/pubspec.yaml]=pubspecReplace FILES[tutorial/dart/console_client/pubspec.yaml]=pubspecReplace @@ -99,9 +96,6 @@ FILES[tutorial/dart/server/pubspec.yaml]=pubspecReplace FILES[tutorial/delphi/DelphiClient/DelphiClient.dproj]=simpleReplace FILES[tutorial/delphi/DelphiServer/DelphiServer.dproj]=simpleReplace FILES[tutorial/hs/ThriftTutorial.cabal]=simpleReplace -FILES[tutorial/netstd/Client/Properties/AssemblyInfo.cs]=simpleReplace -FILES[tutorial/netstd/Interfaces/Properties/AssemblyInfo.cs]=simpleReplace -FILES[tutorial/netstd/Server/Properties/AssemblyInfo.cs]=simpleReplace FILES[tutorial/ocaml/_oasis]=simpleReplace diff --git a/compiler/cpp/src/thrift/version.h b/compiler/cpp/src/thrift/version.h index 3a7250d9d..a1960c4e2 100644 --- a/compiler/cpp/src/thrift/version.h +++ b/compiler/cpp/src/thrift/version.h @@ -24,6 +24,6 @@ #pragma once #endif // _MSC_VER -#define THRIFT_VERSION "0.14.0" +#define THRIFT_VERSION "0.14.1" #endif // _THRIFT_VERSION_H_ diff --git a/configure.ac b/configure.ac index 35f43ee5f..8c656c4a7 100755 --- a/configure.ac +++ b/configure.ac @@ -20,7 +20,7 @@ AC_PREREQ(2.65) AC_CONFIG_MACRO_DIR([./aclocal]) -AC_INIT([thrift], [0.14.0]) +AC_INIT([thrift], [0.14.1]) AC_CONFIG_AUX_DIR([.]) diff --git a/contrib/Rebus/Properties/AssemblyInfo.cs b/contrib/Rebus/Properties/AssemblyInfo.cs index e476eab76..55c935dfd 100644 --- a/contrib/Rebus/Properties/AssemblyInfo.cs +++ b/contrib/Rebus/Properties/AssemblyInfo.cs @@ -34,5 +34,5 @@ using System.Runtime.InteropServices; [assembly: Guid("0af10984-40d3-453d-b1e5-421529e8c7e2")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] +[assembly: AssemblyVersion("0.14.1.0")] +[assembly: AssemblyFileVersion("0.14.1.0")] diff --git a/contrib/thrift-maven-plugin/pom.xml b/contrib/thrift-maven-plugin/pom.xml index 064f0cc41..dc41b3ff6 100644 --- a/contrib/thrift-maven-plugin/pom.xml +++ b/contrib/thrift-maven-plugin/pom.xml @@ -32,7 +32,7 @@ thrift-maven-plugin maven-plugin thrift-maven-plugin - 0.14.0 + 0.14.1 1.8 diff --git a/contrib/thrift.spec b/contrib/thrift.spec index 4c678ba7f..cbc58b905 100644 --- a/contrib/thrift.spec +++ b/contrib/thrift.spec @@ -28,7 +28,7 @@ Name: thrift License: Apache License v2.0 Group: Development Summary: RPC and serialization framework -Version: 0.14.0 +Version: 0.14.1 Release: 0 URL: http://thrift.apache.org Packager: Thrift Developers diff --git a/contrib/zeromq/csharp/AssemblyInfo.cs b/contrib/zeromq/csharp/AssemblyInfo.cs index 12cd434f3..d6f193dc5 100644 --- a/contrib/zeromq/csharp/AssemblyInfo.cs +++ b/contrib/zeromq/csharp/AssemblyInfo.cs @@ -36,7 +36,7 @@ using System.Runtime.CompilerServices; // The form "{Major}.{Minor}.*" will automatically update the build and revision, // and "{Major}.{Minor}.{Build}.*" will update just the revision. -[assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("0.14.1.0")] // The following attributes are used to specify the signing key for the assembly, // if desired. See the Mono documentation for more information about signing. diff --git a/debian/changelog b/debian/changelog index 8fd900c73..5ef73b2db 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +thrift (0.14.1) stable; urgency=low + + * update to 0.14.1 + + -- Apache Thrift Developers Tue, 02 Mar 2021 21:00:00 +0100 + thrift (0.14.0) stable; urgency=low * update to 0.14.0 diff --git a/doap.rdf b/doap.rdf index 6094de728..2d14c3fee 100755 --- a/doap.rdf +++ b/doap.rdf @@ -57,6 +57,11 @@ + + Apache Thrift + 2021-03-02 + 0.14.1 + Apache Thrift 2021-02-04 diff --git a/doc/specs/idl.md b/doc/specs/idl.md index 39b2dddb0..41e820168 100644 --- a/doc/specs/idl.md +++ b/doc/specs/idl.md @@ -1,6 +1,6 @@ ## Thrift interface description language -For Thrift version 0.14.0. +For Thrift version 0.14.1. The Thrift interface definition language (IDL) allows for the definition of [Thrift Types](/docs/types). A Thrift IDL file is processed by the Thrift code generator to produce code for the various target languages to support the defined structs and services in the IDL file. diff --git a/lib/as3/gradle.properties b/lib/as3/gradle.properties index 9ace27538..7702fde28 100644 --- a/lib/as3/gradle.properties +++ b/lib/as3/gradle.properties @@ -1,7 +1,7 @@ # This file is shared currently between this Gradle build and the # Ant builds for fd303 and JavaScript. Keep the dotted notation for # the properties to minimize the changes in the dependencies. -thrift.version=0.14.0 +thrift.version=0.14.1 thrift.groupid=org.apache.thrift release=false sign=false diff --git a/lib/d/src/thrift/base.d b/lib/d/src/thrift/base.d index 4a8fbd759..52427402d 100644 --- a/lib/d/src/thrift/base.d +++ b/lib/d/src/thrift/base.d @@ -50,7 +50,7 @@ class TCompoundOperationException : TException { /// The Thrift version string, used for informative purposes. // Note: This is currently hardcoded, but will likely be filled in by the build // system in future versions. -enum VERSION = "0.14.0"; +enum VERSION = "0.14.1"; /** * Functions used for logging inside Thrift. diff --git a/lib/dart/pubspec.yaml b/lib/dart/pubspec.yaml index 1999b5824..a29da6f83 100644 --- a/lib/dart/pubspec.yaml +++ b/lib/dart/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: thrift -version: 0.14.0 +version: 0.14.1 description: > A Dart library for Apache Thrift author: Apache Thrift Developers diff --git a/lib/delphi/src/Thrift.pas b/lib/delphi/src/Thrift.pas index 1926b11ef..72a951054 100644 --- a/lib/delphi/src/Thrift.pas +++ b/lib/delphi/src/Thrift.pas @@ -28,7 +28,7 @@ uses Thrift.Protocol; const - Version = '0.14.0'; + Version = '0.14.1'; type TException = Thrift.Exception.TException; // compatibility alias diff --git a/lib/erl/src/thrift.app.src b/lib/erl/src/thrift.app.src index 5e8d670f2..c95369bed 100644 --- a/lib/erl/src/thrift.app.src +++ b/lib/erl/src/thrift.app.src @@ -22,7 +22,7 @@ {description, "Thrift bindings"}, % The version of the applicaton - {vsn, "0.14.0"}, + {vsn, "0.14.1"}, % All modules used by the application. {modules, [ diff --git a/lib/haxe/haxelib.json b/lib/haxe/haxelib.json index 894b748ff..ede937c64 100644 --- a/lib/haxe/haxelib.json +++ b/lib/haxe/haxelib.json @@ -4,7 +4,7 @@ "license": "Apache", "tags": ["thrift", "rpc", "serialization", "cross", "framework"], "description": "Haxe bindings for the Apache Thrift RPC and serialization framework", - "version": "0.14.0", + "version": "0.14.1", "releasenote": "Licensed under Apache License, Version 2.0. The Apache Thrift compiler needs to be installed separately.", "contributors": ["ApacheThrift"], "dependencies": { }, diff --git a/lib/hs/thrift.cabal b/lib/hs/thrift.cabal index c60effbe8..10724a41a 100644 --- a/lib/hs/thrift.cabal +++ b/lib/hs/thrift.cabal @@ -18,7 +18,7 @@ -- Name: thrift -Version: 0.14.0 +Version: 0.14.1 Cabal-Version: 1.24 License: Apache Category: Foreign diff --git a/lib/java/gradle.properties b/lib/java/gradle.properties index 8a7acb10d..ad1a9f18c 100644 --- a/lib/java/gradle.properties +++ b/lib/java/gradle.properties @@ -1,7 +1,7 @@ # This file is shared currently between this Gradle build and the # Ant builds for fd303 and JavaScript. Keep the dotted notation for # the properties to minimize the changes in the dependencies. -thrift.version=0.14.0 +thrift.version=0.14.1 thrift.groupid=org.apache.thrift release=false diff --git a/lib/js/package-lock.json b/lib/js/package-lock.json index 3f054cdbc..ea1c04620 100644 --- a/lib/js/package-lock.json +++ b/lib/js/package-lock.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.0", + "version": "0.14.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/lib/js/package.json b/lib/js/package.json index a46a73255..f57c57fb0 100644 --- a/lib/js/package.json +++ b/lib/js/package.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.0", + "version": "0.14.1", "description": "Thrift is a software framework for scalable cross-language services development.", "main": "./src/thrift", "author": { diff --git a/lib/js/src/thrift.js b/lib/js/src/thrift.js index 123f526ac..48f029f89 100644 --- a/lib/js/src/thrift.js +++ b/lib/js/src/thrift.js @@ -46,7 +46,7 @@ var Thrift = { * @const {string} Version * @memberof Thrift */ - Version: '0.14.0', + Version: '0.14.1', /** * Thrift IDL type string to Id mapping. diff --git a/lib/lua/Thrift.lua b/lib/lua/Thrift.lua index 4a290de5c..b8a87001e 100644 --- a/lib/lua/Thrift.lua +++ b/lib/lua/Thrift.lua @@ -48,7 +48,7 @@ function ttable_size(t) return count end -version = '0.14.0' +version = '0.14.1' TType = { STOP = 0, diff --git a/lib/netstd/Thrift/Properties/AssemblyInfo.cs b/lib/netstd/Thrift/Properties/AssemblyInfo.cs index 58aa84495..c37f32604 100644 --- a/lib/netstd/Thrift/Properties/AssemblyInfo.cs +++ b/lib/netstd/Thrift/Properties/AssemblyInfo.cs @@ -52,5 +52,5 @@ using System.Runtime.InteropServices; // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: -[assembly: AssemblyVersion("0.14.0.0")] -[assembly: AssemblyFileVersion("0.14.0.0")] +[assembly: AssemblyVersion("0.14.1.0")] +[assembly: AssemblyFileVersion("0.14.1.0")] diff --git a/lib/netstd/Thrift/Thrift.csproj b/lib/netstd/Thrift/Thrift.csproj index b14a842f0..35a34aed0 100644 --- a/lib/netstd/Thrift/Thrift.csproj +++ b/lib/netstd/Thrift/Thrift.csproj @@ -39,8 +39,8 @@ true thrift.snk false - Apache Thrift 0.14.0 - 0.14.0.0 + Apache Thrift 0.14.1 + 0.14.1.0 false http://thrift.apache.org/ Apache Thrift Developers @@ -49,7 +49,7 @@ C# .NET Core bindings for the Apache Thrift RPC system Apache Thrift RPC - https://github.com/apache/thrift/blob/0.14.0/CHANGES.md + https://github.com/apache/thrift/blob/0.14.1/CHANGES.md Copyright 2021 The Apache Software Foundation diff --git a/lib/ocaml/_oasis b/lib/ocaml/_oasis index 2b6c477b0..8fb774a19 100644 --- a/lib/ocaml/_oasis +++ b/lib/ocaml/_oasis @@ -1,5 +1,5 @@ Name: libthrift-ocaml -Version: 0.14.0 +Version: 0.14.1 OASISFormat: 0.3 Synopsis: OCaml bindings for the Apache Thrift RPC system Authors: Apache Thrift Developers diff --git a/lib/perl/lib/Thrift.pm b/lib/perl/lib/Thrift.pm index 9a7c6bbf8..cdd3f0368 100644 --- a/lib/perl/lib/Thrift.pm +++ b/lib/perl/lib/Thrift.pm @@ -31,6 +31,6 @@ use warnings; # package Thrift; -use version 0.77; our $VERSION = version->declare("v0.14.0"); +use version 0.77; our $VERSION = version->declare("v0.14.1"); 1; diff --git a/lib/py/setup.py b/lib/py/setup.py index 27a392d08..bb5ee5a4e 100644 --- a/lib/py/setup.py +++ b/lib/py/setup.py @@ -91,7 +91,7 @@ def run_setup(with_binary): twisted_deps = ['twisted'] setup(name='thrift', - version='0.14.0', + version='0.14.1', description='Python bindings for the Apache Thrift RPC system', author='Apache Thrift Developers', author_email='dev@thrift.apache.org', diff --git a/lib/rb/thrift.gemspec b/lib/rb/thrift.gemspec index c6f32cb9a..5f948a660 100644 --- a/lib/rb/thrift.gemspec +++ b/lib/rb/thrift.gemspec @@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__) Gem::Specification.new do |s| s.name = 'thrift' - s.version = '0.14.0' + s.version = '0.14.1' s.authors = ['Apache Thrift Developers'] s.email = ['dev@thrift.apache.org'] s.homepage = 'http://thrift.apache.org' diff --git a/lib/rs/Cargo.toml b/lib/rs/Cargo.toml index 4f2b4c82c..5c2339a63 100644 --- a/lib/rs/Cargo.toml +++ b/lib/rs/Cargo.toml @@ -2,7 +2,7 @@ name = "thrift" description = "Rust bindings for the Apache Thrift RPC system" edition = "2018" -version = "0.14.0" +version = "0.14.1" license = "Apache-2.0" authors = ["Apache Thrift Developers "] homepage = "http://thrift.apache.org" diff --git a/lib/st/package.xml b/lib/st/package.xml index eab405225..a45e54f1f 100644 --- a/lib/st/package.xml +++ b/lib/st/package.xml @@ -17,7 +17,7 @@ specific language governing permissions and limitations under the License. --> - + libthrift-st thrift.st diff --git a/lib/swift/Sources/Thrift.swift b/lib/swift/Sources/Thrift.swift index 789aae9e7..9ea6f98f2 100644 --- a/lib/swift/Sources/Thrift.swift +++ b/lib/swift/Sources/Thrift.swift @@ -1,3 +1,3 @@ class Thrift { - let version = "0.14.0" + let version = "0.14.1" } diff --git a/lib/swift/Tests/ThriftTests/ThriftTests.swift b/lib/swift/Tests/ThriftTests/ThriftTests.swift index 226862e2b..ca3ebcf82 100644 --- a/lib/swift/Tests/ThriftTests/ThriftTests.swift +++ b/lib/swift/Tests/ThriftTests/ThriftTests.swift @@ -3,7 +3,7 @@ import XCTest class ThriftTests: XCTestCase { func testVersion() { - XCTAssertEqual(Thrift().version, "0.14.0") + XCTAssertEqual(Thrift().version, "0.14.1") } static var allTests : [(String, (ThriftTests) -> () throws -> Void)] { diff --git a/lib/ts/package-lock.json b/lib/ts/package-lock.json index 49de90bf4..fddef4426 100644 --- a/lib/ts/package-lock.json +++ b/lib/ts/package-lock.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.0", + "version": "0.14.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/lib/ts/package.json b/lib/ts/package.json index 1cd6c7100..77ad0d78b 100644 --- a/lib/ts/package.json +++ b/lib/ts/package.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.0", + "version": "0.14.1", "description": "Thrift is a software framework for scalable cross-language services development.", "author": { "name": "Apache Thrift Developers", diff --git a/package-lock.json b/package-lock.json index 5cab4bff1..9c1e5f581 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.0", + "version": "0.14.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 4928653e3..5b34d5818 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "type": "git", "url": "https://github.com/apache/thrift.git" }, - "version": "0.14.0", + "version": "0.14.1", "author": { "name": "Apache Thrift Developers", "email": "dev@thrift.apache.org", diff --git a/sonar-project.properties b/sonar-project.properties index fcda47762..ef42feb6b 100755 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -16,7 +16,7 @@ development, combines a software stack with a code generation engine to build services that work efficiently and seamlessly between all major languages. # Apache Thrift Version -sonar.projectVersion=0.14.0 +sonar.projectVersion=0.14.1 # use this to set another version string # $ sonar-runner -D sonar.projectVersion=`git rev-parse HEAD` # set projectDate in combination with projectVersion for imports of old releases @@ -54,7 +54,7 @@ module1.sonar.projectName=Apache Thrift - Java Library module1.sonar.projectBaseDir=lib/java module1.sonar.sources=src module1.sonar.tests=test -module1.sonar.binaries=build/libs/libthrift-0.14.0.jar +module1.sonar.binaries=build/libs/libthrift-0.14.1.jar module1.sonar.libraries=build/deps/*.jar module1.sonar.language=java @@ -62,7 +62,7 @@ module2.sonar.projectName=Apache Thrift - Java Tutorial module2.sonar.projectBaseDir=. module2.sonar.sources=tutorial/java/src, tutorial/java/gen-java module2.sonar.binaries=tutorial/java/tutorial.jar -module2.sonar.libraries=lib/java/build/deps/*.jar,lib/java/build/libs/libthrift-0.14.0.jar +module2.sonar.libraries=lib/java/build/deps/*.jar,lib/java/build/libs/libthrift-0.14.1.jar module2.sonar.language=java module3.sonar.projectName=Apache Thrift - JavaScript Library diff --git a/test/dart/test_client/pubspec.yaml b/test/dart/test_client/pubspec.yaml index 648196214..3469ad7b6 100644 --- a/test/dart/test_client/pubspec.yaml +++ b/test/dart/test_client/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: thrift_test_client -version: 0.14.0 +version: 0.14.1 description: A client integration test for the Dart Thrift library author: Apache Thrift Developers homepage: http://thrift.apache.org diff --git a/test/erl/src/thrift_test.app.src b/test/erl/src/thrift_test.app.src index b6242b3ee..2af9c180a 100644 --- a/test/erl/src/thrift_test.app.src +++ b/test/erl/src/thrift_test.app.src @@ -22,7 +22,7 @@ {description, "Thrift cross language test"}, % The version of the applicaton - {vsn, "0.14.0"}, + {vsn, "0.14.1"}, % All modules used by the application. {modules, [ diff --git a/tutorial/dart/client/pubspec.yaml b/tutorial/dart/client/pubspec.yaml index 35880ed08..ffd22a8cb 100644 --- a/tutorial/dart/client/pubspec.yaml +++ b/tutorial/dart/client/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: tutorial_client -version: 0.14.0 +version: 0.14.1 description: A Dart client implementation of the Apache Thrift tutorial author: Apache Thrift Developers homepage: http://thrift.apache.org diff --git a/tutorial/dart/console_client/pubspec.yaml b/tutorial/dart/console_client/pubspec.yaml index 1068f909c..d895c20be 100644 --- a/tutorial/dart/console_client/pubspec.yaml +++ b/tutorial/dart/console_client/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: tutorial_console_client -version: 0.14.0 +version: 0.14.1 description: > A Dart console client to implementation of the Apache Thrift tutorial author: Apache Thrift Developers diff --git a/tutorial/dart/server/pubspec.yaml b/tutorial/dart/server/pubspec.yaml index bdd74b826..2992a9b80 100644 --- a/tutorial/dart/server/pubspec.yaml +++ b/tutorial/dart/server/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: tutorial_server -version: 0.14.0 +version: 0.14.1 description: A Dart server to support the Apache Thrift tutorial author: Apache Thrift Developers homepage: http://thrift.apache.org diff --git a/tutorial/delphi/DelphiClient/DelphiClient.dproj b/tutorial/delphi/DelphiClient/DelphiClient.dproj index 2612f149b..2b68d79a4 100644 --- a/tutorial/delphi/DelphiClient/DelphiClient.dproj +++ b/tutorial/delphi/DelphiClient/DelphiClient.dproj @@ -101,13 +101,13 @@ Thrift Tutorial - 0.14.0.0 + 0.14.1.0 DelphiClient Copyright © 2012 The Apache Software Foundation DelphiClient.exe Thrift - 0.14.0.0 + 0.14.1.0 diff --git a/tutorial/delphi/DelphiServer/DelphiServer.dproj b/tutorial/delphi/DelphiServer/DelphiServer.dproj index f62257e22..3f781468b 100644 --- a/tutorial/delphi/DelphiServer/DelphiServer.dproj +++ b/tutorial/delphi/DelphiServer/DelphiServer.dproj @@ -98,13 +98,13 @@ Thrift Tutorial - 0.14.0.0 + 0.14.1.0 DelphiServer Copyright © 2012 The Apache Software Foundation DelphiServer.exe Thrift - 0.14.0.0 + 0.14.1.0 diff --git a/tutorial/hs/ThriftTutorial.cabal b/tutorial/hs/ThriftTutorial.cabal index acf2130bf..eeb6c4906 100755 --- a/tutorial/hs/ThriftTutorial.cabal +++ b/tutorial/hs/ThriftTutorial.cabal @@ -18,7 +18,7 @@ -- Name: ThriftTutorial -Version: 0.14.0 +Version: 0.14.1 Cabal-Version: >= 1.4 License: OtherLicense Category: Foreign diff --git a/tutorial/ocaml/_oasis b/tutorial/ocaml/_oasis index 7491436e9..c08017089 100644 --- a/tutorial/ocaml/_oasis +++ b/tutorial/ocaml/_oasis @@ -1,5 +1,5 @@ Name: tutorial -Version: 0.14.0 +Version: 0.14.1 OASISFormat: 0.3 Synopsis: OCaml Tutorial example Authors: Apache Thrift Developers From c1e33a8436d716c49501417a5c8755ffd56c8719 Mon Sep 17 00:00:00 2001 From: Jens Geyer Date: Tue, 2 Mar 2021 21:20:41 +0100 Subject: [PATCH 11/14] version 0.14.1 --- CHANGES.md | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/CHANGES.md b/CHANGES.md index eddc05fd9..8c4364fe8 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,5 +1,38 @@ # Apache Thrift Changelog +## 0.14.1 + +### Known Open Issues (Blocker or Critical) + +- [THRIFT-3877](https://issues.apache.org/jira/browse/THRIFT-3877) - C++: library don't work with HTTP (csharp server, cpp client; need cross test enhancement) +- [THRIFT-5098](https://issues.apache.org/jira/browse/THRIFT-5098) - Deprecated: "The high level Network interface is no longer supported. Please use Network.Socket." and other Haskell issues +- [THRIFT-5245](https://issues.apache.org/jira/browse/THRIFT-5245) - NPE when the value of map's key is null + +### Deprecated Languages + +- [THRIFT-5347](https://issues.apache.org/jira/browse/THRIFT-5347) - Deprecate Haskell bindings + +### Build Process + +- [THRIFT-5334](https://issues.apache.org/jira/browse/THRIFT-5334) - version of thrift-maven-plugin is not sync with the main project + +### Delphi + +- [THRIFT-5350](https://issues.apache.org/jira/browse/THRIFT-5350) - 0.14.0 fails to build on non-x86 + +### Go + +- [THRIFT-5353](https://issues.apache.org/jira/browse/THRIFT-5353) - Namespace from type is ignored in generated code + +### Python + +- [THRIFT-5352](https://issues.apache.org/jira/browse/THRIFT-5352) - Python: IDL exceptions with no fields can't be instantiated + +### Rust + +- [THRIFT-5299](https://issues.apache.org/jira/browse/THRIFT-5299) - rs implementation compact protocol seq_id should not use zigzag encoding. + + ## 0.14.0 ### Deprecated Languages From d604602064e9218cc1f0153a4f83dff22fa1b44e Mon Sep 17 00:00:00 2001 From: aaronstgeorge-wf Date: Tue, 30 Mar 2021 00:35:13 +0200 Subject: [PATCH 12/14] THRIFT-5383 TJSONProtocol Java readString throws on bounds check Client: java Patch: Aaron St. George This closes #2366 --- .../org/apache/thrift/protocol/TJSONProtocol.java | 4 +--- .../apache/thrift/protocol/TestTJSONProtocol.java | 14 ++++++++++++++ 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/lib/java/src/org/apache/thrift/protocol/TJSONProtocol.java b/lib/java/src/org/apache/thrift/protocol/TJSONProtocol.java index 6bb49cb2f..95eb62ced 100644 --- a/lib/java/src/org/apache/thrift/protocol/TJSONProtocol.java +++ b/lib/java/src/org/apache/thrift/protocol/TJSONProtocol.java @@ -972,9 +972,7 @@ public class TJSONProtocol extends TProtocol { @Override public String readString() throws TException { - String str = readJSONString(false).toString(StandardCharsets.UTF_8); - getTransport().checkReadBytesAvailable(str.length() * getMinSerializedSize(TType.STRING)); - return str; + return readJSONString(false).toString(StandardCharsets.UTF_8); } @Override diff --git a/lib/java/test/org/apache/thrift/protocol/TestTJSONProtocol.java b/lib/java/test/org/apache/thrift/protocol/TestTJSONProtocol.java index c2ca1fa7a..ecbd10188 100644 --- a/lib/java/test/org/apache/thrift/protocol/TestTJSONProtocol.java +++ b/lib/java/test/org/apache/thrift/protocol/TestTJSONProtocol.java @@ -45,4 +45,18 @@ public class TestTJSONProtocol extends ProtocolTestBase { assertEquals(expectedString, protocol.readString()); } + + public void testExactlySizedBuffer() throws TException { + // Regression test for https://issues.apache.org/jira/browse/THRIFT-5383. + // Ensures that a JSON string can be read after writing to a buffer just + // large enough to contain it. + String inputString = "abcdefg"; + TMemoryBuffer buffer = new TMemoryBuffer(inputString.length() + 2); + + TJSONProtocol protocol = new TJSONProtocol(buffer); + protocol.writeString(inputString); + String outputString = protocol.readString(); + + assertEquals(inputString, outputString); + } } From 63e86ce23a28b990c68fb908971ac95ea30444c6 Mon Sep 17 00:00:00 2001 From: Jens Geyer Date: Fri, 11 Jun 2021 00:41:22 +0200 Subject: [PATCH 13/14] Version 0.14.2 --- ApacheThrift.nuspec | 8 ++++---- CHANGES.md | 7 +++++++ CMakeLists.txt | 2 +- Thrift.podspec | 4 ++-- appveyor.yml | 2 +- bower.json | 2 +- compiler/cpp/src/thrift/version.h | 2 +- configure.ac | 2 +- contrib/Rebus/Properties/AssemblyInfo.cs | 4 ++-- contrib/thrift-maven-plugin/pom.xml | 2 +- contrib/thrift.spec | 2 +- contrib/zeromq/csharp/AssemblyInfo.cs | 2 +- debian/changelog | 6 ++++++ doap.rdf | 5 +++++ doc/specs/idl.md | 2 +- lib/as3/gradle.properties | 2 +- lib/d/src/thrift/base.d | 2 +- lib/dart/pubspec.yaml | 2 +- lib/delphi/src/Thrift.pas | 2 +- lib/erl/src/thrift.app.src | 2 +- lib/haxe/haxelib.json | 2 +- lib/hs/thrift.cabal | 2 +- lib/java/gradle.properties | 2 +- lib/js/package-lock.json | 2 +- lib/js/package.json | 2 +- lib/js/src/thrift.js | 2 +- lib/lua/Thrift.lua | 2 +- lib/netstd/Thrift/Properties/AssemblyInfo.cs | 4 ++-- lib/netstd/Thrift/Thrift.csproj | 6 +++--- lib/ocaml/_oasis | 2 +- lib/perl/lib/Thrift.pm | 2 +- lib/py/setup.py | 2 +- lib/rb/thrift.gemspec | 2 +- lib/rs/Cargo.toml | 2 +- lib/st/package.xml | 2 +- lib/swift/Sources/Thrift.swift | 2 +- lib/swift/Tests/ThriftTests/ThriftTests.swift | 2 +- lib/ts/package-lock.json | 2 +- lib/ts/package.json | 2 +- package-lock.json | 2 +- package.json | 2 +- sonar-project.properties | 6 +++--- test/dart/test_client/pubspec.yaml | 2 +- test/erl/src/thrift_test.app.src | 2 +- tutorial/dart/client/pubspec.yaml | 2 +- tutorial/dart/console_client/pubspec.yaml | 2 +- tutorial/dart/server/pubspec.yaml | 2 +- tutorial/delphi/DelphiClient/DelphiClient.dproj | 4 ++-- tutorial/delphi/DelphiServer/DelphiServer.dproj | 4 ++-- tutorial/hs/ThriftTutorial.cabal | 2 +- tutorial/ocaml/_oasis | 2 +- 51 files changed, 78 insertions(+), 60 deletions(-) diff --git a/ApacheThrift.nuspec b/ApacheThrift.nuspec index 54c5af368..44b76da14 100644 --- a/ApacheThrift.nuspec +++ b/ApacheThrift.nuspec @@ -19,14 +19,14 @@ the "Thrift" project. 2. nuget setApiKey 3. nuget pack ApacheThrift.nuspec -Symbols -SymbolPackageFormat snupkg - 4. nuget push ApacheThrift.0.14.1.nupkg -Source https://api.nuget.org/v3/index.json + 4. nuget push ApacheThrift.0.14.2.nupkg -Source https://api.nuget.org/v3/index.json --> ApacheThrift - 0.14.1 - Apache Thrift 0.14.1 + 0.14.2 + Apache Thrift 0.14.2 Apache Thrift Developers Apache Software Foundation Apache-2.0 @@ -36,7 +36,7 @@ Contains runtime libraries from lib/netstd for netstandard2.0 framework development. - + Apache Thrift RPC diff --git a/CHANGES.md b/CHANGES.md index 8c4364fe8..f1fadcd9d 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,5 +1,12 @@ # Apache Thrift Changelog +## 0.14.2 + +### Java + +- [THRIFT-5383](https://issues.apache.org/jira/browse/THRIFT-5383) - THRIFT-5383 TJSONProtocol Java readString throws on bounds check + + ## 0.14.1 ### Known Open Issues (Blocker or Critical) diff --git a/CMakeLists.txt b/CMakeLists.txt index 602d9ea73..3487abf5d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -28,7 +28,7 @@ endif() # PACKAGE_VERSION is used by cpack scripts currently # Both thrift_VERSION and PACKAGE_VERSION should be the same for now -set(thrift_VERSION "0.14.1") +set(thrift_VERSION "0.14.2") set(PACKAGE_VERSION ${thrift_VERSION}) project("thrift" VERSION ${PACKAGE_VERSION}) diff --git a/Thrift.podspec b/Thrift.podspec index fefbc0dae..3a01b39f4 100644 --- a/Thrift.podspec +++ b/Thrift.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'Thrift' - s.version = '0.14.1' + s.version = '0.14.2' s.summary = "Apache Thrift is a lightweight, language-independent software stack with an associated code generation mechanism for RPC." s.description = <<-DESC The Apache Thrift scalable cross-language software framework for networked services development combines a software stack with a code generation engine to build services that work efficiently and seamlessly between many programming languages. @@ -10,6 +10,6 @@ The Apache Thrift scalable cross-language software framework for networked servi s.author = { 'Apache Thrift Developers' => 'dev@thrift.apache.org' } s.ios.deployment_target = '9.0' s.osx.deployment_target = '10.10' - s.source = { :git => 'https://github.com/apache/thrift.git', :tag => 'v0.14.1' } + s.source = { :git => 'https://github.com/apache/thrift.git', :tag => 'v0.14.2' } s.source_files = 'lib/swift/Sources/*.swift' end diff --git a/appveyor.yml b/appveyor.yml index e60a46319..14b801b3f 100755 --- a/appveyor.yml +++ b/appveyor.yml @@ -19,7 +19,7 @@ # build Apache Thrift on AppVeyor - https://ci.appveyor.com -version: '0.14.1.{build}' +version: '0.14.2.{build}' shallow_clone: true diff --git a/bower.json b/bower.json index a9fa0add4..9121d0326 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.1", + "version": "0.14.2", "homepage": "https://github.com/apache/thrift.git", "authors": [ "Apache Thrift " diff --git a/compiler/cpp/src/thrift/version.h b/compiler/cpp/src/thrift/version.h index a1960c4e2..1dcc5dfdc 100644 --- a/compiler/cpp/src/thrift/version.h +++ b/compiler/cpp/src/thrift/version.h @@ -24,6 +24,6 @@ #pragma once #endif // _MSC_VER -#define THRIFT_VERSION "0.14.1" +#define THRIFT_VERSION "0.14.2" #endif // _THRIFT_VERSION_H_ diff --git a/configure.ac b/configure.ac index 8c656c4a7..ef47dafad 100755 --- a/configure.ac +++ b/configure.ac @@ -20,7 +20,7 @@ AC_PREREQ(2.65) AC_CONFIG_MACRO_DIR([./aclocal]) -AC_INIT([thrift], [0.14.1]) +AC_INIT([thrift], [0.14.2]) AC_CONFIG_AUX_DIR([.]) diff --git a/contrib/Rebus/Properties/AssemblyInfo.cs b/contrib/Rebus/Properties/AssemblyInfo.cs index 55c935dfd..825897ccf 100644 --- a/contrib/Rebus/Properties/AssemblyInfo.cs +++ b/contrib/Rebus/Properties/AssemblyInfo.cs @@ -34,5 +34,5 @@ using System.Runtime.InteropServices; [assembly: Guid("0af10984-40d3-453d-b1e5-421529e8c7e2")] -[assembly: AssemblyVersion("0.14.1.0")] -[assembly: AssemblyFileVersion("0.14.1.0")] +[assembly: AssemblyVersion("0.14.2.0")] +[assembly: AssemblyFileVersion("0.14.2.0")] diff --git a/contrib/thrift-maven-plugin/pom.xml b/contrib/thrift-maven-plugin/pom.xml index dc41b3ff6..1294cb55e 100644 --- a/contrib/thrift-maven-plugin/pom.xml +++ b/contrib/thrift-maven-plugin/pom.xml @@ -32,7 +32,7 @@ thrift-maven-plugin maven-plugin thrift-maven-plugin - 0.14.1 + 0.14.2 1.8 diff --git a/contrib/thrift.spec b/contrib/thrift.spec index cbc58b905..442c0b306 100644 --- a/contrib/thrift.spec +++ b/contrib/thrift.spec @@ -28,7 +28,7 @@ Name: thrift License: Apache License v2.0 Group: Development Summary: RPC and serialization framework -Version: 0.14.1 +Version: 0.14.2 Release: 0 URL: http://thrift.apache.org Packager: Thrift Developers diff --git a/contrib/zeromq/csharp/AssemblyInfo.cs b/contrib/zeromq/csharp/AssemblyInfo.cs index d6f193dc5..12a47f455 100644 --- a/contrib/zeromq/csharp/AssemblyInfo.cs +++ b/contrib/zeromq/csharp/AssemblyInfo.cs @@ -36,7 +36,7 @@ using System.Runtime.CompilerServices; // The form "{Major}.{Minor}.*" will automatically update the build and revision, // and "{Major}.{Minor}.{Build}.*" will update just the revision. -[assembly: AssemblyVersion("0.14.1.0")] +[assembly: AssemblyVersion("0.14.2.0")] // The following attributes are used to specify the signing key for the assembly, // if desired. See the Mono documentation for more information about signing. diff --git a/debian/changelog b/debian/changelog index 5ef73b2db..91e62d38e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +thrift (0.14.2) stable; urgency=low + + * update to 0.14.2 + + -- Apache Thrift Developers Wed, 11 Jun 2021 01:00:00 +0100 + thrift (0.14.1) stable; urgency=low * update to 0.14.1 diff --git a/doap.rdf b/doap.rdf index 2d14c3fee..7143ec16c 100755 --- a/doap.rdf +++ b/doap.rdf @@ -57,6 +57,11 @@ + + Apache Thrift + 2021-06-11 + 0.14.2 + Apache Thrift 2021-03-02 diff --git a/doc/specs/idl.md b/doc/specs/idl.md index 41e820168..ded6cf89a 100644 --- a/doc/specs/idl.md +++ b/doc/specs/idl.md @@ -1,6 +1,6 @@ ## Thrift interface description language -For Thrift version 0.14.1. +For Thrift version 0.14.2. The Thrift interface definition language (IDL) allows for the definition of [Thrift Types](/docs/types). A Thrift IDL file is processed by the Thrift code generator to produce code for the various target languages to support the defined structs and services in the IDL file. diff --git a/lib/as3/gradle.properties b/lib/as3/gradle.properties index 7702fde28..ca89964a8 100644 --- a/lib/as3/gradle.properties +++ b/lib/as3/gradle.properties @@ -1,7 +1,7 @@ # This file is shared currently between this Gradle build and the # Ant builds for fd303 and JavaScript. Keep the dotted notation for # the properties to minimize the changes in the dependencies. -thrift.version=0.14.1 +thrift.version=0.14.2 thrift.groupid=org.apache.thrift release=false sign=false diff --git a/lib/d/src/thrift/base.d b/lib/d/src/thrift/base.d index 52427402d..4c1d0c338 100644 --- a/lib/d/src/thrift/base.d +++ b/lib/d/src/thrift/base.d @@ -50,7 +50,7 @@ class TCompoundOperationException : TException { /// The Thrift version string, used for informative purposes. // Note: This is currently hardcoded, but will likely be filled in by the build // system in future versions. -enum VERSION = "0.14.1"; +enum VERSION = "0.14.2"; /** * Functions used for logging inside Thrift. diff --git a/lib/dart/pubspec.yaml b/lib/dart/pubspec.yaml index a29da6f83..956d89b26 100644 --- a/lib/dart/pubspec.yaml +++ b/lib/dart/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: thrift -version: 0.14.1 +version: 0.14.2 description: > A Dart library for Apache Thrift author: Apache Thrift Developers diff --git a/lib/delphi/src/Thrift.pas b/lib/delphi/src/Thrift.pas index 72a951054..19dd372b0 100644 --- a/lib/delphi/src/Thrift.pas +++ b/lib/delphi/src/Thrift.pas @@ -28,7 +28,7 @@ uses Thrift.Protocol; const - Version = '0.14.1'; + Version = '0.14.2'; type TException = Thrift.Exception.TException; // compatibility alias diff --git a/lib/erl/src/thrift.app.src b/lib/erl/src/thrift.app.src index c95369bed..5c9b23d0a 100644 --- a/lib/erl/src/thrift.app.src +++ b/lib/erl/src/thrift.app.src @@ -22,7 +22,7 @@ {description, "Thrift bindings"}, % The version of the applicaton - {vsn, "0.14.1"}, + {vsn, "0.14.2"}, % All modules used by the application. {modules, [ diff --git a/lib/haxe/haxelib.json b/lib/haxe/haxelib.json index ede937c64..1b67d8201 100644 --- a/lib/haxe/haxelib.json +++ b/lib/haxe/haxelib.json @@ -4,7 +4,7 @@ "license": "Apache", "tags": ["thrift", "rpc", "serialization", "cross", "framework"], "description": "Haxe bindings for the Apache Thrift RPC and serialization framework", - "version": "0.14.1", + "version": "0.14.2", "releasenote": "Licensed under Apache License, Version 2.0. The Apache Thrift compiler needs to be installed separately.", "contributors": ["ApacheThrift"], "dependencies": { }, diff --git a/lib/hs/thrift.cabal b/lib/hs/thrift.cabal index 10724a41a..d7cfad23d 100644 --- a/lib/hs/thrift.cabal +++ b/lib/hs/thrift.cabal @@ -18,7 +18,7 @@ -- Name: thrift -Version: 0.14.1 +Version: 0.14.2 Cabal-Version: 1.24 License: Apache Category: Foreign diff --git a/lib/java/gradle.properties b/lib/java/gradle.properties index ad1a9f18c..40c1ec2d9 100644 --- a/lib/java/gradle.properties +++ b/lib/java/gradle.properties @@ -1,7 +1,7 @@ # This file is shared currently between this Gradle build and the # Ant builds for fd303 and JavaScript. Keep the dotted notation for # the properties to minimize the changes in the dependencies. -thrift.version=0.14.1 +thrift.version=0.14.2 thrift.groupid=org.apache.thrift release=false diff --git a/lib/js/package-lock.json b/lib/js/package-lock.json index ea1c04620..ae200ac57 100644 --- a/lib/js/package-lock.json +++ b/lib/js/package-lock.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.1", + "version": "0.14.2", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/lib/js/package.json b/lib/js/package.json index f57c57fb0..48ea99842 100644 --- a/lib/js/package.json +++ b/lib/js/package.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.1", + "version": "0.14.2", "description": "Thrift is a software framework for scalable cross-language services development.", "main": "./src/thrift", "author": { diff --git a/lib/js/src/thrift.js b/lib/js/src/thrift.js index 48f029f89..ce58c77b5 100644 --- a/lib/js/src/thrift.js +++ b/lib/js/src/thrift.js @@ -46,7 +46,7 @@ var Thrift = { * @const {string} Version * @memberof Thrift */ - Version: '0.14.1', + Version: '0.14.2', /** * Thrift IDL type string to Id mapping. diff --git a/lib/lua/Thrift.lua b/lib/lua/Thrift.lua index b8a87001e..eaf0dc760 100644 --- a/lib/lua/Thrift.lua +++ b/lib/lua/Thrift.lua @@ -48,7 +48,7 @@ function ttable_size(t) return count end -version = '0.14.1' +version = '0.14.2' TType = { STOP = 0, diff --git a/lib/netstd/Thrift/Properties/AssemblyInfo.cs b/lib/netstd/Thrift/Properties/AssemblyInfo.cs index c37f32604..ddebf64d7 100644 --- a/lib/netstd/Thrift/Properties/AssemblyInfo.cs +++ b/lib/netstd/Thrift/Properties/AssemblyInfo.cs @@ -52,5 +52,5 @@ using System.Runtime.InteropServices; // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: -[assembly: AssemblyVersion("0.14.1.0")] -[assembly: AssemblyFileVersion("0.14.1.0")] +[assembly: AssemblyVersion("0.14.2.0")] +[assembly: AssemblyFileVersion("0.14.2.0")] diff --git a/lib/netstd/Thrift/Thrift.csproj b/lib/netstd/Thrift/Thrift.csproj index 35a34aed0..c1f391573 100644 --- a/lib/netstd/Thrift/Thrift.csproj +++ b/lib/netstd/Thrift/Thrift.csproj @@ -39,8 +39,8 @@ true thrift.snk false - Apache Thrift 0.14.1 - 0.14.1.0 + Apache Thrift 0.14.2 + 0.14.2.0 false http://thrift.apache.org/ Apache Thrift Developers @@ -49,7 +49,7 @@ C# .NET Core bindings for the Apache Thrift RPC system Apache Thrift RPC - https://github.com/apache/thrift/blob/0.14.1/CHANGES.md + https://github.com/apache/thrift/blob/0.14.2/CHANGES.md Copyright 2021 The Apache Software Foundation diff --git a/lib/ocaml/_oasis b/lib/ocaml/_oasis index 8fb774a19..e5b0c8495 100644 --- a/lib/ocaml/_oasis +++ b/lib/ocaml/_oasis @@ -1,5 +1,5 @@ Name: libthrift-ocaml -Version: 0.14.1 +Version: 0.14.2 OASISFormat: 0.3 Synopsis: OCaml bindings for the Apache Thrift RPC system Authors: Apache Thrift Developers diff --git a/lib/perl/lib/Thrift.pm b/lib/perl/lib/Thrift.pm index cdd3f0368..d36942b76 100644 --- a/lib/perl/lib/Thrift.pm +++ b/lib/perl/lib/Thrift.pm @@ -31,6 +31,6 @@ use warnings; # package Thrift; -use version 0.77; our $VERSION = version->declare("v0.14.1"); +use version 0.77; our $VERSION = version->declare("v0.14.2"); 1; diff --git a/lib/py/setup.py b/lib/py/setup.py index bb5ee5a4e..efce17d6b 100644 --- a/lib/py/setup.py +++ b/lib/py/setup.py @@ -91,7 +91,7 @@ def run_setup(with_binary): twisted_deps = ['twisted'] setup(name='thrift', - version='0.14.1', + version='0.14.2', description='Python bindings for the Apache Thrift RPC system', author='Apache Thrift Developers', author_email='dev@thrift.apache.org', diff --git a/lib/rb/thrift.gemspec b/lib/rb/thrift.gemspec index 5f948a660..fe1b5438c 100644 --- a/lib/rb/thrift.gemspec +++ b/lib/rb/thrift.gemspec @@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__) Gem::Specification.new do |s| s.name = 'thrift' - s.version = '0.14.1' + s.version = '0.14.2' s.authors = ['Apache Thrift Developers'] s.email = ['dev@thrift.apache.org'] s.homepage = 'http://thrift.apache.org' diff --git a/lib/rs/Cargo.toml b/lib/rs/Cargo.toml index 5c2339a63..05dfe03f7 100644 --- a/lib/rs/Cargo.toml +++ b/lib/rs/Cargo.toml @@ -2,7 +2,7 @@ name = "thrift" description = "Rust bindings for the Apache Thrift RPC system" edition = "2018" -version = "0.14.1" +version = "0.14.2" license = "Apache-2.0" authors = ["Apache Thrift Developers "] homepage = "http://thrift.apache.org" diff --git a/lib/st/package.xml b/lib/st/package.xml index a45e54f1f..45e9dfb26 100644 --- a/lib/st/package.xml +++ b/lib/st/package.xml @@ -17,7 +17,7 @@ specific language governing permissions and limitations under the License. --> - + libthrift-st thrift.st diff --git a/lib/swift/Sources/Thrift.swift b/lib/swift/Sources/Thrift.swift index 9ea6f98f2..e2a494ceb 100644 --- a/lib/swift/Sources/Thrift.swift +++ b/lib/swift/Sources/Thrift.swift @@ -1,3 +1,3 @@ class Thrift { - let version = "0.14.1" + let version = "0.14.2" } diff --git a/lib/swift/Tests/ThriftTests/ThriftTests.swift b/lib/swift/Tests/ThriftTests/ThriftTests.swift index ca3ebcf82..e16642578 100644 --- a/lib/swift/Tests/ThriftTests/ThriftTests.swift +++ b/lib/swift/Tests/ThriftTests/ThriftTests.swift @@ -3,7 +3,7 @@ import XCTest class ThriftTests: XCTestCase { func testVersion() { - XCTAssertEqual(Thrift().version, "0.14.1") + XCTAssertEqual(Thrift().version, "0.14.2") } static var allTests : [(String, (ThriftTests) -> () throws -> Void)] { diff --git a/lib/ts/package-lock.json b/lib/ts/package-lock.json index fddef4426..34b09314b 100644 --- a/lib/ts/package-lock.json +++ b/lib/ts/package-lock.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.1", + "version": "0.14.2", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/lib/ts/package.json b/lib/ts/package.json index 77ad0d78b..8c1313eb7 100644 --- a/lib/ts/package.json +++ b/lib/ts/package.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.1", + "version": "0.14.2", "description": "Thrift is a software framework for scalable cross-language services development.", "author": { "name": "Apache Thrift Developers", diff --git a/package-lock.json b/package-lock.json index 9c1e5f581..9da40f269 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "thrift", - "version": "0.14.1", + "version": "0.14.2", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 5b34d5818..291835cf3 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "type": "git", "url": "https://github.com/apache/thrift.git" }, - "version": "0.14.1", + "version": "0.14.2", "author": { "name": "Apache Thrift Developers", "email": "dev@thrift.apache.org", diff --git a/sonar-project.properties b/sonar-project.properties index ef42feb6b..cae5d99fb 100755 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -16,7 +16,7 @@ development, combines a software stack with a code generation engine to build services that work efficiently and seamlessly between all major languages. # Apache Thrift Version -sonar.projectVersion=0.14.1 +sonar.projectVersion=0.14.2 # use this to set another version string # $ sonar-runner -D sonar.projectVersion=`git rev-parse HEAD` # set projectDate in combination with projectVersion for imports of old releases @@ -54,7 +54,7 @@ module1.sonar.projectName=Apache Thrift - Java Library module1.sonar.projectBaseDir=lib/java module1.sonar.sources=src module1.sonar.tests=test -module1.sonar.binaries=build/libs/libthrift-0.14.1.jar +module1.sonar.binaries=build/libs/libthrift-0.14.2.jar module1.sonar.libraries=build/deps/*.jar module1.sonar.language=java @@ -62,7 +62,7 @@ module2.sonar.projectName=Apache Thrift - Java Tutorial module2.sonar.projectBaseDir=. module2.sonar.sources=tutorial/java/src, tutorial/java/gen-java module2.sonar.binaries=tutorial/java/tutorial.jar -module2.sonar.libraries=lib/java/build/deps/*.jar,lib/java/build/libs/libthrift-0.14.1.jar +module2.sonar.libraries=lib/java/build/deps/*.jar,lib/java/build/libs/libthrift-0.14.2.jar module2.sonar.language=java module3.sonar.projectName=Apache Thrift - JavaScript Library diff --git a/test/dart/test_client/pubspec.yaml b/test/dart/test_client/pubspec.yaml index 3469ad7b6..f447b50fd 100644 --- a/test/dart/test_client/pubspec.yaml +++ b/test/dart/test_client/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: thrift_test_client -version: 0.14.1 +version: 0.14.2 description: A client integration test for the Dart Thrift library author: Apache Thrift Developers homepage: http://thrift.apache.org diff --git a/test/erl/src/thrift_test.app.src b/test/erl/src/thrift_test.app.src index 2af9c180a..27f44c131 100644 --- a/test/erl/src/thrift_test.app.src +++ b/test/erl/src/thrift_test.app.src @@ -22,7 +22,7 @@ {description, "Thrift cross language test"}, % The version of the applicaton - {vsn, "0.14.1"}, + {vsn, "0.14.2"}, % All modules used by the application. {modules, [ diff --git a/tutorial/dart/client/pubspec.yaml b/tutorial/dart/client/pubspec.yaml index ffd22a8cb..d047457f3 100644 --- a/tutorial/dart/client/pubspec.yaml +++ b/tutorial/dart/client/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: tutorial_client -version: 0.14.1 +version: 0.14.2 description: A Dart client implementation of the Apache Thrift tutorial author: Apache Thrift Developers homepage: http://thrift.apache.org diff --git a/tutorial/dart/console_client/pubspec.yaml b/tutorial/dart/console_client/pubspec.yaml index d895c20be..41dcb307e 100644 --- a/tutorial/dart/console_client/pubspec.yaml +++ b/tutorial/dart/console_client/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: tutorial_console_client -version: 0.14.1 +version: 0.14.2 description: > A Dart console client to implementation of the Apache Thrift tutorial author: Apache Thrift Developers diff --git a/tutorial/dart/server/pubspec.yaml b/tutorial/dart/server/pubspec.yaml index 2992a9b80..f1dd1a136 100644 --- a/tutorial/dart/server/pubspec.yaml +++ b/tutorial/dart/server/pubspec.yaml @@ -16,7 +16,7 @@ # under the License. name: tutorial_server -version: 0.14.1 +version: 0.14.2 description: A Dart server to support the Apache Thrift tutorial author: Apache Thrift Developers homepage: http://thrift.apache.org diff --git a/tutorial/delphi/DelphiClient/DelphiClient.dproj b/tutorial/delphi/DelphiClient/DelphiClient.dproj index 2b68d79a4..8b9414288 100644 --- a/tutorial/delphi/DelphiClient/DelphiClient.dproj +++ b/tutorial/delphi/DelphiClient/DelphiClient.dproj @@ -101,13 +101,13 @@ Thrift Tutorial - 0.14.1.0 + 0.14.2.0 DelphiClient Copyright © 2012 The Apache Software Foundation DelphiClient.exe Thrift - 0.14.1.0 + 0.14.2.0 diff --git a/tutorial/delphi/DelphiServer/DelphiServer.dproj b/tutorial/delphi/DelphiServer/DelphiServer.dproj index 3f781468b..b043d9aad 100644 --- a/tutorial/delphi/DelphiServer/DelphiServer.dproj +++ b/tutorial/delphi/DelphiServer/DelphiServer.dproj @@ -98,13 +98,13 @@ Thrift Tutorial - 0.14.1.0 + 0.14.2.0 DelphiServer Copyright © 2012 The Apache Software Foundation DelphiServer.exe Thrift - 0.14.1.0 + 0.14.2.0 diff --git a/tutorial/hs/ThriftTutorial.cabal b/tutorial/hs/ThriftTutorial.cabal index eeb6c4906..d66f39e9b 100755 --- a/tutorial/hs/ThriftTutorial.cabal +++ b/tutorial/hs/ThriftTutorial.cabal @@ -18,7 +18,7 @@ -- Name: ThriftTutorial -Version: 0.14.1 +Version: 0.14.2 Cabal-Version: >= 1.4 License: OtherLicense Category: Foreign diff --git a/tutorial/ocaml/_oasis b/tutorial/ocaml/_oasis index c08017089..deebd5ecb 100644 --- a/tutorial/ocaml/_oasis +++ b/tutorial/ocaml/_oasis @@ -1,5 +1,5 @@ Name: tutorial -Version: 0.14.1 +Version: 0.14.2 OASISFormat: 0.3 Synopsis: OCaml Tutorial example Authors: Apache Thrift Developers From 57e24caa86afa8bacf444e66a9aef6203831416c Mon Sep 17 00:00:00 2001 From: Yuxuan 'fishy' Wang Date: Thu, 25 Mar 2021 17:00:31 -0700 Subject: [PATCH 14/14] THRIFT-5369: Use MaxMessageSize to check container sizes Client: go --- CHANGES.md | 4 ++ lib/go/thrift/binary_protocol.go | 19 +++----- lib/go/thrift/compact_protocol.go | 12 ++--- lib/go/thrift/json_protocol.go | 21 +++++++-- lib/go/thrift/simple_json_protocol.go | 67 +++++++++++++++++++++++---- 5 files changed, 89 insertions(+), 34 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index f1fadcd9d..d7ef279b7 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -6,6 +6,10 @@ - [THRIFT-5383](https://issues.apache.org/jira/browse/THRIFT-5383) - THRIFT-5383 TJSONProtocol Java readString throws on bounds check +### Go + +- [THRIFT-5369](https://issues.apache.org/jira/browse/THRIFT-5369) - No longer pre-allocating the whole container (map/set/list) in compiled go code to avoid huge allocations on malformed messages + ## 0.14.1 diff --git a/lib/go/thrift/binary_protocol.go b/lib/go/thrift/binary_protocol.go index 45c880d32..3ed6608ee 100644 --- a/lib/go/thrift/binary_protocol.go +++ b/lib/go/thrift/binary_protocol.go @@ -23,7 +23,6 @@ import ( "bytes" "context" "encoding/binary" - "errors" "fmt" "io" "math" @@ -334,8 +333,6 @@ func (p *TBinaryProtocol) ReadFieldEnd(ctx context.Context) error { return nil } -var invalidDataLength = NewTProtocolExceptionWithType(INVALID_DATA, errors.New("Invalid data length")) - func (p *TBinaryProtocol) ReadMapBegin(ctx context.Context) (kType, vType TType, size int, err error) { k, e := p.ReadByte(ctx) if e != nil { @@ -354,8 +351,8 @@ func (p *TBinaryProtocol) ReadMapBegin(ctx context.Context) (kType, vType TType, err = NewTProtocolException(e) return } - if size32 < 0 { - err = invalidDataLength + err = checkSizeForProtocol(size32, p.cfg) + if err != nil { return } size = int(size32) @@ -378,8 +375,8 @@ func (p *TBinaryProtocol) ReadListBegin(ctx context.Context) (elemType TType, si err = NewTProtocolException(e) return } - if size32 < 0 { - err = invalidDataLength + err = checkSizeForProtocol(size32, p.cfg) + if err != nil { return } size = int(size32) @@ -403,8 +400,8 @@ func (p *TBinaryProtocol) ReadSetBegin(ctx context.Context) (elemType TType, siz err = NewTProtocolException(e) return } - if size32 < 0 { - err = invalidDataLength + err = checkSizeForProtocol(size32, p.cfg) + if err != nil { return } size = int(size32) @@ -466,10 +463,6 @@ func (p *TBinaryProtocol) ReadString(ctx context.Context) (value string, err err if err != nil { return } - if size < 0 { - err = invalidDataLength - return - } if size == 0 { return "", nil } diff --git a/lib/go/thrift/compact_protocol.go b/lib/go/thrift/compact_protocol.go index a49225dab..e0de07700 100644 --- a/lib/go/thrift/compact_protocol.go +++ b/lib/go/thrift/compact_protocol.go @@ -477,8 +477,8 @@ func (p *TCompactProtocol) ReadMapBegin(ctx context.Context) (keyType TType, val err = NewTProtocolException(e) return } - if size32 < 0 { - err = invalidDataLength + err = checkSizeForProtocol(size32, p.cfg) + if err != nil { return } size = int(size32) @@ -513,12 +513,12 @@ func (p *TCompactProtocol) ReadListBegin(ctx context.Context) (elemType TType, s err = NewTProtocolException(e) return } - if size2 < 0 { - err = invalidDataLength - return - } size = int(size2) } + err = checkSizeForProtocol(size32, p.cfg) + if err != nil { + return + } elemType, e := p.getTType(tCompactType(size_and_type)) if e != nil { err = NewTProtocolException(e) diff --git a/lib/go/thrift/json_protocol.go b/lib/go/thrift/json_protocol.go index 8e59d16cf..98764fa88 100644 --- a/lib/go/thrift/json_protocol.go +++ b/lib/go/thrift/json_protocol.go @@ -311,9 +311,13 @@ func (p *TJSONProtocol) ReadMapBegin(ctx context.Context) (keyType TType, valueT } // read size - iSize, e := p.ReadI64(ctx) - if e != nil { - return keyType, valueType, size, e + iSize, err := p.ReadI64(ctx) + if err != nil { + return keyType, valueType, size, err + } + err = checkSizeForProtocol(int32(iSize), p.cfg) + if err != nil { + return keyType, valueType, 0, err } size = int(iSize) @@ -485,9 +489,16 @@ func (p *TJSONProtocol) ParseElemListBegin() (elemType TType, size int, e error) if err != nil { return elemType, size, err } - nSize, _, err2 := p.ParseI64() + nSize, _, err := p.ParseI64() + if err != nil { + return elemType, 0, err + } + err = checkSizeForProtocol(int32(nSize), p.cfg) + if err != nil { + return elemType, 0, err + } size = int(nSize) - return elemType, size, err2 + return elemType, size, nil } func (p *TJSONProtocol) readElemListBegin() (elemType TType, size int, e error) { diff --git a/lib/go/thrift/simple_json_protocol.go b/lib/go/thrift/simple_json_protocol.go index d1a815453..4967532c5 100644 --- a/lib/go/thrift/simple_json_protocol.go +++ b/lib/go/thrift/simple_json_protocol.go @@ -97,6 +97,8 @@ var errEmptyJSONContextStack = NewTProtocolExceptionWithType(INVALID_DATA, error type TSimpleJSONProtocol struct { trans TTransport + cfg *TConfiguration + parseContextStack jsonContextStack dumpContext jsonContextStack @@ -104,9 +106,18 @@ type TSimpleJSONProtocol struct { reader *bufio.Reader } -// Constructor +// Deprecated: Use NewTSimpleJSONProtocolConf instead.: func NewTSimpleJSONProtocol(t TTransport) *TSimpleJSONProtocol { - v := &TSimpleJSONProtocol{trans: t, + return NewTSimpleJSONProtocolConf(t, &TConfiguration{ + noPropagation: true, + }) +} + +func NewTSimpleJSONProtocolConf(t TTransport, conf *TConfiguration) *TSimpleJSONProtocol { + PropagateTConfiguration(t, conf) + v := &TSimpleJSONProtocol{ + trans: t, + cfg: conf, writer: bufio.NewWriter(t), reader: bufio.NewReader(t), } @@ -116,14 +127,32 @@ func NewTSimpleJSONProtocol(t TTransport) *TSimpleJSONProtocol { } // Factory -type TSimpleJSONProtocolFactory struct{} - -func (p *TSimpleJSONProtocolFactory) GetProtocol(trans TTransport) TProtocol { - return NewTSimpleJSONProtocol(trans) +type TSimpleJSONProtocolFactory struct { + cfg *TConfiguration } +func (p *TSimpleJSONProtocolFactory) GetProtocol(trans TTransport) TProtocol { + return NewTSimpleJSONProtocolConf(trans, p.cfg) +} + +// SetTConfiguration implements TConfigurationSetter for propagation. +func (p *TSimpleJSONProtocolFactory) SetTConfiguration(conf *TConfiguration) { + p.cfg = conf +} + +// Deprecated: Use NewTSimpleJSONProtocolFactoryConf instead. func NewTSimpleJSONProtocolFactory() *TSimpleJSONProtocolFactory { - return &TSimpleJSONProtocolFactory{} + return &TSimpleJSONProtocolFactory{ + cfg: &TConfiguration{ + noPropagation: true, + }, + } +} + +func NewTSimpleJSONProtocolFactoryConf(conf *TConfiguration) *TSimpleJSONProtocolFactory { + return &TSimpleJSONProtocolFactory{ + cfg: conf, + } } var ( @@ -399,6 +428,13 @@ func (p *TSimpleJSONProtocol) ReadMapBegin(ctx context.Context) (keyType TType, // read size iSize, err := p.ReadI64(ctx) + if err != nil { + return keyType, valueType, 0, err + } + err = checkSizeForProtocol(int32(size), p.cfg) + if err != nil { + return keyType, valueType, 0, err + } size = int(iSize) return keyType, valueType, size, err } @@ -1070,9 +1106,16 @@ func (p *TSimpleJSONProtocol) ParseElemListBegin() (elemType TType, size int, e if err != nil { return elemType, size, err } - nSize, _, err2 := p.ParseI64() + nSize, _, err := p.ParseI64() + if err != nil { + return elemType, 0, err + } + err = checkSizeForProtocol(int32(nSize), p.cfg) + if err != nil { + return elemType, 0, err + } size = int(nSize) - return elemType, size, err2 + return elemType, size, nil } func (p *TSimpleJSONProtocol) ParseListEnd() error { @@ -1368,6 +1411,10 @@ func (p *TSimpleJSONProtocol) write(b []byte) (int, error) { // SetTConfiguration implements TConfigurationSetter for propagation. func (p *TSimpleJSONProtocol) SetTConfiguration(conf *TConfiguration) { PropagateTConfiguration(p.trans, conf) + p.cfg = conf } -var _ TConfigurationSetter = (*TSimpleJSONProtocol)(nil) +var ( + _ TConfigurationSetter = (*TSimpleJSONProtocol)(nil) + _ TConfigurationSetter = (*TSimpleJSONProtocolFactory)(nil) +)