Commit graph

3762 commits

Author SHA1 Message Date
Matt Jaffee
442380f8ab add anti-entropy interval arg 2017-03-17 16:43:04 -05:00
Matt Jaffee
b291307dde add plugins path arg to server
also fix an issue where tests would hang if an invalid config file was given
2017-03-17 16:43:04 -05:00
Matt Jaffee
9a18fc11a6 support cluster poll interval arg 2017-03-17 16:43:04 -05:00
Matt Jaffee
03eae77604 add cluster.hosts flag
had to work around a bunch of viper nonsense with handling string slices

changed the validator.Check to use reflect.DeepEqual

fixed a bug where env vars need to be reset between tests

had to change the structure of pilosa.config to enable the passing of hosts as a
slice of strings (it was a slice of structs which each just contained the string
host.) so we lose some generality, but we weren't using it anyway.
2017-03-17 16:43:04 -05:00
Matt Jaffee
2af42eedb5 add replicaN to pilosa server and test 2017-03-17 16:43:04 -05:00
Matt Jaffee
372b7ca1c4 full testing support for pilosa server
1. fixed a couple bugs with config file reading.
2. made cmd.Serve a global variable so tests could inspect it.
3. added table style testing for pilosa server
4. added the ability to stop server programmatically which also causes the cobra
command running it to return.
2017-03-17 16:43:04 -05:00
Matt Jaffee
076cc0960a add some proof of concept command tests 2017-03-17 16:43:04 -05:00
Matt Jaffee
961d18a3bf convert all subcommands to nonglobal style 2017-03-17 16:43:04 -05:00
Matt Jaffee
c3b7710d67 WIP on converting commands to be non-global and testable 2017-03-17 16:43:04 -05:00
Matt Jaffee
943e8ece1e add data-dir flag and simplify server/server.go
Now that the default data dir is defined by the flag, we don't need to set it
explicitly if it isn't set. We also stop reading the config file explicitly in
server.go since viper will read it - we do need to define all the config options
though before the config file will work properly.
2017-03-17 16:43:04 -05:00
Matt Jaffee
26a900843a move setAllConfig and it's invocation to root cmd 2017-03-17 16:43:04 -05:00
Matt Jaffee
232cf53781 rename config function and have it return error 2017-03-17 16:43:04 -05:00
Matt Jaffee
e1a582ad2c experimenting with cascading config
2 changes unrelated to cascading config:

1. using cobra.Command.RunE instead of just Run - similar behavior to log + exit,
but simpler. Also prints error message, then usage, then error again which is
nice.

2. getting serveCmd.Flags() once, and re-using it. More readable methinks.

For cascading config, I'm trying to set things up so that we can define the
flags once, and have them work from a config file, environment variable, or
command line. I also don't want references to viper scattered throughout our
code, so I want to set the config at startup, and not touch it from then on.

