CINXE.COM
platform/external/golang-protobuf - Git at Google
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>platform/external/golang-protobuf - Git at Google</title><link rel="stylesheet" type="text/css" href="/+static/base.css"><link rel="stylesheet" type="text/css" href="/+static/doc.css"><!-- default customHeadTagPart --></head><body class="Site"><header class="Site-header"><div class="Header"><a class="Header-image" href="/"><img src="//www.gstatic.com/images/branding/lockups/2x/lockup_git_color_108x24dp.png" width="108" height="24" alt="Google Git"></a><div class="Header-menu"> <a class="Header-menuItem" href="https://accounts.google.com/AccountChooser?faa=1&service=gerritcodereview&continue=https://android.googlesource.com/login/platform/external/golang-protobuf/">Sign in</a> </div></div></header><div class="Site-content"><div class="Container "><div class="Breadcrumbs"><a class="Breadcrumbs-crumb" href="/?format=HTML">android</a> / <a class="Breadcrumbs-crumb" href="/platform/">platform</a> / <a class="Breadcrumbs-crumb" href="/platform/external/">external</a> / <span class="Breadcrumbs-crumb">golang-protobuf</span></div><div class="CloneRepo"><div class="CloneRepo-title">Clone this repo:</div><input id="clone-repo-input" type="text" class="u-monospace CloneRepo-command" readonly="readonly" value="git clone https://android.googlesource.com/platform/external/golang-protobuf"></div><div class="RepoShortlog"><div class="RepoShortlog-refs"><div class="RefList RefList--responsive"><h3 class="RefList-title">Branches</h3><ul class="RefList-items"><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/main">main</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/aml_ads_341826060">aml_ads_341826060</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/aml_ads_341826300">aml_ads_341826300</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/aml_art_341810020">aml_art_341810020</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/aml_ase_341810000">aml_ase_341810000</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/aml_cbr_341810000">aml_cbr_341810000</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/aml_con_341810060">aml_con_341810060</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/aml_doc_341813030">aml_doc_341813030</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/aml_ext_341816020">aml_ext_341816020</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/heads/aml_hef_341811030">aml_hef_341811030</a></li></ul></div><a href="/platform/external/golang-protobuf/+refs">More...</a><div class="RefList RefList--responsive"><h3 class="RefList-title">Tags</h3><ul class="RefList-items"><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/android-automotiveos-14.0.0_lts3">android-automotiveos-14.0.0_lts3</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/upstream-v1.35.2">upstream-v1.35.2</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r75">android-14.0.0_r75</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/android-cts-12.0_r14">android-cts-12.0_r14</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/android-cts-12.1_r12">android-cts-12.1_r12</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/android-cts-13.0_r10">android-cts-13.0_r10</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/android-cts-15.0_r2">android-cts-15.0_r2</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/android-cts-14.0_r6">android-cts-14.0_r6</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/android-vts-12.0_r14">android-vts-12.0_r14</a></li><li class="RefList-item"><a href="/platform/external/golang-protobuf/+/refs/tags/android-vts-12.1_r12">android-vts-12.1_r12</a></li></ul></div><a href="/platform/external/golang-protobuf/+refs">More...</a></div><div class="RepoShortlog-log"><ol class="CommitLog"><li class="CommitLog-item CommitLog-item--androidOneline"><a class="u-sha1 u-monospace CommitLog-sha1" href="/platform/external/golang-protobuf/+/1c12ee1efe575feb122dbf939ff15148a3b3e8f2">1c12ee1</a> <a href="/platform/external/golang-protobuf/+/1c12ee1efe575feb122dbf939ff15148a3b3e8f2">Upgrade golang-protobuf to v1.30.0 am: fb8fa965ff am: a9ac88b2de am: bdb9197b4f am: 2e590813ee am: 28644ef0ae</a> <span class="CommitLog-author" title="dwillemsen@google.com">by Dan Willemsen</span> <span class="CommitLog-time" title="Fri Mar 17 01:59:00 2023 +0000">· 1 year, 8 months ago</span> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr2-release">android14-qpr2-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr2-s1-release">android14-qpr2-s1-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr2-s2-release">android14-qpr2-s2-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr2-s3-release">android14-qpr2-s3-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr2-s4-release">android14-qpr2-s4-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr2-s5-release">android14-qpr2-s5-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-d1-release">android14-qpr3-d1-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-d1-s1-release">android14-qpr3-d1-s1-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-d1-s2-release">android14-qpr3-d1-s2-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-d1-s3-release">android14-qpr3-d1-s3-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-release">android14-qpr3-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s10-release">android14-qpr3-s10-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s11-release">android14-qpr3-s11-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s12-release">android14-qpr3-s12-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s13-release">android14-qpr3-s13-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s14-release">android14-qpr3-s14-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s15-release">android14-qpr3-s15-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s2-release">android14-qpr3-s2-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s3-release">android14-qpr3-s3-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s4-release">android14-qpr3-s4-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s5-release">android14-qpr3-s5-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s6-release">android14-qpr3-s6-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s7-release">android14-qpr3-s7-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s8-release">android14-qpr3-s8-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr3-s9-release">android14-qpr3-s9-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android15-platform-release">android15-platform-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android15-release">android15-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android15-s1-release">android15-s1-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android15-security-release">android15-security-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android15-tests-dev">android15-tests-dev</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android15-tests-release">android15-tests-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/main">main</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/master">master</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/aml_tz6_351010000">aml_tz6_351010000</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r29">android-14.0.0_r29</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r30">android-14.0.0_r30</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r31">android-14.0.0_r31</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r32">android-14.0.0_r32</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r33">android-14.0.0_r33</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r34">android-14.0.0_r34</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r35">android-14.0.0_r35</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r36">android-14.0.0_r36</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r37">android-14.0.0_r37</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r50">android-14.0.0_r50</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r51">android-14.0.0_r51</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r52">android-14.0.0_r52</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r53">android-14.0.0_r53</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r54">android-14.0.0_r54</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r55">android-14.0.0_r55</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r56">android-14.0.0_r56</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r57">android-14.0.0_r57</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r58">android-14.0.0_r58</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r59">android-14.0.0_r59</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r60">android-14.0.0_r60</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r61">android-14.0.0_r61</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r62">android-14.0.0_r62</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r63">android-14.0.0_r63</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r64">android-14.0.0_r64</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r65">android-14.0.0_r65</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r66">android-14.0.0_r66</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r67">android-14.0.0_r67</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r68">android-14.0.0_r68</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r69">android-14.0.0_r69</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r70">android-14.0.0_r70</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r71">android-14.0.0_r71</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r72">android-14.0.0_r72</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r73">android-14.0.0_r73</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r74">android-14.0.0_r74</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r75">android-14.0.0_r75</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-15.0.0_r1">android-15.0.0_r1</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-15.0.0_r2">android-15.0.0_r2</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-15.0.0_r3">android-15.0.0_r3</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-15.0.0_r4">android-15.0.0_r4</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-15.0.0_r5">android-15.0.0_r5</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-cts-15.0_r1">android-cts-15.0_r1</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-cts-15.0_r2">android-cts-15.0_r2</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-platform-15.0.0_r1">android-platform-15.0.0_r1</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-platform-15.0.0_r2">android-platform-15.0.0_r2</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-security-15.0.0_r1">android-security-15.0.0_r1</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-security-15.0.0_r2">android-security-15.0.0_r2</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-vts-15.0_r1">android-vts-15.0_r1</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-vts-15.0_r2">android-vts-15.0_r2</a></li><li class="CommitLog-item CommitLog-item--androidOneline"><a class="u-sha1 u-monospace CommitLog-sha1" href="/platform/external/golang-protobuf/+/9a2c1a669645810ccc43b3f3fec4da747b487556">9a2c1a6</a> <a href="/platform/external/golang-protobuf/+/9a2c1a669645810ccc43b3f3fec4da747b487556">Upgrade golang-protobuf to v1.30.0 am: fb8fa965ff am: a9ac88b2de am: bdb9197b4f am: 2e590813ee am: 4cd06776fd</a> <span class="CommitLog-author" title="dwillemsen@google.com">by Dan Willemsen</span> <span class="CommitLog-time" title="Fri Mar 17 01:41:01 2023 +0000">· 1 year, 8 months ago</span></li><li class="CommitLog-item CommitLog-item--androidOneline"><a class="u-sha1 u-monospace CommitLog-sha1" href="/platform/external/golang-protobuf/+/28644ef0ae3367ca5e0ce51b06cf06a7a1dd69df">28644ef</a> <a href="/platform/external/golang-protobuf/+/28644ef0ae3367ca5e0ce51b06cf06a7a1dd69df">Upgrade golang-protobuf to v1.30.0 am: fb8fa965ff am: a9ac88b2de am: bdb9197b4f am: 2e590813ee</a> <span class="CommitLog-author" title="dwillemsen@google.com">by Dan Willemsen</span> <span class="CommitLog-time" title="Fri Mar 17 01:05:40 2023 +0000">· 1 year, 8 months ago</span></li><li class="CommitLog-item CommitLog-item--androidOneline"><a class="u-sha1 u-monospace CommitLog-sha1" href="/platform/external/golang-protobuf/+/4cd06776fdeffa7799bbb918ea656d63504469a8">4cd0677</a> <a href="/platform/external/golang-protobuf/+/4cd06776fdeffa7799bbb918ea656d63504469a8">Upgrade golang-protobuf to v1.30.0 am: fb8fa965ff am: a9ac88b2de am: bdb9197b4f am: 2e590813ee</a> <span class="CommitLog-author" title="dwillemsen@google.com">by Dan Willemsen</span> <span class="CommitLog-time" title="Fri Mar 17 01:03:20 2023 +0000">· 1 year, 8 months ago</span> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-d2-release">android14-d2-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-d2-s1-release">android14-d2-s1-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-d2-s2-release">android14-d2-s2-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-d2-s3-release">android14-d2-s3-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-d2-s4-release">android14-d2-s4-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-d2-s5-release">android14-d2-s5-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr1-automotiveos-release">android14-qpr1-automotiveos-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr1-release">android14-qpr1-release</a> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-qpr1-s2-release">android14-qpr1-s2-release</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r16">android-14.0.0_r16</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r17">android-14.0.0_r17</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r18">android-14.0.0_r18</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r19">android-14.0.0_r19</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r20">android-14.0.0_r20</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r21">android-14.0.0_r21</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r22">android-14.0.0_r22</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r23">android-14.0.0_r23</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r24">android-14.0.0_r24</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r25">android-14.0.0_r25</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r26">android-14.0.0_r26</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r27">android-14.0.0_r27</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r38">android-14.0.0_r38</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r39">android-14.0.0_r39</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r40">android-14.0.0_r40</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r41">android-14.0.0_r41</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r42">android-14.0.0_r42</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r43">android-14.0.0_r43</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r44">android-14.0.0_r44</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-14.0.0_r45">android-14.0.0_r45</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-automotiveos-14.0.0_lts2">android-automotiveos-14.0.0_lts2</a> <a class="CommitLog-tagLabel" href="/platform/external/golang-protobuf/+/refs/tags/android-automotiveos-14.0.0_lts3">android-automotiveos-14.0.0_lts3</a></li><li class="CommitLog-item CommitLog-item--androidOneline"><a class="u-sha1 u-monospace CommitLog-sha1" href="/platform/external/golang-protobuf/+/2e590813ee194436517593fc660c1f39cce095ad">2e59081</a> <a href="/platform/external/golang-protobuf/+/2e590813ee194436517593fc660c1f39cce095ad">Upgrade golang-protobuf to v1.30.0 am: fb8fa965ff am: a9ac88b2de am: bdb9197b4f</a> <span class="CommitLog-author" title="dwillemsen@google.com">by Dan Willemsen</span> <span class="CommitLog-time" title="Fri Mar 17 00:25:20 2023 +0000">· 1 year, 8 months ago</span> <a class="CommitLog-branchLabel" href="/platform/external/golang-protobuf/+/refs/heads/android14-dev">android14-dev</a></li></ol><nav class="LogNav"><a class="LogNav-next" href="/platform/external/golang-protobuf/+log">More »</a></nav><div class="doc RepoIndexDoc"><h1><a class="h" name="Go-support-for-Protocol-Buffers" href="#Go-support-for-Protocol-Buffers"><span></span></a><a class="h" name="go-support-for-protocol-buffers" href="#go-support-for-protocol-buffers"><span></span></a>Go support for Protocol Buffers</h1><p><a href="https://pkg.go.dev/google.golang.org/protobuf"><img src="https://pkg.go.dev/badge/google.golang.org/protobuf.svg" alt="Go Reference" /></a> <a href="https://travis-ci.org/protocolbuffers/protobuf-go"><img src="https://travis-ci.org/protocolbuffers/protobuf-go.svg?branch=master" alt="Build Status" /></a></p><p>This project hosts the Go implementation for <a href="https://protobuf.dev">protocol buffers</a>, which is a language-neutral, platform-neutral, extensible mechanism for serializing structured data. The protocol buffer language is a language for specifying the schema for structured data. This schema is compiled into language specific bindings. This project provides both a tool to generate Go code for the protocol buffer language, and also the runtime implementation to handle serialization of messages in Go. See the <a href="https://protobuf.dev/overview">protocol buffer developer guide</a> for more information about protocol buffers themselves.</p><p>This project is comprised of two components:</p><ul><li><p>Code generator: The <a href="https://pkg.go.dev/google.golang.org/protobuf/cmd/protoc-gen-go"><code class="code">protoc-gen-go</code></a> tool is a compiler plugin to <code class="code">protoc</code>, the protocol buffer compiler. It augments the <code class="code">protoc</code> compiler so that it knows how to <a href="https://protobuf.dev/reference/go/go-generated">generate Go specific code for a given <code class="code">.proto</code> file</a>.</p></li><li><p>Runtime library: The <a href="https://pkg.go.dev/mod/google.golang.org/protobuf"><code class="code">protobuf</code></a> module contains a set of Go packages that form the runtime implementation of protobufs in Go. This provides the set of interfaces that <a href="https://pkg.go.dev/google.golang.org/protobuf/reflect/protoreflect">define what a message is</a> and functionality to serialize message in various formats (e.g., <a href="https://pkg.go.dev/google.golang.org/protobuf/proto">wire</a>, <a href="https://pkg.go.dev/google.golang.org/protobuf/encoding/protojson">JSON</a>, and <a href="https://pkg.go.dev/google.golang.org/protobuf/encoding/prototext">text</a>).</p></li></ul><p>See the <a href="https://protobuf.dev/getting-started/gotutorial">developer guide for protocol buffers in Go</a> for a general guide for how to get started using protobufs in Go.</p><p>This project is the second major revision of the Go protocol buffer API implemented by the <a href="https://pkg.go.dev/mod/google.golang.org/protobuf"><code class="code">google.golang.org/protobuf</code></a> module. The first major version is implemented by the <a href="https://pkg.go.dev/mod/github.com/golang/protobuf"><code class="code">github.com/golang/protobuf</code></a> module.</p><h2><a class="h" name="Package-index" href="#Package-index"><span></span></a><a class="h" name="package-index" href="#package-index"><span></span></a>Package index</h2><p>Summary of the packages provided by this module:</p><ul><li><a href="https://pkg.go.dev/google.golang.org/protobuf/proto"><code class="code">proto</code></a>: Package <code class="code">proto</code> provides functions operating on protobuf messages such as cloning, merging, and checking equality, as well as binary serialization.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/encoding/protojson"><code class="code">encoding/protojson</code></a>: Package <code class="code">protojson</code> serializes protobuf messages as JSON.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/encoding/prototext"><code class="code">encoding/prototext</code></a>: Package <code class="code">prototext</code> serializes protobuf messages as the text format.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/encoding/protowire"><code class="code">encoding/protowire</code></a>: Package <code class="code">protowire</code> parses and formats the low-level raw wire encoding. Most users should use package <code class="code">proto</code> to serialize messages in the wire format.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/reflect/protoreflect"><code class="code">reflect/protoreflect</code></a>: Package <code class="code">protoreflect</code> provides interfaces to dynamically manipulate protobuf messages.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/reflect/protoregistry"><code class="code">reflect/protoregistry</code></a>: Package <code class="code">protoregistry</code> provides data structures to register and lookup protobuf descriptor types.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/reflect/protodesc"><code class="code">reflect/protodesc</code></a>: Package <code class="code">protodesc</code> provides functionality for converting <code class="code">descriptorpb.FileDescriptorProto</code> messages to/from the reflective <code class="code">protoreflect.FileDescriptor</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/reflect/protopath"><code class="code">reflect/protopath</code></a>: Package <code class="code">protopath</code> provides a representation of a sequence of protobuf reflection operations on a message.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/reflect/protorange"><code class="code">reflect/protorange</code></a>: Package <code class="code">protorange</code> provides functionality to traverse a protobuf message.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/testing/protocmp"><code class="code">testing/protocmp</code></a>: Package <code class="code">protocmp</code> provides protobuf specific options for the <code class="code">cmp</code> package.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/testing/protopack"><code class="code">testing/protopack</code></a>: Package <code class="code">protopack</code> aids manual encoding and decoding of the wire format.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/testing/prototest"><code class="code">testing/prototest</code></a>: Package <code class="code">prototest</code> exercises the protobuf reflection implementation for concrete message types.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/dynamicpb"><code class="code">types/dynamicpb</code></a>: Package <code class="code">dynamicpb</code> creates protobuf messages at runtime from protobuf descriptors.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/anypb"><code class="code">types/known/anypb</code></a>: Package <code class="code">anypb</code> is the generated package for <code class="code">google/protobuf/any.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/timestamppb"><code class="code">types/known/timestamppb</code></a>: Package <code class="code">timestamppb</code> is the generated package for <code class="code">google/protobuf/timestamp.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/durationpb"><code class="code">types/known/durationpb</code></a>: Package <code class="code">durationpb</code> is the generated package for <code class="code">google/protobuf/duration.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/wrapperspb"><code class="code">types/known/wrapperspb</code></a>: Package <code class="code">wrapperspb</code> is the generated package for <code class="code">google/protobuf/wrappers.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/structpb"><code class="code">types/known/structpb</code></a>: Package <code class="code">structpb</code> is the generated package for <code class="code">google/protobuf/struct.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/fieldmaskpb"><code class="code">types/known/fieldmaskpb</code></a>: Package <code class="code">fieldmaskpb</code> is the generated package for <code class="code">google/protobuf/field_mask.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/apipb"><code class="code">types/known/apipb</code></a>: Package <code class="code">apipb</code> is the generated package for <code class="code">google/protobuf/api.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/typepb"><code class="code">types/known/typepb</code></a>: Package <code class="code">typepb</code> is the generated package for <code class="code">google/protobuf/type.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/sourcecontextpb"><code class="code">types/known/sourcecontextpb</code></a>: Package <code class="code">sourcecontextpb</code> is the generated package for <code class="code">google/protobuf/source_context.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/known/emptypb"><code class="code">types/known/emptypb</code></a>: Package <code class="code">emptypb</code> is the generated package for <code class="code">google/protobuf/empty.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/descriptorpb"><code class="code">types/descriptorpb</code></a>: Package <code class="code">descriptorpb</code> is the generated package for <code class="code">google/protobuf/descriptor.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/types/pluginpb"><code class="code">types/pluginpb</code></a>: Package <code class="code">pluginpb</code> is the generated package for <code class="code">google/protobuf/compiler/plugin.proto</code>.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/compiler/protogen"><code class="code">compiler/protogen</code></a>: Package <code class="code">protogen</code> provides support for writing protoc plugins.</li><li><a href="https://pkg.go.dev/google.golang.org/protobuf/cmd/protoc-gen-go"><code class="code">cmd/protoc-gen-go</code></a>: The <code class="code">protoc-gen-go</code> binary is a protoc plugin to generate a Go protocol buffer package.</li></ul><h2><a class="h" name="Reporting-issues" href="#Reporting-issues"><span></span></a><a class="h" name="reporting-issues" href="#reporting-issues"><span></span></a>Reporting issues</h2><p>The issue tracker for this project is currently located at <a href="https://github.com/golang/protobuf/issues">golang/protobuf</a>.</p><p>Please report any issues there with a sufficient description of the bug or feature request. Bug reports should ideally be accompanied by a minimal reproduction of the issue. Irreproducible bugs are difficult to diagnose and fix (and likely to be closed after some period of time). Bug reports must specify the version of the <a href="https://github.com/protocolbuffers/protobuf-go/releases">Go protocol buffer module</a> and also the version of the <a href="https://github.com/protocolbuffers/protobuf/releases">protocol buffer toolchain</a> being used.</p><h2><a class="h" name="Contributing" href="#Contributing"><span></span></a><a class="h" name="contributing" href="#contributing"><span></span></a>Contributing</h2><p>This project is open-source and accepts contributions. See the <a href="https://github.com/protocolbuffers/protobuf-go/blob/master/CONTRIBUTING.md">contribution guide</a> for more information.</p><h2><a class="h" name="Compatibility" href="#Compatibility"><span></span></a><a class="h" name="compatibility" href="#compatibility"><span></span></a>Compatibility</h2><p>This module and the generated code are expected to be stable over time. However, we reserve the right to make breaking changes without notice for the following reasons:</p><ul><li><strong>Security:</strong> A security issue in the specification or implementation may come to light whose resolution requires breaking compatibility. We reserve the right to address such issues.</li><li><strong>Unspecified behavior:</strong> There are some aspects of the protocol buffer specification that are undefined. Programs that depend on unspecified behavior may break in future releases.</li><li><strong>Specification changes:</strong> It may become necessary to address an inconsistency, incompleteness, or change in the protocol buffer specification, which may affect the behavior of existing programs. We reserve the right to address such changes.</li><li><strong>Bugs:</strong> If a package has a bug that violates correctness, a program depending on the buggy behavior may break if the bug is fixed. We reserve the right to fix such bugs.</li><li><strong>Generated additions</strong>: We reserve the right to add new declarations to generated Go packages of <code class="code">.proto</code> files. This includes declared constants, variables, functions, types, fields in structs, and methods on types. This may break attempts at injecting additional code on top of what is generated by <code class="code">protoc-gen-go</code>. Such practice is not supported by this project.</li><li><strong>Internal changes</strong>: We reserve the right to add, modify, and remove internal code, which includes all unexported declarations, the <a href="https://pkg.go.dev/google.golang.org/protobuf/cmd/protoc-gen-go/internal_gengo"><code class="code">protoc-gen-go/internal_gengo</code></a> package, the <a href="https://pkg.go.dev/google.golang.org/protobuf/runtime/protoimpl?tab=doc"><code class="code">runtime/protoimpl</code></a> package, and all packages under <a href="https://pkg.go.dev/google.golang.org/protobuf/internal"><code class="code">internal</code></a>.</li></ul><p>Any breaking changes outside of these will be announced 6 months in advance to <a href="https://groups.google.com/forum/#!forum/protobuf">protobuf@googlegroups.com</a>.</p><p>Users should use generated code produced by a version of <a href="https://pkg.go.dev/google.golang.org/protobuf/cmd/protoc-gen-go"><code class="code">protoc-gen-go</code></a> that is identical to the runtime version provided by the <a href="https://pkg.go.dev/mod/google.golang.org/protobuf">protobuf module</a>. This project promises that the runtime remains compatible with code produced by a version of the generator that is no older than 1 year from the version of the runtime used, according to the release dates of the minor version. Generated code is expected to use a runtime version that is at least as new as the generator used to produce it. Generated code contains references to <a href="https://pkg.go.dev/google.golang.org/protobuf/runtime/protoimpl?tab=doc#EnforceVersion"><code class="code">protoimpl.EnforceVersion</code></a> to statically ensure that the generated code and runtime do not drift sufficiently far apart.</p><h2><a class="h" name="Historical-legacy" href="#Historical-legacy"><span></span></a><a class="h" name="historical-legacy" href="#historical-legacy"><span></span></a>Historical legacy</h2><p>This project is the second major revision (<a href="https://blog.golang.org/a-new-go-api-for-protocol-buffers">released in 2020</a>) of the Go protocol buffer API implemented by the <a href="https://pkg.go.dev/mod/google.golang.org/protobuf"><code class="code">google.golang.org/protobuf</code></a> module. The first major version (<a href="https://blog.golang.org/third-party-libraries-goprotobuf-and">released publicly in 2010</a>) is implemented by the <a href="https://pkg.go.dev/mod/github.com/golang/protobuf"><code class="code">github.com/golang/protobuf</code></a> module.</p><p>The first version predates the release of Go 1 by several years. It has a long history as one of the first core pieces of infrastructure software ever written in Go. As such, the Go protobuf project was one of many pioneers for determining what the Go language should even look like and what would eventually be considered good design patterns and “idiomatic” Go (by simultaneously being both positive and negative examples of it).</p><p>Consider the changing signature of the <code class="code">proto.Unmarshal</code> function as an example of Go language and library evolution throughout the life of this project:</p><pre class="code"><span class="com">// 2007/09/25 - Conception of Go</span><span class="pln"> </span><span class="com">// 2008/11/12</span><span class="pln"> export func UnMarshal(r io.Read, pb_e reflect.Empty) *os.Error </span><span class="com">// 2008/11/13</span><span class="pln"> export func UnMarshal(buf *[]byte, pb_e reflect.Empty) *os.Error </span><span class="com">// 2008/11/24</span><span class="pln"> export func UnMarshal(buf *[]byte, pb_e interface{}) *os.Error </span><span class="com">// 2008/12/18</span><span class="pln"> export func UnMarshal(buf []byte, pb_e interface{}) *os.Error </span><span class="com">// 2009/01/20</span><span class="pln"> func UnMarshal(buf []byte, pb_e interface{}) *os.Error </span><span class="com">// 2009/04/17</span><span class="pln"> func UnMarshal(buf []byte, pb_e interface{}) os.Error </span><span class="com">// 2009/05/22</span><span class="pln"> func Unmarshal(buf []byte, pb_e interface{}) os.Error </span><span class="com">// 2011/11/03</span><span class="pln"> func Unmarshal(buf []byte, pb_e interface{}) error </span><span class="com">// 2012/03/28 - Release of Go 1</span><span class="pln"> </span><span class="com">// 2012/06/12</span><span class="pln"> func Unmarshal(buf []byte, pb Message) error </span></pre><p>These changes demonstrate the difficulty of determining what the right API is for any new technology. It takes time multiplied by many users to determine what is best; even then, “best” is often still somewhere over the horizon.</p><p>The change on June 6th, 2012 added a degree of type-safety to Go protobufs by declaring a new interface that all protobuf messages were required to implement:</p><pre class="code"><span class="pln">type Message interface { Reset() String() string ProtoMessage() } </span></pre><p>This interface reduced the set of types that can be passed to <code class="code">proto.Unmarshal</code> from the universal set of all possible Go types to those with a special <code class="code">ProtoMessage</code> marker method. The intention of this change is to limit the protobuf API to only operate on protobuf data types (i.e., protobuf messages). For example, there is no sensible operation if a Go channel were passed to the protobuf API as a channel cannot be serialized. The restricted interface would prevent that.</p><p>This interface does not behaviorally describe what a protobuf message is, but acts as a marker with an undocumented expectation that protobuf messages must be a Go struct with a specific layout of fields with formatted tags. This expectation is not statically enforced by the Go language, for it is an implementation detail checked dynamically at runtime using Go reflection. Back in 2012, the only types with this marker were those generated by <code class="code">protoc-gen-go</code>. Since <code class="code">protoc-gen-go</code> would always generate messages with the proper layout of fields, this was deemed an acceptable and dramatic improvement over <code class="code">interface{}</code>.</p><p>Over the next 10 years, <a href="https://blog.golang.org/10years">use of Go would skyrocket</a> and use of protobufs in Go would skyrocket as well. With increased popularity also came more diverse usages and requirements for Go protobufs and an increased number of custom <code class="code">proto.Message</code> implementations that were not generated by <code class="code">protoc-gen-go</code>.</p><p>The increasingly diverse ecosystem of Go types implementing the <code class="code">proto.Message</code> interface led to incompatibilities, which often occurred when:</p><ul><li><p><strong>Passing custom <code class="code">proto.Message</code> types to the protobuf APIs</strong>: A concrete message implementation might work with some top-level functions (e.g., <code class="code">proto.Marshal</code>), but cause others (e.g., <code class="code">proto.Equal</code>) to choke and panic. This occurs because the type only had partial support for being an actual message by only implementing the <code class="code">proto.Marshaler</code> interface or having malformed struct field tags that happened to work with one function, but not another.</p></li><li><p><strong>Using Go reflection on any <code class="code">proto.Message</code> types</strong>: A common desire is to write general-purpose code that operates on any protobuf message. For example, a microservice might want to populate a <code class="code">trace_id</code> field if it is present in a message. To accomplish this, one would use Go reflection to introspect the message type, and assume it were a pointer to a Go struct with a field named <code class="code">TraceId</code> (as would be commonly produced by <code class="code">protoc-gen-go</code>). If the concrete message type did not match this expectation, it either failed to work or even resulted in a panic. Such was the case for concrete message types that might be backed by a Go map instead of a Go struct.</p></li></ul><p>Both of these issues are solved by following the idiom that <em>interfaces should describe behavior, not data</em>. This means that the interface itself should provide sufficient functionality through its methods that users can introspect and interact with all aspects of a protobuf message through a principled API. This feature is called <em>protobuf reflection</em>. Just as how Go reflection provides an API for programmatically interacting with any arbitrary Go value, protobuf reflection provides an API for programmatically interacting with any arbitrary protobuf message.</p><p>Since an interface cannot be extended in a backwards compatible way, this suggested the need for a new major version that defines a new <code class="code">proto.Message</code> interface:</p><pre class="code"><span class="pln">type Message interface { ProtoReflect() protoreflect.Message } </span></pre><p>The new <a href="https://pkg.go.dev/google.golang.org/protobuf/proto?tab=doc#Message"><code class="code">proto.Message</code></a> interface contains a single <code class="code">ProtoReflect</code> method that returns a <a href="https://pkg.go.dev/google.golang.org/protobuf/reflect/protoreflect?tab=doc#Message"><code class="code">protoreflect.Message</code></a>, which is a reflective view over a protobuf message. In addition to making a breaking change to the <code class="code">proto.Message</code> interface, we took this opportunity to cleanup the supporting functionality that operate on a <code class="code">proto.Message</code>, split up complicated functionality apart into manageable packages, and to hide implementation details away from the public API.</p><p>The goal for this major revision is to improve upon all the benefits of, while addressing all the shortcomings of the old API. We hope that it will serve the Go ecosystem well for the next 10 years and beyond.</p></div></div></div></div> <!-- Container --></div> <!-- Site-content --><footer class="Site-footer"><div class="Footer"><span class="Footer-poweredBy">Powered by <a href="https://gerrit.googlesource.com/gitiles/">Gitiles</a>| <a href="https://policies.google.com/privacy">Privacy</a>| <a href="https://policies.google.com/terms">Terms</a></span><span class="Footer-formats"><a class="u-monospace Footer-formatsItem" href="?format=TEXT">txt</a> <a class="u-monospace Footer-formatsItem" href="?format=JSON">json</a></span></div></footer></body></html><script nonce="RKjesGgTVaXpxuNopLj_Xw">{let f = document.getElementById("clone-repo-input"); f.onclick = () => {f.focus(); if (f.selectionStart === f.selectionEnd) {f.select();}};}</script>