Skip to content

Commit bd91531

Browse files
Merge pull request #5 from pinax-network/update-deps
Update to latest substreams version
2 parents 5ce6438 + 36b9468 commit bd91531

File tree

14 files changed

+318
-90
lines changed

14 files changed

+318
-90
lines changed

.github/workflows/golangci-lint.yaml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
name: Linting
33
on:
44
push:
5-
branches: [ develop* ]
5+
branches: [develop*]
66
pull_request:
7-
branches: [ develop*,main ]
7+
branches: [develop*, main]
88

99
permissions:
1010
contents: read
@@ -14,8 +14,8 @@ jobs:
1414
runs-on: ${{ matrix.os }}
1515
strategy:
1616
matrix:
17-
go-version: [ 1.21.x ]
18-
os: [ ubuntu-latest ]
17+
go-version: [1.21.x]
18+
os: [ubuntu-latest]
1919
name: lint
2020
steps:
2121
- name: Checkout repo
@@ -32,13 +32,15 @@ jobs:
3232
repo-token: ${{ secrets.GITHUB_TOKEN }}
3333

3434
- name: Format
35-
run: task test:format
35+
run: cd api-service && task test:format
3636

3737
- name: Run golangci-lint
3838
uses: golangci/golangci-lint-action@v4
3939
with:
4040
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
4141
version: v1.56
42+
# Optional: working directory, useful when you have multiple Go modules
43+
working-directory: api-service
4244
# Optional: golangci-lint command line arguments.
4345
args: --timeout=5m
4446
# Optional: show only new issues if it's a pull request. The default value is `false`.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
syntax = "proto3";
2+
package sf.substreams.sink.kv.v1;
3+
4+
option go_package = "github.com/streamingfast/substreams-sink-kv/pb;pbkv";
5+
6+
message KVOperations {
7+
repeated KVOperation operations = 1;
8+
}
9+
10+
message KVOperation {
11+
string key = 1;
12+
bytes value = 2;
13+
uint64 ordinal = 3;
14+
enum Type {
15+
UNSET = 0; // Protobuf default should not be used, this is used so that the consume can ensure that the value was actually specified
16+
SET = 1;
17+
DELETE = 2;
18+
}
19+
Type type = 4;
20+
}
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
syntax = "proto3";
2+
package sf.substreams.sink.kv.v1;
3+
4+
option go_package = "github.com/streamingfast/substreams-sink-kv/pb;pbkv";
5+
6+
7+
message Config {
8+
int64 start_block = 1;
9+
string input_module = 2;
10+
}
11+
12+
// This defines a KV Sink to be queried with a generic key access interface (Get, GetMany, Scan, Prefix calls).
13+
message GenericService {
14+
Config sink_config = 1;
15+
}
16+
17+
// This defines configuration to run a WASM query service on top of the KV store being sync'd.
18+
message WASMQueryService {
19+
Config sink_config = 1;
20+
21+
// wasm exports: "kv_get_batch", "kv_get", "kv_scan", "kv_prefix"
22+
bytes wasm_query_module = 5;
23+
24+
// Fully qualified Protobuf Service definition name
25+
string grpc_service = 2; // sf.mycustom.v1.MyService
26+
}

0 commit comments

Comments
 (0)