How does protocol buffer handle versioning?

Google designed protobuf to be pretty forgiving with versioning: unexpected data is either stored as “extensions” (making it round-trip safe), or silently dropped, depending on the implementation new fields are generally added as “optional”, meaning that old data can be loaded successfully however: do not renumber fields – that would break existing data you should … Read more

High performance serialization: Java vs Google Protocol Buffers vs …?

I haven’t compared Protocol Buffers with Java’s native serialization in terms of speed, but for interoperability Java’s native serialization is a serious no-no. It’s also not going to be as efficient in terms of space as Protocol Buffers in most cases. Of course, it’s somewhat more flexible in terms of what it can store, and … Read more

How do I get Eclipse to resolve classes generated with Maven 2?

m2eclipse supports this. First, add the path to your build path: <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>build-helper-maven-plugin</artifactId> <version>1.8</version> <executions> <execution> <id>add-source</id> <phase>generate-sources</phase> <goals> <goal>add-source</goal> </goals> <configuration> <sources> <source>${project.build.directory}/generated-sources/java/</source> </sources> </configuration> </execution> </executions> </plugin> Second, add support for that to m2e: <pluginManagement> <plugins> <plugin> <groupId>org.eclipse.m2e</groupId> <artifactId>lifecycle-mapping</artifactId> <version>1.0.0</version> <configuration> <lifecycleMappingMetadata> <pluginExecutions> <pluginExecution> <pluginExecutionFilter> <groupId>org.codehaus.mojo</groupId> <artifactId>build-helper-maven-plugin</artifactId> <versionRange>[1.0,)</versionRange> <goals> <goal>parse-version</goal> <goal>add-source</goal> <goal>maven-version</goal> … Read more

Is there a definitive *nix command line tool for inspecting protocol buffers? [closed]

The Protocol Compiler — protoc — has this functionality built-in via the –decode and –decode_raw flags. This is the same tool you use to generate code from a .proto file so is likely already installed. For example: protoc –decode_raw < message.bin Or using the .proto file: protoc –decode mypkg.MyType myschema.proto < message.bin Here is the … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)