-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: move buf.yaml into the module to fix usage package import error (#…
…75) Because - usage package can't correctly import mgmt package. See [here](https://github.com/instill-ai/protogen-go/blob/1030118a20444e8501a88889b609aab99a351a86/usage/v1alpha/usage.pb.go#L10). This commit - put `buf.yaml` in the module folder (See [buf project directory example](https://docs.buf.build/tour/generate-code#generate-c-and-java-stubs)) - add `healthcheck` package and import it to all backends
- Loading branch information
1 parent
62cf175
commit 3b33ff4
Showing
24 changed files
with
504 additions
and
426 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
version: v1 | ||
directories: | ||
- instill |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,54 +1,34 @@ | ||
syntax = "proto3"; | ||
|
||
package instill.connector.v1alpha; | ||
package connector.v1alpha; | ||
|
||
// Google API | ||
import "google/api/field_behavior.proto"; | ||
|
||
// HealthCheckRequest represents a request to health check a service | ||
message HealthCheckRequest { | ||
// Service name to check for its readiness status | ||
optional string service = 1 [ (google.api.field_behavior) = OPTIONAL ]; | ||
} | ||
|
||
// HealthCheckResponse represents a response for a service heath status | ||
message HealthCheckResponse { | ||
// ServingStatus enumerates the status of a queried service | ||
enum ServingStatus { | ||
// Serving status: UNSPECIFIED | ||
SERVING_STATUS_UNSPECIFIED = 0; | ||
// Serving status: SERVING | ||
SERVING_STATUS_SERVING = 1; | ||
// Serving status: NOT SERVING | ||
SERVING_STATUS_NOT_SERVING = 2; | ||
} | ||
|
||
// Status is the instance of the enum type ServingStatus | ||
ServingStatus status = 1; | ||
} | ||
import "healthcheck/v1alpha/healthcheck.proto"; | ||
|
||
// LivenessRequest represents a request to check a service liveness status | ||
message LivenessRequest { | ||
// HealthCheckRequest message | ||
optional HealthCheckRequest health_check_request = 1 | ||
optional healthcheck.v1alpha.HealthCheckRequest health_check_request = 1 | ||
[ (google.api.field_behavior) = OPTIONAL ]; | ||
} | ||
|
||
// LivenessResponse represents a response for a service liveness status | ||
message LivenessResponse { | ||
// HealthCheckResponse message | ||
HealthCheckResponse health_check_response = 1; | ||
healthcheck.v1alpha.HealthCheckResponse health_check_response = 1; | ||
} | ||
|
||
// ReadinessRequest represents a request to check a service readiness status | ||
message ReadinessRequest { | ||
// HealthCheckRequest message | ||
optional HealthCheckRequest health_check_request = 1 | ||
optional healthcheck.v1alpha.HealthCheckRequest health_check_request = 1 | ||
[ (google.api.field_behavior) = OPTIONAL ]; | ||
} | ||
|
||
// ReadinessResponse represents a response for a service readiness status | ||
message ReadinessResponse { | ||
// HealthCheckResponse message | ||
HealthCheckResponse health_check_response = 1; | ||
healthcheck.v1alpha.HealthCheckResponse health_check_response = 1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
syntax = "proto3"; | ||
|
||
package healthcheck.v1alpha; | ||
|
||
// Google API | ||
import "google/api/field_behavior.proto"; | ||
|
||
// HealthCheckRequest represents a request to health check a service | ||
message HealthCheckRequest { | ||
// Service name to check for its readiness status | ||
optional string service = 1 [ (google.api.field_behavior) = OPTIONAL ]; | ||
} | ||
|
||
// HealthCheckResponse represents a response for a service heath status | ||
message HealthCheckResponse { | ||
// ServingStatus enumerates the status of a queried service | ||
enum ServingStatus { | ||
// Serving status: UNSPECIFIED | ||
SERVING_STATUS_UNSPECIFIED = 0; | ||
// Serving status: SERVING | ||
SERVING_STATUS_SERVING = 1; | ||
// Serving status: NOT SERVING | ||
SERVING_STATUS_NOT_SERVING = 2; | ||
} | ||
|
||
// Status is the instance of the enum type ServingStatus | ||
ServingStatus status = 1; | ||
} | ||
|
||
// LivenessRequest represents a request to check a service liveness status | ||
message LivenessRequest { | ||
// HealthCheckRequest message | ||
optional HealthCheckRequest health_check_request = 1 | ||
[ (google.api.field_behavior) = OPTIONAL ]; | ||
} | ||
|
||
// LivenessResponse represents a response for a service liveness status | ||
message LivenessResponse { | ||
// HealthCheckResponse message | ||
HealthCheckResponse health_check_response = 1; | ||
} | ||
|
||
// ReadinessRequest represents a request to check a service readiness status | ||
message ReadinessRequest { | ||
// HealthCheckRequest message | ||
optional HealthCheckRequest health_check_request = 1 | ||
[ (google.api.field_behavior) = OPTIONAL ]; | ||
} | ||
|
||
// ReadinessResponse represents a response for a service readiness status | ||
message ReadinessResponse { | ||
// HealthCheckResponse message | ||
HealthCheckResponse health_check_response = 1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
syntax = "proto3"; | ||
|
||
package mgmt.v1alpha; | ||
|
||
// Google API | ||
import "google/api/field_behavior.proto"; | ||
|
||
import "healthcheck/v1alpha/healthcheck.proto"; | ||
|
||
// LivenessRequest represents a request to check a service liveness status | ||
message LivenessRequest { | ||
// HealthCheckRequest message | ||
optional healthcheck.v1alpha.HealthCheckRequest health_check_request = 1 | ||
[ (google.api.field_behavior) = OPTIONAL ]; | ||
} | ||
|
||
// LivenessResponse represents a response for a service liveness status | ||
message LivenessResponse { | ||
// HealthCheckResponse message | ||
healthcheck.v1alpha.HealthCheckResponse health_check_response = 1; | ||
} | ||
|
||
// ReadinessRequest represents a request to check a service readiness status | ||
message ReadinessRequest { | ||
// HealthCheckRequest message | ||
optional healthcheck.v1alpha.HealthCheckRequest health_check_request = 1 | ||
[ (google.api.field_behavior) = OPTIONAL ]; | ||
} | ||
|
||
// ReadinessResponse represents a response for a service readiness status | ||
message ReadinessResponse { | ||
// HealthCheckResponse message | ||
healthcheck.v1alpha.HealthCheckResponse health_check_response = 1; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.