The idea here is to iterate through the set up command line flags, and then set
their values from viper which knows about the commmand line, the environment,
and the config file, and will pick the right one. The command line flags were
set pointing to the correct config values in the pilosa object, so the right
values will be set automatically.
2017-03-17 16:43:04 -05:00
Travis Turner
371665f459 Merge pull request #376 from linhvo/pil357-frame-name
Pil357 frame name
2017-03-10 16:18:26 -06:00
Travis
3649a52c00 Change frame meta and data to .meta and .data to be consistent with the DB dot files. 2017-03-10 15:47:17 -06:00
Linh Vo
3ab1d34d9a change frame name to meta for testing 2017-03-10 15:21:55 -06:00
Linh Vo
34b8f30c0d invalid name start with dot 2017-03-10 15:21:55 -06:00
Linh Vo
920b9d01e2 add . before meta frame 2017-03-10 15:21:54 -06:00
Travis
73df55a980 Refactor some repetitive function calls. Correct the casting to float64() 2017-03-10 13:46:57 -06:00
Linh Vo
0a4de77d38 add tanimoto option to pilosa 2017-03-10 13:45:18 -06:00
Yuce Tekol
9908002863 Merge pull request #388 from yuce/makefile-unknown-version
if a version is not found, set it as unknown
2017-03-10 19:43:58 +02:00
Travis Turner
2046e3665c Merge pull request #390 from travisturner/fix-client-test
Fix client test
2017-03-10 11:18:50 -06:00
Travis
2b94be965e Make sure the TopN test is actually using a RankCache supported frame.
Implement cache.Recalculate to bypass the 10-second delay built into cache.Invalidate().
2017-03-10 11:07:18 -06:00
Travis
988e602033 adds validateCallArgs(c) to executor 2017-03-10 09:36:05 -06:00
Yuce Tekol
8e982d2479 if a version is not found, set it as unknown; do not display No names found error message 2017-03-09 21:28:50 +03:00
Matthew Jaffee
e8ab4cfc2d Merge pull request #387 from jaffee/384-time-version-bug
give appropriate path in ldflags for BuildTime and Version
2017-03-09 12:01:08 -06:00
Matt Jaffee
72de534c8c remove duplicate Version/BuildTime from pilosa/server
use only the pilosa/cmd Version and BuildTime which are populated by the ldflags
in the Makefile
2017-03-09 11:39:11 -06:00
Matt Jaffee
51390cdf47 Merge branch '372-invalid-name-bug' 2017-03-09 10:58:08 -06:00
Matt Jaffee
8e0d64fe06 give appropriate path in ldflags for BuildTime and Version 2017-03-09 10:55:53 -06:00
Yuce Tekol
d1bae69150 Merge pull request #383 from yuce/upgrade-docker-go_1.8
Updated Dockerfile to use go 1.8 and ldflags; removed pilosactl stuff…
2017-03-09 17:46:26 +02:00
Travis Turner
1fe4d4b1e6 Merge pull request #379 from travisturner/top-n-fix
If a top-n query contains BitmapIDs, then treat N as having value 0.
2017-03-09 09:34:20 -06:00
Michael Baird
d56a55a0d3 Merge pull request #360 from raskle/topn-multinode-tests
TopN tests across 3 nodes
2017-03-09 09:13:34 -06:00
Yuce Tekol
a446d7b9e6 Updated Dockerfile to use go 1.8 and ldflags; removed pilosactl stuff from Makefile, send ldflags to build container. 2017-03-09 11:14:01 +03:00
Linh Vo
756fc49be6 resolve conflict 2017-03-08 22:17:50 -06:00
Linh Vo
40b1192692 fix comment 2017-03-08 22:11:52 -06:00
Yuce Tekol
d61c825812 Merge pull request #382 from yuce/readme-update-rowcol
quick readme fix
2017-03-09 02:26:26 +02:00
Yuce Tekol
081660f5c8 quick readme fix 2017-03-09 03:13:55 +03:00
Yuce Tekol
a4a14cb5d0 Merge pull request #363 from yuce/readme-update-rowcol
updated readme for row col schema
2017-03-09 02:12:06 +02:00
Travis
15f87e284e fixes some of the comments and removes unused code 2017-03-08 17:30:56 -06:00
Travis
cd7434fa95 remove TODO; Todd confirmed f.cache.Top() was not doing a copy 2017-03-08 16:39:36 -06:00
Travis
41d334aeaf If a top-n query contains BitmapIDs, then treat N as having value 0. 2017-03-08 16:09:56 -06:00
Matthew Jaffee
26798be923 Merge pull request #370 from jaffee/319-float-support
319 float support for attributes
2017-03-08 15:50:34 -06:00
Matt Jaffee
69586ea074 rename NUMBER -> INTEGER 2017-03-08 14:03:21 -06:00
Matt Jaffee
f47c3a4521 fix spaces/tab issue in Makefile 2017-03-08 13:55:18 -06:00
Linh Vo
641832ae10 skip error when open invalid db/frame name 2017-03-07 21:48:59 -06:00
Yuce Tekol
b3ddc49c44 Merged the latest master 2017-03-08 01:15:56 +03:00
Yuce Tekol
d3a3cf5d46 Merge pull request #325 from yuce/readme-update
Readme update
2017-03-08 00:08:35 +02:00
Matt Jaffee
be8b976ba1 update scanner comment and test float with trailing dot 2017-03-07 15:56:02 -06:00
Matt Jaffee
7ffeeeede3 fix duplicate case after rebase 2017-03-07 15:44:53 -06:00
Matt Jaffee
0202c9b849 add float support to proto format
floating point attrs are now fully supported
2017-03-07 15:40:50 -06:00