Skip to content

Instantly share code, notes, and snippets.

@desa
desa / readme.md
Created February 4, 2019 19:27
authz

Access control

There are a number of concepts that are currently loosely related to access control.

  1. Authorizations
  2. Sessions
  3. User Resource Mapping

The way that a request is currently authorized takes place in one of two ways

Case 1. a token (part of an authorization) is provided

@desa
desa / acl.md
Last active January 25, 2019 01:42
authz wip

Authorization

There are primarily two classes of actions that need to be authorized

  1. Performing an action against a specific resource
  2. Retrieving all resources subject is authorized to access

Definitions

  • subject - entity performing the action (org, user, or token)
@desa
desa / non_time_series.md
Last active January 23, 2019 18:57
InfluxDB thoughts

Add support for storing generic non time series data

InfluxDB is great at storing and working with time series data, however that data is often useless without some additional non time series data.

Take Chronograf as an example. Without the ability to store dashboards, Chronograf would be nothing more than a visual query builder. The rich experience that Chronograf provides is only possible since can store some amount of non time series data.

I propose that we allow users to store Tables of non time series data. This would truly

@desa
desa / access_control.md
Last active January 18, 2019 16:18
Ideas

Access control

There are a number of concepts that are currently loosely related to access control.

  1. Authorizations
  2. Sessions
  3. User Resource Mapping

The way that a request is currently authorized takes place in one of two ways

Case 1. a token (part of an authorization) is provided

@desa
desa / main.go
Created October 17, 2016 21:40
Query Perf Script
package main
import (
"fmt"
"math"
"time"
"github.com/influxdata/influxdb/client/v2"
)
@desa
desa / panic.txt
Created September 28, 2016 22:53
packBlock panic
[tsm1] 2016/09/28 15:45:01 compacting level 1 group (0) /Users/michaeldesa/.influxdb/data/stress/autogen/2/000000007-000000001.tsm (#1)
unexpected fault address 0x811b009
fatal error: fault
[signal SIGBUS: bus error code=0x2 addr=0x811b009 pc=0x41def2]
goroutine 781 [running]:
runtime.throw(0x67056a, 0x5)
/usr/local/Cellar/go/1.7.1/libexec/src/runtime/panic.go:566 +0x95 fp=0xc42042d360 sp=0xc42042d340
runtime.sigpanic()
/usr/local/Cellar/go/1.7.1/libexec/src/runtime/sigpanic_unix.go:21 +0x1d0 fp=0xc42042d3b8 sp=0xc42042d360
@desa
desa / panic
Last active March 9, 2016 22:45
Full panic
[query] 2016/03/09 22:44:53 SELECT count("*") * "*" FROM stress."default".cpu
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xb code=0x1 addr=0x20 pc=0x6eb986]
goroutine 115 [running]:
github.com/influxdata/influxdb/influxql.Iterators.Close(0xc20933ac40, 0x1, 0x1, 0x0, 0x0)
/tmp/influxdb/src/github.com/influxdata/influxdb/influxql/iterator.go:39 +0x96
github.com/influxdata/influxdb/influxql.(*Emitter).Close(0xc208170e00, 0x0, 0x0)
/tmp/influxdb/src/github.com/influxdata/influxdb/influxql/emitter.go:38 +0x4d
github.com/influxdata/influxdb/cluster.(*QueryExecutor).executeSelectStatement(0xc20805a6c0, 0xc20b8a2820, 0x2710, 0x0, 0xc20b096180, 0xc20b096120, 0x0, 0x0)
@desa
desa / a
Created February 25, 2016 20:02
markov talk
a
@desa
desa / gist:69ba623f985f10806b65
Created October 5, 2015 16:49
100B point test panic
[tsm1] 2015/10/02 21:48:28 writing new index file /var/opt/influxdb/data/_internal/monitor/1/0000001.tsm1
[tsm1wal] 2015/10/02 21:48:28 /var/opt/influxdb/data/_internal/monitor/1 flush to index took 3.725643ms
[tsm1wal] 2015/10/02 21:49:28 idle flush of /var/opt/influxdb/data/_internal/monitor/1 with 27 keys and 162 total values of 2592 bytes
[tsm1] 2015/10/02 21:49:28 writing new index file /var/opt/influxdb/data/_internal/monitor/1/0000002.tsm1
[tsm1wal] 2015/10/02 21:49:28 /var/opt/influxdb/data/_internal/monitor/1 flush to index took 2.906997ms
[tsm1wal] 2015/10/02 21:50:28 idle flush of /var/opt/influxdb/data/_internal/monitor/1 with 27 keys and 162 total values of 2592 bytes
[tsm1] 2015/10/02 21:50:28 writing new index file /var/opt/influxdb/data/_internal/monitor/1/0000003.tsm1
[tsm1wal] 2015/10/02 21:50:28 /var/opt/influxdb/data/_internal/monitor/1 flush to index took 3.756706ms
[tsm1wal] 2015/10/02 21:51:28 idle flush of /var/opt/influxdb/data/_internal/monitor/1 with 27 keys and 162 total values of
channel_buffer_size = 100000
[write]
concurrency = 10
batch_size = 10000
batch_interval = "0s"
database = "stress"
precision = "n"
address = "localhost:8086"
reset_database = true