Commit graph

63 commits

Author SHA1 Message Date
Mahesh Arumugam
858f889745 FeatureBase Renaming: changing go.mod module name for featurebase 2021-07-19 09:20:30 -07:00
Travis
2bbe1fdde0
remove remaining references to "coordinator" 2021-02-23 17:23:09 -06:00
Travis
22cca67d6a Revert "back out the pql.Decimal changes"
This reverts commit 741ba9b268.
2020-04-01 17:46:46 -05:00
Travis
741ba9b268 back out the pql.Decimal changes 2020-04-01 11:10:33 -05:00
Travis
1da7cf09bb support pql.Decimal for decimal field min/max arguments 2020-03-27 16:02:47 -05:00
Travis
881d3bef06 Adjust the FieldOption logic to be in place prior to field.Open().
This commit changes the order of FieldOption application so that
it's always set before field.Open() is called.

This was required because field.Open() now uses some of the values
from FieldOptions to determine if/when to use a particular
translateStore. For example, when FieldOptions.ForeignIndex is set,
the translateStore from the foreign index is retrieved during
field.Open().
2020-01-10 12:28:28 -06:00
Travis
87b8edc4c5 fix golangci-lint complaints 2019-11-10 17:58:46 -06:00
Matt Jaffee
5dcabfcc7f
support for decimal fields
This commit adds a Decimal field type which is implemented mostly with
the Int field. It adds an optional "Scale" value to the Int field
which means that the values stored in that field are actually meant to
be divided by 10^Scale before being interpreted.

In order to make use of this functionality, we extend the importValue
request to allow a slice of floats rather than just int64. If the
slice of floats is present, each float in the slice is multiplied by
10^Scale and converted to an int64 before being imported. If a slice
of int64 is imported to a Decimal field, it is treated normally, and
scale is ignored. This allows the conversion to be handled at the
client side if desired.

Currently there are Field level methods for querying Float values out
of a decimal field, but no support in PQL or the executor for getting
float values. Going to wait until I can use the generic result type
before doing that, so for now, any values queried will be the scaled
integer values.

needed to add client support for importing float values, and did this
by adding a more general and simplified client method for value
imports.

rewrote api.ImportValue to use the new method which should be more
performant and efficient.

