Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[wip] datastore v2 testing #601

Closed
wants to merge 17 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
126 changes: 63 additions & 63 deletions .github/workflows/build-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,46 +32,46 @@ on: # yamllint disable-line rule:truthy
- "internal/**"
- "proto/**"
jobs:
build:
name: "Build Binary"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v3"
- uses: "actions/setup-go@v3"
with:
go-version: "~1.18"
- uses: "authzed/actions/go-build@main"

image-build:
name: "Build Container Image"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v3"
- uses: "actions/setup-go@v3"
with:
go-version: "~1.18"
- uses: "authzed/actions/docker-build@main"
with:
push: false
tags: "authzed/spicedb:ci"
buildx: false
qemu: false
- uses: "authzed/actions/go-test@main"
with:
working_directory: "cmd/spicedb"
tags: "docker"

unit:
name: "Unit"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v3"
- uses: "actions/setup-go@v3"
with:
go-version: "~1.18"
- uses: "authzed/actions/go-test@main"
with:
tags: "ci"
# build:
# name: "Build Binary"
# runs-on: "ubuntu-latest"
# steps:
# - uses: "actions/checkout@v3"
# - uses: "actions/setup-go@v3"
# with:
# go-version: "~1.18"
# - uses: "authzed/actions/go-build@main"
#
# image-build:
# name: "Build Container Image"
# runs-on: "ubuntu-latest"
# steps:
# - uses: "actions/checkout@v3"
# - uses: "actions/setup-go@v3"
# with:
# go-version: "~1.18"
# - uses: "authzed/actions/docker-build@main"
# with:
# push: false
# tags: "authzed/spicedb:ci"
# buildx: false
# qemu: false
# - uses: "authzed/actions/go-test@main"
# with:
# working_directory: "cmd/spicedb"
# tags: "docker"
#
# unit:
# name: "Unit"
# runs-on: "ubuntu-latest"
# steps:
# - uses: "actions/checkout@v3"
# - uses: "actions/setup-go@v3"
# with:
# go-version: "~1.18"
# - uses: "authzed/actions/go-test@main"
# with:
# tags: "ci"

e2e:
name: "E2E"
Expand Down Expand Up @@ -121,26 +121,26 @@ jobs:
name: "node-logs"
path: "e2e/newenemy/*.log"

protobuf:
name: "Generate Protobufs"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v3"
- uses: "actions/setup-go@v3"
with:
go-version: "~1.18"
- name: "Install Go Protobuf plugins"
run: |
go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.27.1
go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@v1.1
go install github.com/envoyproxy/protoc-gen-validate@v0.6.7
- uses: "authzed/actions/buf-generate@main"
- uses: "bufbuild/buf-breaking-action@v0.4.0"
if: "github.event_name == 'pull_request'"
env:
BUF_INPUT_HTTPS_USERNAME: "${{ github.actor }}"
BUF_INPUT_HTTPS_PASSWORD: "${{ github.token }}"
with:
input: "proto/internal"
against: "https://github.com/authzed/spicedb.git#branch=main,subdir=proto/internal"
buf_token: "${{ secrets.BUF_REGISTRY_TOKEN }}"
# protobuf:
# name: "Generate Protobufs"
# runs-on: "ubuntu-latest"
# steps:
# - uses: "actions/checkout@v3"
# - uses: "actions/setup-go@v3"
# with:
# go-version: "~1.18"
# - name: "Install Go Protobuf plugins"
# run: |
# go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.27.1
# go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@v1.1
# go install github.com/envoyproxy/protoc-gen-validate@v0.6.7
# - uses: "authzed/actions/buf-generate@main"
# - uses: "bufbuild/buf-breaking-action@v0.4.0"
# if: "github.event_name == 'pull_request'"
# env:
# BUF_INPUT_HTTPS_USERNAME: "${{ github.actor }}"
# BUF_INPUT_HTTPS_PASSWORD: "${{ github.token }}"
# with:
# input: "proto/internal"
# against: "https://github.com/authzed/spicedb.git#branch=main,subdir=proto/internal"
# buf_token: "${{ secrets.BUF_REGISTRY_TOKEN }}"
14 changes: 7 additions & 7 deletions .github/workflows/labeler.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ name: "Pull Request Labeler"
on: # yamllint disable-line rule:truthy
- "pull_request_target"
jobs:
triage:
runs-on: "ubuntu-latest"
steps:
- uses: "actions/labeler@v3"
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
sync-labels: true
# triage:
# runs-on: "ubuntu-latest"
# steps:
# - uses: "actions/labeler@v3"
# with:
# repo-token: "${{ secrets.GITHUB_TOKEN }}"
# sync-labels: true
128 changes: 64 additions & 64 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,67 +8,67 @@ on: # yamllint disable-line rule:truthy
pull_request:
branches: ["*"]
jobs:
unit-analyzers:
name: "Unit Test Analyzers"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v3"
- uses: "actions/setup-go@v3"
with:
go-version: "~1.18"
- uses: "authzed/actions/go-test@main"
with:
working_directory: "tools/analyzers"

