Skip to content

Instantly share code, notes, and snippets.

View danburkert's full-sized avatar

Dan Burkert danburkert

View GitHub Profile
@danburkert
danburkert / SchemaInference.java
Created January 10, 2019 22:29
Schema Inference Benchmark Harness
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.ResultSetMetaData;
import java.sql.SQLException;
import java.sql.Statement;
import java.time.Duration;
import java.util.LinkedHashMap;
import java.util.concurrent.Callable;
@danburkert
danburkert / build.rs
Created September 18, 2017 05:15
Example of downloading external .proto files in a build.rs for use with prost
extern crate curl;
extern crate prost_build;
extern crate tempdir;
use std::env;
use std::fs;
use std::io::Write;
use std::path::{Path, PathBuf};
use curl::easy::Easy;
Fresh byteorder v1.0.0
Fresh serde v1.0.8
Fresh libc v0.2.24
Fresh serde_test v1.0.8
Fresh iovec v0.1.0
Fresh bytes v0.4.4 (file:///home/dcb/src/rust/bytes)
Finished dev [unoptimized + debuginfo] target(s) in 0.0 secs
Running `/home/dcb/src/rust/bytes/target/debug/deps/test_bytes-cafb41604a170856`
Uninitialized bytes in __interceptor_memchr at offset 14 inside [0x702000000080, 22)
==9534==WARNING: MemorySanitizer: use-of-uninitialized-value
fn main() {
let key_types = &[
("i32", "int32"),
("i64", "int64"),
("u32", "uint32"),
("u64", "uint64"),
("i32", "sint32"),
("i64", "sint64"),
("u32", "fixed32"),
#![feature(test)]
extern crate proto;
extern crate test;
extern crate bytes;
use test::Bencher;
use bytes::BytesMut;
use bytes::BufMut;
client to server authn server to client authn notes
GSSAPI GSSAPI Kerberos provides strong mutual authentication, tls-server-end-point ties the Kerberos authentication to the TLS channel
Certificate Certificate client and server mutually authenticate via trusted CA-signed certs
Token Certificate

TLS verification will initially require the presented cert to be signed by the trusted root CA. Eventually we will add hostname and/or server ID checking as well.

| client->server authn | server->client TLS verification | client->server TLS verification | notes | | GSSAPI | ✗ | ✗ | GSSAPI/Kerberos provides strong mutual authentication |

DEBUG:kudu::mini_cluster: (master:34541): WARNING: Logging before InitGoogleLogging() is written to STDERR
DEBUG:kudu::mini_cluster: (master:34541): W1114 20:33:03.041072 12477 flags.cc:296] Enabled unsafe flag: --enable_data_block_fsync=false
DEBUG:kudu::mini_cluster: (master:34541): W1114 20:33:03.042135 12477 flags.cc:296] Enabled experimental flag: --rpc_trace_negotiation=true
DEBUG:kudu::mini_cluster: (master:34541): I1114 20:33:03.043179 12477 master_main.cc:60] Master server non-default flags:
DEBUG:kudu::mini_cluster: (master:34541): --enable_data_block_fsync=false
DEBUG:kudu::mini_cluster: (master:34541): --fs_data_dirs=/tmp/kudu-rs-mini-cluster.bskfVtyHDNKS/master-0
DEBUG:kudu::mini_cluster: (master:34541): --fs_wal_dir=/tmp/kudu-rs-mini-cluster.bskfVtyHDNKS/master-0
DEBUG:kudu::mini_cluster: (master:34541): --rpc_trace_negotiation=true
DEBUG:kudu::mini_cluster: (master:34541): --rpc_dump_all_traces=true
DEBUG:kudu::mini_cluster: (master:34541): --rpc_bind_addresses=127.0.0.1:34541
I1003 23:19:21.212206 23805 external_mini_cluster.cc:596] Running /data1/jenkins-workspace/kudu-workspace/build/tsan/bin/kudu-tserver
kudu-tserver
--fs_wal_dir=/data1/test-tmp/alter_table-randomized-test.AlterTableRandomized.TestRandomSequence.1475561879612998-23805/minicluster-data/ts-2
--fs_data_dirs=/data1/test-tmp/alter_table-randomized-test.AlterTableRandomized.TestRandomSequence.1475561879612998-23805/minicluster-data/ts-2
--rpc_bind_addresses=127.92.253.2:43943
--local_ip_for_outbound_sockets=127.92.253.2
--webserver_port=44315
--webserver_interface=127.92.253.2
--tserver_master_addrs=127.0.0.1:44356
--metrics_log_interval_ms=1000
CREATE TABLE t (
a STRING NOT NULL,
b INT32 NOT NULL,
PRIMARY KEY (a, b)
)
PARTITION BY
RANGE (a) (
PARTITION "a" <= VALUES < "c",
PARTITION "f" <= VALUES < "z")
RANGE (b) (