-
Notifications
You must be signed in to change notification settings - Fork 0
Detailed Page Information #47
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
Changes from all commits
b77535c
1887421
01697d0
a0032f6
3163cf9
a990757
19b990d
c8da2c6
ee991d4
8609c73
ecae98e
d45ec16
be751ac
1fff81b
a415595
5a544b6
602a73d
07bc5d9
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,2 +1,2 @@ | ||
| generate-proto:: | ||
| rm -rf ./sdk/java/src/generated && rm -rf ./sdk/golang/gen && rm -rf ./sdk/js/gen && rm -rf ./sdk/openapi && rm -rf ./sdk/rust/src/gen && buf generate --template buf.gen.yaml | ||
| rm -rf ./sdk/java/studio && rm -rf ./sdk/go && rm -rf ./sdk/ts/src/gen && rm -rf ./sdk/openapi && buf generate --template buf.gen.yaml |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,32 +1,47 @@ | ||
| <img width="1024" height="220" alt="image" src="https://github.com/user-attachments/assets/22d1ec29-1486-4704-8061-3b98c092da21" /> | ||
|
|
||
| # Octopus API & SDKs | ||
|
|
||
| **API & SDKs for o7studios product Octopus** | ||
| Source protobufs and generated SDKs for the Octopus product. | ||
|
|
||
| ## What's here | ||
|
|
||
| - `proto/` Protocol Buffer definitions (versioned) | ||
| - `sdk/` Generated SDKs: Go, Java, TypeScript, and OpenAPI | ||
| - `buf.yaml`, `buf.gen.yaml` Buf config for linting and generation | ||
|
|
||
| ## Requirements | ||
|
|
||
| - [Buf](https://buf.build/) for code generation | ||
| - `make` (optional) for the helper target | ||
|
|
||
| ## Generate SDKs | ||
|
|
||
| ```sh | ||
| make generate-proto | ||
| ``` | ||
|
|
||
| This removes existing generated output in `sdk/` and regenerates from `proto/` via `buf`. | ||
|
|
||
| - Uses [Protocol Buffers](https://protobuf.dev/) with [Buf](https://buf.build/) | ||
| ## Install SDKs | ||
|
|
||
| ## Development | ||
| ### Go | ||
|
|
||
| Full development setup available as [Development Container](https://containers.dev/). | ||
| Please use it for being able to tell "It works on my machine". | ||
| ```sh | ||
| go get github.com/o7studios/octopus-sdk/sdk/go@latest | ||
| ``` | ||
|
|
||
| **Docker is required to be installed on your machine!** | ||
| ### TypeScript / JavaScript | ||
|
|
||
| ### IntelliJ IDEA | ||
| ```sh | ||
| npm install @o7studios/octopus-sdk | ||
| ``` | ||
|
|
||
| - Open IntelliJ (Welcome screen) | ||
| - Navigate to `Remote Development` - `Dev Containers` | ||
| - Press `New Dev Container` | ||
| - Select `From VCS Project` | ||
| - Select and connect with `Docker` | ||
| - Select `IntelliJ IDEA` | ||
| - Enter `Git Repository`: `https://github.com/o7studios/octopus-sdk` | ||
| - Select `Detection for devcontainer.json file` `Automatic` | ||
| - Press `Build Container and Continue` | ||
| ### Java | ||
|
|
||
| ### Development Container Issues | ||
| Maven Central: | ||
|
|
||
| If you encounter an issue with setting up a development container, please | ||
| try to rebuild it first before opening a GitHub Issue. It's not uncommon | ||
| that some issues may fix themselves after a fresh container rebuild. | ||
| ```kotlin | ||
| // build.gradle.kts | ||
| dependencies { | ||
| implementation("studio.o7:octopus-sdk:VERSION") | ||
| } | ||
| ``` |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,31 +1,31 @@ | ||
| version: v2 | ||
|
|
||
| plugins: | ||
| # Java | ||
| - remote: buf.build/protocolbuffers/java:v25.3 | ||
| out: ./sdk/java/src/generated/java | ||
| - remote: buf.build/grpc/java:v1.62.2 | ||
| out: ./sdk/java/src/generated/java | ||
|
|
||
| # Golang | ||
| - remote: buf.build/grpc/go:v1.5.1 | ||
| out: ./sdk/golang/gen | ||
| - remote: buf.build/protocolbuffers/java | ||
| out: sdk/java/src/java | ||
|
|
||
| - remote: buf.build/grpc/java | ||
| out: sdk/java/src/java | ||
|
|
||
| - remote: buf.build/protocolbuffers/go | ||
| out: sdk/go | ||
| opt: | ||
| - paths=source_relative | ||
| - remote: buf.build/protocolbuffers/go:v1.36.5 | ||
| out: ./sdk/golang/gen | ||
|
|
||
| - remote: buf.build/grpc/go | ||
| out: sdk/go | ||
| opt: | ||
| - paths=source_relative | ||
|
|
||
| # JavaScript / TypeScript | ||
| - remote: buf.build/bufbuild/es:v2.2.3 | ||
| out: ./sdk/js/gen | ||
| - remote: buf.build/grpc/node:v1.13.0 | ||
| out: ./sdk/js/gen | ||
| - remote: buf.build/bufbuild/es | ||
| out: sdk/ts/src/gen | ||
| opt: | ||
| - target=ts | ||
| include_imports: true | ||
|
|
||
| # OpenAPI (Swagger) | ||
| - remote: buf.build/grpc-ecosystem/openapiv2:v2.27.2 | ||
| out: ./sdk/openapi | ||
| - remote: buf.build/grpc-ecosystem/openapiv2 | ||
| out: sdk/openapi | ||
| opt: | ||
| - allow_merge=true | ||
| - merge_file_name=octopus |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -14,4 +14,4 @@ modules: | |
| - path: proto | ||
|
|
||
| deps: | ||
| - buf.build/googleapis/googleapis | ||
| - buf.build/googleapis/googleapis | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,17 +1,16 @@ | ||
| syntax = "proto3"; | ||
|
|
||
| option go_package = "github.com/o7studios/octopus-sdk/sdk/golang/gen/api/v1;apiv1"; | ||
| option java_package = "studio.o7.octopus.sdk.gen.api.v1"; | ||
| option go_package = "github.com/o7studios/octopus-sdk/go/v1;octopusv1"; | ||
| option java_package = "studio.o7.octopus.sdk.v1"; | ||
| option java_multiple_files = true; | ||
|
|
||
| package api.v1; | ||
| package octopus_sdk.v1; | ||
|
|
||
| import "google/protobuf/struct.proto"; | ||
| import "google/protobuf/empty.proto"; | ||
| import "google/protobuf/timestamp.proto"; | ||
| import "google/api/annotations.proto"; | ||
|
|
||
|
|
||
| service Octopus { | ||
| /** | ||
| * Retrieves existing entries from the database matching a | ||
|
|
@@ -83,10 +82,10 @@ message Object { | |
| google.protobuf.Struct data = 2; | ||
|
|
||
| // Timestamp when the object should no longer be visible by default. | ||
| optional google.protobuf.Timestamp expired_at = 4; | ||
| optional google.protobuf.Timestamp expired_at = 3; | ||
|
|
||
| // Timestamp when the object should be permanently deleted. | ||
| optional google.protobuf.Timestamp deleted_at = 5; | ||
| optional google.protobuf.Timestamp deleted_at = 4; | ||
| } | ||
|
|
||
| /** | ||
|
|
@@ -136,11 +135,22 @@ message GetRequest { | |
| * Paginator for database entry cursor-pagination. | ||
| */ | ||
| message Paginator { | ||
| // 1-based page index (page=1 is first page) | ||
| int32 page = 1; | ||
|
|
||
| // Number of items to return. | ||
| int32 page_size = 1; | ||
| int32 page_size = 2; | ||
| } | ||
|
Comment on lines
+138
to
+143
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Breaking change: Paginator message restructured. The
This is a wire-format breaking change. Existing clients sending pagination with If this breaking change is intentional, document the migration path clearly. |
||
|
|
||
| message PageInfo { | ||
| int32 current_page = 1; // current page (1-based) | ||
| int32 current_page_size = 2; // current page size | ||
|
|
||
| int32 total_pages = 3; // last page number | ||
| int64 total_items = 4; // total matching items | ||
|
|
||
| // Cursor for efficient pagination. First page is empty. | ||
| string cursor = 2; | ||
| optional int32 next_page = 5; // next page number. null if not present | ||
| optional int32 prev_page = 6; // previous page number. null if not present | ||
| } | ||
|
|
||
| /** | ||
|
|
@@ -150,8 +160,8 @@ message GetResponse { | |
| // List of found entries including revision, ID and timestamps. | ||
| repeated Entry entries = 1; | ||
|
|
||
| // Cursor for next page. Empty means "no more results". | ||
| string next_cursor = 2; | ||
| // Page information about the cursor. | ||
| PageInfo page_info = 2; | ||
| } | ||
|
|
||
| /** | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: o7studios/octopus-sdk
Length of output: 2036
🌐 Web query:
gRPC Go v1.78.0 release notes changelog security💡 Result:
Release v1.78.0 (published 23 Dec 2025) — release notes show behavior changes, new features, bug fixes and performance improvements but do not list any security fixes or CVE patches in that release. [1]
The notable gRPC‑Go HTTP/2 rapid‑reset DoS (CVE‑2023‑44487 / GHSA‑m425‑mq94‑257g) was fixed in earlier patch releases (1.56.3, 1.57.1, 1.58.3 and later) rather than in v1.78.0. [2][3]
Sources:
🌐 Web query:
google.golang.org/grpc v1.78.0 breaking changes compatibility💡 Result:
Summary of breaking/compatibility changes in google.golang.org/grpc v1.78.0
Behavior change (potential breaking): the gRPC client now rejects target URLs whose hostname contains unbracketed colons when running with Go 1.26+. This can break code that previously used such target formats. [1]
No other deliberate API removals called out in the v1.78.0 release notes; the release also adds stats/otel metrics features. For prior releases, minimum supported Go version was raised in earlier minor releases (e.g., v1.76.0 / v1.72.0), so verify the minimum Go toolchain required by your dependency graph before upgrading. [1][2]
Recommendation: test your codepaths that construct client target URLs (and any custom resolvers) under v1.78.0; if you rely on hostnames with unbracketed colons, update them to use bracketed IPv6 literals or otherwise canonicalize the target. See the v1.78.0 release notes for details. [1]
Sources:
[1] grpc-go v1.78.0 release notes (summary in dependency bump PRs).
[2] grpc-go v1.78.x branch / repo metadata.
🌐 Web query:
gRPC v1.78.0 CVE security advisories vulnerabilities💡 Result:
gRPC v1.78.0 — relevant public CVEs and notes
Notes: the v1.78.0 release notes do not list new CVE fixes beyond routine bug fixes; you should verify your build/package vendor for backports or distro fixes and update to a release that includes the upstream fixes (or apply vendor patches). [5]
Sources:
Test hostname validation behavior in Go 1.26+ environments.
The gRPC upgrade to v1.78.0 (released 2025-12-23) includes a behavior change: the client now rejects target URLs with unbracketed colons in the hostname when running with Go 1.26+. If your code constructs client targets using IPv6 addresses or custom resolvers, verify they use properly bracketed addresses (e.g.,
[::1]:8080not::1:8080) to avoid connection failures.🤖 Prompt for AI Agents