Skip to content

Instantly share code, notes, and snippets.

View jbowens's full-sized avatar

Jackson Owens jbowens

View GitHub Profile
diff --git a/pkg/kv/kvnemesis/generator.go b/pkg/kv/kvnemesis/generator.go
index 6287d89f249..41a35c9fd60 100644
--- a/pkg/kv/kvnemesis/generator.go
+++ b/pkg/kv/kvnemesis/generator.go
@@ -327,52 +327,28 @@ type ChangeZoneConfig struct {
// yet pass (for example, if the new operation finds a kv bug or edge case).
func newAllOperationsConfig() GeneratorConfig {
clientOpConfig := ClientOperationConfig{
- GetMissing: 1,
- GetMissingForUpdate: 1,
logs/3.unredacted/logs/cockroach.michaelbutler-1658177579-01-n3cpu4-0003.ubuntu.2022-07-18T21_06_59Z.013004.log-I220718 21:06:27.732491 75494 ccl/backupccl/restore_data_processor.go:262 ⋮ [n3,f‹adfb6031›,job=780232219198357505] 4697746 About to Process Span Entry: [‹/Table/107/1›,‹/Table/107/2›)
logs/3.unredacted/logs/cockroach.michaelbutler-1658177579-01-n3cpu4-0003.ubuntu.2022-07-18T21_06_59Z.013004.log-I220718 21:06:27.732528 75494 ccl/backupccl/restore_data_processor.go:267 ⋮ [n3,f‹adfb6031›,job=780232219198357505] 4697747 File 0: ‹/Table/107/1 , /Table/107/2›
logs/3.unredacted/logs/cockroach.michaelbutler-1658177579-01-n3cpu4-0003.ubuntu.2022-07-18T21_06_59Z.013004.log-I220718 21:06:27.732545 75494 ccl/backupccl/restore_data_processor.go:267 ⋮ [n3,f‹adfb6031›,job=780232219198357505] 4697748 File 1: ‹/Table/107/1 , /Table/107/2›
logs/3.unredacted/logs/cockroach.michaelbutler-1658177579-01-n3cpu4-0003.ubuntu.2022-07-18T21_06_59Z.013004.log:W220718 21:06:27.740195 75495 storage/pebble_iterator.go:135 ⋮
(pprof) top50
Showing nodes accounting for 107.40mins, 81.06% of 132.49mins total
Dropped 958 nodes (cum <= 0.66mins)
Showing top 50 nodes out of 145
flat flat% sum% cum cum%
14.67mins 11.07% 11.07% 33.19mins 25.05% github.com/cockroachdb/pebble/sstable.(*blockIter).SeekGE
11.29mins 8.52% 19.60% 11.67mins 8.81% syscall.Syscall
9.14mins 6.89% 26.49% 17.63mins 13.30% main.mvccCompare
8.85mins 6.68% 33.17% 16.75mins 12.65% github.com/cockroachdb/pebble/internal/arenaskl.(*Skiplist).findSpliceForLevel
6.05mins 4.57% 37.74% 6.05mins 4.57% cmpbody
This file has been truncated, but you can view the full file.
I200811 17:43:43.303337 1 util/log/sync_buffer.go:195 [config] file created at: 2020/08/11 17:43:43
I200811 17:43:43.303342 1 util/log/sync_buffer.go:195 [config] running on machine: ip-10-12-17-204
I200811 17:43:43.303345 1 util/log/sync_buffer.go:195 [config] binary: CockroachDB CCL v20.2.0-alpha.1-2003-g0ae791a39a-dirty (x86_64-unknown-linux-gnu, built 2020/08/11 17:03:57, go1.13.14)
I200811 17:43:43.303347 1 util/log/sync_buffer.go:195 [config] arguments: [./cockroach start --insecure --store=path=/mnt/data1/cockroach --log-dir=/home/ubuntu/logs --cache=25% --max-sql-memory=25% --port=26257 --http-port=26258 --locality=cloud=aws,region=us-east-2,zone=us-east-2b --join=18.188.135.187:26257 --advertise-host=10.12.17.204]
I200811 17:43:43.303353 1 util/log/sync_buffer.go:195 [config] line format: [IWEF]yymmdd hh:mm:ss.uuuuuu goid file:line msg utf8=✓
W200811 17:43:43.303260 1 cli/start.go:1314 RUNNING IN INSECURE MODE!
- Your cluster is open for any client that can access <all your IP addresses>.
- An

Ideally, we could evaluate heuristics on:

  • Write amplification
    • We have existing data in Metrics.
  • Space amplification
    • At the end of a test, we could manually Compact(_, _) the entire key space and measure the change in sum of alls stables.
    • Measuring the size of the database's active files at consistent points in the same workload can give us a relative measure of space amplification (eg, this heuristic amplified by x additional bytes), but not an amplification factor.
  • Read amplification
    • Point read amplification
  • How many files are in L0?
package main
import (
"bytes"
"fmt"
)
func main() {
functionWithBuffer()
}
package main
import (
"crypto/tls"
"crypto/x509"
"net/http"
)
const tlsCrt = `-----BEGIN CERTIFICATE-----
MIIBgzCCASmgAwIBAgIQL7MpDWvb8tnkLd7ydYboUjAKBggqhkjOPQQDAjAqMRQw
package main
import (
"fmt"
"time"
)
func main() {
timer := time.NewTicker(time.Second)
package main
import (
"fmt"
"net/http"
"strings"
)
const testUrl = "http://respondto.it/jackson-proxy-test"
const testPayload = "hello world"
@jbowens
jbowens / ImageWithClass.php
Created January 7, 2014 21:47
A jBBCode Code Definition for an image bbcode that supports an option class name argument.
<?php
require_once "jBBCode" . DIRECTORY_SEPARATOR . "Parser.php";
/**
* Implements an [img=alt] tag that supports an optional class argument.
*
*/
class ImageWithClass extends \JBBCode\CodeDefinition
{