refactor(monorepo): rename operator api runtime

This commit is contained in:
2026-03-20 14:46:04 +08:00
parent bc08feda59
commit 4a324d841e
19 changed files with 106 additions and 47 deletions
@@ -3,7 +3,7 @@ package main
import (
"os"
"ai-workflow-skill/packages/orchd-runtime/server"
"ai-workflow-skill/packages/operator-api/server"
)
func main() {
@@ -1,4 +1,4 @@
module ai-workflow-skill/packages/orchd-runtime
module ai-workflow-skill/packages/operator-api
go 1.26
@@ -4,7 +4,7 @@ import (
"context"
"database/sql"
"ai-workflow-skill/packages/orchd-runtime/internal/query"
"ai-workflow-skill/packages/operator-api/internal/query"
"ai-workflow-skill/packages/coord-core/store"
)
@@ -8,7 +8,7 @@ import (
"github.com/go-chi/chi/v5"
"github.com/go-chi/chi/v5/middleware"
"ai-workflow-skill/packages/orchd-runtime/internal/query"
"ai-workflow-skill/packages/operator-api/internal/query"
"ai-workflow-skill/packages/coord-core/store"
)
@@ -9,7 +9,7 @@ import (
"testing"
"time"
"ai-workflow-skill/packages/orchd-runtime/internal/app"
"ai-workflow-skill/packages/operator-api/internal/app"
dbpkg "ai-workflow-skill/packages/coord-core/db"
"ai-workflow-skill/packages/coord-core/store"
)
@@ -14,12 +14,12 @@ import (
"time"
"ai-workflow-skill/packages/coord-core/db"
"ai-workflow-skill/packages/orchd-runtime/internal/app"
"ai-workflow-skill/packages/orchd-runtime/internal/httpapi"
"ai-workflow-skill/packages/operator-api/internal/app"
"ai-workflow-skill/packages/operator-api/internal/httpapi"
)
func Execute(args []string, stderr io.Writer) int {
fs := flag.NewFlagSet("orchd", flag.ContinueOnError)
fs := flag.NewFlagSet("operator-api", flag.ContinueOnError)
fs.SetOutput(stderr)
var (
@@ -71,7 +71,7 @@ func Execute(args []string, stderr io.Writer) int {
}
}()
logger.Printf("orchd listening on %s", listen)
logger.Printf("operator-api listening on %s", listen)
if err := server.ListenAndServe(); err != nil && !errors.Is(err, http.ErrServerClosed) {
logger.Printf("serve http api: %v", err)
return 1