You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
概要 gRPCで通信しようとすると.protoファイルが沢山出てきます。 ただ人によってインデントが異なったりするのは良くないので、何かしらformatterが無いかなと探したら github.com こちらのissueで「Googleではclang-formatを使ってるよ」という回答があったのでそれを使ってみます。 環境 macOS Mojave 10.14.2 clang-format 8.0.0 設定 インストール brew でインストールできます。 $ brew install clang-format 使い方 $ xargs clang-format -i foo.proto で整形できます。ディレクトリ丸ごと実行したい場合は./proto/ディレクトリで定義しているとすると $ find ./proto/ -name "*.proto" | xargs clang-forma
以前の記事では、Protocol Buffers (protobuf)の魅力の1つは周辺ツールを拡張しやすいことだと述べた。そこで本稿では具体的に拡張のためのprotocプラグインの書き方を紹介したい。 ちなみに、protobufの周辺ツールと言うと2種類ある。 1つはprotobufでシリアライズされたデータを処理するツール。JSONやCSVにとってのjqやsedやawkに相当する。 もう1つはprotobufのスキーマを処理するツール。 先の記事にあるようにProtobufはシリアライゼーション機能だけでなくスキーマ言語としても価値が高いので、典型的なweb開発用途では後者のほうが重要だ。 本稿は後者のスキーマ処理の話である。なお前者は、チュートリアルでAPIを覚えたらあとは自分で好きな処理を書きましょうというだけの話なので、別に難しくない。 初めに、protocについて確認しよう。こ
以前の記事ではprotocプラグインの書き方を紹介したが、実は1つ問題があった。 実用的なプラグインを書こうとした場合に、しばしば生成時に必要な、ドメイン固有の情報が足りないのである。本稿ではそれを補うカスタムオプションの話をする。 ここでもう一度確認しよう。protocのプラグインはProtocol Buffersのスキーマを読んで任意の処理を行える仕組みだ。それはCodeGeneratorRequest内のFileDescriptorProto messageを読み取って任意のバイト列を出力し、出力を受け取ったprotocが指定通りにファイルにバイト列を書き込んでくれる。 ただ、FileDescriptorProtoはprotobufのスキーマ言語の文法をprotobufメッセージとして表現したものに過ぎないから、極めて一般的なデータ構造とサービス定義を表現する能力しか持たない。プログ
proto2cpp Wiki Doxygen filter for Google Protocol Buffers files Proto2cpp is a Python script intended to be used as a Doxygen filter for Google Protocol Buffers files (.proto). The script is released under GNU Lesser General Public License version 2.1. How to enable this filter in Doxygen: Generate Doxygen configuration file with command doxygen -g <filename> e.g. doxygen -g doxyfile In the Doxyge
Protobuf-wireshark - Auto-generate Wireshark/Ethereal dissector plugins for Protocol Buffer messages GoalView UDP packets containing messages packed using Google Protocol Buffers in Wireshark (or Ethereal). ApproachIf the .proto file is not available, a generic wireshark dissector plugin displays messages as "field id: value" pairs. If the .proto file is available, a custom wireshark dissector plu
Abstract: Jini has served Orbitz well, but at the cost of tight coupling due in part to shared code and Java™ platform serialization rules. To improve agility, Orbitz is migrating to a RESTful Web services architecture using protocol buffers to define message formats. The result is loosely coupled services with autonomous lifecycles supporting evolvability and innovative mashup-style development.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert Test Platform OS:Mac OS X JVM:Oracle Corporation 11.0.19 CPU:2.6 GHz 6-Core Intel Core i7 os-arch:Darwin Kernel Version 21.6.0 Cores (incl HT):12 Disclaimer Th
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く