Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong initialization of fixed_address_empty_string causes ShutdownProtobufLibrary to fail #8129

Closed

Comments

@danieljoos
Copy link
Contributor

@danieljoos danieljoos commented Dec 8, 2020

What version of protobuf and what language are you using?
Version: v3.14.0, master
Language: C++

What operating system (Linux, Windows, ...) and version?
Windows

What runtime / compiler are you using (e.g., python version or gcc version)
MSVC 14.27.29110
Platform Toolset v142 (Visual Studio 2019)
Debug Runtime

What did you do?
Steps to reproduce the behavior:

#include "addressbook.pb.h"

int main() {
	::google::protobuf::ShutdownProtobufLibrary();
}

with addressbook.proto (it really doesn't matter at all):

syntax = "proto3";

package tutorial;

message AddressBook {
  string name = 1;
}

What did you expect to see

No exception when execution ShutdownProtobufLibrary(). The program should just run-through without any issues.

What did you see instead?

The program throws an exception when run in Debug mode on executing ShutdownProtobufLibrary().

It is caused by attempting to destruct a broken std::string stored ::google::protobuf::internal::fixed_address_empty_string.value.
The reason is that the implementation relies on a static initialization of that variable. The variable fixed_address_empty_string is default constructed to dummy (here

constexpr EmptyString() : dummy{} {}
).
However, as the initialization of static global variables is undefined across translation units in C++, it is possible that InitProtobufDefaultsImpl() (
::new (static_cast<void*>(&fixed_address_empty_string.value)) std::string();
) is called before the initialization of the fixed_address_empty_string (
fixed_address_empty_string; // NOLINT
). This causes the allocated std::string value to get broken, as the dummy value gets initialized "over" the existing std::string object.

This happens, for example when including a generated protobuf header file as a call to AddDescriptors() is forced there to happen during dynamic initialization time.

The actual exception is thrown by the MSCV STL on destruction as the std::string is now malformed.

Anything else we should know about your project / environment

danieljoos added a commit to danieljoos/protobuf that referenced this issue Dec 9, 2020
This makes `fixed_address_empty_string` a function returning a static instance.
It avoids the static-initialization fiasco that can happen when using a global static variable.

Resolves: protocolbuffers#8129
danieljoos added a commit to danieljoos/protobuf that referenced this issue Dec 9, 2020
This makes `fixed_address_empty_string` a function returning a static instance.
It avoids the static-initialization fiasco that can happen when using a global static variable.

Resolves: protocolbuffers#8129
@great944
Copy link

@great944 great944 commented Jan 23, 2021

Hello, I see this issue with windows VS2019 16.8.3.61104. is it possible to merge this fix to master please? just updated to latest release and started seeing this issue when shutting down the program with a debug build.

@danieljoos
Copy link
Contributor Author

@danieljoos danieljoos commented Jan 23, 2021

Hi. Unfortunately, none of the above linked commit actually fixes the issue. I was playing around in my fork and it looks like Github already associated these commits here. Not sure how it can be unlinked.

The actual issue cannot be fixed easily, imo. The problem is the EmptyString structure that relies on constinit, which is not available on MSVC.

The only viable workaround at the moment is to comment-out the DestroyString call for the fixed_address_empty_string in case of msvc debug builds.

@great944
Copy link

@great944 great944 commented Jan 28, 2021

thank you for the update

@danieljoos
Copy link
Contributor Author

@danieljoos danieljoos commented Feb 22, 2021

Seems to be fixed with v3.15.1

gcf-merge-on-green bot pushed a commit to googleapis/java-datacatalog that referenced this issue Jul 5, 2021
…17.3 (#568)

[![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [com.google.protobuf:protobuf-java-util](https://developers.google.com/protocol-buffers/) ([source](https://togithub.com/protocolbuffers/protobuf)) | `3.14.0` -> `3.17.3` | [![age](https://badges.renovateapi.com/packages/maven/com.google.protobuf:protobuf-java-util/3.17.3/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.protobuf:protobuf-java-util/3.17.3/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.protobuf:protobuf-java-util/3.17.3/compatibility-slim/3.14.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.protobuf:protobuf-java-util/3.17.3/confidence-slim/3.14.0)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>protocolbuffers/protobuf</summary>

### [`v3.17.3`](https://togithub.com/protocolbuffers/protobuf/releases/v3.17.3)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.17.2...v3.17.3)

**C++**

-   Introduce FieldAccessListener.
-   Stop emitting boilerplate {Copy/Merge}From in each ProtoBuf class
-   Fixed some uninitialized variable warnings in generated_message_reflection.cc.

**Kotlin**

-   Fix duplicate proto files error ([#&#8203;8699](https://togithub.com/protocolbuffers/protobuf/issues/8699))

**Java**

-   Fixed parser to check that we are at a proper limit when a sub-message has
    finished parsing.

**General**

-   Support M1 ([#&#8203;8557](https://togithub.com/protocolbuffers/protobuf/issues/8557))

### [`v3.17.2`](https://togithub.com/protocolbuffers/protobuf/releases/v3.17.2)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.17.1...v3.17.2)

****Kotlin****

-   Fix duplicate class error ([#&#8203;8653](https://togithub.com/protocolbuffers/protobuf/issues/8653))

****PHP****

-   Fixed SEGV in sub-message getters for well-known types when message is unset
    ([#&#8203;8670](https://togithub.com/protocolbuffers/protobuf/issues/8670))

### [`v3.17.1`](https://togithub.com/protocolbuffers/protobuf/releases/v3.17.1)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.17.0...v3.17.1)

### PHP

-   Fixed PHP memory leaks and arginfo errors. ([#&#8203;8614](https://togithub.com/protocolbuffers/protobuf/issues/8614))
-   Fixed JSON parser to allow multiple values from the same oneof as long as all but one are null.

### Ruby

-   Fixed memory bug: properly root repeated/map field when assigning. ([#&#8203;8639](https://togithub.com/protocolbuffers/protobuf/issues/8639))
-   Fixed JSON parser to allow multiple values from the same oneof as long as all but one are null.

### [`v3.17.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.17.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.16.0...v3.17.0)

### Protocol Compiler

-   Fix the generated source information for reserved values in Enums.

### C++

-   Fix -Wunused-parameter in map\<string, int> fields (fixes [#&#8203;8494](https://togithub.com/protocolbuffers/protobuf/issues/8494)) ([#&#8203;8500](https://togithub.com/protocolbuffers/protobuf/issues/8500))
-   Use byteswap.h when building against musl libc ([#&#8203;8503](https://togithub.com/protocolbuffers/protobuf/issues/8503))
-   Fix -Wundefined-inline error when using SharedCtor() or SharedDtor() ([#&#8203;8532](https://togithub.com/protocolbuffers/protobuf/issues/8532))
-   Fix bug where `Descriptor::DebugString()` printed proto3 synthetic oneofs.
-   Provide stable versions of `SortAndUnique()`.
-   Make sure to cache proto3 optional message fields when they are cleared.
-   Expose UnsafeArena methods to Reflection.
-   Use std::string::empty() rather than std::string::size() > 0.

### Kotlin

-   Introduce support for Kotlin protos ([#&#8203;8272](https://togithub.com/protocolbuffers/protobuf/issues/8272))
-   Restrict extension setter and getter operators to non-nullable T.

### Java

-   updating GSON and Guava to more recent versions ([#&#8203;8524](https://togithub.com/protocolbuffers/protobuf/issues/8524))
-   Reduce the time spent evaluating isExtensionNumber by storing the extension
    ranges in a TreeMap for faster queries. This is particularly relevant for
    protos which define a large number of extension ranges, for example when
    each tag is defined as an extension.
-   Fix java bytecode estimation logic for optional fields.
-   Optimize Descriptor.isExtensionNumber.

### Python

-   Add MethodDescriptor.CopyToProto() ([#&#8203;8327](https://togithub.com/protocolbuffers/protobuf/issues/8327))
-   Remove unused python_protobuf.{cc,h} ([#&#8203;8513](https://togithub.com/protocolbuffers/protobuf/issues/8513))
-   Start publishing python aarch64 manylinux wheels normally ([#&#8203;8530](https://togithub.com/protocolbuffers/protobuf/issues/8530))
-   Fix constness issue detected by MSVC standard conforming mode ([#&#8203;8568](https://togithub.com/protocolbuffers/protobuf/issues/8568))
-   Make JSON parsing match C++ and Java when multiple fields from the same
    oneof are present and all but one is null.

### Ruby

-   Add support for proto3 json_name in compiler and field definitions ([#&#8203;8356](https://togithub.com/protocolbuffers/protobuf/issues/8356))
-   Fixed memory leak of Ruby arena objects. ([#&#8203;8461](https://togithub.com/protocolbuffers/protobuf/issues/8461))
-   Fix source gem compilation ([#&#8203;8471](https://togithub.com/protocolbuffers/protobuf/issues/8471))
-   Fix various exceptions in Ruby on 64-bit Windows ([#&#8203;8563](https://togithub.com/protocolbuffers/protobuf/issues/8563))
-   Fix crash when calculating Message hash values on 64-bit Windows ([#&#8203;8565](https://togithub.com/protocolbuffers/protobuf/issues/8565))

### Conformance Tests

-   Added a conformance test for the case of multiple fields from the same
    oneof.

### Other

-   Use a newer version of rules_proto, with the new rule `proto_descriptor_set` ([#&#8203;8469](https://togithub.com/protocolbuffers/protobuf/issues/8469))

### [`v3.16.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.16.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.8...v3.16.0)

##### C++

-   Fix compiler warnings issue found in conformance_test_runner [#&#8203;8189](https://togithub.com/protocolbuffers/protobuf/issues/8189) ([#&#8203;8190](https://togithub.com/protocolbuffers/protobuf/issues/8190))
-   Fix MinGW-w64 build issues. ([#&#8203;8286](https://togithub.com/protocolbuffers/protobuf/issues/8286))
-   \[Protoc] C++ Resolved an issue where NO_DESTROY and CONSTINIT are in incorrect order ([#&#8203;8296](https://togithub.com/protocolbuffers/protobuf/issues/8296))
-   Fix PROTOBUF_CONSTINIT macro redefinition ([#&#8203;8323](https://togithub.com/protocolbuffers/protobuf/issues/8323))
-   Delete StringPiecePod ([#&#8203;8353](https://togithub.com/protocolbuffers/protobuf/issues/8353))
-   Fix gcc error: comparison of unsigned expression in '>= 0' is always … ([#&#8203;8309](https://togithub.com/protocolbuffers/protobuf/issues/8309))
-   Fix cmake install on iOS ([#&#8203;8301](https://togithub.com/protocolbuffers/protobuf/issues/8301))
-   Create a CMake option to control whether or not RTTI is enabled ([#&#8203;8347](https://togithub.com/protocolbuffers/protobuf/issues/8347))
-   Fix endian.h location on FreeBSD ([#&#8203;8351](https://togithub.com/protocolbuffers/protobuf/issues/8351))
-   Refactor util::Status ([#&#8203;8354](https://togithub.com/protocolbuffers/protobuf/issues/8354))
-   Make util::Status more similar to absl::Status ([#&#8203;8405](https://togithub.com/protocolbuffers/protobuf/issues/8405))
-   Fix -Wsuggest-destructor-override for generated C++ proto classes. ([#&#8203;8408](https://togithub.com/protocolbuffers/protobuf/issues/8408))
-   Refactor StatusOr and StringPiece ([#&#8203;8406](https://togithub.com/protocolbuffers/protobuf/issues/8406))
-   Refactor uint128 ([#&#8203;8416](https://togithub.com/protocolbuffers/protobuf/issues/8416))
-   The ::pb namespace is no longer exposed due to conflicts.
-   Allow MessageDifferencer::TreatAsSet() (and friends) to override previous
    calls instead of crashing.
-   Reduce the size of generated proto headers for protos with `string` or
    `bytes` fields.
-   Move arena() operation on uncommon path to out-of-line routine
-   For iterator-pair function parameter types, take both iterators by value.
-   Code-space savings and perhaps some modest performance improvements in
    RepeatedPtrField.
-   Eliminate nullptr check from every tag parse.
-   Remove unused \_$name$*cached_byte_size* fields.
-   Serialize extension ranges together when not broken by a proto field in the
    middle.
-   Do out-of-line allocation and deallocation of string object in ArenaString.
-   Streamline ParseContext::ParseMessage<T> to avoid code bloat and improve
    performance.
-   New member functions RepeatedField::Assign, RepeatedPtrField::{Add, Assign}.
-   Fix undefined behavior warning due to innocuous uninitialization of value
    on an error path.
-   Avoid expensive inlined code space for encoding message length for messages
    > \= 128 bytes and instead do a procedure call to a shared out-of-line routine.
-   util::DefaultFieldComparator will be final in a future version of protobuf.
    Subclasses should inherit from SimpleFieldComparator instead.

##### C\#

-   Add .NET 5 target and improve WriteString performance with SIMD ([#&#8203;8147](https://togithub.com/protocolbuffers/protobuf/issues/8147))

##### Java

-   deps: update JUnit and Truth ([#&#8203;8319](https://togithub.com/protocolbuffers/protobuf/issues/8319))
-   Detect invalid overflow of byteLimit and return InvalidProtocolBufferException as documented.
-   Exceptions thrown while reading from an InputStream in parseFrom are now
    included as causes.
-   Support potentially more efficient proto parsing from RopeByteStrings.
-   Clarify runtime of ByteString.Output.toStringBuffer().
-   Added UnsafeByteOperations to protobuf-lite ([#&#8203;8426](https://togithub.com/protocolbuffers/protobuf/issues/8426))

##### JavaScript

-   Make Any.pack() chainable.

##### Python

-   Fix some constness / char literal issues being found by MSVC standard conforming mode ([#&#8203;8344](https://togithub.com/protocolbuffers/protobuf/issues/8344))
-   Switch on "new" buffer API ([#&#8203;8339](https://togithub.com/protocolbuffers/protobuf/issues/8339))
-   Enable crosscompiling aarch64 python wheels under dockcross manylinux docker image ([#&#8203;8280](https://togithub.com/protocolbuffers/protobuf/issues/8280))
-   Fixed a bug in text format where a trailing colon was printed for repeated field.
-   When TextFormat encounters a duplicate message map key, replace the current
    one instead of merging.

##### Objective-C

-   Move the class map to a CFDictionary. ([#&#8203;8328](https://togithub.com/protocolbuffers/protobuf/issues/8328))

##### PHP

-   read_property() handler is not supposed to return NULL ([#&#8203;8362](https://togithub.com/protocolbuffers/protobuf/issues/8362))
-   Changed parameter type from long to integer ([#&#8203;7613](https://togithub.com/protocolbuffers/protobuf/issues/7613))
-   fix: README supported PHP version for C extension ([#&#8203;8236](https://togithub.com/protocolbuffers/protobuf/issues/8236))

##### Ruby

-   Fixed quadratic memory usage when appending to arrays. ([#&#8203;8364](https://togithub.com/protocolbuffers/protobuf/issues/8364))
-   Fixed memory leak of Ruby arena objects. ([#&#8203;8461](https://togithub.com/protocolbuffers/protobuf/issues/8461))
-   Add support for proto3 json_name in compiler and field definitions. ([#&#8203;8356](https://togithub.com/protocolbuffers/protobuf/issues/8356))

##### Other

-   Some doc on AOT compilation and protobuf ([#&#8203;8294](https://togithub.com/protocolbuffers/protobuf/issues/8294))
-   \[CMake] Ability to pass options to protoc executable from cmake ([#&#8203;8374](https://togithub.com/protocolbuffers/protobuf/issues/8374))
-   Add --fatal_warnings flag to treat warnings as errors ([#&#8203;8131](https://togithub.com/protocolbuffers/protobuf/issues/8131))
-   \[bazel] Remove deprecated way to depend on googletest ([#&#8203;8396](https://togithub.com/protocolbuffers/protobuf/issues/8396))
-   add error returns missing from protoc to prevent it from exiting with… ([#&#8203;8409](https://togithub.com/protocolbuffers/protobuf/issues/8409))

### [`v3.15.8`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.8)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.7...v3.15.8)

### Ruby

-   Fixed memory leak of Ruby arena objects ([#&#8203;8461](https://togithub.com/protocolbuffers/protobuf/issues/8461))

### [`v3.15.7`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.7)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.6...v3.15.7)

##### C++

-   Remove the ::pb namespace (alias) ([#&#8203;8423](https://togithub.com/protocolbuffers/protobuf/issues/8423))

##### Ruby

-   Fix unbounded memory growth for Ruby <2.7 ([#&#8203;8429](https://togithub.com/protocolbuffers/protobuf/issues/8429))
-   Fixed message equality in cases where the message type is different ([#&#8203;8434](https://togithub.com/protocolbuffers/protobuf/issues/8434))

### [`v3.15.6`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.6)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.5...v3.15.6)

### Ruby

-   Fixed bug in string comparison logic ([#&#8203;8386](https://togithub.com/protocolbuffers/protobuf/issues/8386))

### [`v3.15.5`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.5)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.4...v3.15.5)

##### Ruby

-   Fixed quadratic memory use in array append ([#&#8203;8379](https://togithub.com/protocolbuffers/protobuf/issues/8379))

##### PHP

-   Fixed quadratic memory use in array append ([#&#8203;8379](https://togithub.com/protocolbuffers/protobuf/issues/8379))

##### C++

-   Do not disable RTTI by default in the CMake build ([#&#8203;8377](https://togithub.com/protocolbuffers/protobuf/issues/8377))

### [`v3.15.4`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.4)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.3...v3.15.4)

### Ruby

-   Fixed SEGV when users pass nil messages ([#&#8203;8363](https://togithub.com/protocolbuffers/protobuf/issues/8363))
-   Fixed quadratic memory usage when appending to arrays ([#&#8203;8364](https://togithub.com/protocolbuffers/protobuf/issues/8364))

### C++

-   Create a CMake option to control whether or not RTTI is enabled ([#&#8203;8361](https://togithub.com/protocolbuffers/protobuf/issues/8361))

### PHP

-   read_property() handler is not supposed to return NULL ([#&#8203;8362](https://togithub.com/protocolbuffers/protobuf/issues/8362))

### [`v3.15.3`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.3)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.2...v3.15.3)

##### Ruby

-   Ruby <2.7 now uses WeakMap too, which prevents memory leaks. ([#&#8203;8341](https://togithub.com/protocolbuffers/protobuf/issues/8341))

### [`v3.15.2`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.2)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.1...v3.15.2)

### Ruby

-   Fix for FieldDescriptor.get(msg) ([#&#8203;8330](https://togithub.com/protocolbuffers/protobuf/issues/8330))

### C++

-   Fix PROTOBUF_CONSTINIT macro redefinition ([#&#8203;8323](https://togithub.com/protocolbuffers/protobuf/issues/8323))

### [`v3.15.1`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.1)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.0...v3.15.1)

##### Ruby

-   Bugfix for Message.\[] for repeated or map fields ([#&#8203;8313](https://togithub.com/protocolbuffers/protobuf/issues/8313))
-   Fix for truncating behavior when converting Float to Duration ([#&#8203;8320](https://togithub.com/protocolbuffers/protobuf/issues/8320))

##### C++

-   Small fixes for MinGW and for C++20 with GCC ([#&#8203;8318](https://togithub.com/protocolbuffers/protobuf/issues/8318))

### [`v3.15.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.14.0...v3.15.0)

### Protocol Compiler

-   Optional fields for proto3 are enabled by default, and no longer require
    the --experimental_allow_proto3\_optional flag.

### C++

-   MessageDifferencer: fixed bug when using custom ignore with multiple
    unknown fields
-   Use init_seg in MSVC to push initialization to an earlier phase.
-   Runtime no longer triggers -Wsign-compare warnings.
-   Fixed -Wtautological-constant-out-of-range-compare warning.
-   DynamicCastToGenerated works for nullptr input for even if RTTI is disabled
-   Arena is refactored and optimized.
-   Clarified/specified that the exact value of Arena::SpaceAllocated() is an
    implementation detail users must not rely on. It should not be used in
    unit tests.
-   Change the signature of Any::PackFrom() to return false on error.
-   Add fast reflection getter API for strings.
-   Constant initialize the global message instances
-   Avoid potential for missed wakeup in UnknownFieldSet
-   Now Proto3 Oneof fields have "has" methods for checking their presence in
    C++.
-   Bugfix for NVCC
-   Return early in \_InternalSerialize for empty maps.
-   Adding functionality for outputting map key values in proto path logging
    output (does not affect comparison logic) and stop printing 'value' in the
    path. The modified print functionality is in the
    MessageDifferencer::StreamReporter.
-   Fixed protocolbuffers/protobuf#8129
-   Ensure that null char symbol, package and file names do not result in a
    crash.
-   Constant initialize the global message instances
-   Pretty print 'max' instead of numeric values in reserved ranges.
-   Removed remaining instances of std::is_pod, which is deprecated in C++20.
-   Changes to reduce code size for unknown field handling by making uncommon
    cases out of line.
-   Fix std::is_pod deprecated in C++20 ([#&#8203;7180](https://togithub.com/protocolbuffers/protobuf/issues/7180))
-   Fix some -Wunused-parameter warnings ([#&#8203;8053](https://togithub.com/protocolbuffers/protobuf/issues/8053))
-   Fix detecting file as directory on zOS issue [#&#8203;8051](https://togithub.com/protocolbuffers/protobuf/issues/8051) ([#&#8203;8052](https://togithub.com/protocolbuffers/protobuf/issues/8052))
-   Don't include sys/param.h for \_BYTE_ORDER ([#&#8203;8106](https://togithub.com/protocolbuffers/protobuf/issues/8106))
-   remove CMAKE_THREAD_LIBS_INIT from pkgconfig CFLAGS ([#&#8203;8154](https://togithub.com/protocolbuffers/protobuf/issues/8154))
-   Fix TextFormatMapTest.DynamicMessage [issue#&#8203;5136](https://togithub.com/issue/protobuf/issues/5136) ([#&#8203;8159](https://togithub.com/protocolbuffers/protobuf/issues/8159))
-   Fix for compiler warning [issue#&#8203;8145](https://togithub.com/issue/protobuf/issues/8145) ([#&#8203;8160](https://togithub.com/protocolbuffers/protobuf/issues/8160))
-   fix: support deprecated enums for GCC < 6 ([#&#8203;8164](https://togithub.com/protocolbuffers/protobuf/issues/8164))
-   Fix some warning when compiling with Visual Studio 2019 on x64 target ([#&#8203;8125](https://togithub.com/protocolbuffers/protobuf/issues/8125))

### Python

-   Provided an override for the reverse() method that will reverse the internal
    collection directly instead of using the other methods of the BaseContainer.
-   MessageFactory.CreateProtoype can be overridden to customize class creation.
-   Fix PyUnknownFields memory leak ([#&#8203;7928](https://togithub.com/protocolbuffers/protobuf/issues/7928))
-   Add macOS big sur compatibility ([#&#8203;8126](https://togithub.com/protocolbuffers/protobuf/issues/8126))

### JavaScript

-   Generate `getDescriptor` methods with `*` as their `this` type.
-   Enforce `let/const` for generated messages.
-   js/binary/utils.js: Fix jspb.utils.joinUnsignedDecimalString to work with negative bitsLow and low but non-zero bitsHigh parameter. ([#&#8203;8170](https://togithub.com/protocolbuffers/protobuf/issues/8170))

### PHP

-   Added support for PHP 8. ([#&#8203;8105](https://togithub.com/protocolbuffers/protobuf/issues/8105))
-   unregister INI entries and fix invalid read on shutdown ([#&#8203;8042](https://togithub.com/protocolbuffers/protobuf/issues/8042))
-   Fix PhpDoc comments for message accessors to include "|null". ([#&#8203;8136](https://togithub.com/protocolbuffers/protobuf/issues/8136))
-   fix: convert native PHP floats to single precision ([#&#8203;8187](https://togithub.com/protocolbuffers/protobuf/issues/8187))
-   Fixed PHP to support field numbers >=2\*\*28. ([#&#8203;8235](https://togithub.com/protocolbuffers/protobuf/issues/8235))
-   feat: add support for deprecated fields to PHP compiler ([#&#8203;8223](https://togithub.com/protocolbuffers/protobuf/issues/8223))
-   Protect against stack overflow if the user derives from Message. ([#&#8203;8248](https://togithub.com/protocolbuffers/protobuf/issues/8248))
-   Fixed clone for Message, RepeatedField, and MapField. ([#&#8203;8245](https://togithub.com/protocolbuffers/protobuf/issues/8245))
-   Updated upb to allow nonzero offset minutes in JSON timestamps. ([#&#8203;8258](https://togithub.com/protocolbuffers/protobuf/issues/8258))

### Ruby

-   Added support for Ruby 3. ([#&#8203;8184](https://togithub.com/protocolbuffers/protobuf/issues/8184))
-   Rewrote the data storage layer to be based on upb_msg objects from the
    upb library. This should lead to much better parsing performance,
    particularly for large messages. ([#&#8203;8184](https://togithub.com/protocolbuffers/protobuf/issues/8184)).
-   Fill out JRuby support ([#&#8203;7923](https://togithub.com/protocolbuffers/protobuf/issues/7923))
-   \[Ruby] Fix: (SIGSEGV) gRPC-Ruby issue on Windows. memory alloc infinite
    recursion/run out of memory ([#&#8203;8195](https://togithub.com/protocolbuffers/protobuf/issues/8195))
-   Fix jruby support to handle messages nested more than 1 level deep ([#&#8203;8194](https://togithub.com/protocolbuffers/protobuf/issues/8194))

### Java

-   Avoid possible UnsupportedOperationException when using CodedInputSteam
    with a direct ByteBuffer.
-   Make Durations.comparator() and Timestamps.comparator() Serializable.
-   Add more detailed error information for dynamic message field type
    validation failure
-   Removed declarations of functions declared in java_names.h from
    java_helpers.h.
-   Now Proto3 Oneof fields have "has" methods for checking their presence in
    Java.
-   Annotates Java proto generated \*\_FIELD_NUMBER constants.
-   Add -assumevalues to remove JvmMemoryAccessor on Android.

### C\#

-   Fix parsing negative Int32Value that crosses segment boundary ([#&#8203;8035](https://togithub.com/protocolbuffers/protobuf/issues/8035))
-   Change ByteString to use memory and support unsafe create without copy ([#&#8203;7645](https://togithub.com/protocolbuffers/protobuf/issues/7645))
-   Optimize MapField serialization by removing MessageAdapter ([#&#8203;8143](https://togithub.com/protocolbuffers/protobuf/issues/8143))
-   Allow FileDescriptors to be parsed with extension registries ([#&#8203;8220](https://togithub.com/protocolbuffers/protobuf/issues/8220))
-   Optimize writing small strings ([#&#8203;8149](https://togithub.com/protocolbuffers/protobuf/issues/8149))

</details>

---

### Configuration

📅 **Schedule**: At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

 **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box.

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-datacatalog).
gcf-merge-on-green bot pushed a commit to GoogleCloudPlatform/java-docs-samples that referenced this issue Sep 7, 2021
…3.17.3 (#5953)

[![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [com.google.protobuf:protobuf-java](https://developers.google.com/protocol-buffers/) ([source](https://togithub.com/protocolbuffers/protobuf)) | `3.10.0` -> `3.17.3` | [![age](https://badges.renovateapi.com/packages/maven/com.google.protobuf:protobuf-java/3.17.3/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.protobuf:protobuf-java/3.17.3/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.protobuf:protobuf-java/3.17.3/compatibility-slim/3.10.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.protobuf:protobuf-java/3.17.3/confidence-slim/3.10.0)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>protocolbuffers/protobuf</summary>

### [`v3.17.3`](https://togithub.com/protocolbuffers/protobuf/releases/v3.17.3)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.17.2...v3.17.3)

**Python**

-   Note: This is the last release to support Python 2.7. Future releases will require Python >= 3.5.

**C++**

-   Introduce FieldAccessListener.
-   Stop emitting boilerplate {Copy/Merge}From in each ProtoBuf class
-   Fixed some uninitialized variable warnings in generated_message_reflection.cc.

**Kotlin**

-   Fix duplicate proto files error ([#&#8203;8699](https://togithub.com/protocolbuffers/protobuf/issues/8699))

**Java**

-   Fixed parser to check that we are at a proper limit when a sub-message has
    finished parsing.

**General**

-   Support M1 ([#&#8203;8557](https://togithub.com/protocolbuffers/protobuf/issues/8557))

### [`v3.17.2`](https://togithub.com/protocolbuffers/protobuf/releases/v3.17.2)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.17.1...v3.17.2)

****Kotlin****

-   Fix duplicate class error ([#&#8203;8653](https://togithub.com/protocolbuffers/protobuf/issues/8653))

****PHP****

-   Fixed SEGV in sub-message getters for well-known types when message is unset
    ([#&#8203;8670](https://togithub.com/protocolbuffers/protobuf/issues/8670))

### [`v3.17.1`](https://togithub.com/protocolbuffers/protobuf/releases/v3.17.1)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.17.0...v3.17.1)

##### PHP

-   Fixed PHP memory leaks and arginfo errors. ([#&#8203;8614](https://togithub.com/protocolbuffers/protobuf/issues/8614))
-   Fixed JSON parser to allow multiple values from the same oneof as long as all but one are null.

##### Ruby

-   Fixed memory bug: properly root repeated/map field when assigning. ([#&#8203;8639](https://togithub.com/protocolbuffers/protobuf/issues/8639))
-   Fixed JSON parser to allow multiple values from the same oneof as long as all but one are null.

### [`v3.17.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.17.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.16.0...v3.17.0)

### Protocol Compiler

-   Fix the generated source information for reserved values in Enums.

### C++

-   Fix -Wunused-parameter in map\<string, int> fields (fixes [#&#8203;8494](https://togithub.com/protocolbuffers/protobuf/issues/8494)) ([#&#8203;8500](https://togithub.com/protocolbuffers/protobuf/issues/8500))
-   Use byteswap.h when building against musl libc ([#&#8203;8503](https://togithub.com/protocolbuffers/protobuf/issues/8503))
-   Fix -Wundefined-inline error when using SharedCtor() or SharedDtor() ([#&#8203;8532](https://togithub.com/protocolbuffers/protobuf/issues/8532))
-   Fix bug where `Descriptor::DebugString()` printed proto3 synthetic oneofs.
-   Provide stable versions of `SortAndUnique()`.
-   Make sure to cache proto3 optional message fields when they are cleared.
-   Expose UnsafeArena methods to Reflection.
-   Use std::string::empty() rather than std::string::size() > 0.

### Kotlin

-   Introduce support for Kotlin protos ([#&#8203;8272](https://togithub.com/protocolbuffers/protobuf/issues/8272))
-   Restrict extension setter and getter operators to non-nullable T.

### Java

-   updating GSON and Guava to more recent versions ([#&#8203;8524](https://togithub.com/protocolbuffers/protobuf/issues/8524))
-   Reduce the time spent evaluating isExtensionNumber by storing the extension
    ranges in a TreeMap for faster queries. This is particularly relevant for
    protos which define a large number of extension ranges, for example when
    each tag is defined as an extension.
-   Fix java bytecode estimation logic for optional fields.
-   Optimize Descriptor.isExtensionNumber.

### Python

-   Add MethodDescriptor.CopyToProto() ([#&#8203;8327](https://togithub.com/protocolbuffers/protobuf/issues/8327))
-   Remove unused python_protobuf.{cc,h} ([#&#8203;8513](https://togithub.com/protocolbuffers/protobuf/issues/8513))
-   Start publishing python aarch64 manylinux wheels normally ([#&#8203;8530](https://togithub.com/protocolbuffers/protobuf/issues/8530))
-   Fix constness issue detected by MSVC standard conforming mode ([#&#8203;8568](https://togithub.com/protocolbuffers/protobuf/issues/8568))
-   Make JSON parsing match C++ and Java when multiple fields from the same
    oneof are present and all but one is null.

### Ruby

-   Add support for proto3 json_name in compiler and field definitions ([#&#8203;8356](https://togithub.com/protocolbuffers/protobuf/issues/8356))
-   Fixed memory leak of Ruby arena objects. ([#&#8203;8461](https://togithub.com/protocolbuffers/protobuf/issues/8461))
-   Fix source gem compilation ([#&#8203;8471](https://togithub.com/protocolbuffers/protobuf/issues/8471))
-   Fix various exceptions in Ruby on 64-bit Windows ([#&#8203;8563](https://togithub.com/protocolbuffers/protobuf/issues/8563))
-   Fix crash when calculating Message hash values on 64-bit Windows ([#&#8203;8565](https://togithub.com/protocolbuffers/protobuf/issues/8565))

### Conformance Tests

-   Added a conformance test for the case of multiple fields from the same
    oneof.

### Other

-   Use a newer version of rules_proto, with the new rule `proto_descriptor_set` ([#&#8203;8469](https://togithub.com/protocolbuffers/protobuf/issues/8469))

### [`v3.16.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.16.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.8...v3.16.0)

### C++

-   Fix compiler warnings issue found in conformance_test_runner [#&#8203;8189](https://togithub.com/protocolbuffers/protobuf/issues/8189) ([#&#8203;8190](https://togithub.com/protocolbuffers/protobuf/issues/8190))
-   Fix MinGW-w64 build issues. ([#&#8203;8286](https://togithub.com/protocolbuffers/protobuf/issues/8286))
-   \[Protoc] C++ Resolved an issue where NO_DESTROY and CONSTINIT are in incorrect order ([#&#8203;8296](https://togithub.com/protocolbuffers/protobuf/issues/8296))
-   Fix PROTOBUF_CONSTINIT macro redefinition ([#&#8203;8323](https://togithub.com/protocolbuffers/protobuf/issues/8323))
-   Delete StringPiecePod ([#&#8203;8353](https://togithub.com/protocolbuffers/protobuf/issues/8353))
-   Fix gcc error: comparison of unsigned expression in '>= 0' is always … ([#&#8203;8309](https://togithub.com/protocolbuffers/protobuf/issues/8309))
-   Fix cmake install on iOS ([#&#8203;8301](https://togithub.com/protocolbuffers/protobuf/issues/8301))
-   Create a CMake option to control whether or not RTTI is enabled ([#&#8203;8347](https://togithub.com/protocolbuffers/protobuf/issues/8347))
-   Fix endian.h location on FreeBSD ([#&#8203;8351](https://togithub.com/protocolbuffers/protobuf/issues/8351))
-   Refactor util::Status ([#&#8203;8354](https://togithub.com/protocolbuffers/protobuf/issues/8354))
-   Make util::Status more similar to absl::Status ([#&#8203;8405](https://togithub.com/protocolbuffers/protobuf/issues/8405))
-   Fix -Wsuggest-destructor-override for generated C++ proto classes. ([#&#8203;8408](https://togithub.com/protocolbuffers/protobuf/issues/8408))
-   Refactor StatusOr and StringPiece ([#&#8203;8406](https://togithub.com/protocolbuffers/protobuf/issues/8406))
-   Refactor uint128 ([#&#8203;8416](https://togithub.com/protocolbuffers/protobuf/issues/8416))
-   The ::pb namespace is no longer exposed due to conflicts.
-   Allow MessageDifferencer::TreatAsSet() (and friends) to override previous
    calls instead of crashing.
-   Reduce the size of generated proto headers for protos with `string` or
    `bytes` fields.
-   Move arena() operation on uncommon path to out-of-line routine
-   For iterator-pair function parameter types, take both iterators by value.
-   Code-space savings and perhaps some modest performance improvements in
    RepeatedPtrField.
-   Eliminate nullptr check from every tag parse.
-   Remove unused \_$name$*cached_byte_size* fields.
-   Serialize extension ranges together when not broken by a proto field in the
    middle.
-   Do out-of-line allocation and deallocation of string object in ArenaString.
-   Streamline ParseContext::ParseMessage<T> to avoid code bloat and improve
    performance.
-   New member functions RepeatedField::Assign, RepeatedPtrField::{Add, Assign}.
-   Fix undefined behavior warning due to innocuous uninitialization of value
    on an error path.
-   Avoid expensive inlined code space for encoding message length for messages
    > \= 128 bytes and instead do a procedure call to a shared out-of-line routine.
-   util::DefaultFieldComparator will be final in a future version of protobuf.
    Subclasses should inherit from SimpleFieldComparator instead.

### C\#

-   Add .NET 5 target and improve WriteString performance with SIMD ([#&#8203;8147](https://togithub.com/protocolbuffers/protobuf/issues/8147))

### Java

-   deps: update JUnit and Truth ([#&#8203;8319](https://togithub.com/protocolbuffers/protobuf/issues/8319))
-   Detect invalid overflow of byteLimit and return InvalidProtocolBufferException as documented.
-   Exceptions thrown while reading from an InputStream in parseFrom are now
    included as causes.
-   Support potentially more efficient proto parsing from RopeByteStrings.
-   Clarify runtime of ByteString.Output.toStringBuffer().
-   Added UnsafeByteOperations to protobuf-lite ([#&#8203;8426](https://togithub.com/protocolbuffers/protobuf/issues/8426))

### JavaScript

-   Make Any.pack() chainable.

### Python

-   Fix some constness / char literal issues being found by MSVC standard conforming mode ([#&#8203;8344](https://togithub.com/protocolbuffers/protobuf/issues/8344))
-   Switch on "new" buffer API ([#&#8203;8339](https://togithub.com/protocolbuffers/protobuf/issues/8339))
-   Enable crosscompiling aarch64 python wheels under dockcross manylinux docker image ([#&#8203;8280](https://togithub.com/protocolbuffers/protobuf/issues/8280))
-   Fixed a bug in text format where a trailing colon was printed for repeated field.
-   When TextFormat encounters a duplicate message map key, replace the current
    one instead of merging.

### Objective-C

-   Move the class map to a CFDictionary. ([#&#8203;8328](https://togithub.com/protocolbuffers/protobuf/issues/8328))

### PHP

-   read_property() handler is not supposed to return NULL ([#&#8203;8362](https://togithub.com/protocolbuffers/protobuf/issues/8362))
-   Changed parameter type from long to integer ([#&#8203;7613](https://togithub.com/protocolbuffers/protobuf/issues/7613))
-   fix: README supported PHP version for C extension ([#&#8203;8236](https://togithub.com/protocolbuffers/protobuf/issues/8236))

### Ruby

-   Fixed quadratic memory usage when appending to arrays. ([#&#8203;8364](https://togithub.com/protocolbuffers/protobuf/issues/8364))
-   Fixed memory leak of Ruby arena objects. ([#&#8203;8461](https://togithub.com/protocolbuffers/protobuf/issues/8461))
-   Add support for proto3 json_name in compiler and field definitions. ([#&#8203;8356](https://togithub.com/protocolbuffers/protobuf/issues/8356))

### Other

-   Some doc on AOT compilation and protobuf ([#&#8203;8294](https://togithub.com/protocolbuffers/protobuf/issues/8294))
-   \[CMake] Ability to pass options to protoc executable from cmake ([#&#8203;8374](https://togithub.com/protocolbuffers/protobuf/issues/8374))
-   Add --fatal_warnings flag to treat warnings as errors ([#&#8203;8131](https://togithub.com/protocolbuffers/protobuf/issues/8131))
-   \[bazel] Remove deprecated way to depend on googletest ([#&#8203;8396](https://togithub.com/protocolbuffers/protobuf/issues/8396))
-   add error returns missing from protoc to prevent it from exiting with… ([#&#8203;8409](https://togithub.com/protocolbuffers/protobuf/issues/8409))

### [`v3.15.8`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.8)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.7...v3.15.8)

### Ruby

-   Fixed memory leak of Ruby arena objects ([#&#8203;8461](https://togithub.com/protocolbuffers/protobuf/issues/8461))

### [`v3.15.7`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.7)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.6...v3.15.7)

### C++

-   Remove the ::pb namespace (alias) ([#&#8203;8423](https://togithub.com/protocolbuffers/protobuf/issues/8423))

### Ruby

-   Fix unbounded memory growth for Ruby <2.7 ([#&#8203;8429](https://togithub.com/protocolbuffers/protobuf/issues/8429))
-   Fixed message equality in cases where the message type is different ([#&#8203;8434](https://togithub.com/protocolbuffers/protobuf/issues/8434))

### [`v3.15.6`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.6)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.5...v3.15.6)

### Ruby

-   Fixed bug in string comparison logic ([#&#8203;8386](https://togithub.com/protocolbuffers/protobuf/issues/8386))

### [`v3.15.5`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.5)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.4...v3.15.5)

### Ruby

-   Fixed quadratic memory use in array append ([#&#8203;8379](https://togithub.com/protocolbuffers/protobuf/issues/8379))

### PHP

-   Fixed quadratic memory use in array append ([#&#8203;8379](https://togithub.com/protocolbuffers/protobuf/issues/8379))

### C++

-   Do not disable RTTI by default in the CMake build ([#&#8203;8377](https://togithub.com/protocolbuffers/protobuf/issues/8377))

### [`v3.15.4`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.4)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.3...v3.15.4)

### Ruby

-   Fixed SEGV when users pass nil messages ([#&#8203;8363](https://togithub.com/protocolbuffers/protobuf/issues/8363))
-   Fixed quadratic memory usage when appending to arrays ([#&#8203;8364](https://togithub.com/protocolbuffers/protobuf/issues/8364))

### C++

-   Create a CMake option to control whether or not RTTI is enabled ([#&#8203;8361](https://togithub.com/protocolbuffers/protobuf/issues/8361))

### PHP

-   read_property() handler is not supposed to return NULL ([#&#8203;8362](https://togithub.com/protocolbuffers/protobuf/issues/8362))

### [`v3.15.3`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.3)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.2...v3.15.3)

##### Ruby

-   Ruby <2.7 now uses WeakMap too, which prevents memory leaks. ([#&#8203;8341](https://togithub.com/protocolbuffers/protobuf/issues/8341))

### [`v3.15.2`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.2)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.1...v3.15.2)

### Ruby

-   Fix for FieldDescriptor.get(msg) ([#&#8203;8330](https://togithub.com/protocolbuffers/protobuf/issues/8330))

### C++

-   Fix PROTOBUF_CONSTINIT macro redefinition ([#&#8203;8323](https://togithub.com/protocolbuffers/protobuf/issues/8323))

### [`v3.15.1`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.1)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.15.0...v3.15.1)

### Ruby

-   Bugfix for Message.\[] for repeated or map fields ([#&#8203;8313](https://togithub.com/protocolbuffers/protobuf/issues/8313))
-   Fix for truncating behavior when converting Float to Duration ([#&#8203;8320](https://togithub.com/protocolbuffers/protobuf/issues/8320))

### C++

-   Small fixes for MinGW and for C++20 with GCC ([#&#8203;8318](https://togithub.com/protocolbuffers/protobuf/issues/8318))

### [`v3.15.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.15.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.14.0...v3.15.0)

##### Protocol Compiler

-   Optional fields for proto3 are enabled by default, and no longer require
    the --experimental_allow_proto3\_optional flag.

##### C++

-   MessageDifferencer: fixed bug when using custom ignore with multiple
    unknown fields
-   Use init_seg in MSVC to push initialization to an earlier phase.
-   Runtime no longer triggers -Wsign-compare warnings.
-   Fixed -Wtautological-constant-out-of-range-compare warning.
-   DynamicCastToGenerated works for nullptr input for even if RTTI is disabled
-   Arena is refactored and optimized.
-   Clarified/specified that the exact value of Arena::SpaceAllocated() is an
    implementation detail users must not rely on. It should not be used in
    unit tests.
-   Change the signature of Any::PackFrom() to return false on error.
-   Add fast reflection getter API for strings.
-   Constant initialize the global message instances
-   Avoid potential for missed wakeup in UnknownFieldSet
-   Now Proto3 Oneof fields have "has" methods for checking their presence in
    C++.
-   Bugfix for NVCC
-   Return early in \_InternalSerialize for empty maps.
-   Adding functionality for outputting map key values in proto path logging
    output (does not affect comparison logic) and stop printing 'value' in the
    path. The modified print functionality is in the
    MessageDifferencer::StreamReporter.
-   Fixed [protocolbuffers/protobuf#8129
-   Ensure that null char symbol, package and file names do not result in a
    crash.
-   Constant initialize the global message instances
-   Pretty print 'max' instead of numeric values in reserved ranges.
-   Removed remaining instances of std::is_pod, which is deprecated in C++20.
-   Changes to reduce code size for unknown field handling by making uncommon
    cases out of line.
-   Fix std::is_pod deprecated in C++20 ([#&#8203;7180](https://togithub.com/protocolbuffers/protobuf/issues/7180))
-   Fix some -Wunused-parameter warnings ([#&#8203;8053](https://togithub.com/protocolbuffers/protobuf/issues/8053))
-   Fix detecting file as directory on zOS issue [#&#8203;8051](https://togithub.com/protocolbuffers/protobuf/issues/8051) ([#&#8203;8052](https://togithub.com/protocolbuffers/protobuf/issues/8052))
-   Don't include sys/param.h for \_BYTE_ORDER ([#&#8203;8106](https://togithub.com/protocolbuffers/protobuf/issues/8106))
-   remove CMAKE_THREAD_LIBS_INIT from pkgconfig CFLAGS ([#&#8203;8154](https://togithub.com/protocolbuffers/protobuf/issues/8154))
-   Fix TextFormatMapTest.DynamicMessage [issue#&#8203;5136](https://togithub.com/issue/protobuf/issues/5136) ([#&#8203;8159](https://togithub.com/protocolbuffers/protobuf/issues/8159))
-   Fix for compiler warning [issue#&#8203;8145](https://togithub.com/issue/protobuf/issues/8145) ([#&#8203;8160](https://togithub.com/protocolbuffers/protobuf/issues/8160))
-   fix: support deprecated enums for GCC < 6 ([#&#8203;8164](https://togithub.com/protocolbuffers/protobuf/issues/8164))
-   Fix some warning when compiling with Visual Studio 2019 on x64 target ([#&#8203;8125](https://togithub.com/protocolbuffers/protobuf/issues/8125))

##### Python

-   Provided an override for the reverse() method that will reverse the internal
    collection directly instead of using the other methods of the BaseContainer.
-   MessageFactory.CreateProtoype can be overridden to customize class creation.
-   Fix PyUnknownFields memory leak ([#&#8203;7928](https://togithub.com/protocolbuffers/protobuf/issues/7928))
-   Add macOS big sur compatibility ([#&#8203;8126](https://togithub.com/protocolbuffers/protobuf/issues/8126))

##### JavaScript

-   Generate `getDescriptor` methods with `*` as their `this` type.
-   Enforce `let/const` for generated messages.
-   js/binary/utils.js: Fix jspb.utils.joinUnsignedDecimalString to work with negative bitsLow and low but non-zero bitsHigh parameter. ([#&#8203;8170](https://togithub.com/protocolbuffers/protobuf/issues/8170))

##### PHP

-   Added support for PHP 8. ([#&#8203;8105](https://togithub.com/protocolbuffers/protobuf/issues/8105))
-   unregister INI entries and fix invalid read on shutdown ([#&#8203;8042](https://togithub.com/protocolbuffers/protobuf/issues/8042))
-   Fix PhpDoc comments for message accessors to include "|null". ([#&#8203;8136](https://togithub.com/protocolbuffers/protobuf/issues/8136))
-   fix: convert native PHP floats to single precision ([#&#8203;8187](https://togithub.com/protocolbuffers/protobuf/issues/8187))
-   Fixed PHP to support field numbers >=2\*\*28. ([#&#8203;8235](https://togithub.com/protocolbuffers/protobuf/issues/8235))
-   feat: add support for deprecated fields to PHP compiler ([#&#8203;8223](https://togithub.com/protocolbuffers/protobuf/issues/8223))
-   Protect against stack overflow if the user derives from Message. ([#&#8203;8248](https://togithub.com/protocolbuffers/protobuf/issues/8248))
-   Fixed clone for Message, RepeatedField, and MapField. ([#&#8203;8245](https://togithub.com/protocolbuffers/protobuf/issues/8245))
-   Updated upb to allow nonzero offset minutes in JSON timestamps. ([#&#8203;8258](https://togithub.com/protocolbuffers/protobuf/issues/8258))

##### Ruby

-   Added support for Ruby 3. ([#&#8203;8184](https://togithub.com/protocolbuffers/protobuf/issues/8184))
-   Rewrote the data storage layer to be based on upb_msg objects from the
    upb library. This should lead to much better parsing performance,
    particularly for large messages. ([#&#8203;8184](https://togithub.com/protocolbuffers/protobuf/issues/8184)).
-   Fill out JRuby support ([#&#8203;7923](https://togithub.com/protocolbuffers/protobuf/issues/7923))
-   \[Ruby] Fix: (SIGSEGV) gRPC-Ruby issue on Windows. memory alloc infinite
    recursion/run out of memory ([#&#8203;8195](https://togithub.com/protocolbuffers/protobuf/issues/8195))
-   Fix jruby support to handle messages nested more than 1 level deep ([#&#8203;8194](https://togithub.com/protocolbuffers/protobuf/issues/8194))

##### Java

-   Avoid possible UnsupportedOperationException when using CodedInputSteam
    with a direct ByteBuffer.
-   Make Durations.comparator() and Timestamps.comparator() Serializable.
-   Add more detailed error information for dynamic message field type
    validation failure
-   Removed declarations of functions declared in java_names.h from
    java_helpers.h.
-   Now Proto3 Oneof fields have "has" methods for checking their presence in
    Java.
-   Annotates Java proto generated \*\_FIELD_NUMBER constants.
-   Add -assumevalues to remove JvmMemoryAccessor on Android.

##### C\#

-   Fix parsing negative Int32Value that crosses segment boundary ([#&#8203;8035](https://togithub.com/protocolbuffers/protobuf/issues/8035))
-   Change ByteString to use memory and support unsafe create without copy ([#&#8203;7645](https://togithub.com/protocolbuffers/protobuf/issues/7645))
-   Optimize MapField serialization by removing MessageAdapter ([#&#8203;8143](https://togithub.com/protocolbuffers/protobuf/issues/8143))
-   Allow FileDescriptors to be parsed with extension registries ([#&#8203;8220](https://togithub.com/protocolbuffers/protobuf/issues/8220))
-   Optimize writing small strings ([#&#8203;8149](https://togithub.com/protocolbuffers/protobuf/issues/8149))

### [`v3.14.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.14.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.13.0...v3.14.0)

##### Protocol Compiler

-   The proto compiler no longer requires a .proto filename when it is not
    generating code.
-   Added flag `--deterministic_output` to `protoc --encode=...`.
-   Fixed deadlock when using google.protobuf.Any embedded in aggregate options.

##### C++

-   Arenas are now unconditionally enabled. cc_enable_arenas no longer has
    any effect.
-   Removed inlined string support, which is incompatible with arenas.
-   Fix a memory corruption bug in reflection when mixing optional and
    non-optional fields.
-   Make SpaceUsed() calculation more thorough for map fields.
-   Add stack overflow protection for text format with unknown field values.
-   FieldPath::FollowAll() now returns a bool to signal if an out-of-bounds
    error was encountered.
-   Performance improvements for Map.
-   Minor formatting fix when dumping a descriptor to .proto format with
    DebugString.
-   UBSAN fix in RepeatedField ([#&#8203;2073](https://togithub.com/protocolbuffers/protobuf/issues/2073)).
-   When running under ASAN, skip a test that makes huge allocations.
-   Fixed a crash that could happen when creating more than 256 extensions in
    a single message.
-   Fix a crash in BuildFile when passing in invalid descriptor proto.
-   Parser security fix when operating with CodedInputStream.
-   Warn against the use of AllowUnknownExtension.
-   Migrated to C++11 for-range loops instead of index-based loops where
    possible. This fixes a lot of warnings when compiling with -Wsign-compare.
-   Fix segment fault for proto3 optional ([#&#8203;7805](https://togithub.com/protocolbuffers/protobuf/issues/7805))
-   Adds a CMake option to build `libprotoc` separately ([#&#8203;7949](https://togithub.com/protocolbuffers/protobuf/issues/7949))

##### Java

-   Bugfix in mergeFrom() when a oneof has multiple message fields.
-   Fix RopeByteString.RopeInputStream.read() returning -1 when told to read
    0 bytes when not at EOF.
-   Redefine remove(Object) on primitive repeated field Lists to avoid
    autoboxing.
-   Support "\u" escapes in textformat string literals.
-   Trailing empty spaces are no longer ignored for FieldMask.
-   Fix FieldMaskUtil.subtract to recursively remove mask.
-   Mark enums with `@java.lang.Deprecated` if the proto enum has option
    `deprecated = true;`.
-   Adding forgotten duration.proto to the lite library ([#&#8203;7738](https://togithub.com/protocolbuffers/protobuf/issues/7738))

##### Python

-   Print google.protobuf.NullValue as null instead of "NULL_VALUE" when it is
    used outside WKT Value/Struct.
-   Fix bug occurring when attempting to deep copy an enum type in python 3.
-   Add a setuptools extension for generating Python protobufs ([#&#8203;7783](https://togithub.com/protocolbuffers/protobuf/issues/7783))
-   Remove uses of pkg_resources in non-namespace packages. ([#&#8203;7902](https://togithub.com/protocolbuffers/protobuf/issues/7902))
-   \[bazel/py] Omit google/**init**.py from the Protobuf runtime. ([#&#8203;7908](https://togithub.com/protocolbuffers/protobuf/issues/7908))
-   Removed the unnecessary setuptools package dependency for Python package ([#&#8203;7511](https://togithub.com/protocolbuffers/protobuf/issues/7511))
-   Fix PyUnknownFields memory leak ([#&#8203;7928](https://togithub.com/protocolbuffers/protobuf/issues/7928))

##### PHP

-   Added support for "==" to the PHP C extension ([#&#8203;7883](https://togithub.com/protocolbuffers/protobuf/issues/7883))
-   Added `==` operators for Map and Array. ([#&#8203;7900](https://togithub.com/protocolbuffers/protobuf/issues/7900))
-   Native C well-known types ([#&#8203;7944](https://togithub.com/protocolbuffers/protobuf/issues/7944))
-   Optimized away hex2bin() call in generated code ([#&#8203;8006](https://togithub.com/protocolbuffers/protobuf/issues/8006))
-   New version of upb, and a new hash function wyhash in third_party. ([#&#8203;8000](https://togithub.com/protocolbuffers/protobuf/issues/8000))
-   add missing hasOneof method to check presence of oneof fields ([#&#8203;8003](https://togithub.com/protocolbuffers/protobuf/issues/8003))

##### Go

-   Update go_package options to reference google.golang.org/protobuf module.

##### C\#

-   annotate ByteString.CopyFrom(ReadOnlySpan<byte>) as SecuritySafeCritical ([#&#8203;7701](https://togithub.com/protocolbuffers/protobuf/issues/7701))
-   Fix C# optional field reflection when there are regular fields too ([#&#8203;7705](https://togithub.com/protocolbuffers/protobuf/issues/7705))
-   Fix parsing negative Int32Value that crosses segment boundary ([#&#8203;8035](https://togithub.com/protocolbuffers/protobuf/issues/8035))

##### Javascript

-   JS: parse (un)packed fields conditionally ([#&#8203;7379](https://togithub.com/protocolbuffers/protobuf/issues/7379))

### [`v3.13.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.13.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.12.4...v3.13.0)

### PHP

-   The C extension is completely rewritten. The new C extension has significantly
    better parsing performance and fixes a handful of conformance issues. It will
    also make it easier to add support for more features like proto2 and proto3 presence.
-   The new C extension does not support PHP 5.x, which is the reason for the major
    version bump. PHP 5.x users can still use pure-PHP.

### C++

-   Removed deprecated unsafe arena string accessors
-   Enabled heterogeneous lookup for std::string keys in maps.
-   Removed implicit conversion from StringPiece to std::string
-   Fix use-after-destroy bug when the Map is allocated in the arena.
-   Improved the randomness of map ordering
-   Added stack overflow protection for text format with unknown fields
-   Use std::hash for proto maps to help with portability.
-   Added more Windows macros to proto whitelist.
-   Arena constructors for map entry messages are now marked "explicit"
    (for regular messages they were already explicit).
-   Fix subtle aliasing bug in RepeatedField::Add
-   Fix mismatch between MapEntry ByteSize and Serialize with respect to unset
    fields.

### Python

-   JSON format conformance fixes:
    -   Reject lowercase t for Timestamp json format.
    -   Print full_name directly for extensions (no camelCase).
    -   Reject boolean values for integer fields.
    -   Reject NaN, Infinity, -Infinity that is not quoted.
    -   Base64 fixes for bytes fields: accept URL-safe base64 and missing padding.
-   Bugfix for fields/files named "async" or "await".
-   Improved the error message when AttributeError is returned from **getattr**
    in EnumTypeWrapper.

### Java

-   Fixed a bug where setting optional proto3 enums with setFooValue() would
    not mark the value as present.
-   Add Subtract function to FieldMaskUtil.

### C\#

-   Dropped support for netstandard1.0 (replaced by support for netstandard1.1).
    This was required to modernize the parsing stack to use the `Span<byte>`
    type internally. ([#&#8203;7351](https://togithub.com/protocolbuffers/protobuf/issues/7351))
-   Add `ParseFrom(ReadOnlySequence<byte>)` method to enable GC friendly
    parsing with reduced allocations and buffer copies. ([#&#8203;7351](https://togithub.com/protocolbuffers/protobuf/issues/7351))
-   Add support for serialization directly to a `IBufferWriter<byte>` or
    to a `Span<byte>` to enable GC friendly serialization.
    The new API is available as extension methods on the `IMessage` type. ([#&#8203;7576](https://togithub.com/protocolbuffers/protobuf/issues/7576))
-   Add `GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE` define to make
    generated code compatible with old C# compilers (pre-roslyn compilers
    from .NET framework and old versions of mono) that do not support
    ref structs. Users that are still on a legacy stack that does
    not support C# 7.2 compiler might need to use the new define
    in their projects to be able to build the newly generated code. ([#&#8203;7490](https://togithub.com/protocolbuffers/protobuf/issues/7490))
-   Due to the major overhaul of parsing and serialization internals ([#&#8203;7351](https://togithub.com/protocolbuffers/protobuf/issues/7351) and [#&#8203;7576](https://togithub.com/protocolbuffers/protobuf/issues/7576)),
    it is recommended to regenerate your generated code to achieve the best
    performance (the legacy generated code will still work, but might incur
    a slight performance penalty).

### [`v3.12.4`](https://togithub.com/protocolbuffers/protobuf/compare/v3.12.2...v3.12.4)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.12.2...v3.12.4)

### [`v3.12.2`](https://togithub.com/protocolbuffers/protobuf/releases/v3.12.2)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.12.1...v3.12.2)

##### C++

-   Simplified the template export macros to fix the build for mingw32. ([#&#8203;7539](https://togithub.com/protocolbuffers/protobuf/issues/7539))

##### Objective-C

-   Fix for the :protobuf_objc target in the Bazel BUILD file. ([#&#8203;7538](https://togithub.com/protocolbuffers/protobuf/issues/7538))

### [`v3.12.1`](https://togithub.com/protocolbuffers/protobuf/releases/v3.12.1)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.12.0...v3.12.1)

### Ruby

-   Re-add binary gems for Ruby 2.3 and 2.4. These are EOL upstream, however
    many people still use them and dropping support will require more
    coordination. ([#&#8203;7529](https://togithub.com/protocolbuffers/protobuf/issues/7529), [#&#8203;7531](https://togithub.com/protocolbuffers/protobuf/issues/7531)).

### [`v3.12.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.12.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.11.4...v3.12.0)

### Protocol Compiler

-   \[experimental] Singular, non-message typed fields in proto3 now support
    presence tracking. This is enabled by adding the "optional" field label and
    passing the `--experimental_allow_proto3_optional` flag to protoc.
    -   For usage info, see [docs/field_presence.md](docs/field_presence.md).
    -   During this experimental phase, code generators should update to support
        proto3 presence, see [docs/implementing_proto3\_presence.md](docs/implementing_proto3\_presence.md) for instructions.
-   Allow duplicate symbol names when multiple descriptor sets are passed on
    the command-line, to match the behavior when multiple .proto files are passed.
-   Deterministic `protoc --descriptor_set_out` ([#&#8203;7175](https://togithub.com/protocolbuffers/protobuf/issues/7175))

### C++

-   \[experimental] Added proto3 presence support.
-   New descriptor APIs to support proto3 presence.
-   Fix for [#&#8203;7463](https://togithub.com/protocolbuffers/protobuf/issues/7463) in -rc1 (core dump mixing optional and singular fields in proto3)
-   Enable Arenas by default on all .proto files.
-   Documented that users are not allowed to subclass Message or MessageLite.
-   Mark generated classes as final; inheriting from protos is strongly discouraged.
-   Add stack overflow protection for text format with unknown fields.
-   Add accessors for map key and value FieldDescriptors.
-   Add FieldMaskUtil::FromFieldNumbers().
-   MessageDifferencer: use ParsePartial() on Any fields so the diff does not
    fail when there are missing required fields.
-   ReflectionOps::Merge(): lookup messages in the right factory, if it can.
-   Added Descriptor::WellKnownTypes enum and Descriptor::well_known_type()
    accessor as an easier way of determining if a message is a Well-Known Type.
-   Optimized RepeatedField::Add() when it is used in a loop.
-   Made proto move/swap more efficient.
-   De-virtualize the GetArena() method in MessageLite.
-   Improves performance of json_stream_parser.cc by factor 1000 ([#&#8203;7230](https://togithub.com/protocolbuffers/protobuf/issues/7230))
-   bug: [#&#8203;7076](https://togithub.com/protocolbuffers/protobuf/issues/7076) undefine Windows OUT and OPTIONAL macros ([#&#8203;7087](https://togithub.com/protocolbuffers/protobuf/issues/7087))
-   Fixed a bug in FieldDescriptor::DebugString() that would erroneously print
    an "optional" label for a field in a oneof.
-   Fix bug in parsing bool extensions that assumed they are always 1 byte.
-   Fix off-by-one error in FieldOptions::ByteSize() when extensions are present.
-   Clarified the comments to show an example of the difference between
    Descriptor::extension and DescriptorPool::FindAllExtensions.
-   Add a compiler option 'code_size' to force optimize_for=code_size on all
    protos where this is possible.

### Java

-   \[experimental] Added proto3 presence support.
-   Fix for [#&#8203;7480](https://togithub.com/protocolbuffers/protobuf/issues/7480) in -rc1 ("TextFormat and JsonFormat ignore experimental proto3 optional enums")
-   Fix for [#&#8203;7505](https://togithub.com/protocolbuffers/protobuf/issues/7505) in -rc1 (" toString() returns incorrect ascii when there are duplicate keys in a map")
-   Mark java enum \_VALUE constants as [@&#8203;Deprecated](https://togithub.com/Deprecated) if the enum field is deprecated
-   reduce <clinit> size for enums with allow_alias set to true.
-   Sort map fields alphabetically by the field's key when printing textproto.
-   TextFormat.merge() handles Any as top level type.
-   Throw a descriptive IllegalArgumentException when calling
    getValueDescriptor() on enum special value UNRECOGNIZED instead of
    ArrayIndexOutOfBoundsException.
-   Fixed an issue with JsonFormat.printer() where setting printingEnumsAsInts()
    would override the configuration passed into includingDefaultValueFields().
-   Implement overrides of indexOf() and contains() on primitive lists returned
    for repeated fields to avoid autoboxing the list contents.
-   Add overload to FieldMaskUtil.fromStringList that accepts a descriptor.
-   \[bazel] Move Java runtime/toolchains into //java ([#&#8203;7190](https://togithub.com/protocolbuffers/protobuf/issues/7190))

### Python

-   \[experimental] Added proto3 presence support.
-   \[experimental] fast import protobuf module, only works with cpp generated code linked in.
-   Truncate 'float' fields to 4 bytes of precision in setters for pure-Python
    implementation (C++ extension was already doing this).
-   Fixed a memory leak in C++ bindings.
-   Added a deprecation warning when code tries to create Descriptor objects
    directly.
-   Fix unintended comparison between bytes and string in descriptor.py.
-   Avoid printing excess digits for float fields in TextFormat.
-   Remove Python 2.5 syntax compatibility from the proto compiler generated \_pb2.py module code.
-   Drop 3.3, 3.4 and use single version docker images for all python tests ([#&#8203;7396](https://togithub.com/protocolbuffers/protobuf/issues/7396))

### JavaScript

-   Fix js message pivot selection ([#&#8203;6813](https://togithub.com/protocolbuffers/protobuf/issues/6813))

### PHP

-   Persistent Descriptor Pool ([#&#8203;6899](https://togithub.com/protocolbuffers/protobuf/issues/6899))
-   Implement lazy loading of php class for proto messages ([#&#8203;6911](https://togithub.com/protocolbuffers/protobuf/issues/6911))
-   Correct [@&#8203;return](https://togithub.com/return) in Any.unpack docblock ([#&#8203;7089](https://togithub.com/protocolbuffers/protobuf/issues/7089))
-   Ignore unknown enum value when ignore_unknown specified ([#&#8203;7455](https://togithub.com/protocolbuffers/protobuf/issues/7455))

### Ruby

-   \[experimental] Implemented proto3 presence for Ruby. ([#&#8203;7406](https://togithub.com/protocolbuffers/protobuf/issues/7406))
-   Stop building binary gems for ruby <2.5 ([#&#8203;7453](https://togithub.com/protocolbuffers/protobuf/issues/7453))
-   Fix for wrappers with a zero value ([#&#8203;7195](https://togithub.com/protocolbuffers/protobuf/issues/7195))
-   Fix for JSON serialization of 0/empty-valued wrapper types ([#&#8203;7198](https://togithub.com/protocolbuffers/protobuf/issues/7198))
-   Call "Class#new" over rb_class_new_instance in decoding ([#&#8203;7352](https://togithub.com/protocolbuffers/protobuf/issues/7352))
-   Build extensions for Ruby 2.7 ([#&#8203;7027](https://togithub.com/protocolbuffers/protobuf/issues/7027))
-   assigning 'nil' to submessage should clear the field. ([#&#8203;7397](https://togithub.com/protocolbuffers/protobuf/issues/7397))

### C\#

-   \[experimental] Add support for proto3 presence fields in C# ([#&#8203;7382](https://togithub.com/protocolbuffers/protobuf/issues/7382))
-   Cleanup various bits of Google.Protobuf ([#&#8203;6674](https://togithub.com/protocolbuffers/protobuf/issues/6674))
-   Fix conformance test failures for Google.Protobuf ([#&#8203;6910](https://togithub.com/protocolbuffers/protobuf/issues/6910))
-   Fix latest ArgumentException for C# extensions ([#&#8203;6938](https://togithub.com/protocolbuffers/protobuf/issues/6938))
-   Remove unnecessary branch from ReadTag ([#&#8203;7289](https://togithub.com/protocolbuffers/protobuf/issues/7289))
-   Enforce recursion depth checking for unknown fields ([#&#8203;7132](https://togithub.com/protocolbuffers/protobuf/issues/7132))
-   Mark GetOption API as obsolete and expose the "GetOptions()" method
    on descriptors instead ([#&#8203;7491](https://togithub.com/protocolbuffers/protobuf/issues/7491))
-   Remove Has/Clear members for C# message fields in proto2 ([#&#8203;7429](https://togithub.com/protocolbuffers/protobuf/issues/7429))

### Objective-C

-   \[experimental] ObjC Proto3 optional support ([#&#8203;7421](https://togithub.com/protocolbuffers/protobuf/issues/7421))
-   Block subclassing of generated classes ([#&#8203;7124](https://togithub.com/protocolbuffers/protobuf/issues/7124))
-   Use references to Obj C classes instead of names in descriptors. ([#&#8203;7026](https://togithub.com/protocolbuffers/protobuf/issues/7026))
-   Revisit how the WKTs are bundled with ObjC. ([#&#8203;7173](https://togithub.com/protocolbuffers/protobuf/issues/7173))

### Other

-   Add a proto_lang_toolchain for javalite ([#&#8203;6882](https://togithub.com/protocolbuffers/protobuf/issues/6882))
-   \[bazel] Update gtest and deprecate //external:{gtest,gtest_main} ([#&#8203;7237](https://togithub.com/protocolbuffers/protobuf/issues/7237))
-   Add application note for explicit presence tracking. ([#&#8203;7390](https://togithub.com/protocolbuffers/protobuf/issues/7390))
-   Howto doc for implementing proto3 presence in a code generator. ([#&#8203;7407](https://togithub.com/protocolbuffers/protobuf/issues/7407))

### [`v3.11.4`](https://togithub.com/protocolbuffers/protobuf/compare/v3.11.3...v3.11.4)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.11.3...v3.11.4)

### [`v3.11.3`](https://togithub.com/protocolbuffers/protobuf/compare/v3.11.2...v3.11.3)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.11.1...v3.11.3)

### [`v3.11.1`](https://togithub.com/protocolbuffers/protobuf/releases/v3.11.1)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.11.0...v3.11.1)

# PHP

-   Extern declare protobuf_globals ([#&#8203;6946](https://togithub.com/protocolbuffers/protobuf/issues/6946))

### [`v3.11.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.11.0)

[Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.10.0...v3.11.0)

# C++

-   Make serialization method naming consistent
-   Make proto runtime + generated code free of deprecation warnings
-   Moved ShutdownProtobufLibrary() to message_lite.h.  For backward compatibility a declaration is still available in stubs/common.h, but users should prefer message_lite.h
-   Removed non-namespace macro EXPECT_OK()
-   Removed mathlimits.h from stubs in favor of using std::numeric_limits from C++11
-   Fixed bug in parser when ending on a group tag
-   Add a helper function to UnknownFieldSet to deal with the changing return value of message::unknown_fields()
-   Fix incorrect use of string_view iterators
-   Support direct pickling of nested messages
-   Skip extension tag validation for MessageSet if unknown dependencies are allowed
-   Updated deprecation macros to annotate deprecated code ([#&#8203;6612](https://togithub.com/protocolbuffers/protobuf/issues/6612))
-   Remove conversion warning in MapEntryFuncs::ByteSizeLong ([#&#8203;6766](https://togithub.com/protocolbuffers/protobuf/issues/6766))
-   Revert "Make shared libraries be able to link to MSVC static runtime libraries, so that VC runtime is not required." ([#&#8203;6914](https://togithub.com/protocolbuffers/protobuf/issues/6914))

# Java

-   Remove the usage of MethodHandle, so that Android users prior to API version 26 can use protobuf-java
-   Publish ProGuard config for javalite
-   Fix for StrictMode disk read violation in ExtensionRegistryLite
-   Include part of the ByteString's content in its toString().
-   Include unknown fields when merging proto3 messages in Java lite builders

# Python

-   Add float_precision option in json format printer
-   Optionally print bytes fields as messages in unknown fields, if possible
-   FieldPath: fix testing IsSet on root path ''
-   Experimental code gen (fast import protobuf module) which only work with cpp generated code linked in

# JavaScript

-   Remove guard for Symbol iterator for jspb.Map

# PHP

-   Avoid too much overhead in layout_init ([#&#8203;6716](https://togithub.com/protocolbuffers/protobuf/issues/6716))
-   Lazily Create Singular Wrapper Message ([#&#8203;6833](https://togithub.com/protocolbuffers/protobuf/issues/6833))
-   Implement lazy loading of php class for proto messages ([#&#8203;6911](https://togithub.com/protocolbuffers/protobuf/issues/6911))

# Ruby

-   Ruby lazy wrappers optimization ([#&#8203;6797](https://togithub.com/protocolbuffers/protobuf/issues/6797))

# C\#

-   (RepeatedField): Capacity property to resize the internal array ([#&#8203;6530](https://togithub.com/protocolbuffers/protobuf/issues/6530))
-   Experimental proto2 support is now officially available ([#&#8203;4642](https://togithub.com/protocolbuffers/protobuf/issues/4642), [#&#8203;5183](https://togithub.com/protocolbuffers/protobuf/issues/5183), [#&#8203;5350](https://togithub.com/protocolbuffers/protobuf/issues/5350), [#&#8203;5936](https://togithub.com/protocolbuffers/protobuf/issues/5936))
-   Getting started doc: https://github.com/protocolbuffers/protobuf/blob/master/docs/csharp/proto2.md
-   Add length checks to ExtensionCollection ([#&#8203;6759](https://togithub.com/protocolbuffers/protobuf/issues/6759))
-   Optimize parsing of some primitive and wrapper types ([#&#8203;6843](https://togithub.com/protocolbuffers/protobuf/issues/6843))
-   Use 3 parameter Encoding.GetString for default string values ([#&#8203;6828](https://togithub.com/protocolbuffers/protobuf/issues/6828))
-   Change \_Extensions property to normal body rather than expression ([#&#8203;6856](https://togithub.com/protocolbuffers/protobuf/issues/6856))

# Objective C

-   Fixed unaligned reads for 32bit arm with newer Xcode versions ([#&#8203;6678](https://togithub.com/protocolbuffers/protobuf/issues/6678))

</details>

---

### Configuration

📅 **Schedule**: At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

 **Rebasing**: Never, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box.

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/GoogleCloudPlatform/java-docs-samples).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment