service

package
v0.1.2-bate Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

README ¶

Service Directory Documentation

Welcome to this documentation! 🎉🎉🎉 Here, we will delve into the main purpose and usage of the service directory.

1. The Service Provider: The Service Directory 📡

The service directory is the service provider of our project. It's a place where we declare the specific services that our application offers. You can think of it as the front desk 🎫 of a hotel, where guests (clients) can request specific services.

Each service provided corresponds one-to-one with the service interfaces generated under the api directory's proto files. This means our application can offer a wide array of services, each tailored to a specific need.

2. Protocol Compatibility and Request Handling 🎯

The service directory is also a protocol chameleon 🦎, capable of adapting to multiple protocols for service calls. In general, it allows service calls via HTTP and gRPC protocols, providing flexibility for various use-cases.

The logic in the service layer mainly involves some parameter validation and request content conversion operations. Specifically, it performs req -> bo (request to business object) conversions and bo -> rep (business object to response) operations.

By doing so, the service directory ensures that our services are robust, reliable, and adaptable to various client needs. 🚀🚀🚀

We hope this guide helps you navigate the service directory more effectively. Happy coding! 💻💻💻

Documentation ¶

Index ¶

Constants ¶

This section is empty.

Variables ¶

View Source
var ProviderSet = wire.NewSet(NewLoginService)

Functions ¶

This section is empty.

Types ¶

type LoginService ¶

type LoginService struct {
	v1.UnimplementedLoginServer
	// contains filtered or unexported fields
}

func NewLoginService ¶

func NewLoginService(uc *biz.LoginUseCase) *LoginService

func (*LoginService) Login ¶

func (svc *LoginService) Login(ctx context.Context, req *v1.LoginRequest) (*v1.LoginReply, error)

Jump to

Keyboard shortcuts

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