Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
Controller definition.
func NewController ¶
func NewController(srv *Service, logger *zap.Logger) *Controller
NewController create a new controler.
func (*Controller) GetCurrentGuardianSet ¶
func (c *Controller) GetCurrentGuardianSet(ctx context.Context) (*GuardianSetDoc, error)
func (*Controller) GetGuardianSet ¶
func (c *Controller) GetGuardianSet(ctx *fiber.Ctx) error
GetGuardianSet handler for the endpoint /api/guardianset/current This endpoint has been migrated from the guardian grpc api.
type GuardianSetDoc ¶
type Repository ¶
type Repository struct {
// contains filtered or unexported fields
}
func NewRepository ¶
func NewRepository(db *mongo.Database, logger *zap.Logger) *Repository
func (*Repository) GetCurrentGuardianSet ¶
func (r *Repository) GetCurrentGuardianSet(ctx context.Context) (*GuardianSetDoc, error)
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶
func NewService(dao *Repository, logger *zap.Logger) *Service
func (*Service) GetCurrentGuardianSet ¶
func (s *Service) GetCurrentGuardianSet(ctx context.Context) (*GuardianSetDoc, error)
Click to show internal directories.
Click to hide internal directories.