pax_global_header00006660000000000000000000000064136107034120014507gustar00rootroot0000000000000052 comment=7bc5445566f0fe75b15de23e6b93886e982d7bf9 golang-github-prometheus-client-model-0.2.0/000077500000000000000000000000001361070341200210005ustar00rootroot00000000000000golang-github-prometheus-client-model-0.2.0/.gitignore000066400000000000000000000000101361070341200227570ustar00rootroot00000000000000target/ golang-github-prometheus-client-model-0.2.0/CONTRIBUTING.md000066400000000000000000000006521361070341200232340ustar00rootroot00000000000000# Contributing This repository is deprecated. It is only used for specific purposes by the [Go instrumentation library](https://github.com/prometheus/client_golang). Therefore, contributions to this repository are only expected to happen as required by changes in the instrumentation library. Please see [CONTRIBUTING.md](https://github.com/prometheus/client_golang/blob/master/CONTRIBUTING.md) of the latter for details. golang-github-prometheus-client-model-0.2.0/LICENSE000066400000000000000000000261351361070341200220140ustar00rootroot00000000000000 Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. golang-github-prometheus-client-model-0.2.0/MAINTAINERS.md000066400000000000000000000000601361070341200230700ustar00rootroot00000000000000* Björn Rabenstein @beorn7 golang-github-prometheus-client-model-0.2.0/Makefile000066400000000000000000000014471361070341200224460ustar00rootroot00000000000000# Copyright 2013 Prometheus Team # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. KEY_ID ?= _DEFINE_ME_ all: go SUFFIXES: go: go/metrics.pb.go go/metrics.pb.go: metrics.proto protoc $< --go_out=import_path=github.com/prometheus/client_model/,paths=source_relative:go/ clean: -rm -rf go/* .PHONY: all clean go golang-github-prometheus-client-model-0.2.0/NOTICE000066400000000000000000000002471361070341200217070ustar00rootroot00000000000000Data model artifacts for Prometheus. Copyright 2012-2015 The Prometheus Authors This product includes software developed at SoundCloud Ltd. (http://soundcloud.com/). golang-github-prometheus-client-model-0.2.0/README.md000066400000000000000000000036351361070341200222660ustar00rootroot00000000000000# Deprecation note This repository used to contain the [protocol buffer](https://developers.google.com/protocol-buffers) code that defined both the data model and the exposition format of Prometheus metrics. Starting with v2.0.0, the [Prometheus server](https://github.com/prometheus/prometheus) does not ingest the protobuf-based exposition format anymore. Currently, all but one of the [official instrumentation libraries](https://prometheus.io/docs/instrumenting/clientlibs/) do not expose the protobuf-based exposition format. The [Go instrumentation library](https://github.com/prometheus/client_golang), however, has been built around the protobuf-based data model. As a byproduct thereof, it is still able to expose the protobuf-based exposition format. The Go instrumentation library is the only remaining repository within the [Prometheus GitHub org](https://github.com/prometheus) directly using the prometheus/client_model repository. Therefore, formerly existing support for languages other than Go (namely C++, Java, Python, Ruby) has been removed from this repository. If you are a 3rd party user of those languages, you can go back to [commit 14fe0d1](https://github.com/prometheus/client_model/commit/14fe0d1b01d4d5fc031dd4bec1823bd3ebbe8016) to keep using the old code, or you can consume [`metrics.proto`](https://github.com/prometheus/client_model/blob/master/metrics.proto) directly with your own protobuf tooling. Note, however, that changes of `metrics.proto` after [commit 14fe0d1](https://github.com/prometheus/client_model/commit/14fe0d1b01d4d5fc031dd4bec1823bd3ebbe8016) are solely informed by requirements of the Go instrumentation library and will not take into account any requirements of other languages or stability concerns for the protobuf-based exposition format. Check out the [OpenMetrics project](https://openmetrics.io/) for the future of the data model and exposition format used by Prometheus and others. golang-github-prometheus-client-model-0.2.0/go.mod000066400000000000000000000002441361070341200221060ustar00rootroot00000000000000module github.com/prometheus/client_model go 1.9 require ( github.com/golang/protobuf v1.2.0 golang.org/x/sync v0.0.0-20181108010431-42b317875d0f // indirect ) golang-github-prometheus-client-model-0.2.0/go.sum000066400000000000000000000005741361070341200221410ustar00rootroot00000000000000github.com/golang/protobuf v1.2.0 h1:P3YflyNX/ehuJFLhxviNdFxQPkGK5cDcApsge1SqnvM= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f h1:Bl/8QSvNqXvPGPGXa2z5xUTmV7VDcZyvRZ+QQXkXTZQ= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang-github-prometheus-client-model-0.2.0/go/000077500000000000000000000000001361070341200214055ustar00rootroot00000000000000golang-github-prometheus-client-model-0.2.0/go/metrics.pb.go000066400000000000000000000567531361070341200240220ustar00rootroot00000000000000// Code generated by protoc-gen-go. DO NOT EDIT. // source: metrics.proto package io_prometheus_client import ( fmt "fmt" proto "github.com/golang/protobuf/proto" timestamp "github.com/golang/protobuf/ptypes/timestamp" math "math" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package type MetricType int32 const ( MetricType_COUNTER MetricType = 0 MetricType_GAUGE MetricType = 1 MetricType_SUMMARY MetricType = 2 MetricType_UNTYPED MetricType = 3 MetricType_HISTOGRAM MetricType = 4 ) var MetricType_name = map[int32]string{ 0: "COUNTER", 1: "GAUGE", 2: "SUMMARY", 3: "UNTYPED", 4: "HISTOGRAM", } var MetricType_value = map[string]int32{ "COUNTER": 0, "GAUGE": 1, "SUMMARY": 2, "UNTYPED": 3, "HISTOGRAM": 4, } func (x MetricType) Enum() *MetricType { p := new(MetricType) *p = x return p } func (x MetricType) String() string { return proto.EnumName(MetricType_name, int32(x)) } func (x *MetricType) UnmarshalJSON(data []byte) error { value, err := proto.UnmarshalJSONEnum(MetricType_value, data, "MetricType") if err != nil { return err } *x = MetricType(value) return nil } func (MetricType) EnumDescriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{0} } type LabelPair struct { Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` Value *string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *LabelPair) Reset() { *m = LabelPair{} } func (m *LabelPair) String() string { return proto.CompactTextString(m) } func (*LabelPair) ProtoMessage() {} func (*LabelPair) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{0} } func (m *LabelPair) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_LabelPair.Unmarshal(m, b) } func (m *LabelPair) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_LabelPair.Marshal(b, m, deterministic) } func (m *LabelPair) XXX_Merge(src proto.Message) { xxx_messageInfo_LabelPair.Merge(m, src) } func (m *LabelPair) XXX_Size() int { return xxx_messageInfo_LabelPair.Size(m) } func (m *LabelPair) XXX_DiscardUnknown() { xxx_messageInfo_LabelPair.DiscardUnknown(m) } var xxx_messageInfo_LabelPair proto.InternalMessageInfo func (m *LabelPair) GetName() string { if m != nil && m.Name != nil { return *m.Name } return "" } func (m *LabelPair) GetValue() string { if m != nil && m.Value != nil { return *m.Value } return "" } type Gauge struct { Value *float64 `protobuf:"fixed64,1,opt,name=value" json:"value,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Gauge) Reset() { *m = Gauge{} } func (m *Gauge) String() string { return proto.CompactTextString(m) } func (*Gauge) ProtoMessage() {} func (*Gauge) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{1} } func (m *Gauge) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Gauge.Unmarshal(m, b) } func (m *Gauge) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Gauge.Marshal(b, m, deterministic) } func (m *Gauge) XXX_Merge(src proto.Message) { xxx_messageInfo_Gauge.Merge(m, src) } func (m *Gauge) XXX_Size() int { return xxx_messageInfo_Gauge.Size(m) } func (m *Gauge) XXX_DiscardUnknown() { xxx_messageInfo_Gauge.DiscardUnknown(m) } var xxx_messageInfo_Gauge proto.InternalMessageInfo func (m *Gauge) GetValue() float64 { if m != nil && m.Value != nil { return *m.Value } return 0 } type Counter struct { Value *float64 `protobuf:"fixed64,1,opt,name=value" json:"value,omitempty"` Exemplar *Exemplar `protobuf:"bytes,2,opt,name=exemplar" json:"exemplar,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Counter) Reset() { *m = Counter{} } func (m *Counter) String() string { return proto.CompactTextString(m) } func (*Counter) ProtoMessage() {} func (*Counter) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{2} } func (m *Counter) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Counter.Unmarshal(m, b) } func (m *Counter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Counter.Marshal(b, m, deterministic) } func (m *Counter) XXX_Merge(src proto.Message) { xxx_messageInfo_Counter.Merge(m, src) } func (m *Counter) XXX_Size() int { return xxx_messageInfo_Counter.Size(m) } func (m *Counter) XXX_DiscardUnknown() { xxx_messageInfo_Counter.DiscardUnknown(m) } var xxx_messageInfo_Counter proto.InternalMessageInfo func (m *Counter) GetValue() float64 { if m != nil && m.Value != nil { return *m.Value } return 0 } func (m *Counter) GetExemplar() *Exemplar { if m != nil { return m.Exemplar } return nil } type Quantile struct { Quantile *float64 `protobuf:"fixed64,1,opt,name=quantile" json:"quantile,omitempty"` Value *float64 `protobuf:"fixed64,2,opt,name=value" json:"value,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Quantile) Reset() { *m = Quantile{} } func (m *Quantile) String() string { return proto.CompactTextString(m) } func (*Quantile) ProtoMessage() {} func (*Quantile) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{3} } func (m *Quantile) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Quantile.Unmarshal(m, b) } func (m *Quantile) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Quantile.Marshal(b, m, deterministic) } func (m *Quantile) XXX_Merge(src proto.Message) { xxx_messageInfo_Quantile.Merge(m, src) } func (m *Quantile) XXX_Size() int { return xxx_messageInfo_Quantile.Size(m) } func (m *Quantile) XXX_DiscardUnknown() { xxx_messageInfo_Quantile.DiscardUnknown(m) } var xxx_messageInfo_Quantile proto.InternalMessageInfo func (m *Quantile) GetQuantile() float64 { if m != nil && m.Quantile != nil { return *m.Quantile } return 0 } func (m *Quantile) GetValue() float64 { if m != nil && m.Value != nil { return *m.Value } return 0 } type Summary struct { SampleCount *uint64 `protobuf:"varint,1,opt,name=sample_count,json=sampleCount" json:"sample_count,omitempty"` SampleSum *float64 `protobuf:"fixed64,2,opt,name=sample_sum,json=sampleSum" json:"sample_sum,omitempty"` Quantile []*Quantile `protobuf:"bytes,3,rep,name=quantile" json:"quantile,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Summary) Reset() { *m = Summary{} } func (m *Summary) String() string { return proto.CompactTextString(m) } func (*Summary) ProtoMessage() {} func (*Summary) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{4} } func (m *Summary) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Summary.Unmarshal(m, b) } func (m *Summary) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Summary.Marshal(b, m, deterministic) } func (m *Summary) XXX_Merge(src proto.Message) { xxx_messageInfo_Summary.Merge(m, src) } func (m *Summary) XXX_Size() int { return xxx_messageInfo_Summary.Size(m) } func (m *Summary) XXX_DiscardUnknown() { xxx_messageInfo_Summary.DiscardUnknown(m) } var xxx_messageInfo_Summary proto.InternalMessageInfo func (m *Summary) GetSampleCount() uint64 { if m != nil && m.SampleCount != nil { return *m.SampleCount } return 0 } func (m *Summary) GetSampleSum() float64 { if m != nil && m.SampleSum != nil { return *m.SampleSum } return 0 } func (m *Summary) GetQuantile() []*Quantile { if m != nil { return m.Quantile } return nil } type Untyped struct { Value *float64 `protobuf:"fixed64,1,opt,name=value" json:"value,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Untyped) Reset() { *m = Untyped{} } func (m *Untyped) String() string { return proto.CompactTextString(m) } func (*Untyped) ProtoMessage() {} func (*Untyped) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{5} } func (m *Untyped) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Untyped.Unmarshal(m, b) } func (m *Untyped) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Untyped.Marshal(b, m, deterministic) } func (m *Untyped) XXX_Merge(src proto.Message) { xxx_messageInfo_Untyped.Merge(m, src) } func (m *Untyped) XXX_Size() int { return xxx_messageInfo_Untyped.Size(m) } func (m *Untyped) XXX_DiscardUnknown() { xxx_messageInfo_Untyped.DiscardUnknown(m) } var xxx_messageInfo_Untyped proto.InternalMessageInfo func (m *Untyped) GetValue() float64 { if m != nil && m.Value != nil { return *m.Value } return 0 } type Histogram struct { SampleCount *uint64 `protobuf:"varint,1,opt,name=sample_count,json=sampleCount" json:"sample_count,omitempty"` SampleSum *float64 `protobuf:"fixed64,2,opt,name=sample_sum,json=sampleSum" json:"sample_sum,omitempty"` Bucket []*Bucket `protobuf:"bytes,3,rep,name=bucket" json:"bucket,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Histogram) Reset() { *m = Histogram{} } func (m *Histogram) String() string { return proto.CompactTextString(m) } func (*Histogram) ProtoMessage() {} func (*Histogram) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{6} } func (m *Histogram) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Histogram.Unmarshal(m, b) } func (m *Histogram) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Histogram.Marshal(b, m, deterministic) } func (m *Histogram) XXX_Merge(src proto.Message) { xxx_messageInfo_Histogram.Merge(m, src) } func (m *Histogram) XXX_Size() int { return xxx_messageInfo_Histogram.Size(m) } func (m *Histogram) XXX_DiscardUnknown() { xxx_messageInfo_Histogram.DiscardUnknown(m) } var xxx_messageInfo_Histogram proto.InternalMessageInfo func (m *Histogram) GetSampleCount() uint64 { if m != nil && m.SampleCount != nil { return *m.SampleCount } return 0 } func (m *Histogram) GetSampleSum() float64 { if m != nil && m.SampleSum != nil { return *m.SampleSum } return 0 } func (m *Histogram) GetBucket() []*Bucket { if m != nil { return m.Bucket } return nil } type Bucket struct { CumulativeCount *uint64 `protobuf:"varint,1,opt,name=cumulative_count,json=cumulativeCount" json:"cumulative_count,omitempty"` UpperBound *float64 `protobuf:"fixed64,2,opt,name=upper_bound,json=upperBound" json:"upper_bound,omitempty"` Exemplar *Exemplar `protobuf:"bytes,3,opt,name=exemplar" json:"exemplar,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Bucket) Reset() { *m = Bucket{} } func (m *Bucket) String() string { return proto.CompactTextString(m) } func (*Bucket) ProtoMessage() {} func (*Bucket) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{7} } func (m *Bucket) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Bucket.Unmarshal(m, b) } func (m *Bucket) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Bucket.Marshal(b, m, deterministic) } func (m *Bucket) XXX_Merge(src proto.Message) { xxx_messageInfo_Bucket.Merge(m, src) } func (m *Bucket) XXX_Size() int { return xxx_messageInfo_Bucket.Size(m) } func (m *Bucket) XXX_DiscardUnknown() { xxx_messageInfo_Bucket.DiscardUnknown(m) } var xxx_messageInfo_Bucket proto.InternalMessageInfo func (m *Bucket) GetCumulativeCount() uint64 { if m != nil && m.CumulativeCount != nil { return *m.CumulativeCount } return 0 } func (m *Bucket) GetUpperBound() float64 { if m != nil && m.UpperBound != nil { return *m.UpperBound } return 0 } func (m *Bucket) GetExemplar() *Exemplar { if m != nil { return m.Exemplar } return nil } type Exemplar struct { Label []*LabelPair `protobuf:"bytes,1,rep,name=label" json:"label,omitempty"` Value *float64 `protobuf:"fixed64,2,opt,name=value" json:"value,omitempty"` Timestamp *timestamp.Timestamp `protobuf:"bytes,3,opt,name=timestamp" json:"timestamp,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Exemplar) Reset() { *m = Exemplar{} } func (m *Exemplar) String() string { return proto.CompactTextString(m) } func (*Exemplar) ProtoMessage() {} func (*Exemplar) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{8} } func (m *Exemplar) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Exemplar.Unmarshal(m, b) } func (m *Exemplar) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Exemplar.Marshal(b, m, deterministic) } func (m *Exemplar) XXX_Merge(src proto.Message) { xxx_messageInfo_Exemplar.Merge(m, src) } func (m *Exemplar) XXX_Size() int { return xxx_messageInfo_Exemplar.Size(m) } func (m *Exemplar) XXX_DiscardUnknown() { xxx_messageInfo_Exemplar.DiscardUnknown(m) } var xxx_messageInfo_Exemplar proto.InternalMessageInfo func (m *Exemplar) GetLabel() []*LabelPair { if m != nil { return m.Label } return nil } func (m *Exemplar) GetValue() float64 { if m != nil && m.Value != nil { return *m.Value } return 0 } func (m *Exemplar) GetTimestamp() *timestamp.Timestamp { if m != nil { return m.Timestamp } return nil } type Metric struct { Label []*LabelPair `protobuf:"bytes,1,rep,name=label" json:"label,omitempty"` Gauge *Gauge `protobuf:"bytes,2,opt,name=gauge" json:"gauge,omitempty"` Counter *Counter `protobuf:"bytes,3,opt,name=counter" json:"counter,omitempty"` Summary *Summary `protobuf:"bytes,4,opt,name=summary" json:"summary,omitempty"` Untyped *Untyped `protobuf:"bytes,5,opt,name=untyped" json:"untyped,omitempty"` Histogram *Histogram `protobuf:"bytes,7,opt,name=histogram" json:"histogram,omitempty"` TimestampMs *int64 `protobuf:"varint,6,opt,name=timestamp_ms,json=timestampMs" json:"timestamp_ms,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Metric) Reset() { *m = Metric{} } func (m *Metric) String() string { return proto.CompactTextString(m) } func (*Metric) ProtoMessage() {} func (*Metric) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{9} } func (m *Metric) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Metric.Unmarshal(m, b) } func (m *Metric) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Metric.Marshal(b, m, deterministic) } func (m *Metric) XXX_Merge(src proto.Message) { xxx_messageInfo_Metric.Merge(m, src) } func (m *Metric) XXX_Size() int { return xxx_messageInfo_Metric.Size(m) } func (m *Metric) XXX_DiscardUnknown() { xxx_messageInfo_Metric.DiscardUnknown(m) } var xxx_messageInfo_Metric proto.InternalMessageInfo func (m *Metric) GetLabel() []*LabelPair { if m != nil { return m.Label } return nil } func (m *Metric) GetGauge() *Gauge { if m != nil { return m.Gauge } return nil } func (m *Metric) GetCounter() *Counter { if m != nil { return m.Counter } return nil } func (m *Metric) GetSummary() *Summary { if m != nil { return m.Summary } return nil } func (m *Metric) GetUntyped() *Untyped { if m != nil { return m.Untyped } return nil } func (m *Metric) GetHistogram() *Histogram { if m != nil { return m.Histogram } return nil } func (m *Metric) GetTimestampMs() int64 { if m != nil && m.TimestampMs != nil { return *m.TimestampMs } return 0 } type MetricFamily struct { Name *string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` Help *string `protobuf:"bytes,2,opt,name=help" json:"help,omitempty"` Type *MetricType `protobuf:"varint,3,opt,name=type,enum=io.prometheus.client.MetricType" json:"type,omitempty"` Metric []*Metric `protobuf:"bytes,4,rep,name=metric" json:"metric,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *MetricFamily) Reset() { *m = MetricFamily{} } func (m *MetricFamily) String() string { return proto.CompactTextString(m) } func (*MetricFamily) ProtoMessage() {} func (*MetricFamily) Descriptor() ([]byte, []int) { return fileDescriptor_6039342a2ba47b72, []int{10} } func (m *MetricFamily) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_MetricFamily.Unmarshal(m, b) } func (m *MetricFamily) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_MetricFamily.Marshal(b, m, deterministic) } func (m *MetricFamily) XXX_Merge(src proto.Message) { xxx_messageInfo_MetricFamily.Merge(m, src) } func (m *MetricFamily) XXX_Size() int { return xxx_messageInfo_MetricFamily.Size(m) } func (m *MetricFamily) XXX_DiscardUnknown() { xxx_messageInfo_MetricFamily.DiscardUnknown(m) } var xxx_messageInfo_MetricFamily proto.InternalMessageInfo func (m *MetricFamily) GetName() string { if m != nil && m.Name != nil { return *m.Name } return "" } func (m *MetricFamily) GetHelp() string { if m != nil && m.Help != nil { return *m.Help } return "" } func (m *MetricFamily) GetType() MetricType { if m != nil && m.Type != nil { return *m.Type } return MetricType_COUNTER } func (m *MetricFamily) GetMetric() []*Metric { if m != nil { return m.Metric } return nil } func init() { proto.RegisterEnum("io.prometheus.client.MetricType", MetricType_name, MetricType_value) proto.RegisterType((*LabelPair)(nil), "io.prometheus.client.LabelPair") proto.RegisterType((*Gauge)(nil), "io.prometheus.client.Gauge") proto.RegisterType((*Counter)(nil), "io.prometheus.client.Counter") proto.RegisterType((*Quantile)(nil), "io.prometheus.client.Quantile") proto.RegisterType((*Summary)(nil), "io.prometheus.client.Summary") proto.RegisterType((*Untyped)(nil), "io.prometheus.client.Untyped") proto.RegisterType((*Histogram)(nil), "io.prometheus.client.Histogram") proto.RegisterType((*Bucket)(nil), "io.prometheus.client.Bucket") proto.RegisterType((*Exemplar)(nil), "io.prometheus.client.Exemplar") proto.RegisterType((*Metric)(nil), "io.prometheus.client.Metric") proto.RegisterType((*MetricFamily)(nil), "io.prometheus.client.MetricFamily") } func init() { proto.RegisterFile("metrics.proto", fileDescriptor_6039342a2ba47b72) } var fileDescriptor_6039342a2ba47b72 = []byte{ // 665 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcd, 0x6e, 0xd3, 0x4c, 0x14, 0xfd, 0xdc, 0x38, 0x3f, 0xbe, 0x69, 0x3f, 0xa2, 0x51, 0x17, 0x56, 0xa1, 0x24, 0x78, 0x55, 0x58, 0x38, 0xa2, 0x6a, 0x05, 0x2a, 0xb0, 0x68, 0x4b, 0x48, 0x91, 0x48, 0x5b, 0x26, 0xc9, 0xa2, 0xb0, 0x88, 0x1c, 0x77, 0x70, 0x2c, 0x3c, 0xb1, 0xb1, 0x67, 0x2a, 0xb2, 0x66, 0xc1, 0x16, 0x5e, 0x81, 0x17, 0x05, 0xcd, 0x8f, 0x6d, 0x2a, 0xb9, 0x95, 0x40, 0xec, 0x66, 0xee, 0x3d, 0xe7, 0xfa, 0xcc, 0xf8, 0x9c, 0x81, 0x0d, 0x4a, 0x58, 0x1a, 0xfa, 0x99, 0x9b, 0xa4, 0x31, 0x8b, 0xd1, 0x66,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 0x00, 0x00, 0x00, 0xff, 0xff, 0xd0, 0x84, 0x91, 0x73, 0x59, 0x06, 0x00, 0x00, } golang-github-prometheus-client-model-0.2.0/metrics.proto000066400000000000000000000046341361070341200235420ustar00rootroot00000000000000// Copyright 2013 Prometheus Team // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. syntax = "proto2"; package io.prometheus.client; option java_package = "io.prometheus.client"; option go_package = "github.com/prometheus/client_model/go;io_prometheus_client"; import "google/protobuf/timestamp.proto"; message LabelPair { optional string name = 1; optional string value = 2; } enum MetricType { COUNTER = 0; GAUGE = 1; SUMMARY = 2; UNTYPED = 3; HISTOGRAM = 4; } message Gauge { optional double value = 1; } message Counter { optional double value = 1; optional Exemplar exemplar = 2; } message Quantile { optional double quantile = 1; optional double value = 2; } message Summary { optional uint64 sample_count = 1; optional double sample_sum = 2; repeated Quantile quantile = 3; } message Untyped { optional double value = 1; } message Histogram { optional uint64 sample_count = 1; optional double sample_sum = 2; repeated Bucket bucket = 3; // Ordered in increasing order of upper_bound, +Inf bucket is optional. } message Bucket { optional uint64 cumulative_count = 1; // Cumulative in increasing order. optional double upper_bound = 2; // Inclusive. optional Exemplar exemplar = 3; } message Exemplar { repeated LabelPair label = 1; optional double value = 2; optional google.protobuf.Timestamp timestamp = 3; // OpenMetrics-style. } message Metric { repeated LabelPair label = 1; optional Gauge gauge = 2; optional Counter counter = 3; optional Summary summary = 4; optional Untyped untyped = 5; optional Histogram histogram = 7; optional int64 timestamp_ms = 6; } message MetricFamily { optional string name = 1; optional string help = 2; optional MetricType type = 3; repeated Metric metric = 4; }