|
| 1 | +2017-08-14 version 3.4.0 (C++/Java/Python/PHP/Objective-C/C#/Ruby/JavaScript) |
| 2 | + Planned Future Changes |
| 3 | + * There are some changes that are not included in this release but are planned |
| 4 | + for the near future |
| 5 | + - Preserve unknown fields in proto3: We are going to bring unknown fields |
| 6 | + back into proto3. In this release, some languages start to support |
| 7 | + preserving unknown fields in proto3, controlled by flags/options. Some |
| 8 | + languages also introduce explicit APIs to drop unknown fields for |
| 9 | + migration. Please read the change log sections by languages for details. |
| 10 | + For general timeline and plan: |
| 11 | + |
| 12 | + https://docs.google.com/document/d/1KMRX-G91Aa-Y2FkEaHeeviLRRNblgIahbsk4wA14gRk/view |
| 13 | + |
| 14 | + For issues and discussions: |
| 15 | + |
| 16 | + https://github.com/google/protobuf/issues/272 |
| 17 | + |
| 18 | + - Make C++ implementation C++11 only: we plan to require C++11 to build |
| 19 | + protobuf code starting from 3.5.0 or 3.6.0 release, after unknown fields |
| 20 | + semantic changes are finished. Please join this |
| 21 | + github issue: |
| 22 | + |
| 23 | + https://github.com/google/protobuf/issues/2780 |
| 24 | + |
| 25 | + to provide your feedback. |
| 26 | + |
| 27 | + General |
| 28 | + * Extension ranges now accept options and are customizable. |
| 29 | + * "reserve" keyword now supports “max” in field number ranges, |
| 30 | + e.g. reserve 1000 to max; |
| 31 | + |
| 32 | + C++ |
| 33 | + * Proto3 messages are now able to preserve unknown fields. The default |
| 34 | + behavior is still to drop unknowns, which will be flipped in a future |
| 35 | + release. If you rely on unknowns fields being dropped. Please use |
| 36 | + Message::DiscardUnknownFields() explicitly. |
| 37 | + * Packable proto3 fields are now packed by default in serialization. |
| 38 | + * Following C++11 features are introduced when C++11 is available: |
| 39 | + - move-constructor and move-assignment are introduced to messages |
| 40 | + - Repeated fields constructor now takes std::initializer_list |
| 41 | + - rvalue setters are introduced for string fields |
| 42 | + * Experimental Table-Driven parsing and serialization available to test. To |
| 43 | + enable it, pass in table_driven_parsing table_driven_serialization protoc |
| 44 | + generator flags for C++ |
| 45 | + |
| 46 | + $ protoc --cpp_out=table_driven_parsing,table_driven_serialization:./ \ |
| 47 | + test.proto |
| 48 | + |
| 49 | + * lite generator parameter supported by the generator. Once set, all generated |
| 50 | + files, use lite runtime regardless of the optimizer_for setting in the |
| 51 | + .proto file. |
| 52 | + * Various optimizations to make C++ code more performant on PowerPC platform |
| 53 | + * Fixed maps data corruption when the maps are modified by both reflection API |
| 54 | + and generated API. |
| 55 | + * Deterministic serialization on maps reflection now uses stable sort. |
| 56 | + * file() accessors are introduced to various *Descriptor classes to make |
| 57 | + writing template function easier. |
| 58 | + * ByteSize() and SpaceUsed() are deprecated.Use ByteSizeLong() and |
| 59 | + SpaceUsedLong() instead |
| 60 | + * Consistent hash function is used for maps in DEBUG and NDEBUG build. |
| 61 | + * "using namespace std" is removed from stubs/common.h |
| 62 | + * Various performance optimizations and bug fixes |
| 63 | + |
| 64 | + Java |
| 65 | + * Introduced new parser API DiscardUnknownFieldsParser in preparation of |
| 66 | + proto3 unknown fields preservation change. Users who want to drop unknown |
| 67 | + fields should migrate to use this new parser API. For example: |
| 68 | + |
| 69 | + Parser<Foo> parser = DiscardUnknownFieldsParser.wrap(Foo.parser()); |
| 70 | + Foo foo = parser.parseFrom(input); |
| 71 | + |
| 72 | + * Introduced new TextFormat API printUnicodeFieldValue() that prints field |
| 73 | + value without escaping unicode characters. |
| 74 | + * Added Durations.compare(Duration, Duration) and |
| 75 | + Timestamps.compare(Timestamp, Timestamp). |
| 76 | + * JsonFormat now accepts base64url encoded bytes fields. |
| 77 | + * Optimized CodedInputStream to do less copies when parsing large bytes |
| 78 | + fields. |
| 79 | + * Optimized TextFormat to allocate less memory when printing. |
| 80 | + |
| 81 | + Python |
| 82 | + * SerializeToString API is changed to SerializeToString(self, **kwargs), |
| 83 | + deterministic parameter is accepted for deterministic serialization. |
| 84 | + * Added sort_keys parameter in json format to make the output deterministic. |
| 85 | + * Added indent parameter in json format. |
| 86 | + * Added extension support in json format. |
| 87 | + * Added __repr__ support for repeated field in cpp implementation. |
| 88 | + * Added file in FieldDescriptor. |
| 89 | + * Added pretty-print filter to text format. |
| 90 | + * Services and method descriptors are always printed even if generic_service |
| 91 | + option is turned off. |
| 92 | + * Note: AppEngine 2.5 is deprecated on June 2017 that AppEngine 2.5 will |
| 93 | + never update protobuf runtime. Users who depend on AppEngine 2.5 should use |
| 94 | + old protoc. |
| 95 | + |
| 96 | + PHP |
| 97 | + * Support PHP generic services. Specify file option php_generic_service=true |
| 98 | + to enable generating service interface. |
| 99 | + * Message, repeated and map fields setters take value instead of reference. |
| 100 | + * Added map iterator in c extension. |
| 101 | + * Support json encode/decode. |
| 102 | + * Added more type info in getter/setter phpdoc |
| 103 | + * Fixed the problem that c extension and php implementation cannot be used |
| 104 | + together. |
| 105 | + * Added file option php_namespace to use custom php namespace instead of |
| 106 | + package. |
| 107 | + * Added fluent setter. |
| 108 | + * Added descriptor API in runtime for custom encode/decode. |
| 109 | + * Various bug fixes. |
| 110 | + |
| 111 | + Objective-C |
| 112 | + * Fix for GPBExtensionRegistry copying and add tests. |
| 113 | + * Optimize GPBDictionary.m codegen to reduce size of overall library by 46K |
| 114 | + per architecture. |
| 115 | + * Fix some cases of reading of 64bit map values. |
| 116 | + * Properly error on a tag with field number zero. |
| 117 | + * Preserve unknown fields in proto3 syntax files. |
| 118 | + * Document the exceptions on some of the writing apis. |
| 119 | + |
| 120 | + C# |
| 121 | + * Implemented IReadOnlyDictionary<K,V> in MapField<K,V> |
| 122 | + * Added TryUnpack method for Any message in addition to Unpack. |
| 123 | + * Converted C# projects to MSBuild (csproj) format. |
| 124 | + |
| 125 | + Ruby |
| 126 | + * Several bug fixes. |
| 127 | + |
| 128 | + Javascript |
| 129 | + * Added support of field option js_type. Now one can specify the JS type of a |
| 130 | + 64-bit integer field to be string in the generated code by adding option |
| 131 | + [jstype = JS_STRING] on the field. |
| 132 | + |
1 | 133 | 2017-04-05 version 3.3.0 (C++/Java/Python/PHP/Objective-C/C#/Ruby/JavaScript)
|
2 | 134 | Planned Future Changes
|
3 | 135 | * There are some changes that are not included in this release but are
|
|
0 commit comments