woocoo

package module
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2022 License: MIT Imports: 10 Imported by: 24

README

WooCoo

Language codecov Go Report Card Build Status Release GoDoc

Introduction

WooCoo is an application development framework and toolkit written in GO(Golang). It is easy to develop WebApi applications or RPC services.

WooCoo mainly plays a role of adhesive, and its core components are from other open source projects. The current features are as follows:

Features

  • component configurable,easy to split multi environments
  • logger and rotate support. Detail,
  • OpenTelemetry support. Detail
  • built-in web router,supports GraphQL.
  • built-in grpc server and easy to use grpc client.
  • JWT-based validation
  • microservice registry and discovery:
    • etcdv3: register and discovery services
    • Polaris: service discovery and governance

Tools

  • woco-cli: command line tool, include feature:

    • generate code support: Ent
    • server code generator for openapi 3.0 spec. seeOpenApi3 Generator

Work With

examples

woocoo examples

others:

contact:

  • QQ: 21997272

Thanks

image

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	// contains filtered or unexported fields
}

App is the application.

func New

func New(opts ...Option) *App

func (*App) AppConfiguration

func (a *App) AppConfiguration() *conf.AppConfiguration

func (*App) RegisterServer

func (a *App) RegisterServer(servers ...Server)

func (*App) Run

func (a *App) Run() error

func (*App) Stop

func (a *App) Stop() error

Stop the application.

type Option

type Option func(o *options)

func WithAppConfiguration

func WithAppConfiguration(cnf *conf.Configuration) Option

WithAppConfiguration set up the configuration of the web server by a configuration instance

type Server

type Server interface {
	Start(ctx context.Context) error
	Stop(ctx context.Context) error
}

Server is the interface that can run in App.

Directories

Path Synopsis
cmd
woco Module
contrib
etcd Module
gql Module
opentelemetry Module
polarismesh Module
telemetry Module
examples
hello-web Module
pkg
cnp
Package cnp includes concurrence and parallel tools
Package cnp includes concurrence and parallel tools
gds
log
rpc
test
web

Jump to

Keyboard shortcuts

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