感动中国

This commit is contained in:
eson
2023-08-10 12:04:36 +08:00
parent 68488da99c
commit 440f13bee8
102 changed files with 146 additions and 125 deletions

View File

@@ -6,7 +6,6 @@ import (
"fusenapi/server/auth/internal/config"
"fusenapi/shared"
"fusenapi/utils/auth"
"fusenapi/utils/autoconfig"
"net/http"
"fusenapi/initalize"
@@ -28,12 +27,12 @@ type ServiceContext struct {
func NewServiceContext(c config.Config) *ServiceContext {
conn := initalize.InitMysql(c.SourceMysql)
StateServer := shared.StartNode(c.ReplicaId, autoconfig.AutoGetAllServerConfig(), conn)
// StateServer := shared.StartNode(c.ReplicaId, autoconfig.AutoGetAllServerConfig(), conn)
return &ServiceContext{
Config: c,
MysqlConn: conn,
SharedState: StateServer,
SharedState: nil,
AllModels: gmodel.NewAllModels(initalize.InitMysql(c.SourceMysql)),
TokenManger: auth.NewConfirmationLink[auth.RegisterToken](c.Auth.AccessSecret, "http://localhost:9900/api/auth/oauth2/register"),
}