Commit graph

7158 commits

Author SHA1 Message Date
Todd Gruben
94d7b295ea added more graceful error handling for corrupt containers 2021-03-12 10:37:40 -06:00
Kuba Podgórski
1b486ac812
Merge pull request #1522 from kuba--/core-344
CORE-344: Fix deprecation plan for "github.com/golang/protobuf/protoc-gen-go/generator" package
2021-03-12 15:29:54 +01:00
Kuba Podgórski
4043f22db2
Merge branch 'master' into core-344 2021-03-12 14:08:03 +01:00
Travis Turner
81c47b778e
Merge pull request #1525 from travisturner/startup-log-dir
[CORE-362] Create the data directory during "log startup" if it doesn't already exist
2021-03-12 06:47:45 -06:00
Kuba Podgórski
1ba52dbca9 Update go.sum 2021-03-12 13:06:23 +01:00
Kuba Podgórski
a12a130420
Merge branch 'master' into core-344 2021-03-12 12:51:58 +01:00
Kuba Podgórski
ddc924de0c go mod tidy 2021-03-12 12:48:53 +01:00
Travis
9e0ea9709a
Create the data directory during "log startup" if it doesn't already exist.
Prior to using etcd for node membership, the data director was created
during the cluster topology setup. Since that no longer exists, we
weren't actually creating the data directory before getting to
logStartup(). So this change ensure that the data directory exists.
2021-03-11 17:31:46 -06:00
tgruben
9b913ce904
Merge pull request #1489 from tgruben/theoracle
Theoracle
2021-03-11 16:11:38 -06:00
tgruben
391588bd1b
Merge branch 'master' into theoracle 2021-03-11 13:56:34 -06:00
Alan Bernstein
7df5375572
Merge pull request #1524 from alanbernstein/fix-null-schema
Represent zero indexes in /schema response as [] instead of null
2021-03-11 13:23:19 -06:00
tgruben
21910ef321
Update main.go 2021-03-11 11:47:57 -06:00
tgruben
a5dceaae11
Update main.go 2021-03-11 11:26:58 -06:00
Alan Bernstein
8e123b821d Replace null with [] in schema response 2021-03-11 11:23:20 -06:00
Todd Gruben
47e74f2603 Basic pilosa changes for oracle support 2021-03-11 11:16:53 -06:00
Kuba Podgórski
95eaab8ffc
Merge pull request #1514 from seebs/discoSyncer
CORE-299 check for nil translate store while reading translate entries
2021-03-11 13:03:24 +01:00
Kuba Podgórski
3fde2dcac2
Merge branch 'master' into discoSyncer 2021-03-10 12:35:10 +01:00
Kuba Podgórski
5af850c64a
Merge pull request #1518 from kuba--/fix-metadata-noder
Get metadata in Tx. Fix Nodes implementation
2021-03-10 11:24:09 +01:00
Kuba Podgórski
4c787870b2 Get metadata in Tx. Fix Nodes implementation 2021-03-10 00:28:49 +01:00
Seebs
810f840839 combine field and index translation readers
There's no need to have two different translation readers, a single
reader can handle both partitions and fields at the same time, so we
can combine them. This may not actually change things much but was
a useful step in diagnosing a different problem with translate readers,
and I think it is a minor improvement so I'm preserving the patch
just in case.
2021-03-09 13:37:51 -06:00
Seebs
76e4181740 don't reuse sync.Mutex between translate readers
The functional option and returned closure combine to result in
us using the same sync.Mutex object for every TranslateReader on
a given server, which means that if one of them isn't producing anything,
we eventually end up waiting on that with all the others blocked
waiting for the lock. Use separate locks for each, of the same
type as the one initially provided as a template. This does mean
that multiple readers can be operating at once, but in theory
no two readers should ever be writing to the same stores, we
think.
2021-03-08 17:04:52 -06:00
Seebs
51744dc77a check for nil translate store while reading translate entries
If we are using replication, we can be a replica translate store for a
partition, which means we start a translate store reader to replicate
data for it. The translation logic does not admit *stopping* the
translate reader, only "resetting" it (stopping and immediately
restarting), so the translate reader just runs until it hits an error
and terminates, which it does even if perhaps it shouldn't. Oops.

Anyway, one potential failure mode is that if you hit timing just
right, you can end up trying to process translation *while* the
index is being closed, and the index can close its translation stores,
and make them all nil, right before we request a store and try to use
it. Another is a similar error, but during the initial startup of the
translate store readers. Either way, we want to error out of the
process cleanly if this happens.

This could also happen during initial creation, perhaps.

