releasehandler

package
v0.0.0-...-6794387 Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2021 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const AddReleaseType string = "add-release"

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct {
	ReleaseExchange              string
	Broker                       *broker.Broker
	MaxReleaseCatcherMessageSize int
	JwtSecret                    string
	RedisClient                  *redis.RedisClient
	AccountsMongoDBClient        *accounts.AccountsMongoDBClient
}

func (*Handler) HandleHTTP

func (handler *Handler) HandleHTTP(ctx *fasthttp.RequestCtx)

HandleHTTP processes HTTP requests with JSON body

type ReleaseFile

type ReleaseFile struct {
	Name    string `json:"name"`
	Payload []byte `json:"payload"`
}

ReleaseFile represents file content and its name

type ReleaseMessage

type ReleaseMessage struct {
	ProjectId string                `json:"projectId"`
	Type      string                `json:"type"`
	Payload   ReleaseMessagePayload `json:"payload"`
}

ReleaseMessage represents message structure for sending to queue

type ReleaseMessagePayload

type ReleaseMessagePayload struct {
	Release string          `json:"release"`
	Commits json.RawMessage `json:"commits,omitempty"`
	Files   []ReleaseFile   `json:"files,omitempty"`
}

ReleaseMessagePayload represents payload structure of the message for sending to queue

type ResponseMessage

type ResponseMessage struct {
	Code    int    `json:"code"`
	Error   bool   `json:"error"`
	Message string `json:"message"`
}

ResponseMessage represents response message to a client

Jump to

Keyboard shortcuts

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