go-lint:
name: "Lint Go"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v3"
- uses: "actions/setup-go@v3"
with:
go-version: "~1.18"
- uses: "authzed/actions/gofumpt@main"
- uses: "authzed/actions/go-mod-tidy@main"
- uses: "authzed/actions/go-mod-tidy@main"
with:
working_directory: "e2e"
- uses: "authzed/actions/go-mod-tidy@main"
with:
working_directory: "tools/analyzers"
- uses: "authzed/actions/go-generate@main"
- uses: "authzed/actions/golangci-lint@main"
- uses: "authzed/actions/go-build@main"
with:
working_directory: "tools/analyzers"
- name: "Run custom analyzers"
run: "./tools/analyzers/analyzers -skip-pkg \"github.com/authzed/spicedb/pkg/proto/dispatch/v1\" -disallowed-nil-return-type-paths \"*github.com/authzed/spicedb/pkg/proto/dispatch/v1.DispatchCheckResponse,*github.com/authzed/spicedb/pkg/proto/dispatch/v1.DispatchExpandResponse,*github.com/authzed/spicedb/pkg/proto/dispatch/v1.DispatchLookupResponse\" ./..."

extra-lint:
name: "Lint YAML & Markdown"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v3"
- uses: "authzed/actions/yaml-lint@main"
- uses: "instrumenta/kubeval-action@5915e4adba5adccac07cb156b82e54c3fed74921"
with:
files: "k8s"
- uses: "authzed/actions/markdown-lint@main"
- uses: "ludeeus/action-shellcheck@1.1.0"
with:
scandir: "./hack"

codeql:
name: "Analyze with CodeQL"
runs-on: "ubuntu-latest"
permissions:
actions: "read"
contents: "read"
security-events: "write"
strategy:
fail-fast: false
matrix:
language: ["go"]
steps:
- uses: "actions/checkout@v3"
- uses: "authzed/actions/codeql@main"
# unit-analyzers:
# name: "Unit Test Analyzers"
# runs-on: "ubuntu-latest"
# steps:
# - uses: "actions/checkout@v3"
# - uses: "actions/setup-go@v3"
# with:
# go-version: "~1.18"
# - uses: "authzed/actions/go-test@main"
# with:
# working_directory: "tools/analyzers"
#
# go-lint:
# name: "Lint Go"
# runs-on: "ubuntu-latest"
# steps:
# - uses: "actions/checkout@v3"
# - uses: "actions/setup-go@v3"
# with:
# go-version: "~1.18"
# - uses: "authzed/actions/gofumpt@main"
# - uses: "authzed/actions/go-mod-tidy@main"
# - uses: "authzed/actions/go-mod-tidy@main"
# with:
# working_directory: "e2e"
# - uses: "authzed/actions/go-mod-tidy@main"
# with:
# working_directory: "tools/analyzers"
# - uses: "authzed/actions/go-generate@main"
# - uses: "authzed/actions/golangci-lint@main"
# - uses: "authzed/actions/go-build@main"
# with:
# working_directory: "tools/analyzers"
# - name: "Run custom analyzers"
# run: "./tools/analyzers/analyzers -skip-pkg \"github.com/authzed/spicedb/pkg/proto/dispatch/v1\" -disallowed-nil-return-type-paths \"*github.com/authzed/spicedb/pkg/proto/dispatch/v1.DispatchCheckResponse,*github.com/authzed/spicedb/pkg/proto/dispatch/v1.DispatchExpandResponse,*github.com/authzed/spicedb/pkg/proto/dispatch/v1.DispatchLookupResponse\" ./..."
#
# extra-lint:
# name: "Lint YAML & Markdown"
# runs-on: "ubuntu-latest"
# steps:
# - uses: "actions/checkout@v3"
# - uses: "authzed/actions/yaml-lint@main"
# - uses: "instrumenta/kubeval-action@5915e4adba5adccac07cb156b82e54c3fed74921"
# with:
# files: "k8s"
# - uses: "authzed/actions/markdown-lint@main"
# - uses: "ludeeus/action-shellcheck@1.1.0"
# with:
# scandir: "./hack"
#
# codeql:
# name: "Analyze with CodeQL"
# runs-on: "ubuntu-latest"
# permissions:
# actions: "read"
# contents: "read"
# security-events: "write"
# strategy:
# fail-fast: false
# matrix:
# language: ["go"]
# steps:
# - uses: "actions/checkout@v3"
# - uses: "authzed/actions/codeql@main"
2 changes: 1 addition & 1 deletion cmd/spicedb/migrate_integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ import (
"github.com/ory/dockertest/v3/docker"
"github.com/stretchr/testify/require"

"github.com/authzed/spicedb/internal/datastore"
testdatastore "github.com/authzed/spicedb/internal/testserver/datastore"
"github.com/authzed/spicedb/pkg/datastore"
)

var toSkip = []string{"memory"}
Expand Down
Loading