We're aborting translation sync on these errors, because otherwise
we'd continue accepting new keys, and then end up with our highest
known key being higher than some keys we missed; this way the next
restart will restart from the last key we have.
2021-03-08 17:04:52 -06:00
Travis Turner
45577494c3
Merge pull request #1517 from travisturner/datadir-take-3
Remove stutter and suffix from backend files
2021-03-08 11:50:42 -06:00
Travis Turner
2a0765d7f0
Merge branch 'master' into datadir-take-3 2021-03-08 11:21:05 -06:00
Kuba Podgórski
d6e9e88872
Merge pull request #1516 from kuba--/test-close
Close resources in TestLeasedKv
2021-03-08 11:01:40 +01:00
Travis
f78a6508f0
Remove stutter and suffix from backend files 2021-03-07 22:11:51 -06:00
Kuba Podgórski
7b005f69c6 Close resources in TestLeasedKv 2021-03-06 12:03:57 +01:00
Travis Turner
ab50403c35
Merge pull request #1512 from travisturner/datadir-take-2
Core-316 Reorganize Pilosa datadir
2021-03-05 17:15:03 -06:00
Travis
cad78f1d34
remove "Default*" from const names 2021-03-05 16:56:44 -06:00
Travis
5191d0c3f4
remove unnecessary skip check 2021-03-05 16:56:44 -06:00
Travis
4661f3ac08
reorganize the storage backends directory 2021-03-05 16:56:44 -06:00
Travis
4738a818d2
change attributes file ".data" to "column/row-attributes" 2021-03-05 16:56:44 -06:00
Travis
345d076fdf
introduce "fields" directory between index and field 2021-03-05 16:56:44 -06:00
Travis
4e7ec34c6d
change directory ".disco" to "disco" 2021-03-05 16:56:44 -06:00
Travis
7789e24965
introduce "indexes" directory between datadir and index 2021-03-05 16:56:43 -06:00
Matthew Jaffee
863e57d5d1
Merge pull request #1513 from ajnavarro/disco/improve-leased-keys
[CORE-312] Improve leased keys.
2021-03-05 16:47:54 -06:00
Antonio Navarro Perez
542a98548a Breaking code at friday afternoon...
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2021-03-05 23:35:53 +01:00
Antonio Navarro Perez
2927943734 Copy paste fix.
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2021-03-05 23:35:53 +01:00
Antonio Navarro Perez
feea0fa347 Requested changes.
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2021-03-05 23:35:53 +01:00
Antonio Navarro Perez
85a43c519d Fix problem with context errors.
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2021-03-05 23:35:53 +01:00
Antonio Navarro Perez
df0064c55f Add godoc.
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2021-03-05 23:35:53 +01:00
Antonio Navarro Perez
955ab2b5a0 Requested changes
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2021-03-05 23:35:53 +01:00
Antonio Navarro Perez
851c41cd45 Implement infinite lease renewal logic.
Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2021-03-05 23:35:53 +01:00
Antonio Navarro Perez
7a1e4cd2d7 Improve leased keys.
Added a leasedKV struct in charge of maintain a lease for a specific
key.

Signed-off-by: Antonio Navarro Perez <antnavper@gmail.com>
2021-03-05 23:35:53 +01:00
Matthew Jaffee
6966c3f7c3
Merge pull request #1515 from jaffee/invalid-pilosa-message-fix
CORE-319 Fix issue where restarting a node fails to sync and logs "invalid pilosa.Message"
2021-03-05 15:58:06 -06:00
Matt Jaffee
f97ac4928c
add test for pilosa.Message issue
this doesn't quite work as-is, but I verified that it reproduced/fixed
the issue by adding a panic where the problem log statement
is. There's a follow up ticket to fix the test... it's just a bit open
ended as to the best way to do that.
2021-03-05 14:16:52 -06:00
Matt Jaffee
08d4511e6c
fix issue where restarting a cluster logged "invalid pilosa.Message"
we were sending pilosa.Message objects from a spool, but actually
passing a pointer to them rather than the Message itself. I'm
concerned this wasn't caught in any test, and also curious if that
needed to be a pointer for some reason or if it's a typo.

Definitely need to write a test still.
2021-03-05 12:51:39 -06:00
Travis Turner
fa9e17878f
Merge pull request #1503 from molecula/disco
DisCo
2021-03-04 17:24:42 -06:00
Matt Jaffee
bb713f94a5
Merge branch 'master' into disco 2021-03-04 16:56:35 -06:00
Cody Soyland
bf050a69d2
Merge pull request #1511 from codysoyland/release-on-tag
Run release stage when tags are pushed
2021-03-04 15:22:01 -06:00