allow floats to be "pilosa import"ed into decimal fields
2019-10-29 16:36:14 -05:00
Ben Johnson
c7c9c1e1d7
v2.0.0
Co-authored-by: Cody Soyland <codysoyland@gmail.com>
2019-10-08 14:56:17 -06:00
Cody Soyland
be91ee2103 Copy dependency into project and use pilosa's logger 2019-10-03 09:44:48 -05:00
Matt Jaffee
daa87d8e12
fix staticcheck warnings 2019-01-21 14:24:11 -06:00
Yuce Tekol
fc231ff802
Fixes #1731 2018-11-08 17:01:05 +03:00
Travis Turner
a7a15c64a2
support clear imports to int fields. fix bug in fragment.sum 2018-10-23 17:37:57 -05:00
Travis Turner
caf8e06712
add clear functional option for imports 2018-10-23 17:37:57 -05:00
Yuce Tekol
81f126dd34
Added field options to pilosa import 2018-09-06 17:04:07 +03:00
Yuce Tekol
48bd76b967
Removed --string-keys option from pilosa import 2018-09-05 22:58:23 +03:00
Yuce Tekol
7b872e00cb
Implements #1570 2018-09-05 17:10:56 +03:00
Travis Turner
bf4e2e598b
add support for column keys when importing to int fields 2018-08-15 16:00:31 -05:00
Travis Turner
2f892e5e80
change string-keys DEPRECATED message to REMOVED 2018-08-15 14:55:02 -05:00
Travis Turner
6a327a26fe
add deprecation warnings for --string-keys flag 2018-08-15 10:31:27 -05:00
Travis Turner
862dabe27d
address review comments 2018-08-14 14:37:51 -05:00
Travis Turner
fd96d3a02e
This commit ensures that keyed imports are sent to the coordinator
node (as opposed to sending to shard0, which may or may not be the
coordinator). It adds a `Nodes()` method to the `InternalClient`
which is used by the importer to determine which node is the
coordinator.
2018-08-14 12:34:17 -05:00
Ben Johnson
a31a08c330
Support keys on import CLI. 2018-08-14 09:32:39 -05:00
Cody Soyland
f01d850b17 Fix linter issues: gosimple 2018-07-20 09:06:43 -05:00
Cody Soyland
de99b5720f Fix linter issues: vet 2018-07-19 11:37:50 -05:00
Cody Soyland
187ded0a52 Fix linter issues: maligned 2018-07-19 11:07:59 -05:00
Cody Soyland
eea29f664f Unexport ctl.ImportCommand.Client 2018-07-05 23:11:56 -05:00
Cody Soyland
f9a792ea49 Unexport ctl.ImportCommand.IndexOptions 2018-07-05 23:11:56 -05:00
Cody Soyland
7185c0f791 Unexport ctl.CommandClient 2018-07-05 23:11:56 -05:00
Travis Turner
5dd7a9556a
rename slice to shard 2018-06-28 14:07:07 -05:00
Travis Turner
028e95d914
Allow a single functional option for field options.
Move field type specific validation to functional options.
2018-06-26 10:37:56 -05:00
Travis Turner
50794bf63b
move fieldOptions unmarshal to the handler
validate fieldOptions in http package
2018-06-25 15:14:22 -05:00
Cody Soyland
f2c104dfef Migrate HTTP handler and client into http subpackage. 2018-06-12 13:22:40 -05:00
Travis Turner
2a9b1e9e5b
final Frame to Field rename 2018-06-06 01:27:12 -05:00
Travis Turner
6dbe80350f
GoRename Frame to Field in client.go 2018-06-05 23:02:15 -05:00
Travis Turner
3531c128c4
GoRename Frame to Field in index.go 2018-06-05 22:33:48 -05:00
Travis Turner
1d3c4d6fcb
first pass at GoRename Frame to Field in frame.go 2018-06-05 17:52:22 -05:00
Travis Turner
80d656ae9c
final removal of field instances 2018-06-05 16:56:16 -05:00
Travis Turner
96208283df
remove final instances of Field 2018-06-05 16:38:29 -05:00
Travis Turner
0d44e586cc
remove field flag from pilosa import command 2018-06-05 16:14:26 -05:00
Travis Turner
2111a3d521
more Field removal/rename 2018-06-05 11:13:51 -05:00
Matt Jaffee
4ef266e5cc
revert a bunch of stuff and fix some comments 2018-05-24 16:35:27 -05:00
Todd Gruben
e3da6efe3c revert to old labels on BSI; revert MustSetColumns 2018-05-24 12:48:24 -05:00
Todd Gruben
fb7bf11825 Bit -> Column migration 2018-05-23 15:05:22 -05:00
Alan Bernstein
f5a4fd82b1 Wrap errors in ctl/*.go 2018-05-08 17:10:36 -05:00
Matthew Jaffee
876ed56e30
move pilosa.Config to pilosa/server.Config
step 1 of #1203

The Config object is really just a specification of the options to pilosa
server, so it makes sense to have it in that package.
2018-04-19 14:51:42 -05:00
Travis Turner
d8559ae469
refactor to remove BitK (in favor of Bit) 2018-01-22 15:35:10 -06:00
Travis Turner
a56410a70b
WIP: Modify pilosa import to support string rows/columns
This PR adds a flag `pilosa import --string-keys=true` which treats the
payload CSV as comma separated strings.
2018-01-22 15:34:45 -06:00
Cody Soyland
27748259a2 Fix field value import: Use signed int and respect field minimum. Fixes #875 2017-10-31 13:32:26 -05:00
Yuce Tekol
e201afe241
Replaced all http.Clients with InternalClient; updated InternalClient interface. 2017-10-17 15:53:42 +03:00