add sqlite

This commit is contained in:
2023-08-10 22:16:14 +03:00
parent a5a6c683a4
commit 6eb76b1d15
11 changed files with 364 additions and 11 deletions

View File

@@ -2,16 +2,17 @@ package handler
import (
"context"
"io"
"net/http"
cmsstorage "go.unistack.org/cms-service/storage"
"go.unistack.org/micro/v3"
"go.unistack.org/micro/v3/errors"
"go.unistack.org/unistack-org/pkgdash/config"
pb "go.unistack.org/unistack-org/pkgdash/proto/go_generate"
"go.unistack.org/unistack-org/pkgdash/service/client_git"
cligit "go.unistack.org/unistack-org/pkgdash/service/client_git"
"go.unistack.org/unistack-org/pkgdash/storage"
"google.golang.org/protobuf/encoding/protojson"
"io"
"net/http"
)
type Handler struct {
@@ -22,7 +23,7 @@ type Handler struct {
protojson.MarshalOptions
protojson.UnmarshalOptions
git client_git.Client
git cligit.Client
chanUrl chan *pb.AddPackageRsp
}
@@ -150,7 +151,7 @@ func (h *Handler) AddPackage(w http.ResponseWriter, r *http.Request) {
logger.Debug(ctx, "Success finish addPackage")
}
func NewHandler(svc micro.Service, w writer, client client_git.Client) *Handler {
func NewHandler(svc micro.Service, w writer, client cligit.Client) *Handler {
h := &Handler{
svc: svc,
writer: w,