From 1e5388dbe994598ce5c1b830880784708099ec5d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kuba=20Podg=C3=B3rski?= Date: Mon, 22 Mar 2021 20:06:14 +0100 Subject: [PATCH] Move internals proto files into separate package (pb) --- Makefile | 2 +- attr.go | 22 +- client/batch_test.go | 4 +- client/client.go | 78 ++-- client/client_internal_it_test.go | 4 +- client/client_it_test.go | 32 +- client/client_test.go | 44 +- client/cluster.go | 39 +- client/cluster_test.go | 39 +- client/csv/csv_it_test.go | 40 +- client/doc.go | 39 +- client/error.go | 36 +- client/orm.go | 39 +- client/orm_test.go | 39 +- client/record.go | 39 +- client/record_test.go | 39 +- client/response.go | 57 +-- client/response_test.go | 79 ++-- client/shardnodes.go | 17 + client/tracer.go | 39 +- client/validate.go | 39 +- client/validate_test.go | 39 +- client/version.go | 17 + ctl/inspect.go | 4 +- encoding/proto/proto.go | 674 +++++++++++++++--------------- executor.go | 180 ++++---- fragment.go | 10 +- go.mod | 2 - go.sum | 4 - internal/LICENSE | 202 --------- internal/internal.go => pb/pb.go | 2 +- {internal => pb}/private.pb.go | 282 +++++++------ {internal => pb}/private.proto | 2 +- {internal => pb}/public.pb.go | 319 +++++++------- {internal => pb}/public.proto | 2 +- 35 files changed, 1057 insertions(+), 1448 deletions(-) delete mode 100644 internal/LICENSE rename internal/internal.go => pb/pb.go (98%) rename {internal => pb}/private.pb.go (95%) rename {internal => pb}/private.proto (99%) rename {internal => pb}/public.pb.go (95%) rename {internal => pb}/public.proto (99%) diff --git a/Makefile b/Makefile index 966ffe755..dd9b03606 100644 --- a/Makefile +++ b/Makefile @@ -163,7 +163,7 @@ upgrade-lattice: lattice # `go generate` protocol buffers generate-protoc: require-protoc require-protoc-gen-gofast - $(GO) generate github.com/pilosa/pilosa/v2/internal + $(GO) generate github.com/pilosa/pilosa/v2/pb # `go generate` statik assets (lattice UI) generate-statik: build-lattice require-statik diff --git a/attr.go b/attr.go index 3502688d1..66667f806 100644 --- a/attr.go +++ b/attr.go @@ -19,7 +19,7 @@ import ( "sort" "github.com/gogo/protobuf/proto" - "github.com/pilosa/pilosa/v2/internal" + "github.com/pilosa/pilosa/v2/pb" ) // Attribute data type enum. @@ -119,21 +119,21 @@ func (a attrBlocks) Diff(other []AttrBlock) []uint64 { } } -func encodeAttrs(m map[string]interface{}) []*internal.Attr { +func encodeAttrs(m map[string]interface{}) []*pb.Attr { keys := make([]string, 0, len(m)) for k := range m { keys = append(keys, k) } sort.Strings(keys) - a := make([]*internal.Attr, len(keys)) + a := make([]*pb.Attr, len(keys)) for i := range keys { a[i] = encodeAttr(keys[i], m[keys[i]]) } return a } -func decodeAttrs(pb []*internal.Attr) map[string]interface{} { +func decodeAttrs(pb []*pb.Attr) map[string]interface{} { m := make(map[string]interface{}, len(pb)) for i := range pb { key, value := decodeAttr(pb[i]) @@ -142,9 +142,9 @@ func decodeAttrs(pb []*internal.Attr) map[string]interface{} { return m } -// encodeAttr converts a key/value pair into an Attr internal representation. -func encodeAttr(key string, value interface{}) *internal.Attr { - pb := &internal.Attr{Key: key} +// encodeAttr converts a key/value pair into an Attr pb.representation. +func encodeAttr(key string, value interface{}) *pb.Attr { + pb := &pb.Attr{Key: key} switch value := value.(type) { case string: pb.Type = attrTypeString @@ -165,8 +165,8 @@ func encodeAttr(key string, value interface{}) *internal.Attr { return pb } -// decodeAttr converts from an Attr internal representation to a key/value pair. -func decodeAttr(attr *internal.Attr) (key string, value interface{}) { +// decodeAttr converts from an Attr pb.representation to a key/value pair. +func decodeAttr(attr *pb.Attr) (key string, value interface{}) { switch attr.Type { case attrTypeString: return attr.Key, attr.StringValue @@ -192,12 +192,12 @@ func cloneAttrs(m map[string]interface{}) map[string]interface{} { // EncodeAttrs encodes an attribute map into a byte slice. func EncodeAttrs(attr map[string]interface{}) ([]byte, error) { - return proto.Marshal(&internal.AttrMap{Attrs: encodeAttrs(attr)}) + return proto.Marshal(&pb.AttrMap{Attrs: encodeAttrs(attr)}) } // DecodeAttrs decodes a byte slice into an attribute map. func DecodeAttrs(v []byte) (map[string]interface{}, error) { - var pb internal.AttrMap + var pb pb.AttrMap if err := proto.Unmarshal(v, &pb); err != nil { return nil, err } diff --git a/client/batch_test.go b/client/batch_test.go index 8255562eb..69cb6d247 100644 --- a/client/batch_test.go +++ b/client/batch_test.go @@ -1,5 +1,3 @@ -//+build integration - // Copyright 2017 Pilosa Corp. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -14,6 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. +//+build integration + package client import ( diff --git a/client/client.go b/client/client.go index 846daebb4..f3542697e 100644 --- a/client/client.go +++ b/client/client.go @@ -1,35 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client import ( @@ -53,8 +37,8 @@ import ( "github.com/golang/protobuf/proto" //nolint:staticcheck "github.com/opentracing/opentracing-go" "github.com/pilosa/pilosa/v2" - "github.com/pilosa/pilosa/v2/internal" pnet "github.com/pilosa/pilosa/v2/net" + "github.com/pilosa/pilosa/v2/pb" "github.com/pilosa/pilosa/v2/pql" "github.com/pilosa/pilosa/v2/roaring" "github.com/pilosa/pilosa/v2/stats" @@ -323,7 +307,7 @@ func (c *Client) Query(query PQLQuery, options ...interface{}) (*QueryResponse, if err != nil { return nil, err } - iqr := &internal.QueryResponse{} + iqr := &pb.QueryResponse{} err = proto.Unmarshal(respData, iqr) if err != nil { return nil, err @@ -541,7 +525,7 @@ func (c *Client) Import(field *Field, shard uint64, vals, ids []uint64, clear bo // EncodeImport computes the HTTP path and payload for an import // request. It is typically followed by a call to DoImport. func (c *Client) EncodeImport(field *Field, shard uint64, vals, ids []uint64, clear bool) (path string, data []byte, err error) { - msg := &internal.ImportRequest{ + msg := &pb.ImportRequest{ Index: field.index.Name(), IndexCreatedAt: field.index.CreatedAt(), Field: field.Name(), @@ -588,7 +572,7 @@ func (c *Client) DoImport(index string, shard uint64, path string, data []byte) // import-values request. It is typically followed by a call to // DoImportValues. func (c *Client) EncodeImportValues(field *Field, shard uint64, vals []int64, ids []uint64, clear bool) (path string, data []byte, err error) { - msg := &internal.ImportValueRequest{ + msg := &pb.ImportValueRequest{ Index: field.index.Name(), IndexCreatedAt: field.index.CreatedAt(), Field: field.Name(), @@ -632,7 +616,7 @@ func (c *Client) fetchFragmentNodes(indexName string, shard uint64) ([]fragmentN if c.manualFragmentNode != nil { return []fragmentNode{*c.manualFragmentNode}, nil } - path := fmt.Sprintf("/internal/fragment/nodes?shard=%d&index=%s", shard, indexName) + path := fmt.Sprintf("/pb.fragment/nodes?shard=%d&index=%s", shard, indexName) _, body, err := c.HTTPRequest("GET", path, []byte{}, nil) if err != nil { return nil, err @@ -693,14 +677,14 @@ func (c *Client) ImportRoaringBitmap(field *Field, shard uint64, views map[strin } func (c *Client) importRoaringBitmap(uri *pnet.URI, field *Field, shard uint64, views viewImports, options *ImportOptions) error { - protoViews := []*internal.ImportRoaringRequestView{} + protoViews := []*pb.ImportRoaringRequestView{} for name, bmp := range views { buf := &bytes.Buffer{} _, err := bmp.WriteTo(buf) if err != nil { return errors.Wrap(err, "marshalling bitmap") } - protoViews = append(protoViews, &internal.ImportRoaringRequestView{ + protoViews = append(protoViews, &pb.ImportRoaringRequestView{ Name: name, Data: buf.Bytes(), }) @@ -708,7 +692,7 @@ func (c *Client) importRoaringBitmap(uri *pnet.URI, field *Field, shard uint64, params := url.Values{} params.Add("clear", strconv.FormatBool(options.clear)) path := makeRoaringImportPath(field, shard, params) - req := &internal.ImportRoaringRequest{ + req := &pb.ImportRoaringRequest{ Clear: options.clear, Views: protoViews, IndexCreatedAt: field.index.CreatedAt(), @@ -803,14 +787,14 @@ func (c *Client) readSchema() ([]SchemaIndex, error) { } func (c *Client) shardsMax() (map[string]uint64, error) { - _, data, err := c.HTTPRequest("GET", "/internal/shards/max", nil, nil) + _, data, err := c.HTTPRequest("GET", "/pb.shards/max", nil, nil) if err != nil { - return nil, errors.Wrap(err, "requesting /internal/shards/max") + return nil, errors.Wrap(err, "requesting /pb.shards/max") } m := map[string]map[string]uint64{} err = json.Unmarshal(data, &m) if err != nil { - return nil, errors.Wrap(err, "unmarshaling /internal/shards/max data") + return nil, errors.Wrap(err, "unmarshaling /pb.shards/max data") } return m["standard"], nil } @@ -1033,7 +1017,7 @@ func (c *Client) augmentHeaders(headers map[string]string) map[string]string { } func (c *Client) TranslateRowKeys(field *Field, keys []string) ([]uint64, error) { - req := &internal.TranslateKeysRequest{ + req := &pb.TranslateKeysRequest{ Index: field.index.name, Field: field.name, Keys: keys, @@ -1046,7 +1030,7 @@ func (c *Client) TranslateColumnKeys(index *Index, keys []string) ([]uint64, err // point in partitioning the translation request on the client // because every request is going to be sent to the manual URI. if c.manualServerURI != nil { - req := &internal.TranslateKeysRequest{ + req := &pb.TranslateKeysRequest{ Index: index.name, Keys: keys, } @@ -1084,7 +1068,7 @@ func (c *Client) TranslateColumnKeys(index *Index, keys []string) ([]uint64, err uri := uri keys := keys eg.Go(func() error { - req := &internal.TranslateKeysRequest{ + req := &pb.TranslateKeysRequest{ Index: index.name, Keys: keys, } @@ -1150,7 +1134,7 @@ func keyPartition(index, key string, partitionN int) int { return int(h.Sum64() % uint64(partitionN)) } -func (c *Client) translateKeys(req *internal.TranslateKeysRequest, uris ...pnet.URI) ([]uint64, error) { +func (c *Client) translateKeys(req *pb.TranslateKeysRequest, uris ...pnet.URI) ([]uint64, error) { if len(req.Keys) == 0 { return []uint64{}, nil } @@ -1161,16 +1145,16 @@ func (c *Client) translateKeys(req *internal.TranslateKeysRequest, uris ...pnet. var respData []byte if len(uris) == 0 { - if _, respData, err = c.httpRequest("POST", "/internal/translate/keys", reqData, defaultProtobufHeaders(), true); err != nil { + if _, respData, err = c.httpRequest("POST", "/pb.translate/keys", reqData, defaultProtobufHeaders(), true); err != nil { return nil, err } } else { - if _, respData, err = c.doRequest(&uris[0], "POST", "/internal/translate/keys", defaultProtobufHeaders(), reqData); err != nil { - return nil, errors.Wrapf(err, "reading response body of /internal/translate/keys request to %v", uris[0]) + if _, respData, err = c.doRequest(&uris[0], "POST", "/pb.translate/keys", defaultProtobufHeaders(), reqData); err != nil { + return nil, errors.Wrapf(err, "reading response body of /pb.translate/keys request to %v", uris[0]) } } - idsResp := &internal.TranslateKeysResponse{} + idsResp := &pb.TranslateKeysResponse{} err = proto.Unmarshal(respData, idsResp) if err != nil { return nil, errors.Wrap(err, "unmarshalling traslate keys response") @@ -1332,7 +1316,7 @@ func newHTTPClient(options *ClientOptions) *http.Client { } func makeRequestData(query string, options *QueryOptions) ([]byte, error) { - request := &internal.QueryRequest{ + request := &pb.QueryRequest{ Query: query, Shards: options.Shards, ColumnAttrs: options.ColumnAttrs, diff --git a/client/client_internal_it_test.go b/client/client_internal_it_test.go index 8c88384af..977074006 100644 --- a/client/client_internal_it_test.go +++ b/client/client_internal_it_test.go @@ -1,5 +1,3 @@ -//+build integration - // Copyright 2017 Pilosa Corp. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -14,6 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. +//+build integration + package client import ( diff --git a/client/client_it_test.go b/client/client_it_test.go index 8f26bc6ed..08b6ad920 100644 --- a/client/client_it_test.go +++ b/client/client_it_test.go @@ -1,5 +1,3 @@ -//+build integration - // Copyright 2017 Pilosa Corp. // // Licensed under the Apache License, Version 2.0 (the "License"); @@ -14,6 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. +//+build integration + package client import ( @@ -33,8 +33,8 @@ import ( "time" "github.com/golang/protobuf/proto" //nolint:staticcheck - "github.com/pilosa/pilosa/v2/internal" pnet "github.com/pilosa/pilosa/v2/net" + "github.com/pilosa/pilosa/v2/pb" "github.com/pkg/errors" ) @@ -1323,7 +1323,7 @@ func TestImportNodeFails(t *testing.T) { defer server.Close() uri, _ := pnet.NewURIFromAddress(server.URL) client, _ := NewClient(uri, OptClientRetries(0)) - importRequest := &internal.ImportRequest{ + importRequest := &pb.ImportRequest{ ColumnIDs: []uint64{}, RowIDs: []uint64{}, Timestamps: []int64{}, @@ -1353,12 +1353,12 @@ func TestQueryUnmarshalFails(t *testing.T) { } func TestResponseWithInvalidType(t *testing.T) { - qr := &internal.QueryResponse{ + qr := &pb.QueryResponse{ Err: "", - ColumnAttrSets: []*internal.ColumnAttrSet{ + ColumnAttrSets: []*pb.ColumnAttrSet{ { ID: 0, - Attrs: []*internal.Attr{ + Attrs: []*pb.Attr{ { Type: 9999, StringValue: "NOVAL", @@ -1366,7 +1366,7 @@ func TestResponseWithInvalidType(t *testing.T) { }, }, }, - Results: []*internal.QueryResult{}, + Results: []*pb.QueryResult{}, } data, err := proto.Marshal(qr) if err != nil { @@ -1473,7 +1473,7 @@ func TestExportFieldFailure(t *testing.T) { statusCode: 404, contentLength: -1, }, - "/internal/shards/max": { + "/pb.shards/max": { content: []byte(`{"standard":{"go-testindex": 0}}`), statusCode: 404, contentLength: -1, @@ -1493,9 +1493,9 @@ func TestExportFieldFailure(t *testing.T) { if err == nil { t.Fatal("should have failed") } - statusItem = paths["/internal/shards/max"] + statusItem = paths["/pb.shards/max"] statusItem.statusCode = 200 - paths["/internal/shards/max"] = statusItem + paths["/pb.shards/max"] = statusItem _, err = client.ExportField(testField) if err == nil { t.Fatal("should have failed") @@ -1616,7 +1616,7 @@ func TestServerWarning(t *testing.T) { } }() handler := http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { - content, err := proto.Marshal(&internal.QueryResponse{}) + content, err := proto.Marshal(&pb.QueryResponse{}) if err != nil { // Cannot directly interact with t from another goroutine. herr = err @@ -1963,14 +1963,14 @@ func TestImportAtomicRecord(t *testing.T) { transferUSD := int64(100) setBal := func(bal0, bal1 int64) (data []byte, err error) { - ivr0 := &internal.ImportValueRequest{ + ivr0 := &pb.ImportValueRequest{ Index: indexARname, Field: fieldAcct0, Shard: shard, ColumnIDs: []uint64{acctOwnerID}, Values: []int64{bal0}, } - ivr1 := &internal.ImportValueRequest{ + ivr1 := &pb.ImportValueRequest{ Index: indexARname, Field: fieldAcct1, Shard: shard, @@ -1978,10 +1978,10 @@ func TestImportAtomicRecord(t *testing.T) { Values: []int64{bal1}, } - ar := &internal.AtomicRecord{ + ar := &pb.AtomicRecord{ Index: indexARname, Shard: shard, - Ivr: []*internal.ImportValueRequest{ + Ivr: []*pb.ImportValueRequest{ ivr0, ivr1, }, } diff --git a/client/client_test.go b/client/client_test.go index ab737c101..22c615bb4 100644 --- a/client/client_test.go +++ b/client/client_test.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client @@ -38,7 +23,6 @@ import ( "reflect" "testing" - "github.com/pilosa/pilosa/v2" pnet "github.com/pilosa/pilosa/v2/net" ) @@ -161,8 +145,8 @@ func TestNewClientWithInvalidAddr(t *testing.T) { t.Fatalf("should have failed: %+v", err) } _, err = NewClient([]string{"valid:8000", ":invalid"}) - if err != pilosa.ErrInvalidAddress { - t.Fatalf("Should have failed '%v', got '%v'", pilosa.ErrInvalidAddress, err) + if err != pnet.ErrInvalidAddress { + t.Fatalf("Should have failed '%v, got '%v'", pnet.ErrInvalidAddress, err) } } diff --git a/client/cluster.go b/client/cluster.go index 9c66a23b5..4c0df25db 100644 --- a/client/cluster.go +++ b/client/cluster.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client diff --git a/client/cluster_test.go b/client/cluster_test.go index acc8eed05..caf1284f2 100644 --- a/client/cluster_test.go +++ b/client/cluster_test.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client diff --git a/client/csv/csv_it_test.go b/client/csv/csv_it_test.go index 3df6badc9..159b801dd 100644 --- a/client/csv/csv_it_test.go +++ b/client/csv/csv_it_test.go @@ -1,36 +1,18 @@ -//+build integration - // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +//+build integration package csv_test diff --git a/client/doc.go b/client/doc.go index 212642ff1..43ab67b93 100644 --- a/client/doc.go +++ b/client/doc.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. /* Package pilosa enables querying a Pilosa server. diff --git a/client/error.go b/client/error.go index ec9bc7912..ee011bbc7 100644 --- a/client/error.go +++ b/client/error.go @@ -1,34 +1,16 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. package client diff --git a/client/orm.go b/client/orm.go index 71e44bf58..f48c8e2dc 100644 --- a/client/orm.go +++ b/client/orm.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client diff --git a/client/orm_test.go b/client/orm_test.go index 61e2c71d7..57a7d128f 100644 --- a/client/orm_test.go +++ b/client/orm_test.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client diff --git a/client/record.go b/client/record.go index d12ec6a92..9f48cf750 100644 --- a/client/record.go +++ b/client/record.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client diff --git a/client/record_test.go b/client/record_test.go index 8e4d72db4..0bf6ac903 100644 --- a/client/record_test.go +++ b/client/record_test.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client_test diff --git a/client/response.go b/client/response.go index 111286d2a..0ec9382ee 100644 --- a/client/response.go +++ b/client/response.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client @@ -37,7 +22,7 @@ import ( "errors" "fmt" - "github.com/pilosa/pilosa/v2/internal" + "github.com/pilosa/pilosa/v2/pb" ) // QueryResponse types. @@ -65,7 +50,7 @@ type QueryResponse struct { Success bool `json:"success,omitempty"` } -func newQueryResponseFromInternal(response *internal.QueryResponse) (*QueryResponse, error) { +func newQueryResponseFromInternal(response *pb.QueryResponse) (*QueryResponse, error) { if response.Err != "" { return &QueryResponse{ ErrorMessage: response.Err, @@ -142,7 +127,7 @@ type QueryResult interface { RowIdentifiers() RowIdentifiersResult } -func newQueryResultFromInternal(result *internal.QueryResult) (QueryResult, error) { +func newQueryResultFromInternal(result *pb.QueryResult) (QueryResult, error) { switch result.Type { case QueryResultTypeNil: return NilResult{}, nil @@ -222,11 +207,11 @@ func (CountItem) GroupCounts() []GroupCount { return nil } // RowIdentifiers returns the result of a Rows call. func (CountItem) RowIdentifiers() RowIdentifiersResult { return RowIdentifiersResult{} } -func countItemFromInternal(item *internal.Pair) CountResultItem { +func countItemFromInternal(item *pb.Pair) CountResultItem { return CountResultItem{ID: item.ID, Key: item.Key, Count: item.Count} } -func countItemsFromInternal(items []*internal.Pair) TopNResult { +func countItemsFromInternal(items []*pb.Pair) TopNResult { result := make([]CountResultItem, 0, len(items)) for _, v := range items { result = append(result, countItemFromInternal(v)) @@ -276,7 +261,7 @@ type RowResult struct { Keys []string `json:"keys"` } -func newRowResultFromInternal(row *internal.Row) (*RowResult, error) { +func newRowResultFromInternal(row *pb.Row) (*RowResult, error) { attrs, err := convertInternalAttrsToMap(row.Attrs) if err != nil { return nil, err @@ -538,7 +523,7 @@ func (RowIdentifiersResult) GroupCounts() []GroupCount { return nil } // RowIdentifiers returns the result of a Rows call. func (r RowIdentifiersResult) RowIdentifiers() RowIdentifiersResult { return r } -func groupCountsFromInternal(items *internal.GroupCounts) GroupCountResult { +func groupCountsFromInternal(items *pb.GroupCounts) GroupCountResult { result := make([]GroupCount, 0, len(items.Groups)) for _, g := range items.Groups { groups := make([]FieldRow, 0, len(g.Group)) @@ -569,7 +554,7 @@ const ( floatType = 4 ) -func convertInternalAttrsToMap(attrs []*internal.Attr) (attrsMap map[string]interface{}, err error) { +func convertInternalAttrsToMap(attrs []*pb.Attr) (attrsMap map[string]interface{}, err error) { attrsMap = make(map[string]interface{}, len(attrs)) for _, attr := range attrs { switch attr.Type { @@ -597,7 +582,7 @@ type ColumnItem struct { Attributes map[string]interface{} `json:"attributes,omitempty"` } -func newColumnItemFromInternal(column *internal.ColumnAttrSet) (ColumnItem, error) { +func newColumnItemFromInternal(column *pb.ColumnAttrSet) (ColumnItem, error) { attrs, err := convertInternalAttrsToMap(column.Attrs) if err != nil { return ColumnItem{}, err diff --git a/client/response_test.go b/client/response_test.go index 7c228305e..12efdf533 100644 --- a/client/response_test.go +++ b/client/response_test.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client @@ -39,7 +24,7 @@ import ( "reflect" "testing" - "github.com/pilosa/pilosa/v2/internal" + "github.com/pilosa/pilosa/v2/pb" ) func TestNewRowResultFromInternal(t *testing.T) { @@ -50,13 +35,13 @@ func TestNewRowResultFromInternal(t *testing.T) { "height": 1.83, } targetColumns := []uint64{5, 10} - attrs := []*internal.Attr{ + attrs := []*pb.Attr{ {Key: "name", StringValue: "some string", Type: 1}, {Key: "age", IntValue: 95, Type: 2}, {Key: "registered", BoolValue: true, Type: 3}, {Key: "height", FloatValue: 1.83, Type: 4}, } - row := &internal.Row{ + row := &pb.Row{ Attrs: attrs, Columns: []uint64{5, 10}, } @@ -84,21 +69,21 @@ func TestNewQueryResponseFromInternal(t *testing.T) { targetCountItems := []CountResultItem{ {ID: 10, Count: 100}, } - attrs := []*internal.Attr{ + attrs := []*pb.Attr{ {Key: "name", StringValue: "some string", Type: 1}, {Key: "age", IntValue: 95, Type: 2}, {Key: "registered", BoolValue: true, Type: 3}, {Key: "height", FloatValue: 1.83, Type: 4}, } - row := &internal.Row{ + row := &pb.Row{ Attrs: attrs, Columns: []uint64{5, 10}, } - pairs := []*internal.Pair{ + pairs := []*pb.Pair{ {ID: 10, Count: 100}, } - response := &internal.QueryResponse{ - Results: []*internal.QueryResult{ + response := &pb.QueryResponse{ + Results: []*pb.QueryResult{ {Type: QueryResultTypeRow, Row: row}, {Type: QueryResultTypePairs, Pairs: pairs}, }, @@ -134,7 +119,7 @@ func TestNewQueryResponseFromInternal(t *testing.T) { } func TestNewQueryResponseWithErrorFromInternal(t *testing.T) { - response := &internal.QueryResponse{ + response := &pb.QueryResponse{ Err: "some error", } qr, err := newQueryResponseFromInternal(response) @@ -153,21 +138,21 @@ func TestNewQueryResponseWithErrorFromInternal(t *testing.T) { } func TestNewQueryResponseFromInternalFailure(t *testing.T) { - attrs := []*internal.Attr{ + attrs := []*pb.Attr{ {Key: "name", StringValue: "some string", Type: 99}, } - row := &internal.Row{ + row := &pb.Row{ Attrs: attrs, } - response := &internal.QueryResponse{ - Results: []*internal.QueryResult{{Type: QueryResultTypeRow, Row: row}}, + response := &pb.QueryResponse{ + Results: []*pb.QueryResult{{Type: QueryResultTypeRow, Row: row}}, } qr, err := newQueryResponseFromInternal(response) if qr != nil && err == nil { t.Fatalf("Should have failed") } - response = &internal.QueryResponse{ - ColumnAttrSets: []*internal.ColumnAttrSet{{ID: 1, Attrs: attrs}}, + response = &pb.QueryResponse{ + ColumnAttrSets: []*pb.ColumnAttrSet{{ID: 1, Attrs: attrs}}, } qr, err = newQueryResponseFromInternal(response) if qr != nil && err == nil { @@ -197,20 +182,20 @@ func TestCountResultItemToString(t *testing.T) { } func TestMarshalResults(t *testing.T) { - attrs := []*internal.Attr{ + attrs := []*pb.Attr{ {Key: "name", StringValue: "some string", Type: 1}, {Key: "age", IntValue: 95, Type: 2}, {Key: "registered", BoolValue: true, Type: 3}, {Key: "height", FloatValue: 1.83, Type: 4}, } - row := &internal.Row{ + row := &pb.Row{ Attrs: attrs, Columns: []uint64{5, 10}, } - pairs := []*internal.Pair{ + pairs := []*pb.Pair{ {ID: 10, Count: 100}, } - pbufResults := []*internal.QueryResult{ + pbufResults := []*pb.QueryResult{ {Type: QueryResultTypeRow, Row: row}, {Type: QueryResultTypePairs, Pairs: pairs}, } @@ -239,7 +224,7 @@ func TestMarshalResults(t *testing.T) { } func TestUnknownQueryResultType(t *testing.T) { - result := &internal.QueryResult{ + result := &pb.QueryResult{ Type: 999, } _, err := newQueryResultFromInternal(result) diff --git a/client/shardnodes.go b/client/shardnodes.go index 836385c44..a0f0a296f 100644 --- a/client/shardnodes.go +++ b/client/shardnodes.go @@ -1,3 +1,20 @@ +// Copyright 2017 Pilosa Corp. +// +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. + package client import ( diff --git a/client/tracer.go b/client/tracer.go index 660bc0098..f838bd3b6 100644 --- a/client/tracer.go +++ b/client/tracer.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client diff --git a/client/validate.go b/client/validate.go index 7e865c91a..77f89c42c 100644 --- a/client/validate.go +++ b/client/validate.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client diff --git a/client/validate_test.go b/client/validate_test.go index ce07eb7ed..1284ccf10 100644 --- a/client/validate_test.go +++ b/client/validate_test.go @@ -1,34 +1,19 @@ // Copyright 2017 Pilosa Corp. // -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions -// are met: +// 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 // -// 1. Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. +// http://www.apache.org/licenses/LICENSE-2.0 // -// 2. Redistributions in binary form must reproduce the above copyright -// notice, this list of conditions and the following disclaimer in the -// documentation and/or other materials provided with the distribution. -// -// 3. Neither the name of the copyright holder nor the names of its -// contributors may be used to endorse or promote products derived -// from this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND -// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, -// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, -// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -// DAMAGE. +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. package client diff --git a/client/version.go b/client/version.go index cd0017e2a..b3b3a474a 100644 --- a/client/version.go +++ b/client/version.go @@ -1,3 +1,20 @@ +// Copyright 2017 Pilosa Corp. +// +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. + package client // Version is the client version. diff --git a/ctl/inspect.go b/ctl/inspect.go index 09de20370..f20c974c6 100644 --- a/ctl/inspect.go +++ b/ctl/inspect.go @@ -32,7 +32,7 @@ import ( "github.com/gogo/protobuf/proto" "github.com/pilosa/pilosa/v2" - "github.com/pilosa/pilosa/v2/internal" + "github.com/pilosa/pilosa/v2/pb" "github.com/pilosa/pilosa/v2/roaring" "github.com/pkg/errors" ) @@ -234,7 +234,7 @@ func (cmd *InspectCommand) Run(ctx context.Context) error { } // loadTopology is copied almost exactly from pilosa/cluster.go. -func loadTopology(path string) (topology internal.Topology, myID string, err error) { +func loadTopology(path string) (topology pb.Topology, myID string, err error) { buf, err := ioutil.ReadFile(filepath.Join(path, ".topology")) if os.IsNotExist(err) { return topology, myID, err diff --git a/encoding/proto/proto.go b/encoding/proto/proto.go index 9755d5bb6..1fe993501 100644 --- a/encoding/proto/proto.go +++ b/encoding/proto/proto.go @@ -22,8 +22,8 @@ import ( "github.com/gogo/protobuf/proto" "github.com/pilosa/pilosa/v2" "github.com/pilosa/pilosa/v2/disco" - "github.com/pilosa/pilosa/v2/internal" pnet "github.com/pilosa/pilosa/v2/net" + "github.com/pilosa/pilosa/v2/pb" "github.com/pilosa/pilosa/v2/pql" "github.com/pilosa/pilosa/v2/roaring" "github.com/pilosa/pilosa/v2/topology" @@ -52,7 +52,7 @@ func (s Serializer) Marshal(m pilosa.Message) ([]byte, error) { func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { switch mt := m.(type) { case *pilosa.CreateShardMessage: - msg := &internal.CreateShardMessage{} + msg := &pb.CreateShardMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling CreateShardMessage") @@ -60,7 +60,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeCreateShardMessage(msg, mt) return nil case *pilosa.CreateIndexMessage: - msg := &internal.CreateIndexMessage{} + msg := &pb.CreateIndexMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling CreateIndexMessage") @@ -68,7 +68,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeCreateIndexMessage(msg, mt) return nil case *pilosa.DeleteIndexMessage: - msg := &internal.DeleteIndexMessage{} + msg := &pb.DeleteIndexMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling DeleteIndexMessage") @@ -76,7 +76,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeDeleteIndexMessage(msg, mt) return nil case *pilosa.CreateFieldMessage: - msg := &internal.CreateFieldMessage{} + msg := &pb.CreateFieldMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling CreateFieldMessage") @@ -84,7 +84,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeCreateFieldMessage(msg, mt) return nil case *pilosa.DeleteFieldMessage: - msg := &internal.DeleteFieldMessage{} + msg := &pb.DeleteFieldMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling DeleteFieldMessage") @@ -92,7 +92,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeDeleteFieldMessage(msg, mt) return nil case *pilosa.DeleteAvailableShardMessage: - msg := &internal.DeleteAvailableShardMessage{} + msg := &pb.DeleteAvailableShardMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling DeleteAvailableShardMessage") @@ -100,7 +100,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeDeleteAvailableShardMessage(msg, mt) return nil case *pilosa.CreateViewMessage: - msg := &internal.CreateViewMessage{} + msg := &pb.CreateViewMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling CreateViewMessage") @@ -108,7 +108,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeCreateViewMessage(msg, mt) return nil case *pilosa.DeleteViewMessage: - msg := &internal.DeleteViewMessage{} + msg := &pb.DeleteViewMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling DeleteViewMessage") @@ -116,7 +116,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeDeleteViewMessage(msg, mt) return nil case *pilosa.ClusterStatus: - msg := &internal.ClusterStatus{} + msg := &pb.ClusterStatus{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ClusterStatus") @@ -124,7 +124,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeClusterStatus(msg, mt) return nil case *pilosa.ResizeInstruction: - msg := &internal.ResizeInstruction{} + msg := &pb.ResizeInstruction{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ResizeInstruction") @@ -132,7 +132,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeResizeInstruction(msg, mt) return nil case *pilosa.ResizeInstructionComplete: - msg := &internal.ResizeInstructionComplete{} + msg := &pb.ResizeInstructionComplete{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ResizeInstructionComplete") @@ -140,7 +140,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeResizeInstructionComplete(msg, mt) return nil case *pilosa.NodeStateMessage: - msg := &internal.NodeStateMessage{} + msg := &pb.NodeStateMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling NodeStateMessage") @@ -148,7 +148,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeNodeStateMessage(msg, mt) return nil case *pilosa.RecalculateCaches: - msg := &internal.RecalculateCaches{} + msg := &pb.RecalculateCaches{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling RecalculateCaches") @@ -156,7 +156,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeRecalculateCaches(msg, mt) return nil case *pilosa.LoadSchemaMessage: - msg := &internal.LoadSchemaMessage{} + msg := &pb.LoadSchemaMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling LoadSchemaMessage") @@ -164,7 +164,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeLoadSchemaMessage(msg, mt) return nil case *pilosa.NodeEvent: - msg := &internal.NodeEventMessage{} + msg := &pb.NodeEventMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling NodeEvent") @@ -172,7 +172,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeNodeEventMessage(msg, mt) return nil case *pilosa.NodeStatus: - msg := &internal.NodeStatus{} + msg := &pb.NodeStatus{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling NodeStatus") @@ -180,7 +180,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeNodeStatus(msg, mt) return nil case *topology.Node: - msg := &internal.Node{} + msg := &pb.Node{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling Node") @@ -188,7 +188,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeNode(msg, mt) return nil case *pilosa.QueryRequest: - msg := &internal.QueryRequest{} + msg := &pb.QueryRequest{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling QueryRequest") @@ -196,7 +196,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeQueryRequest(msg, mt) return nil case *pilosa.QueryResponse: - msg := &internal.QueryResponse{} + msg := &pb.QueryResponse{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling QueryResponse") @@ -204,7 +204,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeQueryResponse(msg, mt) return nil case *pilosa.ImportRequest: - msg := &internal.ImportRequest{} + msg := &pb.ImportRequest{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ImportRequest") @@ -212,7 +212,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeImportRequest(msg, mt) return nil case *pilosa.ImportValueRequest: - msg := &internal.ImportValueRequest{} + msg := &pb.ImportValueRequest{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ImportValueRequest") @@ -220,7 +220,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeImportValueRequest(msg, mt) return nil case *pilosa.ImportRoaringRequest: - msg := &internal.ImportRoaringRequest{} + msg := &pb.ImportRoaringRequest{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ImportRoaringRequest") @@ -228,7 +228,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeImportRoaringRequest(msg, mt) return nil case *pilosa.ImportColumnAttrsRequest: - msg := &internal.ImportColumnAttrsRequest{} + msg := &pb.ImportColumnAttrsRequest{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ImportColumnAttrsRequest") @@ -236,7 +236,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeImportColumnAttrsRequest(msg, mt) return nil case *pilosa.ImportResponse: - msg := &internal.ImportResponse{} + msg := &pb.ImportResponse{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ImportResponse") @@ -244,7 +244,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeImportResponse(msg, mt) return nil case *pilosa.BlockDataRequest: - msg := &internal.BlockDataRequest{} + msg := &pb.BlockDataRequest{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling BlockDataRequest") @@ -252,7 +252,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeBlockDataRequest(msg, mt) return nil case *pilosa.BlockDataResponse: - msg := &internal.BlockDataResponse{} + msg := &pb.BlockDataResponse{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling BlockDataResponse") @@ -260,7 +260,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeBlockDataResponse(msg, mt) return nil case *pilosa.TranslateKeysRequest: - msg := &internal.TranslateKeysRequest{} + msg := &pb.TranslateKeysRequest{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling TranslateKeysRequest") @@ -268,7 +268,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeTranslateKeysRequest(msg, mt) return nil case *pilosa.TranslateKeysResponse: - msg := &internal.TranslateKeysResponse{} + msg := &pb.TranslateKeysResponse{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling TranslateKeysResponse") @@ -276,7 +276,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeTranslateKeysResponse(msg, mt) return nil case *pilosa.TranslateIDsRequest: - msg := &internal.TranslateIDsRequest{} + msg := &pb.TranslateIDsRequest{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling TranslateIDsRequest") @@ -284,7 +284,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeTranslateIDsRequest(msg, mt) return nil case *pilosa.TranslateIDsResponse: - msg := &internal.TranslateIDsResponse{} + msg := &pb.TranslateIDsResponse{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling TranslateIDsResponse") @@ -292,7 +292,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeTranslateIDsResponse(msg, mt) return nil case *pilosa.TransactionMessage: - msg := &internal.TransactionMessage{} + msg := &pb.TransactionMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling TransactionMessage") @@ -300,7 +300,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { decodeTransactionMessage(msg, mt) return nil case *pilosa.AtomicRecord: - msg := &internal.AtomicRecord{} + msg := &pb.AtomicRecord{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling AtomicRecord") @@ -308,7 +308,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { s.decodeAtomicRecord(msg, mt) return nil case *[]*pilosa.Row: - msg := &internal.RowMatrix{} + msg := &pb.RowMatrix{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling RowMatrix") @@ -317,7 +317,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { return nil case *pilosa.ResizeNodeMessage: - msg := &internal.ResizeNodeMessage{} + msg := &pb.ResizeNodeMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ResizeNodeMessage") @@ -326,7 +326,7 @@ func (s Serializer) Unmarshal(buf []byte, m pilosa.Message) error { return nil case *pilosa.ResizeAbortMessage: - msg := &internal.ResizeAbortMessage{} + msg := &pb.ResizeAbortMessage{} err := proto.Unmarshal(buf, msg) if err != nil { return errors.Wrap(err, "unmarshaling ResizeAbortMessage") @@ -413,8 +413,8 @@ func (s Serializer) encodeToProto(m pilosa.Message) proto.Message { return nil } -func (s Serializer) encodeBlockDataRequest(m *pilosa.BlockDataRequest) *internal.BlockDataRequest { - return &internal.BlockDataRequest{ +func (s Serializer) encodeBlockDataRequest(m *pilosa.BlockDataRequest) *pb.BlockDataRequest { + return &pb.BlockDataRequest{ Index: m.Index, Field: m.Field, View: m.View, @@ -422,21 +422,21 @@ func (s Serializer) encodeBlockDataRequest(m *pilosa.BlockDataRequest) *internal Block: m.Block, } } -func (s Serializer) encodeBlockDataResponse(m *pilosa.BlockDataResponse) *internal.BlockDataResponse { - return &internal.BlockDataResponse{ +func (s Serializer) encodeBlockDataResponse(m *pilosa.BlockDataResponse) *pb.BlockDataResponse { + return &pb.BlockDataResponse{ RowIDs: m.RowIDs, ColumnIDs: m.ColumnIDs, } } -func (s Serializer) encodeImportResponse(m *pilosa.ImportResponse) *internal.ImportResponse { - return &internal.ImportResponse{ +func (s Serializer) encodeImportResponse(m *pilosa.ImportResponse) *pb.ImportResponse { + return &pb.ImportResponse{ Err: m.Err, } } -func (s Serializer) encodeImportRequest(m *pilosa.ImportRequest) *internal.ImportRequest { - return &internal.ImportRequest{ +func (s Serializer) encodeImportRequest(m *pilosa.ImportRequest) *pb.ImportRequest { + return &pb.ImportRequest{ Index: m.Index, Field: m.Field, IndexCreatedAt: m.IndexCreatedAt, @@ -451,8 +451,8 @@ func (s Serializer) encodeImportRequest(m *pilosa.ImportRequest) *internal.Impor } } -func (s Serializer) encodeImportValueRequest(m *pilosa.ImportValueRequest) *internal.ImportValueRequest { - return &internal.ImportValueRequest{ +func (s Serializer) encodeImportValueRequest(m *pilosa.ImportValueRequest) *pb.ImportValueRequest { + return &pb.ImportValueRequest{ Index: m.Index, Field: m.Field, IndexCreatedAt: m.IndexCreatedAt, @@ -467,17 +467,17 @@ func (s Serializer) encodeImportValueRequest(m *pilosa.ImportValueRequest) *inte } } -func (s Serializer) encodeImportRoaringRequest(m *pilosa.ImportRoaringRequest) *internal.ImportRoaringRequest { - views := make([]*internal.ImportRoaringRequestView, len(m.Views)) +func (s Serializer) encodeImportRoaringRequest(m *pilosa.ImportRoaringRequest) *pb.ImportRoaringRequest { + views := make([]*pb.ImportRoaringRequestView, len(m.Views)) i := 0 for viewName, viewData := range m.Views { - views[i] = &internal.ImportRoaringRequestView{ + views[i] = &pb.ImportRoaringRequestView{ Name: viewName, Data: viewData, } i++ } - return &internal.ImportRoaringRequest{ + return &pb.ImportRoaringRequest{ IndexCreatedAt: m.IndexCreatedAt, FieldCreatedAt: m.FieldCreatedAt, Clear: m.Clear, @@ -488,8 +488,8 @@ func (s Serializer) encodeImportRoaringRequest(m *pilosa.ImportRoaringRequest) * } } -func (s Serializer) encodeImportColumnAttrsRequest(m *pilosa.ImportColumnAttrsRequest) *internal.ImportColumnAttrsRequest { - return &internal.ImportColumnAttrsRequest{ +func (s Serializer) encodeImportColumnAttrsRequest(m *pilosa.ImportColumnAttrsRequest) *pb.ImportColumnAttrsRequest { + return &pb.ImportColumnAttrsRequest{ Index: m.Index, IndexCreatedAt: m.IndexCreatedAt, Shard: m.Shard, @@ -499,8 +499,8 @@ func (s Serializer) encodeImportColumnAttrsRequest(m *pilosa.ImportColumnAttrsRe } } -func (s Serializer) encodeQueryRequest(m *pilosa.QueryRequest) *internal.QueryRequest { - r := &internal.QueryRequest{ +func (s Serializer) encodeQueryRequest(m *pilosa.QueryRequest) *pb.QueryRequest { + r := &pb.QueryRequest{ Query: m.Query, Shards: m.Shards, ColumnAttrs: m.ColumnAttrs, @@ -508,7 +508,7 @@ func (s Serializer) encodeQueryRequest(m *pilosa.QueryRequest) *internal.QueryRe ExcludeRowAttrs: m.ExcludeRowAttrs, ExcludeColumns: m.ExcludeColumns, PreTranslated: m.PreTranslated, - EmbeddedData: make([]*internal.Row, len(m.EmbeddedData)), + EmbeddedData: make([]*pb.Row, len(m.EmbeddedData)), } for i := range m.EmbeddedData { r.EmbeddedData[i] = s.encodeRow(m.EmbeddedData[i]) @@ -516,77 +516,77 @@ func (s Serializer) encodeQueryRequest(m *pilosa.QueryRequest) *internal.QueryRe return r } -func (s Serializer) encodeQueryResponse(m *pilosa.QueryResponse) *internal.QueryResponse { - pb := &internal.QueryResponse{ - Results: make([]*internal.QueryResult, len(m.Results)), +func (s Serializer) encodeQueryResponse(m *pilosa.QueryResponse) *pb.QueryResponse { + resp := &pb.QueryResponse{ + Results: make([]*pb.QueryResult, len(m.Results)), ColumnAttrSets: s.encodeColumnAttrSets(m.ColumnAttrSets), } for i := range m.Results { - pb.Results[i] = &internal.QueryResult{} + resp.Results[i] = &pb.QueryResult{} switch result := m.Results[i].(type) { case pilosa.SignedRow: - pb.Results[i].Type = queryResultTypeSignedRow - pb.Results[i].SignedRow = s.encodeSignedRow(result) + resp.Results[i].Type = queryResultTypeSignedRow + resp.Results[i].SignedRow = s.encodeSignedRow(result) case *pilosa.Row: - pb.Results[i].Type = queryResultTypeRow - pb.Results[i].Row = s.encodeRow(result) + resp.Results[i].Type = queryResultTypeRow + resp.Results[i].Row = s.encodeRow(result) case []pilosa.Pair: - pb.Results[i].Type = queryResultTypePairs - pb.Results[i].Pairs = s.encodePairs(result) + resp.Results[i].Type = queryResultTypePairs + resp.Results[i].Pairs = s.encodePairs(result) case *pilosa.PairsField: - pb.Results[i].Type = queryResultTypePairsField - pb.Results[i].PairsField = s.encodePairsField(result) + resp.Results[i].Type = queryResultTypePairsField + resp.Results[i].PairsField = s.encodePairsField(result) case pilosa.ValCount: - pb.Results[i].Type = queryResultTypeValCount - pb.Results[i].ValCount = s.encodeValCount(result) + resp.Results[i].Type = queryResultTypeValCount + resp.Results[i].ValCount = s.encodeValCount(result) case uint64: - pb.Results[i].Type = queryResultTypeUint64 - pb.Results[i].N = result + resp.Results[i].Type = queryResultTypeUint64 + resp.Results[i].N = result case bool: - pb.Results[i].Type = queryResultTypeBool - pb.Results[i].Changed = result + resp.Results[i].Type = queryResultTypeBool + resp.Results[i].Changed = result case pilosa.RowIDs: - pb.Results[i].Type = queryResultTypeRowIDs - pb.Results[i].RowIDs = result + resp.Results[i].Type = queryResultTypeRowIDs + resp.Results[i].RowIDs = result case pilosa.ExtractedIDMatrix: - pb.Results[i].Type = queryResultTypeExtractedIDMatrix - pb.Results[i].ExtractedIDMatrix = s.endcodeExtractedIDMatrix(result) + resp.Results[i].Type = queryResultTypeExtractedIDMatrix + resp.Results[i].ExtractedIDMatrix = s.endcodeExtractedIDMatrix(result) case *pilosa.GroupCounts: - pb.Results[i].Type = queryResultTypeGroupCounts - pb.Results[i].GroupCounts = s.encodeGroupCounts(result) + resp.Results[i].Type = queryResultTypeGroupCounts + resp.Results[i].GroupCounts = s.encodeGroupCounts(result) case pilosa.RowIdentifiers: - pb.Results[i].Type = queryResultTypeRowIdentifiers - pb.Results[i].RowIdentifiers = s.encodeRowIdentifiers(result) + resp.Results[i].Type = queryResultTypeRowIdentifiers + resp.Results[i].RowIdentifiers = s.encodeRowIdentifiers(result) case pilosa.ExtractedTable: - pb.Results[i].Type = queryResultTypeExtractedTable - pb.Results[i].ExtractedTable = s.encodeExtractedTable(result) + resp.Results[i].Type = queryResultTypeExtractedTable + resp.Results[i].ExtractedTable = s.encodeExtractedTable(result) case pilosa.Pair: - pb.Results[i].Type = queryResultTypePair - pb.Results[i].Pairs = []*internal.Pair{s.encodePair(result)} + resp.Results[i].Type = queryResultTypePair + resp.Results[i].Pairs = []*pb.Pair{s.encodePair(result)} case pilosa.PairField: - pb.Results[i].Type = queryResultTypePairField - pb.Results[i].PairField = s.encodePairField(result) + resp.Results[i].Type = queryResultTypePairField + resp.Results[i].PairField = s.encodePairField(result) case []*pilosa.Row: - pb.Results[i].Type = queryResultTypeRowMatrix - pb.Results[i].RowMatrix = s.encodeRowMatrix(result) + resp.Results[i].Type = queryResultTypeRowMatrix + resp.Results[i].RowMatrix = s.encodeRowMatrix(result) case nil: - pb.Results[i].Type = queryResultTypeNil + resp.Results[i].Type = queryResultTypeNil default: panic(fmt.Errorf("unknown type: %T", m.Results[i])) } } if m.Err != nil { - pb.Err = m.Err.Error() + resp.Err = m.Err.Error() } - return pb + return resp } -func (s Serializer) encodeResizeInstruction(m *pilosa.ResizeInstruction) *internal.ResizeInstruction { - return &internal.ResizeInstruction{ +func (s Serializer) encodeResizeInstruction(m *pilosa.ResizeInstruction) *pb.ResizeInstruction { + return &pb.ResizeInstruction{ JobID: m.JobID, Node: s.encodeNode(m.Node), Primary: s.encodeNode(m.Primary), @@ -597,16 +597,16 @@ func (s Serializer) encodeResizeInstruction(m *pilosa.ResizeInstruction) *intern } } -func (s Serializer) encodeResizeSources(srcs []*pilosa.ResizeSource) []*internal.ResizeSource { - new := make([]*internal.ResizeSource, 0, len(srcs)) +func (s Serializer) encodeResizeSources(srcs []*pilosa.ResizeSource) []*pb.ResizeSource { + new := make([]*pb.ResizeSource, 0, len(srcs)) for _, src := range srcs { new = append(new, s.encodeResizeSource(src)) } return new } -func (s Serializer) encodeResizeSource(m *pilosa.ResizeSource) *internal.ResizeSource { - return &internal.ResizeSource{ +func (s Serializer) encodeResizeSource(m *pilosa.ResizeSource) *pb.ResizeSource { + return &pb.ResizeSource{ Node: s.encodeNode(m.Node), Index: m.Index, Field: m.Field, @@ -615,38 +615,38 @@ func (s Serializer) encodeResizeSource(m *pilosa.ResizeSource) *internal.ResizeS } } -func (s Serializer) encodeTranslationResizeSources(srcs []*pilosa.TranslationResizeSource) []*internal.TranslationResizeSource { - new := make([]*internal.TranslationResizeSource, 0, len(srcs)) +func (s Serializer) encodeTranslationResizeSources(srcs []*pilosa.TranslationResizeSource) []*pb.TranslationResizeSource { + new := make([]*pb.TranslationResizeSource, 0, len(srcs)) for _, src := range srcs { new = append(new, s.encodeTranslationResizeSource(src)) } return new } -func (s Serializer) encodeTranslationResizeSource(m *pilosa.TranslationResizeSource) *internal.TranslationResizeSource { - return &internal.TranslationResizeSource{ +func (s Serializer) encodeTranslationResizeSource(m *pilosa.TranslationResizeSource) *pb.TranslationResizeSource { + return &pb.TranslationResizeSource{ Node: s.encodeNode(m.Node), Index: m.Index, PartitionID: int32(m.PartitionID), } } -func (s Serializer) encodeSchema(m *pilosa.Schema) *internal.Schema { - return &internal.Schema{ +func (s Serializer) encodeSchema(m *pilosa.Schema) *pb.Schema { + return &pb.Schema{ Indexes: s.encodeIndexInfos(m.Indexes), } } -func (s Serializer) encodeIndexInfos(idxs []*pilosa.IndexInfo) []*internal.Index { - new := make([]*internal.Index, 0, len(idxs)) +func (s Serializer) encodeIndexInfos(idxs []*pilosa.IndexInfo) []*pb.Index { + new := make([]*pb.Index, 0, len(idxs)) for _, idx := range idxs { new = append(new, s.encodeIndexInfo(idx)) } return new } -func (s Serializer) encodeIndexInfo(idx *pilosa.IndexInfo) *internal.Index { - return &internal.Index{ +func (s Serializer) encodeIndexInfo(idx *pilosa.IndexInfo) *pb.Index { + return &pb.Index{ Name: idx.Name, CreatedAt: idx.CreatedAt, Options: s.encodeIndexMeta(&idx.Options), @@ -654,16 +654,16 @@ func (s Serializer) encodeIndexInfo(idx *pilosa.IndexInfo) *internal.Index { } } -func (s Serializer) encodeFieldInfos(fs []*pilosa.FieldInfo) []*internal.Field { - new := make([]*internal.Field, 0, len(fs)) +func (s Serializer) encodeFieldInfos(fs []*pilosa.FieldInfo) []*pb.Field { + new := make([]*pb.Field, 0, len(fs)) for _, f := range fs { new = append(new, s.encodeFieldInfo(f)) } return new } -func (s Serializer) encodeFieldInfo(f *pilosa.FieldInfo) *internal.Field { - ifield := &internal.Field{ +func (s Serializer) encodeFieldInfo(f *pilosa.FieldInfo) *pb.Field { + ifield := &pb.Field{ Name: f.Name, CreatedAt: f.CreatedAt, Meta: s.encodeFieldOptions(&f.Options), @@ -676,16 +676,16 @@ func (s Serializer) encodeFieldInfo(f *pilosa.FieldInfo) *internal.Field { return ifield } -func (s Serializer) encodeFieldOptions(o *pilosa.FieldOptions) *internal.FieldOptions { +func (s Serializer) encodeFieldOptions(o *pilosa.FieldOptions) *pb.FieldOptions { if o == nil { return nil } - return &internal.FieldOptions{ + return &pb.FieldOptions{ Type: o.Type, CacheType: o.CacheType, CacheSize: o.CacheSize, - Min: &internal.Decimal{Value: o.Min.Value, Scale: o.Min.Scale}, - Max: &internal.Decimal{Value: o.Max.Value, Scale: o.Max.Scale}, + Min: &pb.Decimal{Value: o.Min.Value, Scale: o.Min.Scale}, + Max: &pb.Decimal{Value: o.Max.Value, Scale: o.Max.Scale}, Base: o.Base, Scale: o.Scale, BitDepth: uint64(o.BitDepth), @@ -695,19 +695,19 @@ func (s Serializer) encodeFieldOptions(o *pilosa.FieldOptions) *internal.FieldOp } } -// s.encodeNodes converts a slice of Nodes into its internal representation. -func (s Serializer) encodeNodes(a []*topology.Node) []*internal.Node { - other := make([]*internal.Node, len(a)) +// s.encodeNodes converts a slice of Nodes into its pb.representation. +func (s Serializer) encodeNodes(a []*topology.Node) []*pb.Node { + other := make([]*pb.Node, len(a)) for i := range a { other[i] = s.encodeNode(a[i]) } return other } -// s.encodeNode converts a Node into its internal representation. -func (s Serializer) encodeNode(m *topology.Node) *internal.Node { +// s.encodeNode converts a Node into its pb.representation. +func (s Serializer) encodeNode(m *topology.Node) *pb.Node { n := m.Clone() - return &internal.Node{ + return &pb.Node{ ID: n.ID, URI: s.encodeURI(n.URI), State: string(n.State), @@ -715,16 +715,16 @@ func (s Serializer) encodeNode(m *topology.Node) *internal.Node { } } -func (s Serializer) encodeURI(u pnet.URI) *internal.URI { - return &internal.URI{ +func (s Serializer) encodeURI(u pnet.URI) *pb.URI { + return &pb.URI{ Scheme: u.Scheme, Host: u.Host, Port: uint32(u.Port), } } -func (s Serializer) encodeClusterStatus(m *pilosa.ClusterStatus) *internal.ClusterStatus { - return &internal.ClusterStatus{ +func (s Serializer) encodeClusterStatus(m *pilosa.ClusterStatus) *pb.ClusterStatus { + return &pb.ClusterStatus{ State: m.State, ClusterID: m.ClusterID, Nodes: s.encodeNodes(m.Nodes), @@ -732,37 +732,37 @@ func (s Serializer) encodeClusterStatus(m *pilosa.ClusterStatus) *internal.Clust } } -func (s Serializer) encodeCreateShardMessage(m *pilosa.CreateShardMessage) *internal.CreateShardMessage { - return &internal.CreateShardMessage{ +func (s Serializer) encodeCreateShardMessage(m *pilosa.CreateShardMessage) *pb.CreateShardMessage { + return &pb.CreateShardMessage{ Index: m.Index, Field: m.Field, Shard: m.Shard, } } -func (s Serializer) encodeCreateIndexMessage(m *pilosa.CreateIndexMessage) *internal.CreateIndexMessage { - return &internal.CreateIndexMessage{ +func (s Serializer) encodeCreateIndexMessage(m *pilosa.CreateIndexMessage) *pb.CreateIndexMessage { + return &pb.CreateIndexMessage{ Index: m.Index, CreatedAt: m.CreatedAt, Meta: s.encodeIndexMeta(&m.Meta), } } -func (s Serializer) encodeIndexMeta(m *pilosa.IndexOptions) *internal.IndexMeta { - return &internal.IndexMeta{ +func (s Serializer) encodeIndexMeta(m *pilosa.IndexOptions) *pb.IndexMeta { + return &pb.IndexMeta{ Keys: m.Keys, TrackExistence: m.TrackExistence, } } -func (s Serializer) encodeDeleteIndexMessage(m *pilosa.DeleteIndexMessage) *internal.DeleteIndexMessage { - return &internal.DeleteIndexMessage{ +func (s Serializer) encodeDeleteIndexMessage(m *pilosa.DeleteIndexMessage) *pb.DeleteIndexMessage { + return &pb.DeleteIndexMessage{ Index: m.Index, } } -func (s Serializer) encodeCreateFieldMessage(m *pilosa.CreateFieldMessage) *internal.CreateFieldMessage { - return &internal.CreateFieldMessage{ +func (s Serializer) encodeCreateFieldMessage(m *pilosa.CreateFieldMessage) *pb.CreateFieldMessage { + return &pb.CreateFieldMessage{ Index: m.Index, Field: m.Field, CreatedAt: m.CreatedAt, @@ -770,109 +770,109 @@ func (s Serializer) encodeCreateFieldMessage(m *pilosa.CreateFieldMessage) *inte } } -func (s Serializer) encodeDeleteFieldMessage(m *pilosa.DeleteFieldMessage) *internal.DeleteFieldMessage { - return &internal.DeleteFieldMessage{ +func (s Serializer) encodeDeleteFieldMessage(m *pilosa.DeleteFieldMessage) *pb.DeleteFieldMessage { + return &pb.DeleteFieldMessage{ Index: m.Index, Field: m.Field, } } -func (s Serializer) encodeDeleteAvailableShardMessage(m *pilosa.DeleteAvailableShardMessage) *internal.DeleteAvailableShardMessage { - return &internal.DeleteAvailableShardMessage{ +func (s Serializer) encodeDeleteAvailableShardMessage(m *pilosa.DeleteAvailableShardMessage) *pb.DeleteAvailableShardMessage { + return &pb.DeleteAvailableShardMessage{ Index: m.Index, Field: m.Field, ShardID: m.ShardID, } } -func (s Serializer) encodeCreateViewMessage(m *pilosa.CreateViewMessage) *internal.CreateViewMessage { - return &internal.CreateViewMessage{ +func (s Serializer) encodeCreateViewMessage(m *pilosa.CreateViewMessage) *pb.CreateViewMessage { + return &pb.CreateViewMessage{ Index: m.Index, Field: m.Field, View: m.View, } } -func (s Serializer) encodeDeleteViewMessage(m *pilosa.DeleteViewMessage) *internal.DeleteViewMessage { - return &internal.DeleteViewMessage{ +func (s Serializer) encodeDeleteViewMessage(m *pilosa.DeleteViewMessage) *pb.DeleteViewMessage { + return &pb.DeleteViewMessage{ Index: m.Index, Field: m.Field, View: m.View, } } -func (s Serializer) encodeResizeInstructionComplete(m *pilosa.ResizeInstructionComplete) *internal.ResizeInstructionComplete { - return &internal.ResizeInstructionComplete{ +func (s Serializer) encodeResizeInstructionComplete(m *pilosa.ResizeInstructionComplete) *pb.ResizeInstructionComplete { + return &pb.ResizeInstructionComplete{ JobID: m.JobID, Node: s.encodeNode(m.Node), Error: m.Error, } } -func (s Serializer) encodeNodeStateMessage(m *pilosa.NodeStateMessage) *internal.NodeStateMessage { - return &internal.NodeStateMessage{ +func (s Serializer) encodeNodeStateMessage(m *pilosa.NodeStateMessage) *pb.NodeStateMessage { + return &pb.NodeStateMessage{ NodeID: m.NodeID, State: m.State, } } -func (s Serializer) encodeNodeEventMessage(m *pilosa.NodeEvent) *internal.NodeEventMessage { - return &internal.NodeEventMessage{ +func (s Serializer) encodeNodeEventMessage(m *pilosa.NodeEvent) *pb.NodeEventMessage { + return &pb.NodeEventMessage{ Event: uint32(m.Event), Node: s.encodeNode(m.Node), } } -func (s Serializer) encodeNodeStatus(m *pilosa.NodeStatus) *internal.NodeStatus { - return &internal.NodeStatus{ +func (s Serializer) encodeNodeStatus(m *pilosa.NodeStatus) *pb.NodeStatus { + return &pb.NodeStatus{ Node: s.encodeNode(m.Node), Indexes: s.encodeIndexStatuses(m.Indexes), Schema: s.encodeSchema(m.Schema), } } -func (s Serializer) encodeIndexStatus(m *pilosa.IndexStatus) *internal.IndexStatus { - return &internal.IndexStatus{ +func (s Serializer) encodeIndexStatus(m *pilosa.IndexStatus) *pb.IndexStatus { + return &pb.IndexStatus{ Name: m.Name, CreatedAt: m.CreatedAt, Fields: s.encodeFieldStatuses(m.Fields), } } -func (s Serializer) encodeIndexStatuses(a []*pilosa.IndexStatus) []*internal.IndexStatus { - other := make([]*internal.IndexStatus, len(a)) +func (s Serializer) encodeIndexStatuses(a []*pilosa.IndexStatus) []*pb.IndexStatus { + other := make([]*pb.IndexStatus, len(a)) for i := range a { other[i] = s.encodeIndexStatus(a[i]) } return other } -func (s Serializer) encodeFieldStatus(m *pilosa.FieldStatus) *internal.FieldStatus { - return &internal.FieldStatus{ +func (s Serializer) encodeFieldStatus(m *pilosa.FieldStatus) *pb.FieldStatus { + return &pb.FieldStatus{ Name: m.Name, CreatedAt: m.CreatedAt, AvailableShards: m.AvailableShards.Slice(), } } -func (s Serializer) encodeFieldStatuses(a []*pilosa.FieldStatus) []*internal.FieldStatus { - other := make([]*internal.FieldStatus, len(a)) +func (s Serializer) encodeFieldStatuses(a []*pilosa.FieldStatus) []*pb.FieldStatus { + other := make([]*pb.FieldStatus, len(a)) for i := range a { other[i] = s.encodeFieldStatus(a[i]) } return other } -func (s Serializer) encodeRecalculateCaches(*pilosa.RecalculateCaches) *internal.RecalculateCaches { - return &internal.RecalculateCaches{} +func (s Serializer) encodeRecalculateCaches(*pilosa.RecalculateCaches) *pb.RecalculateCaches { + return &pb.RecalculateCaches{} } -func (s Serializer) encodeLoadSchemaMessage(*pilosa.LoadSchemaMessage) *internal.LoadSchemaMessage { - return &internal.LoadSchemaMessage{} +func (s Serializer) encodeLoadSchemaMessage(*pilosa.LoadSchemaMessage) *pb.LoadSchemaMessage { + return &pb.LoadSchemaMessage{} } -func (s Serializer) encodeTranslateKeysRequest(request *pilosa.TranslateKeysRequest) *internal.TranslateKeysRequest { - return &internal.TranslateKeysRequest{ +func (s Serializer) encodeTranslateKeysRequest(request *pilosa.TranslateKeysRequest) *pb.TranslateKeysRequest { + return &pb.TranslateKeysRequest{ Index: request.Index, Field: request.Field, Keys: request.Keys, @@ -880,35 +880,35 @@ func (s Serializer) encodeTranslateKeysRequest(request *pilosa.TranslateKeysRequ } } -func (s Serializer) encodeTranslateKeysResponse(response *pilosa.TranslateKeysResponse) *internal.TranslateKeysResponse { - return &internal.TranslateKeysResponse{ +func (s Serializer) encodeTranslateKeysResponse(response *pilosa.TranslateKeysResponse) *pb.TranslateKeysResponse { + return &pb.TranslateKeysResponse{ IDs: response.IDs, } } -func (s Serializer) encodeTranslateIDsRequest(request *pilosa.TranslateIDsRequest) *internal.TranslateIDsRequest { - return &internal.TranslateIDsRequest{ +func (s Serializer) encodeTranslateIDsRequest(request *pilosa.TranslateIDsRequest) *pb.TranslateIDsRequest { + return &pb.TranslateIDsRequest{ Index: request.Index, Field: request.Field, IDs: request.IDs, } } -func (s Serializer) encodeTranslateIDsResponse(response *pilosa.TranslateIDsResponse) *internal.TranslateIDsResponse { - return &internal.TranslateIDsResponse{ +func (s Serializer) encodeTranslateIDsResponse(response *pilosa.TranslateIDsResponse) *pb.TranslateIDsResponse { + return &pb.TranslateIDsResponse{ Keys: response.Keys, } } -func (s Serializer) encodeTransactionMessage(msg *pilosa.TransactionMessage) *internal.TransactionMessage { - return &internal.TransactionMessage{ +func (s Serializer) encodeTransactionMessage(msg *pilosa.TransactionMessage) *pb.TransactionMessage { + return &pb.TransactionMessage{ Action: msg.Action, Transaction: s.encodeTransaction(msg.Transaction), } } -func (s Serializer) encodeAtomicRecord(msg *pilosa.AtomicRecord) *internal.AtomicRecord { - ar := &internal.AtomicRecord{ +func (s Serializer) encodeAtomicRecord(msg *pilosa.AtomicRecord) *pb.AtomicRecord { + ar := &pb.AtomicRecord{ Index: msg.Index, Shard: msg.Shard, } @@ -921,20 +921,20 @@ func (s Serializer) encodeAtomicRecord(msg *pilosa.AtomicRecord) *internal.Atomi return ar } -func (s Serializer) encodeRowMatrix(msg []*pilosa.Row) *internal.RowMatrix { - rows := make([]*internal.Row, len(msg)) +func (s Serializer) encodeRowMatrix(msg []*pilosa.Row) *pb.RowMatrix { + rows := make([]*pb.Row, len(msg)) for i, r := range msg { rows[i] = s.encodeRow(r) } - return &internal.RowMatrix{Rows: rows} + return &pb.RowMatrix{Rows: rows} } -func (s Serializer) encodeTransaction(trns *pilosa.Transaction) *internal.Transaction { +func (s Serializer) encodeTransaction(trns *pilosa.Transaction) *pb.Transaction { if trns == nil { return nil } - return &internal.Transaction{ + return &pb.Transaction{ ID: trns.ID, Active: trns.Active, Exclusive: trns.Exclusive, @@ -951,11 +951,11 @@ func (s Serializer) encodeTransactionDeadline(deadline time.Time) int64 { return deadline.UnixNano() } -func (s Serializer) encodeTransactionStats(stats pilosa.TransactionStats) *internal.TransactionStats { - return &internal.TransactionStats{} +func (s Serializer) encodeTransactionStats(stats pilosa.TransactionStats) *pb.TransactionStats { + return &pb.TransactionStats{} } -func (s Serializer) decodeResizeInstruction(ri *internal.ResizeInstruction, m *pilosa.ResizeInstruction) { +func (s Serializer) decodeResizeInstruction(ri *pb.ResizeInstruction, m *pilosa.ResizeInstruction) { m.JobID = ri.JobID m.Node = &topology.Node{} s.decodeNode(ri.Node, m.Node) @@ -971,14 +971,14 @@ func (s Serializer) decodeResizeInstruction(ri *internal.ResizeInstruction, m *p s.decodeClusterStatus(ri.ClusterStatus, m.ClusterStatus) } -func (s Serializer) decodeResizeSources(srcs []*internal.ResizeSource, m []*pilosa.ResizeSource) { +func (s Serializer) decodeResizeSources(srcs []*pb.ResizeSource, m []*pilosa.ResizeSource) { for i := range srcs { m[i] = &pilosa.ResizeSource{} s.decodeResizeSource(srcs[i], m[i]) } } -func (s Serializer) decodeResizeSource(rs *internal.ResizeSource, m *pilosa.ResizeSource) { +func (s Serializer) decodeResizeSource(rs *pb.ResizeSource, m *pilosa.ResizeSource) { m.Node = &topology.Node{} s.decodeNode(rs.Node, m.Node) m.Index = rs.Index @@ -987,33 +987,33 @@ func (s Serializer) decodeResizeSource(rs *internal.ResizeSource, m *pilosa.Resi m.Shard = rs.Shard } -func (s Serializer) decodeTranslationResizeSources(srcs []*internal.TranslationResizeSource, m []*pilosa.TranslationResizeSource) { +func (s Serializer) decodeTranslationResizeSources(srcs []*pb.TranslationResizeSource, m []*pilosa.TranslationResizeSource) { for i := range srcs { m[i] = &pilosa.TranslationResizeSource{} s.decodeTranslationResizeSource(srcs[i], m[i]) } } -func (s Serializer) decodeTranslationResizeSource(rs *internal.TranslationResizeSource, m *pilosa.TranslationResizeSource) { +func (s Serializer) decodeTranslationResizeSource(rs *pb.TranslationResizeSource, m *pilosa.TranslationResizeSource) { m.Node = &topology.Node{} s.decodeNode(rs.Node, m.Node) m.Index = rs.Index m.PartitionID = int(rs.PartitionID) } -func (s Serializer) decodeSchema(sc *internal.Schema, m *pilosa.Schema) { +func (s Serializer) decodeSchema(sc *pb.Schema, m *pilosa.Schema) { m.Indexes = make([]*pilosa.IndexInfo, len(sc.Indexes)) s.decodeIndexes(sc.Indexes, m.Indexes) } -func (s Serializer) decodeIndexes(idxs []*internal.Index, m []*pilosa.IndexInfo) { +func (s Serializer) decodeIndexes(idxs []*pb.Index, m []*pilosa.IndexInfo) { for i := range idxs { m[i] = &pilosa.IndexInfo{} s.decodeIndex(idxs[i], m[i]) } } -func (s Serializer) decodeIndex(idx *internal.Index, m *pilosa.IndexInfo) { +func (s Serializer) decodeIndex(idx *pb.Index, m *pilosa.IndexInfo) { m.Name = idx.Name m.CreatedAt = idx.CreatedAt m.Options = pilosa.IndexOptions{} @@ -1022,14 +1022,14 @@ func (s Serializer) decodeIndex(idx *internal.Index, m *pilosa.IndexInfo) { s.decodeFields(idx.Fields, m.Fields) } -func (s Serializer) decodeFields(fs []*internal.Field, m []*pilosa.FieldInfo) { +func (s Serializer) decodeFields(fs []*pb.Field, m []*pilosa.FieldInfo) { for i := range fs { m[i] = &pilosa.FieldInfo{} s.decodeField(fs[i], m[i]) } } -func (s Serializer) decodeField(f *internal.Field, m *pilosa.FieldInfo) { +func (s Serializer) decodeField(f *pb.Field, m *pilosa.FieldInfo) { m.Name = f.Name m.CreatedAt = f.CreatedAt m.Options = pilosa.FieldOptions{} @@ -1040,7 +1040,7 @@ func (s Serializer) decodeField(f *internal.Field, m *pilosa.FieldInfo) { } } -func (s Serializer) decodeFieldOptions(options *internal.FieldOptions, m *pilosa.FieldOptions) { +func (s Serializer) decodeFieldOptions(options *pb.FieldOptions, m *pilosa.FieldOptions) { m.Type = options.Type m.CacheType = options.CacheType m.CacheSize = options.CacheSize @@ -1054,19 +1054,19 @@ func (s Serializer) decodeFieldOptions(options *internal.FieldOptions, m *pilosa m.ForeignIndex = options.ForeignIndex } -func (s Serializer) decodeDecimal(d *internal.Decimal, m *pql.Decimal) { +func (s Serializer) decodeDecimal(d *pb.Decimal, m *pql.Decimal) { m.Value = d.Value m.Scale = d.Scale } -func (s Serializer) decodeNodes(a []*internal.Node, m []*topology.Node) { +func (s Serializer) decodeNodes(a []*pb.Node, m []*topology.Node) { for i := range a { m[i] = &topology.Node{} s.decodeNode(a[i], m[i]) } } -func (s Serializer) decodeClusterStatus(cs *internal.ClusterStatus, m *pilosa.ClusterStatus) { +func (s Serializer) decodeClusterStatus(cs *pb.ClusterStatus, m *pilosa.ClusterStatus) { m.State = cs.State m.ClusterID = cs.ClusterID m.Nodes = make([]*topology.Node, len(cs.Nodes)) @@ -1075,44 +1075,44 @@ func (s Serializer) decodeClusterStatus(cs *internal.ClusterStatus, m *pilosa.Cl s.decodeSchema(cs.Schema, m.Schema) } -func (s Serializer) decodeNode(node *internal.Node, m *topology.Node) { +func (s Serializer) decodeNode(node *pb.Node, m *topology.Node) { m.ID = node.ID s.decodeURI(node.URI, &m.URI) s.decodeURI(node.GRPCURI, &m.GRPCURI) m.State = disco.NodeState(node.State) } -func (s Serializer) decodeURI(i *internal.URI, m *pnet.URI) { +func (s Serializer) decodeURI(i *pb.URI, m *pnet.URI) { m.Scheme = i.Scheme m.Host = i.Host m.Port = uint16(i.Port) } -func (s Serializer) decodeCreateShardMessage(pb *internal.CreateShardMessage, m *pilosa.CreateShardMessage) { +func (s Serializer) decodeCreateShardMessage(pb *pb.CreateShardMessage, m *pilosa.CreateShardMessage) { m.Index = pb.Index m.Field = pb.Field m.Shard = pb.Shard } -func (s Serializer) decodeCreateIndexMessage(pb *internal.CreateIndexMessage, m *pilosa.CreateIndexMessage) { +func (s Serializer) decodeCreateIndexMessage(pb *pb.CreateIndexMessage, m *pilosa.CreateIndexMessage) { m.Index = pb.Index m.CreatedAt = pb.CreatedAt m.Meta = pilosa.IndexOptions{} s.decodeIndexMeta(pb.Meta, &m.Meta) } -func (s Serializer) decodeIndexMeta(pb *internal.IndexMeta, m *pilosa.IndexOptions) { +func (s Serializer) decodeIndexMeta(pb *pb.IndexMeta, m *pilosa.IndexOptions) { if pb != nil { m.Keys = pb.Keys m.TrackExistence = pb.TrackExistence } } -func (s Serializer) decodeDeleteIndexMessage(pb *internal.DeleteIndexMessage, m *pilosa.DeleteIndexMessage) { +func (s Serializer) decodeDeleteIndexMessage(pb *pb.DeleteIndexMessage, m *pilosa.DeleteIndexMessage) { m.Index = pb.Index } -func (s Serializer) decodeCreateFieldMessage(pb *internal.CreateFieldMessage, m *pilosa.CreateFieldMessage) { +func (s Serializer) decodeCreateFieldMessage(pb *pb.CreateFieldMessage, m *pilosa.CreateFieldMessage) { m.Index = pb.Index m.Field = pb.Field m.CreatedAt = pb.CreatedAt @@ -1120,55 +1120,55 @@ func (s Serializer) decodeCreateFieldMessage(pb *internal.CreateFieldMessage, m s.decodeFieldOptions(pb.Meta, m.Meta) } -func (s Serializer) decodeDeleteFieldMessage(pb *internal.DeleteFieldMessage, m *pilosa.DeleteFieldMessage) { +func (s Serializer) decodeDeleteFieldMessage(pb *pb.DeleteFieldMessage, m *pilosa.DeleteFieldMessage) { m.Index = pb.Index m.Field = pb.Field } -func (s Serializer) decodeDeleteAvailableShardMessage(pb *internal.DeleteAvailableShardMessage, m *pilosa.DeleteAvailableShardMessage) { +func (s Serializer) decodeDeleteAvailableShardMessage(pb *pb.DeleteAvailableShardMessage, m *pilosa.DeleteAvailableShardMessage) { m.Index = pb.Index m.Field = pb.Field m.ShardID = pb.ShardID } -func (s Serializer) decodeCreateViewMessage(pb *internal.CreateViewMessage, m *pilosa.CreateViewMessage) { +func (s Serializer) decodeCreateViewMessage(pb *pb.CreateViewMessage, m *pilosa.CreateViewMessage) { m.Index = pb.Index m.Field = pb.Field m.View = pb.View } -func (s Serializer) decodeDeleteViewMessage(pb *internal.DeleteViewMessage, m *pilosa.DeleteViewMessage) { +func (s Serializer) decodeDeleteViewMessage(pb *pb.DeleteViewMessage, m *pilosa.DeleteViewMessage) { m.Index = pb.Index m.Field = pb.Field m.View = pb.View } -func (s Serializer) decodeResizeInstructionComplete(pb *internal.ResizeInstructionComplete, m *pilosa.ResizeInstructionComplete) { +func (s Serializer) decodeResizeInstructionComplete(pb *pb.ResizeInstructionComplete, m *pilosa.ResizeInstructionComplete) { m.JobID = pb.JobID m.Node = &topology.Node{} s.decodeNode(pb.Node, m.Node) m.Error = pb.Error } -func (s Serializer) decodeNodeStateMessage(pb *internal.NodeStateMessage, m *pilosa.NodeStateMessage) { +func (s Serializer) decodeNodeStateMessage(pb *pb.NodeStateMessage, m *pilosa.NodeStateMessage) { m.NodeID = pb.NodeID m.State = pb.State } -func (s Serializer) decodeNodeEventMessage(pb *internal.NodeEventMessage, m *pilosa.NodeEvent) { +func (s Serializer) decodeNodeEventMessage(pb *pb.NodeEventMessage, m *pilosa.NodeEvent) { m.Event = pilosa.NodeEventType(pb.Event) m.Node = &topology.Node{} s.decodeNode(pb.Node, m.Node) } -func (s Serializer) decodeNodeStatus(pb *internal.NodeStatus, m *pilosa.NodeStatus) { +func (s Serializer) decodeNodeStatus(pb *pb.NodeStatus, m *pilosa.NodeStatus) { m.Node = &topology.Node{} m.Indexes = s.decodeIndexStatuses(pb.Indexes) m.Schema = &pilosa.Schema{} s.decodeSchema(pb.Schema, m.Schema) } -func (s Serializer) decodeIndexStatuses(a []*internal.IndexStatus) []*pilosa.IndexStatus { +func (s Serializer) decodeIndexStatuses(a []*pb.IndexStatus) []*pilosa.IndexStatus { m := make([]*pilosa.IndexStatus, 0) for i := range a { m = append(m, &pilosa.IndexStatus{}) @@ -1177,13 +1177,13 @@ func (s Serializer) decodeIndexStatuses(a []*internal.IndexStatus) []*pilosa.Ind return m } -func (s Serializer) decodeIndexStatus(pb *internal.IndexStatus, m *pilosa.IndexStatus) { +func (s Serializer) decodeIndexStatus(pb *pb.IndexStatus, m *pilosa.IndexStatus) { m.Name = pb.Name m.CreatedAt = pb.CreatedAt m.Fields = s.decodeFieldStatuses(pb.Fields) } -func (s Serializer) decodeFieldStatuses(a []*internal.FieldStatus) []*pilosa.FieldStatus { +func (s Serializer) decodeFieldStatuses(a []*pb.FieldStatus) []*pilosa.FieldStatus { m := make([]*pilosa.FieldStatus, 0) for i := range a { m = append(m, &pilosa.FieldStatus{}) @@ -1192,19 +1192,19 @@ func (s Serializer) decodeFieldStatuses(a []*internal.FieldStatus) []*pilosa.Fie return m } -func (s Serializer) decodeFieldStatus(pb *internal.FieldStatus, m *pilosa.FieldStatus) { +func (s Serializer) decodeFieldStatus(pb *pb.FieldStatus, m *pilosa.FieldStatus) { m.Name = pb.Name m.CreatedAt = pb.CreatedAt m.AvailableShards = roaring.NewBitmap(pb.AvailableShards...) } -func (s Serializer) decodeRecalculateCaches(pb *internal.RecalculateCaches, m *pilosa.RecalculateCaches) { +func (s Serializer) decodeRecalculateCaches(pb *pb.RecalculateCaches, m *pilosa.RecalculateCaches) { } -func (s Serializer) decodeLoadSchemaMessage(pb *internal.LoadSchemaMessage, m *pilosa.LoadSchemaMessage) { +func (s Serializer) decodeLoadSchemaMessage(pb *pb.LoadSchemaMessage, m *pilosa.LoadSchemaMessage) { } -func (s Serializer) decodeQueryRequest(pb *internal.QueryRequest, m *pilosa.QueryRequest) { +func (s Serializer) decodeQueryRequest(pb *pb.QueryRequest, m *pilosa.QueryRequest) { m.Query = pb.Query m.Shards = pb.Shards m.ColumnAttrs = pb.ColumnAttrs @@ -1218,7 +1218,7 @@ func (s Serializer) decodeQueryRequest(pb *internal.QueryRequest, m *pilosa.Quer } } -func (s Serializer) decodeImportRequest(pb *internal.ImportRequest, m *pilosa.ImportRequest) { +func (s Serializer) decodeImportRequest(pb *pb.ImportRequest, m *pilosa.ImportRequest) { m.Index = pb.Index m.Field = pb.Field m.Shard = pb.Shard @@ -1232,7 +1232,7 @@ func (s Serializer) decodeImportRequest(pb *internal.ImportRequest, m *pilosa.Im m.Clear = pb.Clear } -func (s Serializer) decodeImportValueRequest(pb *internal.ImportValueRequest, m *pilosa.ImportValueRequest) { +func (s Serializer) decodeImportValueRequest(pb *pb.ImportValueRequest, m *pilosa.ImportValueRequest) { m.Index = pb.Index m.Field = pb.Field m.Shard = pb.Shard @@ -1246,7 +1246,7 @@ func (s Serializer) decodeImportValueRequest(pb *internal.ImportValueRequest, m m.Clear = pb.Clear } -func (s Serializer) decodeImportRoaringRequest(pb *internal.ImportRoaringRequest, m *pilosa.ImportRoaringRequest) { +func (s Serializer) decodeImportRoaringRequest(pb *pb.ImportRoaringRequest, m *pilosa.ImportRoaringRequest) { views := map[string][]byte{} for _, view := range pb.Views { views[view.Name] = view.Data @@ -1260,7 +1260,7 @@ func (s Serializer) decodeImportRoaringRequest(pb *internal.ImportRoaringRequest m.UpdateExistence = pb.UpdateExistence } -func (s Serializer) decodeImportColumnAttrsRequest(pb *internal.ImportColumnAttrsRequest, m *pilosa.ImportColumnAttrsRequest) { +func (s Serializer) decodeImportColumnAttrsRequest(pb *pb.ImportColumnAttrsRequest, m *pilosa.ImportColumnAttrsRequest) { m.Index = pb.Index m.IndexCreatedAt = pb.IndexCreatedAt m.Shard = pb.Shard @@ -1269,11 +1269,11 @@ func (s Serializer) decodeImportColumnAttrsRequest(pb *internal.ImportColumnAttr m.ColumnIDs = pb.ColumnIDs } -func (s Serializer) decodeImportResponse(pb *internal.ImportResponse, m *pilosa.ImportResponse) { +func (s Serializer) decodeImportResponse(pb *pb.ImportResponse, m *pilosa.ImportResponse) { m.Err = pb.Err } -func (s Serializer) decodeBlockDataRequest(pb *internal.BlockDataRequest, m *pilosa.BlockDataRequest) { +func (s Serializer) decodeBlockDataRequest(pb *pb.BlockDataRequest, m *pilosa.BlockDataRequest) { m.Index = pb.Index m.Field = pb.Field m.View = pb.View @@ -1281,12 +1281,12 @@ func (s Serializer) decodeBlockDataRequest(pb *internal.BlockDataRequest, m *pil m.Block = pb.Block } -func (s Serializer) decodeBlockDataResponse(pb *internal.BlockDataResponse, m *pilosa.BlockDataResponse) { +func (s Serializer) decodeBlockDataResponse(pb *pb.BlockDataResponse, m *pilosa.BlockDataResponse) { m.RowIDs = pb.RowIDs m.ColumnIDs = pb.ColumnIDs } -func (s Serializer) decodeQueryResponse(pb *internal.QueryResponse, m *pilosa.QueryResponse) { +func (s Serializer) decodeQueryResponse(pb *pb.QueryResponse, m *pilosa.QueryResponse) { m.ColumnAttrSets = make([]*pilosa.ColumnAttrSet, len(pb.ColumnAttrSets)) s.decodeColumnAttrSets(pb.ColumnAttrSets, m.ColumnAttrSets) if pb.Err == "" { @@ -1298,47 +1298,47 @@ func (s Serializer) decodeQueryResponse(pb *internal.QueryResponse, m *pilosa.Qu s.decodeQueryResults(pb.Results, m.Results) } -func (s Serializer) decodeColumnAttrSets(pb []*internal.ColumnAttrSet, m []*pilosa.ColumnAttrSet) { +func (s Serializer) decodeColumnAttrSets(pb []*pb.ColumnAttrSet, m []*pilosa.ColumnAttrSet) { for i := range pb { m[i] = &pilosa.ColumnAttrSet{} s.decodeColumnAttrSet(pb[i], m[i]) } } -func (s Serializer) decodeColumnAttrSet(pb *internal.ColumnAttrSet, m *pilosa.ColumnAttrSet) { +func (s Serializer) decodeColumnAttrSet(pb *pb.ColumnAttrSet, m *pilosa.ColumnAttrSet) { m.ID = pb.ID m.Key = pb.Key m.Attrs = s.decodeAttrs(pb.Attrs) } -func (s Serializer) decodeQueryResults(pb []*internal.QueryResult, m []interface{}) { +func (s Serializer) decodeQueryResults(pb []*pb.QueryResult, m []interface{}) { for i := range pb { m[i] = s.decodeQueryResult(pb[i]) } } -func (s Serializer) decodeTranslateKeysRequest(pb *internal.TranslateKeysRequest, m *pilosa.TranslateKeysRequest) { +func (s Serializer) decodeTranslateKeysRequest(pb *pb.TranslateKeysRequest, m *pilosa.TranslateKeysRequest) { m.Index = pb.Index m.Field = pb.Field m.Keys = pb.Keys m.NotWritable = pb.NotWritable } -func (s Serializer) decodeTranslateKeysResponse(pb *internal.TranslateKeysResponse, m *pilosa.TranslateKeysResponse) { +func (s Serializer) decodeTranslateKeysResponse(pb *pb.TranslateKeysResponse, m *pilosa.TranslateKeysResponse) { m.IDs = pb.IDs } -func (s Serializer) decodeTranslateIDsRequest(pb *internal.TranslateIDsRequest, m *pilosa.TranslateIDsRequest) { +func (s Serializer) decodeTranslateIDsRequest(pb *pb.TranslateIDsRequest, m *pilosa.TranslateIDsRequest) { m.Index = pb.Index m.Field = pb.Field m.IDs = pb.IDs } -func (s Serializer) decodeTranslateIDsResponse(pb *internal.TranslateIDsResponse, m *pilosa.TranslateIDsResponse) { +func (s Serializer) decodeTranslateIDsResponse(pb *pb.TranslateIDsResponse, m *pilosa.TranslateIDsResponse) { m.Keys = pb.Keys } -func decodeTransactionMessage(pb *internal.TransactionMessage, m *pilosa.TransactionMessage) { +func decodeTransactionMessage(pb *pb.TransactionMessage, m *pilosa.TransactionMessage) { m.Action = pb.Action if pb.Transaction == nil { m.Transaction = nil @@ -1349,7 +1349,7 @@ func decodeTransactionMessage(pb *internal.TransactionMessage, m *pilosa.Transac decodeTransaction(pb.Transaction, m.Transaction) } -func (s Serializer) decodeAtomicRecord(pb *internal.AtomicRecord, m *pilosa.AtomicRecord) { +func (s Serializer) decodeAtomicRecord(pb *pb.AtomicRecord, m *pilosa.AtomicRecord) { m.Index = pb.Index m.Shard = pb.Shard m.Ivr = make([]*pilosa.ImportValueRequest, len(pb.Ivr)) @@ -1365,7 +1365,7 @@ func (s Serializer) decodeAtomicRecord(pb *internal.AtomicRecord, m *pilosa.Atom } } -func (s Serializer) decodeRowMatrix(pb *internal.RowMatrix) []*pilosa.Row { +func (s Serializer) decodeRowMatrix(pb *pb.RowMatrix) []*pilosa.Row { rows := make([]*pilosa.Row, len(pb.Rows)) for i, r := range pb.Rows { rows[i] = s.decodeRow(r) @@ -1373,7 +1373,7 @@ func (s Serializer) decodeRowMatrix(pb *internal.RowMatrix) []*pilosa.Row { return rows } -func decodeTransaction(pb *internal.Transaction, trns *pilosa.Transaction) { +func decodeTransaction(pb *pb.Transaction, trns *pilosa.Transaction) { trns.ID = pb.ID trns.Active = pb.Active trns.Exclusive = pb.Exclusive @@ -1402,7 +1402,7 @@ const ( queryResultTypeExtractedTable ) -func (s Serializer) decodeQueryResult(pb *internal.QueryResult) interface{} { +func (s Serializer) decodeQueryResult(pb *pb.QueryResult) interface{} { switch pb.Type { case queryResultTypeSignedRow: return s.decodeSignedRow(pb.SignedRow) @@ -1440,8 +1440,8 @@ func (s Serializer) decodeQueryResult(pb *internal.QueryResult) interface{} { panic(fmt.Sprintf("unknown type: %d", pb.Type)) } -// s.decodeRow converts r from its internal representation. -func (s Serializer) decodeRow(pr *internal.Row) *pilosa.Row { +// s.decodeRow converts r from its pb.representation. +func (s Serializer) decodeRow(pr *pb.Row) *pilosa.Row { if pr == nil { return pilosa.NewRow() } @@ -1463,7 +1463,7 @@ func (s Serializer) decodeRow(pr *internal.Row) *pilosa.Row { return r } -func (s Serializer) decodeSignedRow(pr *internal.SignedRow) pilosa.SignedRow { +func (s Serializer) decodeSignedRow(pr *pb.SignedRow) pilosa.SignedRow { if pr == nil { return pilosa.SignedRow{} } @@ -1474,7 +1474,7 @@ func (s Serializer) decodeSignedRow(pr *internal.SignedRow) pilosa.SignedRow { return r } -func (s Serializer) decodeAttrs(pb []*internal.Attr) map[string]interface{} { +func (s Serializer) decodeAttrs(pb []*pb.Attr) map[string]interface{} { m := make(map[string]interface{}, len(pb)) for i := range pb { key, value := s.decodeAttr(pb[i]) @@ -1490,7 +1490,7 @@ const ( attrTypeFloat = 4 ) -func (s Serializer) decodeAttr(attr *internal.Attr) (key string, value interface{}) { +func (s Serializer) decodeAttr(attr *pb.Attr) (key string, value interface{}) { switch attr.Type { case attrTypeString: return attr.Key, attr.StringValue @@ -1505,7 +1505,7 @@ func (s Serializer) decodeAttr(attr *internal.Attr) (key string, value interface } } -func (s Serializer) decodeExtractedIDMatrix(m *internal.ExtractedIDMatrix) pilosa.ExtractedIDMatrix { +func (s Serializer) decodeExtractedIDMatrix(m *pb.ExtractedIDMatrix) pilosa.ExtractedIDMatrix { cols := make([]pilosa.ExtractedIDColumn, len(m.Columns)) for i, c := range m.Columns { rows := make([][]uint64, len(c.Vals)) @@ -1525,7 +1525,7 @@ func (s Serializer) decodeExtractedIDMatrix(m *internal.ExtractedIDMatrix) pilos } } -func (s Serializer) decodeExtractedTable(t *internal.ExtractedTable) pilosa.ExtractedTable { +func (s Serializer) decodeExtractedTable(t *pb.ExtractedTable) pilosa.ExtractedTable { fields := make([]pilosa.ExtractedTableField, len(t.Fields)) for i, f := range t.Fields { fields[i] = pilosa.ExtractedTableField{ @@ -1538,11 +1538,11 @@ func (s Serializer) decodeExtractedTable(t *internal.ExtractedTable) pilosa.Extr for i, c := range t.Columns { var col pilosa.KeyOrID switch kid := c.KeyOrID.(type) { - case *internal.ExtractedTableColumn_ID: + case *pb.ExtractedTableColumn_ID: col = pilosa.KeyOrID{ ID: kid.ID, } - case *internal.ExtractedTableColumn_Key: + case *pb.ExtractedTableColumn_Key: col = pilosa.KeyOrID{ Keyed: true, Key: kid.Key, @@ -1553,17 +1553,17 @@ func (s Serializer) decodeExtractedTable(t *internal.ExtractedTable) pilosa.Extr for j, v := range rows { var val interface{} switch v := v.(type) { - case *internal.ExtractedTableValue_IDs: + case *pb.ExtractedTableValue_IDs: val = v.IDs.IDs - case *internal.ExtractedTableValue_Keys: + case *pb.ExtractedTableValue_Keys: val = v.Keys.Keys - case *internal.ExtractedTableValue_BSIValue: + case *pb.ExtractedTableValue_BSIValue: val = v.BSIValue - case *internal.ExtractedTableValue_MutexID: + case *pb.ExtractedTableValue_MutexID: val = v.MutexID - case *internal.ExtractedTableValue_MutexKey: + case *pb.ExtractedTableValue_MutexKey: val = v.MutexKey - case *internal.ExtractedTableValue_Bool: + case *pb.ExtractedTableValue_Bool: val = v.Bool } @@ -1582,24 +1582,24 @@ func (s Serializer) decodeExtractedTable(t *internal.ExtractedTable) pilosa.Extr } } -func (s Serializer) decodeRowIdentifiers(a *internal.RowIdentifiers) *pilosa.RowIdentifiers { +func (s Serializer) decodeRowIdentifiers(a *pb.RowIdentifiers) *pilosa.RowIdentifiers { return &pilosa.RowIdentifiers{ Rows: a.Rows, Keys: a.Keys, } } -func (s Serializer) decodeGroupCounts(a *internal.GroupCounts, b []*internal.GroupCount) *pilosa.GroupCounts { +func (s Serializer) decodeGroupCounts(a *pb.GroupCounts, b []*pb.GroupCount) *pilosa.GroupCounts { // Workaround: If we get an old-style "[]*GroupCount", we translate it. if a == nil { - a = &internal.GroupCounts{Aggregate: "", Groups: b} + a = &pb.GroupCounts{Aggregate: "", Groups: b} } other := make([]pilosa.GroupCount, len(a.Groups)) for i, gc := range a.Groups { other[i] = pilosa.GroupCount{ Group: s.decodeFieldRows(gc.Group), Count: gc.Count, - // note: not renaming the `internal` structure members now + // note: not renaming the `pb. structure members now // to avoid breaking protobuf interactions. Agg: gc.Agg, } @@ -1607,7 +1607,7 @@ func (s Serializer) decodeGroupCounts(a *internal.GroupCounts, b []*internal.Gro return pilosa.NewGroupCounts(a.Aggregate, other...) } -func (s Serializer) decodeFieldRows(a []*internal.FieldRow) []pilosa.FieldRow { +func (s Serializer) decodeFieldRows(a []*pb.FieldRow) []pilosa.FieldRow { other := make([]pilosa.FieldRow, len(a)) for i := range a { fr := a[i] @@ -1623,7 +1623,7 @@ func (s Serializer) decodeFieldRows(a []*internal.FieldRow) []pilosa.FieldRow { return other } -func (s Serializer) decodePairs(a []*internal.Pair) []pilosa.Pair { +func (s Serializer) decodePairs(a []*pb.Pair) []pilosa.Pair { other := make([]pilosa.Pair, len(a)) for i := range a { other[i] = s.decodePair(a[i]) @@ -1631,7 +1631,7 @@ func (s Serializer) decodePairs(a []*internal.Pair) []pilosa.Pair { return other } -func (s Serializer) decodePairsField(a *internal.PairsField) *pilosa.PairsField { +func (s Serializer) decodePairsField(a *pb.PairsField) *pilosa.PairsField { other := &pilosa.PairsField{ Pairs: make([]pilosa.Pair, len(a.Pairs)), } @@ -1642,7 +1642,7 @@ func (s Serializer) decodePairsField(a *internal.PairsField) *pilosa.PairsField return other } -func (s Serializer) decodePair(pb *internal.Pair) pilosa.Pair { +func (s Serializer) decodePair(pb *pb.Pair) pilosa.Pair { return pilosa.Pair{ ID: pb.ID, Key: pb.Key, @@ -1650,7 +1650,7 @@ func (s Serializer) decodePair(pb *internal.Pair) pilosa.Pair { } } -func (s Serializer) decodePairField(pb *internal.PairField) pilosa.PairField { +func (s Serializer) decodePairField(pb *pb.PairField) pilosa.PairField { return pilosa.PairField{ Pair: pilosa.Pair{ ID: pb.Pair.ID, @@ -1661,7 +1661,7 @@ func (s Serializer) decodePairField(pb *internal.PairField) pilosa.PairField { } } -func (s Serializer) decodeValCount(pb *internal.ValCount) pilosa.ValCount { +func (s Serializer) decodeValCount(pb *pb.ValCount) pilosa.ValCount { return pilosa.ValCount{ Val: pb.Val, FloatVal: pb.FloatVal, @@ -1670,7 +1670,7 @@ func (s Serializer) decodeValCount(pb *internal.ValCount) pilosa.ValCount { } } -func (s Serializer) decodeDecimalStruct(pb *internal.Decimal) *pql.Decimal { +func (s Serializer) decodeDecimalStruct(pb *pb.Decimal) *pql.Decimal { if pb == nil { return nil } @@ -1680,36 +1680,36 @@ func (s Serializer) decodeDecimalStruct(pb *internal.Decimal) *pql.Decimal { } } -func (s Serializer) encodeColumnAttrSets(a []*pilosa.ColumnAttrSet) []*internal.ColumnAttrSet { - other := make([]*internal.ColumnAttrSet, len(a)) +func (s Serializer) encodeColumnAttrSets(a []*pilosa.ColumnAttrSet) []*pb.ColumnAttrSet { + other := make([]*pb.ColumnAttrSet, len(a)) for i := range a { other[i] = s.encodeColumnAttrSet(a[i]) } return other } -func (s Serializer) encodeColumnAttrSet(set *pilosa.ColumnAttrSet) *internal.ColumnAttrSet { - return &internal.ColumnAttrSet{ +func (s Serializer) encodeColumnAttrSet(set *pilosa.ColumnAttrSet) *pb.ColumnAttrSet { + return &pb.ColumnAttrSet{ ID: set.ID, Key: set.Key, Attrs: s.encodeAttrs(set.Attrs), } } -func (s Serializer) encodeSignedRow(r pilosa.SignedRow) *internal.SignedRow { - ir := &internal.SignedRow{ +func (s Serializer) encodeSignedRow(r pilosa.SignedRow) *pb.SignedRow { + ir := &pb.SignedRow{ Pos: s.encodeRow(r.Pos), Neg: s.encodeRow(r.Neg), } return ir } -func (s Serializer) encodeRow(r *pilosa.Row) *internal.Row { +func (s Serializer) encodeRow(r *pilosa.Row) *pb.Row { if r == nil { - return &internal.Row{} // Generated proto code doesn't like a nil Row. + return &pb.Row{} // Generated proto code doesn't like a nil Row. } - ir := &internal.Row{ + ir := &pb.Row{ Keys: r.Keys, Attrs: s.encodeAttrs(r.Attrs), Index: r.Index, @@ -1723,22 +1723,22 @@ func (s Serializer) encodeRow(r *pilosa.Row) *internal.Row { return ir } -func (s Serializer) encodeRowIdentifiers(r pilosa.RowIdentifiers) *internal.RowIdentifiers { - return &internal.RowIdentifiers{ +func (s Serializer) encodeRowIdentifiers(r pilosa.RowIdentifiers) *pb.RowIdentifiers { + return &pb.RowIdentifiers{ Rows: r.Rows, Keys: r.Keys, //Attrs: s.encodeAttrs(r.Attrs), } } -func (s Serializer) encodeGroupCounts(counts *pilosa.GroupCounts) *internal.GroupCounts { +func (s Serializer) encodeGroupCounts(counts *pilosa.GroupCounts) *pb.GroupCounts { groups := counts.Groups() - result := &internal.GroupCounts{ - Groups: make([]*internal.GroupCount, len(groups)), + result := &pb.GroupCounts{ + Groups: make([]*pb.GroupCount, len(groups)), Aggregate: counts.AggregateColumn(), } for i, gc := range groups { - result.Groups[i] = &internal.GroupCount{ + result.Groups[i] = &pb.GroupCount{ Group: s.encodeFieldRows(gc.Group), Count: gc.Count, Agg: gc.Agg, @@ -1747,14 +1747,14 @@ func (s Serializer) encodeGroupCounts(counts *pilosa.GroupCounts) *internal.Grou return result } -func (s Serializer) encodeFieldRows(a []pilosa.FieldRow) []*internal.FieldRow { - other := make([]*internal.FieldRow, len(a)) +func (s Serializer) encodeFieldRows(a []pilosa.FieldRow) []*pb.FieldRow { + other := make([]*pb.FieldRow, len(a)) for i := range a { fr := a[i] - other[i] = &internal.FieldRow{Field: fr.Field} + other[i] = &pb.FieldRow{Field: fr.Field} if fr.Value != nil { - other[i].Value = &internal.Int64{Value: *fr.Value} + other[i].Value = &pb.Int64{Value: *fr.Value} } else if fr.RowKey == "" { other[i].RowID = fr.RowID } else { @@ -1764,82 +1764,82 @@ func (s Serializer) encodeFieldRows(a []pilosa.FieldRow) []*internal.FieldRow { return other } -func (s Serializer) endcodeExtractedIDMatrix(m pilosa.ExtractedIDMatrix) *internal.ExtractedIDMatrix { - cols := make([]*internal.ExtractedIDColumn, len(m.Columns)) +func (s Serializer) endcodeExtractedIDMatrix(m pilosa.ExtractedIDMatrix) *pb.ExtractedIDMatrix { + cols := make([]*pb.ExtractedIDColumn, len(m.Columns)) for i, v := range m.Columns { - vals := make([]*internal.IDList, len(v.Rows)) + vals := make([]*pb.IDList, len(v.Rows)) for j, f := range v.Rows { - vals[j] = &internal.IDList{IDs: f} + vals[j] = &pb.IDList{IDs: f} } - cols[i] = &internal.ExtractedIDColumn{ + cols[i] = &pb.ExtractedIDColumn{ ID: v.ColumnID, Vals: vals, } } - return &internal.ExtractedIDMatrix{ + return &pb.ExtractedIDMatrix{ Fields: m.Fields, Columns: cols, } } -func (s Serializer) encodeExtractedTable(t pilosa.ExtractedTable) *internal.ExtractedTable { - fields := make([]*internal.ExtractedTableField, len(t.Fields)) +func (s Serializer) encodeExtractedTable(t pilosa.ExtractedTable) *pb.ExtractedTable { + fields := make([]*pb.ExtractedTableField, len(t.Fields)) for i, f := range t.Fields { - fields[i] = &internal.ExtractedTableField{ + fields[i] = &pb.ExtractedTableField{ Name: f.Name, Type: f.Type, } } - cols := make([]*internal.ExtractedTableColumn, len(t.Columns)) + cols := make([]*pb.ExtractedTableColumn, len(t.Columns)) for i, c := range t.Columns { - var col internal.ExtractedTableColumn + var col pb.ExtractedTableColumn if c.Column.Keyed { - col.KeyOrID = &internal.ExtractedTableColumn_Key{Key: c.Column.Key} + col.KeyOrID = &pb.ExtractedTableColumn_Key{Key: c.Column.Key} } else { - col.KeyOrID = &internal.ExtractedTableColumn_ID{ID: c.Column.ID} + col.KeyOrID = &pb.ExtractedTableColumn_ID{ID: c.Column.ID} } - rows := make([]*internal.ExtractedTableValue, len(c.Rows)) + rows := make([]*pb.ExtractedTableValue, len(c.Rows)) for j, v := range c.Rows { switch v := v.(type) { case []uint64: - rows[j] = &internal.ExtractedTableValue{ - Value: &internal.ExtractedTableValue_IDs{ - IDs: &internal.IDList{ + rows[j] = &pb.ExtractedTableValue{ + Value: &pb.ExtractedTableValue_IDs{ + IDs: &pb.IDList{ IDs: v, }, }, } case []string: - rows[j] = &internal.ExtractedTableValue{ - Value: &internal.ExtractedTableValue_Keys{ - Keys: &internal.KeyList{ + rows[j] = &pb.ExtractedTableValue{ + Value: &pb.ExtractedTableValue_Keys{ + Keys: &pb.KeyList{ Keys: v, }, }, } case int64: - rows[j] = &internal.ExtractedTableValue{ - Value: &internal.ExtractedTableValue_BSIValue{ + rows[j] = &pb.ExtractedTableValue{ + Value: &pb.ExtractedTableValue_BSIValue{ BSIValue: v, }, } case uint64: - rows[j] = &internal.ExtractedTableValue{ - Value: &internal.ExtractedTableValue_MutexID{ + rows[j] = &pb.ExtractedTableValue{ + Value: &pb.ExtractedTableValue_MutexID{ MutexID: v, }, } case string: - rows[j] = &internal.ExtractedTableValue{ - Value: &internal.ExtractedTableValue_MutexKey{ + rows[j] = &pb.ExtractedTableValue{ + Value: &pb.ExtractedTableValue_MutexKey{ MutexKey: v, }, } case bool: - rows[j] = &internal.ExtractedTableValue{ - Value: &internal.ExtractedTableValue_Bool{ + rows[j] = &pb.ExtractedTableValue{ + Value: &pb.ExtractedTableValue_Bool{ Bool: v, }, } @@ -1850,23 +1850,23 @@ func (s Serializer) encodeExtractedTable(t pilosa.ExtractedTable) *internal.Extr cols[i] = &col } - return &internal.ExtractedTable{ + return &pb.ExtractedTable{ Fields: fields, Columns: cols, } } -func (s Serializer) encodePairs(a pilosa.Pairs) []*internal.Pair { - other := make([]*internal.Pair, len(a)) +func (s Serializer) encodePairs(a pilosa.Pairs) []*pb.Pair { + other := make([]*pb.Pair, len(a)) for i := range a { other[i] = s.encodePair(a[i]) } return other } -func (s Serializer) encodePairsField(a *pilosa.PairsField) *internal.PairsField { - other := &internal.PairsField{ - Pairs: make([]*internal.Pair, len(a.Pairs)), +func (s Serializer) encodePairsField(a *pilosa.PairsField) *pb.PairsField { + other := &pb.PairsField{ + Pairs: make([]*pb.Pair, len(a.Pairs)), } for i := range a.Pairs { other.Pairs[i] = s.encodePair(a.Pairs[i]) @@ -1875,23 +1875,23 @@ func (s Serializer) encodePairsField(a *pilosa.PairsField) *internal.PairsField return other } -func (s Serializer) encodePair(p pilosa.Pair) *internal.Pair { - return &internal.Pair{ +func (s Serializer) encodePair(p pilosa.Pair) *pb.Pair { + return &pb.Pair{ ID: p.ID, Key: p.Key, Count: p.Count, } } -func (s Serializer) encodePairField(p pilosa.PairField) *internal.PairField { - return &internal.PairField{ +func (s Serializer) encodePairField(p pilosa.PairField) *pb.PairField { + return &pb.PairField{ Pair: s.encodePair(p.Pair), Field: p.Field, } } -func (s Serializer) encodeValCount(vc pilosa.ValCount) *internal.ValCount { - return &internal.ValCount{ +func (s Serializer) encodeValCount(vc pilosa.ValCount) *pb.ValCount { + return &pb.ValCount{ Val: vc.Val, FloatVal: vc.FloatVal, DecimalVal: s.encodeDecimal(vc.DecimalVal), @@ -1899,33 +1899,33 @@ func (s Serializer) encodeValCount(vc pilosa.ValCount) *internal.ValCount { } } -func (s Serializer) encodeDecimal(p *pql.Decimal) *internal.Decimal { +func (s Serializer) encodeDecimal(p *pql.Decimal) *pb.Decimal { if p == nil { return nil } - return &internal.Decimal{ + return &pb.Decimal{ Value: p.Value, Scale: p.Scale, } } -func (s Serializer) encodeAttrs(m map[string]interface{}) []*internal.Attr { +func (s Serializer) encodeAttrs(m map[string]interface{}) []*pb.Attr { keys := make([]string, 0, len(m)) for k := range m { keys = append(keys, k) } sort.Strings(keys) - a := make([]*internal.Attr, len(keys)) + a := make([]*pb.Attr, len(keys)) for i := range keys { a[i] = s.encodeAttr(keys[i], m[keys[i]]) } return a } -// s.encodeAttr converts a key/value pair into an Attr internal representation. -func (s Serializer) encodeAttr(key string, value interface{}) *internal.Attr { - pb := &internal.Attr{Key: key} +// s.encodeAttr converts a key/value pair into an Attr pb.representation. +func (s Serializer) encodeAttr(key string, value interface{}) *pb.Attr { + pb := &pb.Attr{Key: key} switch value := value.(type) { case string: pb.Type = attrTypeString @@ -1946,22 +1946,22 @@ func (s Serializer) encodeAttr(key string, value interface{}) *internal.Attr { return pb } -func (s Serializer) encodeResizeNodeMessage(m *pilosa.ResizeNodeMessage) *internal.ResizeNodeMessage { - return &internal.ResizeNodeMessage{ +func (s Serializer) encodeResizeNodeMessage(m *pilosa.ResizeNodeMessage) *pb.ResizeNodeMessage { + return &pb.ResizeNodeMessage{ NodeID: m.NodeID, Action: m.Action, } } -func (s Serializer) encodeResizeAbortMessage(*pilosa.ResizeAbortMessage) *internal.ResizeAbortMessage { - return &internal.ResizeAbortMessage{} +func (s Serializer) encodeResizeAbortMessage(*pilosa.ResizeAbortMessage) *pb.ResizeAbortMessage { + return &pb.ResizeAbortMessage{} } -func decodeResizeNodeMessage(pb *internal.ResizeNodeMessage, m *pilosa.ResizeNodeMessage) { +func decodeResizeNodeMessage(pb *pb.ResizeNodeMessage, m *pilosa.ResizeNodeMessage) { m.NodeID = pb.NodeID m.Action = pb.Action } -func decodeResizeAbortMessage(pb *internal.ResizeAbortMessage, m *pilosa.ResizeAbortMessage) { +func decodeResizeAbortMessage(pb *pb.ResizeAbortMessage, m *pilosa.ResizeAbortMessage) { } diff --git a/executor.go b/executor.go index 9ee05633e..bc9b3014e 100644 --- a/executor.go +++ b/executor.go @@ -30,7 +30,7 @@ import ( "github.com/pilosa/pilosa/v2/disco" "github.com/pilosa/pilosa/v2/pql" - pb "github.com/pilosa/pilosa/v2/proto" + "github.com/pilosa/pilosa/v2/proto" "github.com/pilosa/pilosa/v2/roaring" "github.com/pilosa/pilosa/v2/shardwidth" "github.com/pilosa/pilosa/v2/testhook" @@ -2734,37 +2734,37 @@ func (r *RowIdentifiers) Clone() (clone *RowIdentifiers) { } // ToTable implements the ToTabler interface. -func (r RowIdentifiers) ToTable() (*pb.TableResponse, error) { +func (r RowIdentifiers) ToTable() (*proto.TableResponse, error) { var n int if len(r.Keys) > 0 { n = len(r.Keys) } else { n = len(r.Rows) } - return pb.RowsToTable(&r, n) + return proto.RowsToTable(&r, n) } // ToRows implements the ToRowser interface. -func (r RowIdentifiers) ToRows(callback func(*pb.RowResponse) error) error { +func (r RowIdentifiers) ToRows(callback func(*proto.RowResponse) error) error { if len(r.Keys) > 0 { - ci := []*pb.ColumnInfo{{Name: r.Field(), Datatype: "string"}} + ci := []*proto.ColumnInfo{{Name: r.Field(), Datatype: "string"}} for _, key := range r.Keys { - if err := callback(&pb.RowResponse{ + if err := callback(&proto.RowResponse{ Headers: ci, - Columns: []*pb.ColumnResponse{ - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_StringVal{StringVal: key}}, + Columns: []*proto.ColumnResponse{ + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_StringVal{StringVal: key}}, }}); err != nil { return errors.Wrap(err, "calling callback") } ci = nil } } else { - ci := []*pb.ColumnInfo{{Name: r.Field(), Datatype: "uint64"}} + ci := []*proto.ColumnInfo{{Name: r.Field(), Datatype: "uint64"}} for _, id := range r.Rows { - if err := callback(&pb.RowResponse{ + if err := callback(&proto.RowResponse{ Headers: ci, - Columns: []*pb.ColumnResponse{ - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Uint64Val{Uint64Val: uint64(id)}}, + Columns: []*proto.ColumnResponse{ + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Uint64Val{Uint64Val: uint64(id)}}, }}); err != nil { return errors.Wrap(err, "calling callback") } @@ -3282,50 +3282,50 @@ func NewGroupCounts(agg string, groups ...GroupCount) *GroupCounts { } // ToTable implements the ToTabler interface. -func (g *GroupCounts) ToTable() (*pb.TableResponse, error) { - return pb.RowsToTable(g, len(g.Groups())) +func (g *GroupCounts) ToTable() (*proto.TableResponse, error) { + return proto.RowsToTable(g, len(g.Groups())) } // ToRows implements the ToRowser interface. -func (g *GroupCounts) ToRows(callback func(*pb.RowResponse) error) error { +func (g *GroupCounts) ToRows(callback func(*proto.RowResponse) error) error { agg := g.AggregateColumn() for i, gc := range g.Groups() { - var ci []*pb.ColumnInfo + var ci []*proto.ColumnInfo if i == 0 { for _, fieldRow := range gc.Group { if fieldRow.RowKey != "" { - ci = append(ci, &pb.ColumnInfo{Name: fieldRow.Field, Datatype: "string"}) + ci = append(ci, &proto.ColumnInfo{Name: fieldRow.Field, Datatype: "string"}) } else if fieldRow.Value != nil { - ci = append(ci, &pb.ColumnInfo{Name: fieldRow.Field, Datatype: "int64"}) + ci = append(ci, &proto.ColumnInfo{Name: fieldRow.Field, Datatype: "int64"}) } else { - ci = append(ci, &pb.ColumnInfo{Name: fieldRow.Field, Datatype: "uint64"}) + ci = append(ci, &proto.ColumnInfo{Name: fieldRow.Field, Datatype: "uint64"}) } } - ci = append(ci, &pb.ColumnInfo{Name: "count", Datatype: "uint64"}) + ci = append(ci, &proto.ColumnInfo{Name: "count", Datatype: "uint64"}) if agg != "" { - ci = append(ci, &pb.ColumnInfo{Name: agg, Datatype: "int64"}) + ci = append(ci, &proto.ColumnInfo{Name: agg, Datatype: "int64"}) } } - rowResp := &pb.RowResponse{ + rowResp := &proto.RowResponse{ Headers: ci, - Columns: []*pb.ColumnResponse{}, + Columns: []*proto.ColumnResponse{}, } for _, fieldRow := range gc.Group { if fieldRow.RowKey != "" { - rowResp.Columns = append(rowResp.Columns, &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_StringVal{StringVal: fieldRow.RowKey}}) + rowResp.Columns = append(rowResp.Columns, &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_StringVal{StringVal: fieldRow.RowKey}}) } else if fieldRow.Value != nil { - rowResp.Columns = append(rowResp.Columns, &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Int64Val{Int64Val: *fieldRow.Value}}) + rowResp.Columns = append(rowResp.Columns, &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Int64Val{Int64Val: *fieldRow.Value}}) } else { - rowResp.Columns = append(rowResp.Columns, &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Uint64Val{Uint64Val: fieldRow.RowID}}) + rowResp.Columns = append(rowResp.Columns, &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Uint64Val{Uint64Val: fieldRow.RowID}}) } } rowResp.Columns = append(rowResp.Columns, - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Uint64Val{Uint64Val: gc.Count}}) + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Uint64Val{Uint64Val: gc.Count}}) if agg != "" { rowResp.Columns = append(rowResp.Columns, - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Int64Val{Int64Val: gc.Agg}}) + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Int64Val{Int64Val: gc.Agg}}) } if err := callback(rowResp); err != nil { return errors.Wrap(err, "calling callback") @@ -3861,93 +3861,93 @@ type ExtractedTable struct { } // ToRows implements the ToRowser interface. -func (t ExtractedTable) ToRows(callback func(*pb.RowResponse) error) error { +func (t ExtractedTable) ToRows(callback func(*proto.RowResponse) error) error { if len(t.Columns) == 0 { return nil } - headers := make([]*pb.ColumnInfo, len(t.Fields)+1) + headers := make([]*proto.ColumnInfo, len(t.Fields)+1) colType := "uint64" if t.Columns[0].Column.Keyed { colType = "string" } - headers[0] = &pb.ColumnInfo{ + headers[0] = &proto.ColumnInfo{ Name: "_id", Datatype: colType, } dataHeaders := headers[1:] for i, f := range t.Fields { - dataHeaders[i] = &pb.ColumnInfo{ + dataHeaders[i] = &proto.ColumnInfo{ Name: f.Name, Datatype: f.Type, } } for _, c := range t.Columns { - cols := make([]*pb.ColumnResponse, len(c.Rows)+1) + cols := make([]*proto.ColumnResponse, len(c.Rows)+1) if c.Column.Keyed { - cols[0] = &pb.ColumnResponse{ - ColumnVal: &pb.ColumnResponse_StringVal{ + cols[0] = &proto.ColumnResponse{ + ColumnVal: &proto.ColumnResponse_StringVal{ StringVal: c.Column.Key, }, } } else { - cols[0] = &pb.ColumnResponse{ - ColumnVal: &pb.ColumnResponse_Uint64Val{ + cols[0] = &proto.ColumnResponse{ + ColumnVal: &proto.ColumnResponse_Uint64Val{ Uint64Val: c.Column.ID, }, } } valCols := cols[1:] for i, r := range c.Rows { - var col *pb.ColumnResponse + var col *proto.ColumnResponse switch r := r.(type) { case nil: - col = &pb.ColumnResponse{} + col = &proto.ColumnResponse{} case bool: - col = &pb.ColumnResponse{ - ColumnVal: &pb.ColumnResponse_BoolVal{ + col = &proto.ColumnResponse{ + ColumnVal: &proto.ColumnResponse_BoolVal{ BoolVal: r, }, } case int64: - col = &pb.ColumnResponse{ - ColumnVal: &pb.ColumnResponse_Int64Val{ + col = &proto.ColumnResponse{ + ColumnVal: &proto.ColumnResponse_Int64Val{ Int64Val: r, }, } case uint64: - col = &pb.ColumnResponse{ - ColumnVal: &pb.ColumnResponse_Uint64Val{ + col = &proto.ColumnResponse{ + ColumnVal: &proto.ColumnResponse_Uint64Val{ Uint64Val: r, }, } case string: - col = &pb.ColumnResponse{ - ColumnVal: &pb.ColumnResponse_StringVal{ + col = &proto.ColumnResponse{ + ColumnVal: &proto.ColumnResponse_StringVal{ StringVal: r, }, } case []uint64: - col = &pb.ColumnResponse{ - ColumnVal: &pb.ColumnResponse_Uint64ArrayVal{ - Uint64ArrayVal: &pb.Uint64Array{ + col = &proto.ColumnResponse{ + ColumnVal: &proto.ColumnResponse_Uint64ArrayVal{ + Uint64ArrayVal: &proto.Uint64Array{ Vals: r, }, }, } case []string: - col = &pb.ColumnResponse{ - ColumnVal: &pb.ColumnResponse_StringArrayVal{ - StringArrayVal: &pb.StringArray{ + col = &proto.ColumnResponse{ + ColumnVal: &proto.ColumnResponse_StringArrayVal{ + StringArrayVal: &proto.StringArray{ Vals: r, }, }, } case pql.Decimal: - col = &pb.ColumnResponse{ - ColumnVal: &pb.ColumnResponse_DecimalVal{ - DecimalVal: &pb.Decimal{ + col = &proto.ColumnResponse{ + ColumnVal: &proto.ColumnResponse_DecimalVal{ + DecimalVal: &proto.Decimal{ Value: r.Value, Scale: r.Scale, }, @@ -3958,7 +3958,7 @@ func (t ExtractedTable) ToRows(callback func(*pb.RowResponse) error) error { } valCols[i] = col } - err := callback(&pb.RowResponse{ + err := callback(&proto.RowResponse{ Headers: headers, Columns: cols, }) @@ -3971,8 +3971,8 @@ func (t ExtractedTable) ToRows(callback func(*pb.RowResponse) error) error { } // ToTable converts the table to protobuf format. -func (t ExtractedTable) ToTable() (*pb.TableResponse, error) { - return pb.RowsToTable(t, len(t.Columns)) +func (t ExtractedTable) ToTable() (*proto.TableResponse, error) { + return proto.RowsToTable(t, len(t.Columns)) } type ExtractedIDColumn struct { @@ -5633,12 +5633,12 @@ func (e *executor) remoteExec(ctx context.Context, node *topology.Node, index st EmbeddedData: embed, } - pb, err := e.client.QueryNode(ctx, &node.URI, index, pbreq) + resp, err := e.client.QueryNode(ctx, &node.URI, index, pbreq) if err != nil { return nil, err } - return pb.Results, pb.Err + return resp.Results, resp.Err } // shardsByNode returns a mapping of nodes to shards. @@ -7305,7 +7305,7 @@ func (s *SignedRow) Field() string { } // ToTable implements the ToTabler interface. -func (s SignedRow) ToTable() (*pb.TableResponse, error) { +func (s SignedRow) ToTable() (*proto.TableResponse, error) { var n uint64 if s.Neg != nil { n += s.Neg.Count() @@ -7313,13 +7313,13 @@ func (s SignedRow) ToTable() (*pb.TableResponse, error) { if s.Pos != nil { n += s.Pos.Count() } - return pb.RowsToTable(&s, int(n)) + return proto.RowsToTable(&s, int(n)) } // ToRows implements the ToRowser interface. -func (s SignedRow) ToRows(callback func(*pb.RowResponse) error) error { +func (s SignedRow) ToRows(callback func(*proto.RowResponse) error) error { - ci := []*pb.ColumnInfo{{Name: s.Field(), Datatype: "int64"}} + ci := []*proto.ColumnInfo{{Name: s.Field(), Datatype: "int64"}} if s.Neg != nil { negs := s.Neg.Columns() for i := len(negs) - 1; i >= 0; i-- { @@ -7328,10 +7328,10 @@ func (s SignedRow) ToRows(callback func(*pb.RowResponse) error) error { return errors.Wrap(err, "converting uint64 to int64 (negative)") } - if err := callback(&pb.RowResponse{ + if err := callback(&proto.RowResponse{ Headers: ci, - Columns: []*pb.ColumnResponse{ - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Int64Val{Int64Val: val}}, + Columns: []*proto.ColumnResponse{ + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Int64Val{Int64Val: val}}, }, }); err != nil { return errors.Wrap(err, "calling callback") @@ -7346,10 +7346,10 @@ func (s SignedRow) ToRows(callback func(*pb.RowResponse) error) error { return errors.Wrap(err, "converting uint64 to int64 (positive)") } - if err := callback(&pb.RowResponse{ + if err := callback(&proto.RowResponse{ Headers: ci, - Columns: []*pb.ColumnResponse{ - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Int64Val{Int64Val: val}}, + Columns: []*proto.ColumnResponse{ + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Int64Val{Int64Val: val}}, }, }); err != nil { return errors.Wrap(err, "calling callback") @@ -7430,51 +7430,51 @@ func (v *ValCount) Clone() (r *ValCount) { } // ToTable implements the ToTabler interface. -func (v ValCount) ToTable() (*pb.TableResponse, error) { - return pb.RowsToTable(&v, 1) +func (v ValCount) ToTable() (*proto.TableResponse, error) { + return proto.RowsToTable(&v, 1) } // ToRows implements the ToRowser interface. -func (v ValCount) ToRows(callback func(*pb.RowResponse) error) error { - var ci []*pb.ColumnInfo +func (v ValCount) ToRows(callback func(*proto.RowResponse) error) error { + var ci []*proto.ColumnInfo // ValCount can have a decimal, float, or integer value, but // not more than one (as of this writing). if v.DecimalVal != nil { - ci = []*pb.ColumnInfo{ + ci = []*proto.ColumnInfo{ {Name: "value", Datatype: "decimal"}, {Name: "count", Datatype: "int64"}, } - if err := callback(&pb.RowResponse{ + if err := callback(&proto.RowResponse{ Headers: ci, - Columns: []*pb.ColumnResponse{ - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_DecimalVal{DecimalVal: &pb.Decimal{Value: v.DecimalVal.Value, Scale: v.DecimalVal.Scale}}}, - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Int64Val{Int64Val: v.Count}}, + Columns: []*proto.ColumnResponse{ + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_DecimalVal{DecimalVal: &proto.Decimal{Value: v.DecimalVal.Value, Scale: v.DecimalVal.Scale}}}, + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Int64Val{Int64Val: v.Count}}, }}); err != nil { return errors.Wrap(err, "calling callback") } } else if v.FloatVal != 0 { - ci = []*pb.ColumnInfo{ + ci = []*proto.ColumnInfo{ {Name: "value", Datatype: "float64"}, {Name: "count", Datatype: "int64"}, } - if err := callback(&pb.RowResponse{ + if err := callback(&proto.RowResponse{ Headers: ci, - Columns: []*pb.ColumnResponse{ - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Float64Val{Float64Val: v.FloatVal}}, - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Int64Val{Int64Val: v.Count}}, + Columns: []*proto.ColumnResponse{ + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Float64Val{Float64Val: v.FloatVal}}, + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Int64Val{Int64Val: v.Count}}, }}); err != nil { return errors.Wrap(err, "calling callback") } } else { - ci = []*pb.ColumnInfo{ + ci = []*proto.ColumnInfo{ {Name: "value", Datatype: "int64"}, {Name: "count", Datatype: "int64"}, } - if err := callback(&pb.RowResponse{ + if err := callback(&proto.RowResponse{ Headers: ci, - Columns: []*pb.ColumnResponse{ - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Int64Val{Int64Val: v.Val}}, - &pb.ColumnResponse{ColumnVal: &pb.ColumnResponse_Int64Val{Int64Val: v.Count}}, + Columns: []*proto.ColumnResponse{ + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Int64Val{Int64Val: v.Val}}, + &proto.ColumnResponse{ColumnVal: &proto.ColumnResponse_Int64Val{Int64Val: v.Count}}, }}); err != nil { return errors.Wrap(err, "calling callback") } diff --git a/fragment.go b/fragment.go index b9c6eb154..675146a16 100644 --- a/fragment.go +++ b/fragment.go @@ -40,9 +40,9 @@ import ( "github.com/cespare/xxhash" "github.com/gogo/protobuf/proto" - "github.com/pilosa/pilosa/v2/internal" "github.com/pilosa/pilosa/v2/logger" pnet "github.com/pilosa/pilosa/v2/net" + "github.com/pilosa/pilosa/v2/pb" "github.com/pilosa/pilosa/v2/pql" "github.com/pilosa/pilosa/v2/roaring" "github.com/pilosa/pilosa/v2/shardwidth" @@ -533,7 +533,7 @@ func (f *fragment) openCache() error { } // Unmarshal cache data. - var pb internal.Cache + var pb pb.Cache if err := proto.Unmarshal(buf, &pb); err != nil { f.holder.Logger.Printf("error unmarshaling cache data, skipping: path=%s, err=%s", path, err) return nil @@ -696,7 +696,7 @@ func (f *fragment) setBit(tx Tx, rowID, columnID uint64) (changed bool, err erro err = f.gen.Transaction(wp, doSetFunc) } else { if tx.Type() == RoaringTxn { - panic("internal error: f.gen was nil. should never happen under roaring b/c storage should be open") + panic("pb.error: f.gen was nil. should never happen under roaring b/c storage should be open") } // else blue green or transactional backend. Just do it. err = doSetFunc() @@ -2535,7 +2535,7 @@ func (f *fragment) importPositions(tx Tx, set, clear []uint64, rowSet map[uint64 err = f.gen.Transaction(wp, doFunc) } else { if tx.Type() == RoaringTxn { - panic("internal error: 2nd place, f.gen was nil. should never happen under roaring b/c storage should be open") + panic("pb.error: 2nd place, f.gen was nil. should never happen under roaring b/c storage should be open") } // else blue green or transactional backend. Just do it. err = doFunc() @@ -2992,7 +2992,7 @@ func (f *fragment) flushCache() error { ids := f.cache.IDs() // Marshal cache data to bytes. - buf, err := proto.Marshal(&internal.Cache{IDs: ids}) + buf, err := proto.Marshal(&pb.Cache{IDs: ids}) if err != nil { return errors.Wrap(err, "marshalling") } diff --git a/go.mod b/go.mod index 20a40f07d..b21a10dad 100644 --- a/go.mod +++ b/go.mod @@ -23,7 +23,6 @@ require ( github.com/gorilla/handlers v1.3.0 github.com/gorilla/mux v1.7.0 github.com/improbable-eng/grpc-web v0.13.0 - github.com/kisielk/errcheck v1.5.0 // indirect github.com/lib/pq v1.8.0 github.com/molecula/apophenia v0.0.0-20190827192002-68b7a14a478b github.com/opentracing/opentracing-go v1.1.0 @@ -51,7 +50,6 @@ require ( golang.org/x/sync v0.0.0-20210220032951-036812b2e83c golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4 // indirect golang.org/x/text v0.3.5 // indirect - golang.org/x/tools v0.0.0-20210106214847-113979e3529a // indirect google.golang.org/grpc v1.28.0 gopkg.in/yaml.v2 v2.3.0 // indirect modernc.org/mathutil v1.0.0 diff --git a/go.sum b/go.sum index c987751dd..56cd62a14 100644 --- a/go.sum +++ b/go.sum @@ -138,12 +138,8 @@ github.com/gopherjs/gopherjs v0.0.0-20200217142428-fce0ec30dd00 h1:l5lAOZEym3oK3 github.com/gopherjs/gopherjs v0.0.0-20200217142428-fce0ec30dd00/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/handlers v1.3.0 h1:tsg9qP3mjt1h4Roxp+M1paRjrVBfPSOpBuVclh6YluI= github.com/gorilla/handlers v1.3.0/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ= -github.com/gorilla/handlers v1.4.1 h1:BHvcRGJe/TrL+OqFxoKQGddTgeibiOjaBssV5a/N9sw= -github.com/gorilla/handlers v1.4.1/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ= github.com/gorilla/mux v1.7.0 h1:tOSd0UKHQd6urX6ApfOn4XdBMY6Sh1MfxV3kmaazO+U= github.com/gorilla/mux v1.7.0/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= -github.com/gorilla/mux v1.7.3 h1:gnP5JzjVOuiZD07fKKToCAOjS0yOpj/qPETTXCCS6hw= -github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= github.com/gorilla/websocket v1.4.2 h1:+/TMaTYc4QFitKJxsQ7Yye35DkWvkdLcvGKqM+x0Ufc= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= diff --git a/internal/LICENSE b/internal/LICENSE deleted file mode 100644 index d64569567..000000000 --- a/internal/LICENSE +++ /dev/null @@ -1,202 +0,0 @@ - - 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. diff --git a/internal/internal.go b/pb/pb.go similarity index 98% rename from internal/internal.go rename to pb/pb.go index e316aba1b..b30055f3e 100644 --- a/internal/internal.go +++ b/pb/pb.go @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -package internal +package pb import ( "io" diff --git a/internal/private.pb.go b/pb/private.pb.go similarity index 95% rename from internal/private.pb.go rename to pb/private.pb.go index 742211a43..e464f3f8f 100644 --- a/internal/private.pb.go +++ b/pb/private.pb.go @@ -1,7 +1,24 @@ +// Copyright 2017 Pilosa Corp. +// +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. + // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: private.proto -package internal +package pb import ( fmt "fmt" @@ -2472,143 +2489,142 @@ func (m *ResizeNodeMessage) GetAction() string { } func init() { - proto.RegisterType((*IndexMeta)(nil), "internal.IndexMeta") - proto.RegisterType((*FieldOptions)(nil), "internal.FieldOptions") - proto.RegisterType((*ImportResponse)(nil), "internal.ImportResponse") - proto.RegisterType((*BlockDataRequest)(nil), "internal.BlockDataRequest") - proto.RegisterType((*BlockDataResponse)(nil), "internal.BlockDataResponse") - proto.RegisterType((*Cache)(nil), "internal.Cache") - proto.RegisterType((*MaxShards)(nil), "internal.MaxShards") - proto.RegisterMapType((map[string]uint64)(nil), "internal.MaxShards.StandardEntry") - proto.RegisterType((*CreateShardMessage)(nil), "internal.CreateShardMessage") - proto.RegisterType((*DeleteIndexMessage)(nil), "internal.DeleteIndexMessage") - proto.RegisterType((*CreateIndexMessage)(nil), "internal.CreateIndexMessage") - proto.RegisterType((*CreateFieldMessage)(nil), "internal.CreateFieldMessage") - proto.RegisterType((*DeleteFieldMessage)(nil), "internal.DeleteFieldMessage") - proto.RegisterType((*DeleteAvailableShardMessage)(nil), "internal.DeleteAvailableShardMessage") - proto.RegisterType((*Field)(nil), "internal.Field") - proto.RegisterType((*Schema)(nil), "internal.Schema") - proto.RegisterType((*Index)(nil), "internal.Index") - proto.RegisterType((*URI)(nil), "internal.URI") - proto.RegisterType((*Node)(nil), "internal.Node") - proto.RegisterType((*NodeStateMessage)(nil), "internal.NodeStateMessage") - proto.RegisterType((*NodeEventMessage)(nil), "internal.NodeEventMessage") - proto.RegisterType((*NodeStatus)(nil), "internal.NodeStatus") - proto.RegisterType((*IndexStatus)(nil), "internal.IndexStatus") - proto.RegisterType((*FieldStatus)(nil), "internal.FieldStatus") - proto.RegisterType((*ClusterStatus)(nil), "internal.ClusterStatus") - proto.RegisterType((*BSIGroup)(nil), "internal.BSIGroup") - proto.RegisterType((*CreateViewMessage)(nil), "internal.CreateViewMessage") - proto.RegisterType((*DeleteViewMessage)(nil), "internal.DeleteViewMessage") - proto.RegisterType((*ResizeInstruction)(nil), "internal.ResizeInstruction") - proto.RegisterType((*ResizeSource)(nil), "internal.ResizeSource") - proto.RegisterType((*TranslationResizeSource)(nil), "internal.TranslationResizeSource") - proto.RegisterType((*ResizeInstructionComplete)(nil), "internal.ResizeInstructionComplete") - proto.RegisterType((*Topology)(nil), "internal.Topology") - proto.RegisterType((*RecalculateCaches)(nil), "internal.RecalculateCaches") - proto.RegisterType((*LoadSchemaMessage)(nil), "internal.LoadSchemaMessage") - proto.RegisterType((*TransactionMessage)(nil), "internal.TransactionMessage") - proto.RegisterType((*Transaction)(nil), "internal.Transaction") - proto.RegisterType((*TransactionStats)(nil), "internal.TransactionStats") - proto.RegisterType((*ResizeAbortMessage)(nil), "internal.ResizeAbortMessage") - proto.RegisterType((*ResizeNodeMessage)(nil), "internal.ResizeNodeMessage") + proto.RegisterType((*IndexMeta)(nil), "pb.IndexMeta") + proto.RegisterType((*FieldOptions)(nil), "pb.FieldOptions") + proto.RegisterType((*ImportResponse)(nil), "pb.ImportResponse") + proto.RegisterType((*BlockDataRequest)(nil), "pb.BlockDataRequest") + proto.RegisterType((*BlockDataResponse)(nil), "pb.BlockDataResponse") + proto.RegisterType((*Cache)(nil), "pb.Cache") + proto.RegisterType((*MaxShards)(nil), "pb.MaxShards") + proto.RegisterMapType((map[string]uint64)(nil), "pb.MaxShards.StandardEntry") + proto.RegisterType((*CreateShardMessage)(nil), "pb.CreateShardMessage") + proto.RegisterType((*DeleteIndexMessage)(nil), "pb.DeleteIndexMessage") + proto.RegisterType((*CreateIndexMessage)(nil), "pb.CreateIndexMessage") + proto.RegisterType((*CreateFieldMessage)(nil), "pb.CreateFieldMessage") + proto.RegisterType((*DeleteFieldMessage)(nil), "pb.DeleteFieldMessage") + proto.RegisterType((*DeleteAvailableShardMessage)(nil), "pb.DeleteAvailableShardMessage") + proto.RegisterType((*Field)(nil), "pb.Field") + proto.RegisterType((*Schema)(nil), "pb.Schema") + proto.RegisterType((*Index)(nil), "pb.Index") + proto.RegisterType((*URI)(nil), "pb.URI") + proto.RegisterType((*Node)(nil), "pb.Node") + proto.RegisterType((*NodeStateMessage)(nil), "pb.NodeStateMessage") + proto.RegisterType((*NodeEventMessage)(nil), "pb.NodeEventMessage") + proto.RegisterType((*NodeStatus)(nil), "pb.NodeStatus") + proto.RegisterType((*IndexStatus)(nil), "pb.IndexStatus") + proto.RegisterType((*FieldStatus)(nil), "pb.FieldStatus") + proto.RegisterType((*ClusterStatus)(nil), "pb.ClusterStatus") + proto.RegisterType((*BSIGroup)(nil), "pb.BSIGroup") + proto.RegisterType((*CreateViewMessage)(nil), "pb.CreateViewMessage") + proto.RegisterType((*DeleteViewMessage)(nil), "pb.DeleteViewMessage") + proto.RegisterType((*ResizeInstruction)(nil), "pb.ResizeInstruction") + proto.RegisterType((*ResizeSource)(nil), "pb.ResizeSource") + proto.RegisterType((*TranslationResizeSource)(nil), "pb.TranslationResizeSource") + proto.RegisterType((*ResizeInstructionComplete)(nil), "pb.ResizeInstructionComplete") + proto.RegisterType((*Topology)(nil), "pb.Topology") + proto.RegisterType((*RecalculateCaches)(nil), "pb.RecalculateCaches") + proto.RegisterType((*LoadSchemaMessage)(nil), "pb.LoadSchemaMessage") + proto.RegisterType((*TransactionMessage)(nil), "pb.TransactionMessage") + proto.RegisterType((*Transaction)(nil), "pb.Transaction") + proto.RegisterType((*TransactionStats)(nil), "pb.TransactionStats") + proto.RegisterType((*ResizeAbortMessage)(nil), "pb.ResizeAbortMessage") + proto.RegisterType((*ResizeNodeMessage)(nil), "pb.ResizeNodeMessage") } func init() { proto.RegisterFile("private.proto", fileDescriptor_d2a91b51c7bdc125) } var fileDescriptor_d2a91b51c7bdc125 = []byte{ - // 1456 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x58, 0xdd, 0x6e, 0x1b, 0xc5, - 0x17, 0xff, 0xaf, 0xd7, 0x8e, 0xed, 0xe3, 0x38, 0x75, 0xa6, 0x69, 0xba, 0xcd, 0xbf, 0x0a, 0x66, - 0x40, 0xd4, 0x54, 0x6a, 0xa8, 0x5a, 0x24, 0x10, 0xa8, 0x52, 0x93, 0x38, 0x2d, 0x86, 0xa6, 0x4d, - 0x27, 0x69, 0xef, 0x27, 0xeb, 0x51, 0xb3, 0xca, 0x7a, 0xd7, 0xdd, 0x8f, 0xd4, 0x2e, 0x12, 0xb7, - 0x20, 0xb8, 0x42, 0x70, 0xc1, 0x25, 0xef, 0xc1, 0x0b, 0x70, 0xc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 0x3f, 0x58, 0xc3, 0xd4, 0xbc, 0xb0, 0x0c, - 0x29, 0x7f, 0x3b, 0x76, 0x05, 0xef, 0xfb, 0x5e, 0x20, 0x70, 0x82, 0x6c, 0x96, 0xd1, 0xe4, 0xa6, - 0xda, 0xd5, 0xe6, 0x18, 0xac, 0xcd, 0x84, 0x8f, 0x1a, 0x6a, 0x8f, 0xc7, 0x94, 0x40, 0x6b, 0x5a, - 0x44, 0x57, 0x80, 0xa8, 0x99, 0xd8, 0x3c, 0x0c, 0x23, 0x73, 0xb5, 0xd3, 0x6d, 0xb3, 0x9e, 0x64, - 0x27, 0xe6, 0xbd, 0x18, 0xf2, 0x2a, 0x97, 0x8a, 0x55, 0xde, 0x6a, 0xfd, 0xfe, 0x6a, 0xdd, 0xfa, - 0xe3, 0xd5, 0xba, 0xf5, 0xe7, 0xab, 0x75, 0xeb, 0x97, 0xbf, 0xd6, 0xff, 0x77, 0xb8, 0x80, 0xff, - 0x2e, 0xdc, 0xfe, 0x27, 0x00, 0x00, 0xff, 0xff, 0x17, 0x40, 0x19, 0xfb, 0x86, 0x10, 0x00, 0x00, + // 1436 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x57, 0xdd, 0x6e, 0x1b, 0xc5, + 0x17, 0xff, 0xef, 0x87, 0x63, 0xfb, 0x38, 0x4e, 0x9c, 0xf9, 0x47, 0x65, 0xfb, 0x41, 0xe4, 0x0e, + 0x88, 0x86, 0x4a, 0x44, 0xa2, 0x5c, 0x14, 0xc1, 0x4d, 0x93, 0x38, 0x2d, 0xa6, 0xa4, 0x0d, 0xe3, + 0xb4, 0xb7, 0x68, 0xbc, 0x1e, 0x35, 0xab, 0xac, 0x77, 0xcd, 0x7e, 0xa4, 0x76, 0x2f, 0x90, 0x40, + 0x20, 0x78, 0x00, 0x2e, 0x78, 0x11, 0xde, 0x81, 0x1b, 0x24, 0x1e, 0x01, 0x95, 0x17, 0x41, 0x73, + 0x66, 0x66, 0x77, 0xed, 0xba, 0x35, 0x44, 0xdc, 0xed, 0xf9, 0x9d, 0x99, 0x73, 0x7e, 0xe7, 0x63, + 0xce, 0xcc, 0x42, 0x7b, 0x92, 0x04, 0x17, 0x3c, 0x13, 0x7b, 0x93, 0x24, 0xce, 0x62, 0x62, 0x4f, + 0x86, 0xd7, 0xd6, 0x27, 0xf9, 0x30, 0x0c, 0x7c, 0x85, 0xd0, 0x07, 0xd0, 0xec, 0x47, 0x23, 0x31, + 0x3d, 0x16, 0x19, 0x27, 0x04, 0xdc, 0x87, 0x62, 0x96, 0x7a, 0x4e, 0xd7, 0xda, 0x6d, 0x30, 0xfc, + 0x26, 0xef, 0xc1, 0xc6, 0x69, 0xc2, 0xfd, 0xf3, 0xa3, 0x69, 0x90, 0x66, 0x22, 0xf2, 0x85, 0xe7, + 0xa2, 0x76, 0x01, 0xa5, 0x3f, 0x3b, 0xb0, 0x7e, 0x3f, 0x10, 0xe1, 0xe8, 0xf1, 0x24, 0x0b, 0xe2, + 0x28, 0x95, 0xc6, 0x4e, 0x67, 0x13, 0xe1, 0x35, 0xba, 0xd6, 0x6e, 0x93, 0xe1, 0x37, 0xb9, 0x01, + 0xcd, 0x43, 0xee, 0x9f, 0x09, 0x54, 0x38, 0xa8, 0x28, 0x81, 0x42, 0x3b, 0x08, 0x5e, 0x28, 0x2f, + 0x6d, 0x56, 0x02, 0xa4, 0x0b, 0xad, 0xd3, 0x60, 0x2c, 0xbe, 0xcc, 0x79, 0x94, 0xe5, 0x63, 0xaf, + 0x86, 0xbb, 0xab, 0x10, 0xb9, 0x02, 0x6b, 0x8f, 0xc3, 0xd1, 0x71, 0x10, 0x79, 0xcd, 0xae, 0xb5, + 0xeb, 0x30, 0x2d, 0x19, 0x9c, 0x4f, 0x3d, 0x28, 0x71, 0x3e, 0x2d, 0xc2, 0x6d, 0xcd, 0x87, 0xfb, + 0x28, 0x1e, 0x64, 0x3c, 0x1a, 0x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, 0xac, 0x69, + 0xf4, 0xed, 0x05, 0xe2, 0xa8, 0x53, 0x93, 0x37, 0xa5, 0x04, 0x3a, 0x8b, 0x2a, 0xba, 0x0d, 0x44, + 0x75, 0xc0, 0xfe, 0x30, 0x4e, 0xcc, 0x6d, 0x4b, 0x0f, 0xcd, 0x70, 0x91, 0xd9, 0x5f, 0x75, 0x89, + 0x97, 0x99, 0xb5, 0xab, 0x99, 0x3d, 0xe8, 0xfc, 0xf6, 0x72, 0xc7, 0xfa, 0xe3, 0xe5, 0x8e, 0xf5, + 0xe7, 0xcb, 0x1d, 0xeb, 0x97, 0xbf, 0x76, 0xfe, 0x37, 0x5c, 0xc3, 0xdf, 0xf5, 0x8f, 0xfe, 0x0e, + 0x00, 0x00, 0xff, 0xff, 0x77, 0x8c, 0x9b, 0xf7, 0xd1, 0x0f, 0x00, 0x00, } func (m *IndexMeta) Marshal() (dAtA []byte, err error) { diff --git a/internal/private.proto b/pb/private.proto similarity index 99% rename from internal/private.proto rename to pb/private.proto index 8cc195fdf..da641ac8b 100644 --- a/internal/private.proto +++ b/pb/private.proto @@ -1,6 +1,6 @@ syntax = "proto3"; -package internal; +package pb; import "public.proto"; diff --git a/internal/public.pb.go b/pb/public.pb.go similarity index 95% rename from internal/public.pb.go rename to pb/public.pb.go index 98fc6ef34..6ae80e41c 100644 --- a/internal/public.pb.go +++ b/pb/public.pb.go @@ -1,7 +1,24 @@ +// Copyright 2017 Pilosa Corp. +// +// 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. + +// package ctl contains all pilosa subcommands other than 'server'. These are +// generally administration, testing, and debugging tools. + // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: public.proto -package internal +package pb import ( encoding_binary "encoding/binary" @@ -2726,162 +2743,160 @@ func (m *GroupCounts) GetGroups() []*GroupCount { } func init() { - proto.RegisterType((*Row)(nil), "internal.Row") - proto.RegisterType((*RowMatrix)(nil), "internal.RowMatrix") - proto.RegisterType((*SignedRow)(nil), "internal.SignedRow") - proto.RegisterType((*RowIdentifiers)(nil), "internal.RowIdentifiers") - proto.RegisterType((*IDList)(nil), "internal.IDList") - proto.RegisterType((*ExtractedIDColumn)(nil), "internal.ExtractedIDColumn") - proto.RegisterType((*ExtractedIDMatrix)(nil), "internal.ExtractedIDMatrix") - proto.RegisterType((*KeyList)(nil), "internal.KeyList") - proto.RegisterType((*ExtractedTableValue)(nil), "internal.ExtractedTableValue") - proto.RegisterType((*ExtractedTableColumn)(nil), "internal.ExtractedTableColumn") - proto.RegisterType((*ExtractedTableField)(nil), "internal.ExtractedTableField") - proto.RegisterType((*ExtractedTable)(nil), "internal.ExtractedTable") - proto.RegisterType((*Pair)(nil), "internal.Pair") - proto.RegisterType((*PairField)(nil), "internal.PairField") - proto.RegisterType((*PairsField)(nil), "internal.PairsField") - proto.RegisterType((*Int64)(nil), "internal.Int64") - proto.RegisterType((*FieldRow)(nil), "internal.FieldRow") - proto.RegisterType((*GroupCount)(nil), "internal.GroupCount") - proto.RegisterType((*ValCount)(nil), "internal.ValCount") - proto.RegisterType((*Decimal)(nil), "internal.Decimal") - proto.RegisterType((*ColumnAttrSet)(nil), "internal.ColumnAttrSet") - proto.RegisterType((*Attr)(nil), "internal.Attr") - proto.RegisterType((*AttrMap)(nil), "internal.AttrMap") - proto.RegisterType((*QueryRequest)(nil), "internal.QueryRequest") - proto.RegisterType((*QueryResponse)(nil), "internal.QueryResponse") - proto.RegisterType((*QueryResult)(nil), "internal.QueryResult") - proto.RegisterType((*ImportRequest)(nil), "internal.ImportRequest") - proto.RegisterType((*ImportValueRequest)(nil), "internal.ImportValueRequest") - proto.RegisterType((*AtomicRecord)(nil), "internal.AtomicRecord") - proto.RegisterType((*AtomicImportResponse)(nil), "internal.AtomicImportResponse") - proto.RegisterType((*TranslateKeysRequest)(nil), "internal.TranslateKeysRequest") - proto.RegisterType((*TranslateKeysResponse)(nil), "internal.TranslateKeysResponse") - proto.RegisterType((*TranslateIDsRequest)(nil), "internal.TranslateIDsRequest") - proto.RegisterType((*TranslateIDsResponse)(nil), "internal.TranslateIDsResponse") - proto.RegisterType((*ImportRoaringRequestView)(nil), "internal.ImportRoaringRequestView") - proto.RegisterType((*ImportRoaringRequest)(nil), "internal.ImportRoaringRequest") - proto.RegisterType((*ImportColumnAttrsRequest)(nil), "internal.ImportColumnAttrsRequest") - proto.RegisterType((*GroupCounts)(nil), "internal.GroupCounts") + proto.RegisterType((*Row)(nil), "pb.Row") + proto.RegisterType((*RowMatrix)(nil), "pb.RowMatrix") + proto.RegisterType((*SignedRow)(nil), "pb.SignedRow") + proto.RegisterType((*RowIdentifiers)(nil), "pb.RowIdentifiers") + proto.RegisterType((*IDList)(nil), "pb.IDList") + proto.RegisterType((*ExtractedIDColumn)(nil), "pb.ExtractedIDColumn") + proto.RegisterType((*ExtractedIDMatrix)(nil), "pb.ExtractedIDMatrix") + proto.RegisterType((*KeyList)(nil), "pb.KeyList") + proto.RegisterType((*ExtractedTableValue)(nil), "pb.ExtractedTableValue") + proto.RegisterType((*ExtractedTableColumn)(nil), "pb.ExtractedTableColumn") + proto.RegisterType((*ExtractedTableField)(nil), "pb.ExtractedTableField") + proto.RegisterType((*ExtractedTable)(nil), "pb.ExtractedTable") + proto.RegisterType((*Pair)(nil), "pb.Pair") + proto.RegisterType((*PairField)(nil), "pb.PairField") + proto.RegisterType((*PairsField)(nil), "pb.PairsField") + proto.RegisterType((*Int64)(nil), "pb.Int64") + proto.RegisterType((*FieldRow)(nil), "pb.FieldRow") + proto.RegisterType((*GroupCount)(nil), "pb.GroupCount") + proto.RegisterType((*ValCount)(nil), "pb.ValCount") + proto.RegisterType((*Decimal)(nil), "pb.Decimal") + proto.RegisterType((*ColumnAttrSet)(nil), "pb.ColumnAttrSet") + proto.RegisterType((*Attr)(nil), "pb.Attr") + proto.RegisterType((*AttrMap)(nil), "pb.AttrMap") + proto.RegisterType((*QueryRequest)(nil), "pb.QueryRequest") + proto.RegisterType((*QueryResponse)(nil), "pb.QueryResponse") + proto.RegisterType((*QueryResult)(nil), "pb.QueryResult") + proto.RegisterType((*ImportRequest)(nil), "pb.ImportRequest") + proto.RegisterType((*ImportValueRequest)(nil), "pb.ImportValueRequest") + proto.RegisterType((*AtomicRecord)(nil), "pb.AtomicRecord") + proto.RegisterType((*AtomicImportResponse)(nil), "pb.AtomicImportResponse") + proto.RegisterType((*TranslateKeysRequest)(nil), "pb.TranslateKeysRequest") + proto.RegisterType((*TranslateKeysResponse)(nil), "pb.TranslateKeysResponse") + proto.RegisterType((*TranslateIDsRequest)(nil), "pb.TranslateIDsRequest") + proto.RegisterType((*TranslateIDsResponse)(nil), "pb.TranslateIDsResponse") + proto.RegisterType((*ImportRoaringRequestView)(nil), "pb.ImportRoaringRequestView") + proto.RegisterType((*ImportRoaringRequest)(nil), "pb.ImportRoaringRequest") + proto.RegisterType((*ImportColumnAttrsRequest)(nil), "pb.ImportColumnAttrsRequest") + proto.RegisterType((*GroupCounts)(nil), "pb.GroupCounts") } func init() { proto.RegisterFile("public.proto", fileDescriptor_413a91106d7bcce8) } var fileDescriptor_413a91106d7bcce8 = []byte{ - // 1779 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x58, 0x4f, 0x6f, 0x23, 0x49, - 0x15, 0x4f, 0xbb, 0xdb, 0xb1, 0xfd, 0xec, 0x64, 0xb2, 0x35, 0x9e, 0xa5, 0x35, 0xcc, 0x64, 0x43, - 0x2b, 0xb0, 0x06, 0xad, 0xb2, 0xca, 0xb0, 0x03, 0x73, 0xe0, 0xcf, 0x26, 0xe3, 0x2c, 0x69, 0x0d, - 0x93, 0x1d, 0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d, 0x0b, 0x3c, 0x9e, 0xae, 0xd4, 0x1d, 0xbb, - 0x4f, 0xb6, 0xcc, 0xb9, 0x3c, 0x5d, 0x71, 0x12, 0x05, 0x2f, 0xa1, 0x73, 0x1e, 0x4f, 0x66, 0x62, - 0x8c, 0x6e, 0xbd, 0x07, 0xee, 0xab, 0x14, 0xd5, 0x9d, 0x75, 0x75, 0x94, 0xa0, 0xc2, 0x99, 0x98, - 0xf8, 0x8d, 0x5a, 0x85, 0x33, 0x31, 0x09, 0x9e, 0xc1, 0x36, 0x4f, 0x57, 0xe1, 0x58, 0xcc, 0x64, - 0xfc, 0x9b, 0x58, 0x64, 0x04, 0x48, 0x71, 0x07, 0x4f, 0x1d, 0x5a, 0x80, 0xd4, 0x30, 0x20, 0x05, - 0x0f, 0x61, 0x33, 0x1c, 0xfe, 0x3c, 0x5e, 0x48, 0xb6, 0x03, 0x6e, 0x38, 0xd4, 0x1b, 0x70, 0x19, - 0x84, 0xf0, 0xce, 0xc9, 0x95, 0xcc, 0xa2, 0x91, 0x14, 0xe3, 0x70, 0xa8, 0xa0, 0x66, 0xdb, 0xd0, - 0x08, 0x87, 0x74, 0x57, 0x8f, 0x37, 0xc2, 0x21, 0xdb, 0x07, 0xef, 0x22, 0x4a, 0x34, 0xc8, 0x3b, - 0xe6, 0x72, 0xca, 0x2c, 0x27, 0x69, 0x70, 0x59, 0x32, 0x95, 0xe3, 0xf4, 0x2e, 0x6c, 0x12, 0x7a, - 0xea, 0xd0, 0x0e, 0xcf, 0x29, 0xf6, 0xd4, 0x84, 0x59, 0x59, 0xfd, 0xa6, 0xb1, 0xba, 0x76, 0xa1, - 0x22, 0x07, 0x82, 0xc7, 0xd0, 0x7a, 0x21, 0xae, 0xc9, 0x17, 0xed, 0xa9, 0x63, 0x79, 0xfa, 0x6f, - 0x07, 0xee, 0x17, 0xbb, 0x5f, 0x47, 0x97, 0x89, 0xb8, 0x88, 0x92, 0xa5, 0x60, 0xfb, 0xda, 0x6f, - 0xa7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, 0x4a, 0xbe, 0x9a, 0x83, 0xcd, 0xb8, 0xaf, 0x49, 0x9c, 0xbd, 0x71, - 0x49, 0x7f, 0x5d, 0x3c, 0x8a, 0x67, 0x41, 0x7f, 0x45, 0xfd, 0x5a, 0x87, 0x65, 0xb3, 0x0e, 0x96, - 0xe0, 0x57, 0xa5, 0x0e, 0x87, 0x46, 0x8f, 0x26, 0x93, 0x4c, 0x4c, 0x22, 0xa9, 0x33, 0xc2, 0x30, - 0xd8, 0x07, 0xb0, 0x49, 0xca, 0x3a, 0xa8, 0xf5, 0x23, 0x4e, 0xae, 0x73, 0xbc, 0xf3, 0x8f, 0x37, - 0xbb, 0xce, 0x3f, 0xdf, 0xec, 0x3a, 0xff, 0x79, 0xb3, 0xeb, 0xfc, 0xe9, 0xbf, 0xbb, 0x1b, 0x97, - 0x9b, 0xf4, 0xb7, 0xef, 0xfb, 0xff, 0x0f, 0x00, 0x00, 0xff, 0xff, 0x8c, 0xa8, 0x3e, 0x99, 0xfd, - 0x13, 0x00, 0x00, + // 1754 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x58, 0x5f, 0x6f, 0x23, 0x49, + 0x11, 0xcf, 0xfc, 0xf1, 0xbf, 0xb2, 0xe3, 0xe4, 0xfa, 0x72, 0xcb, 0xdc, 0x92, 0x33, 0xbe, 0x11, + 0x3a, 0x79, 0x09, 0xca, 0x89, 0x00, 0x27, 0x38, 0x09, 0x50, 0x1c, 0xe7, 0xc8, 0x68, 0xd9, 0xdc, + 0x5e, 0x3b, 0x04, 0x1e, 0x78, 0x99, 0xd8, 0x8d, 0x6f, 0xc4, 0xd8, 0x63, 0xc6, 0xe3, 0x73, 0x22, + 0x3e, 0xc0, 0xf1, 0x11, 0x40, 0x3c, 0x23, 0xf1, 0x39, 0x78, 0x81, 0x37, 0x78, 0xe4, 0x11, 0x2d, + 0x5f, 0x04, 0x55, 0x75, 0xf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6, 0x8f, 0x13, 0xa3, 0x1b, 0x79, + 0x9d, 0xc2, 0x78, 0xce, 0xe4, 0x46, 0xb7, 0xba, 0xd8, 0x31, 0x79, 0x79, 0xfb, 0xb4, 0xa9, 0x3a, + 0x56, 0x49, 0x21, 0xdf, 0x31, 0xa9, 0x7d, 0x5c, 0x6d, 0xdb, 0x5e, 0xb7, 0x80, 0xa2, 0x2c, 0xe1, + 0xd5, 0x06, 0x7f, 0x62, 0x8c, 0xc0, 0xde, 0x41, 0x71, 0xdb, 0x9c, 0xc9, 0x8d, 0x11, 0xf9, 0x7b, + 0xd0, 0x36, 0x03, 0x75, 0x48, 0xea, 0x07, 0xe5, 0x40, 0xad, 0xb8, 0xa9, 0xe3, 0xff, 0xc3, 0x86, + 0xfd, 0x60, 0xbe, 0x4c, 0xd2, 0xcc, 0x28, 0x28, 0x72, 0x40, 0xb7, 0x76, 0x0e, 0xe8, 0x76, 0xa5, + 0x27, 0x52, 0x61, 0xa1, 0x42, 0xe2, 0x72, 0x49, 0x18, 0xa9, 0xe4, 0x96, 0x52, 0xe9, 0x18, 0x5a, + 0xf2, 0x95, 0xa0, 0xa8, 0x46, 0xa2, 0x82, 0x21, 0x3f, 0x19, 0x36, 0x34, 0x32, 0x36, 0x68, 0xfc, + 0xd4, 0x24, 0x96, 0x4f, 0xa9, 0x46, 0xc2, 0x26, 0x09, 0x0d, 0x0e, 0xca, 0x6f, 0xa2, 0xb9, 0x58, + 0x65, 0xe1, 0x7c, 0x89, 0x55, 0xc9, 0x19, 0x38, 0xdc, 0xe0, 0x60, 0x41, 0x22, 0x27, 0x2e, 0x52, + 0x81, 0x55, 0xe2, 0x3c, 0xa3, 0x54, 0x74, 0x78, 0x85, 0x8b, 0x7a, 0xe4, 0x56, 0xa1, 0x07, 0x52, + 0xaf, 0xcc, 0xa5, 0x16, 0x1a, 0x8b, 0x30, 0xa5, 0x64, 0x6b, 0x72, 0x49, 0xf8, 0xff, 0xb1, 0x81, + 0x49, 0x24, 0xe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0xbe, 0xe8, + 0x59, 0x7f, 0xfa, 0x5f, 0x6f, 0xef, 0xae, 0x4e, 0xff, 0xc1, 0xbe, 0xff, 0xff, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x7b, 0x22, 0x9e, 0xfd, 0x17, 0x13, 0x00, 0x00, } func (m *Row) Marshal() (dAtA []byte, err error) { diff --git a/internal/public.proto b/pb/public.proto similarity index 99% rename from internal/public.proto rename to pb/public.proto index 077ed87f9..770273aa0 100644 --- a/internal/public.proto +++ b/pb/public.proto @@ -1,6 +1,6 @@ syntax = "proto3"; -package internal; +package pb; message Row { repeated uint64 Columns = 1;