aepc

command module
v0.0.0-...-8083434 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 5, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

README

aepc

Generates AEP-compliant RPCs from proto messages. See the main README.md for usage.

Purpose

aepc is designed to primarily work off of a resource model: rather than having individual RPCs / methods on a resource, the user declares resources that live under a service. The common operations against a resource (Create, Read, Update, List, and Delete) are generatable based on the desired control plane standard, such as the AEP standard or custom resource definitions for the Kubernetes Resource Model.

Design

aepc works off of an internal "hub" representation of a resource, while each of the consumers and producers is a "spoke", using the resource information for generation of service, clients, or documentation:

flowchart LR
    hub("unified service and resource hub")
    protoResources("proto messages")
    proto("protobuf")
    crd("Custom Resource Definitions (K8S)")
    http("HTTP REST APIs")
    protoResources --> hub
    hub  --> proto
    hub  --> http
    hub  --> crd

User Guide

go run main.go -i ./example/bookstore/bookstore.yaml -o ./example/bookstore/bookstore.yaml.output.proto

Documentation

Overview

Copyright 2023 Yusuke Fredrick Tsutsumi

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Directories

Path Synopsis
main serves as a convenience function to start both the service and grpc gateway simultaneously.
main serves as a convenience function to start both the service and grpc gateway simultaneously.
bookstore
Package bookstore is a reverse proxy.
Package bookstore is a reverse proxy.
package parser converts the schema into a full-fledged struct that provides more functionality for discovering resource references, etc.
package parser converts the schema into a full-fledged struct that provides more functionality for discovering resource references, etc.
Package validator exposes validation functionality for the resource definition.
Package validator exposes validation functionality for the resource definition.
writer

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL