Update version from 2.2.0 to 2.3.0 Tarball is attached.
2010-01-08 version 2.3.0:
General
* Parsers for repeated numeric fields now always accept both packed and
unpacked input. The [packed=true] option only affects serializers.
Therefore, it is possible to switch a field to packed format without
breaking backwards-compatibility -- as long as all parties are using
protobuf 2.3.0 or above, at least.
* The generic RPC service code generated by the C++, Java, and Python
generators can be disabled via file options:
option cc_generic_services = false;
option java_generic_services = false;
option py_generic_services = false;
This allows plugins to generate alternative code, possibly specific to some
particular RPC implementation.
protoc
* Now supports a plugin system for code generators. Plugins can generate
code for new languages or inject additional code into the output of other
code generators. Plugins are just binaries which accept a protocol buffer
on stdin and write a protocol buffer to stdout, so they may be written in
any language. See src/google/protobuf/compiler/plugin.proto.
**WARNING**: Plugins are experimental. The interface may change in a
future version.
* If the output location ends in .zip or .jar, protoc will write its output
to a zip/jar archive instead of a directory. For example:
protoc --java_out=myproto_srcs.jar --python_out=myproto.zip myproto.proto
Currently the archive contents are not compressed, though this could change
in the future.
* inf, -inf, and nan can now be used as default values for float and double
fields.
C++
* Various speed and code size optimizations.
* DynamicMessageFactory is now fully thread-safe.
* Message::Utf8DebugString() method is like DebugString() but avoids escaping
UTF-8 bytes.
* Compiled-in message types can now contain dynamic extensions, through use
of CodedInputStream::SetExtensionRegistry().
* Now compiles shared libraries (DLLs) by default on Cygwin and MinGW, to
match other platforms. Use --disable-shared to avoid this.
Java
* parseDelimitedFrom() and mergeDelimitedFrom() now detect EOF and return
false/null instead of throwing an exception.
* Fixed some initialization ordering bugs.
* Fixes for OpenJDK 7.
Python
* 10-25 times faster than 2.2.0, still pure-Python.
* Calling a mutating method on a sub-message always instantiates the message
in its parent even if the mutating method doesn't actually mutate anything
(e.g. parsing from an empty string).
* Expanded descriptors a bit.
On Thu, Dec 31, 2009 at 1:57 PM, Auclair Vincent
<[email protected]> wrote:
> attached is a port of google protobuf
>
> Information for inst:protobuf-2.2.0
>
> Comment:
> c++ protocol buffers
>
> Description:
> Protocol buffers are a flexible, efficient, automated mechanism for
> serializing
> structured data - think XML, but smaller, faster, and simpler. You define how
> you want your data to be structured once, then you can use special generated
> source code to easily write and read your structured data to and from a
> variety
> of data streams and using a variety of languages. You can even update your
> data
> structure without breaking deployed programs that are compiled against the
> "old"
> format.
>
> Maintainer: Vincent Auclair <[email protected]>
>
> WWW: http://code.google.com/p/protobuf/
>
> It uses the installed gtest instead of the shipped one for regressions tests.
> This is only the c++ part. There are also a java and python part in it.
> Which I am not currently planning to port.
>
> Comments ?
> This was also ported for the ACSEL. (same as gtest, glog) So it would be nice
> if
> it could be mentioned in the commit message. :)
> This is the 2.2.0 version as the 2.2.0a is only a debian fix.
> The 2.3.0 is in release candidate.
>
> I am copying the website example here :
>
> You write a .proto file like this:
>
> message Person {
> required int32 id = 1;
> required string name = 2;
> optional string email = 3;
> }
>
> Then you compile it with protoc, the protocol buffer compiler,
> to produce code in C++, Java, or Python.
>
> Then, if you are using C++, you use that code like this:
>
> Person person;
> person.set_id(123);
> person.set_name("Bob");
> person.set_email("[email protected]");
>
> fstream out("person.pb", ios::out | ios::binary | ios::trunc);
> person.SerializeToOstream(&out);
> out.close();
>
> Or like this:
>
> Person person;
> fstream in("person.pb", ios::in | ios::binary);
> if (!person.ParseFromIstream(&in)) {
> cerr << "Failed to parse person.pb." << endl;
> exit(1);
> }
>
> cout << "ID: " << person.id() << endl;
> cout << "name: " << person.name() << endl;
> if (person.has_email()) {
> cout << "e-mail: " << person.email() << endl;
> }
>
--
Vincent Auclair - auclair.vincent[ at ]gmail.com
(+33) 6 80 77 59 67
protobuf.tar.gz
Description: GNU Zip compressed data
