refactor: 更新proto及客户端导入路径,调整Docker构建配置

This commit is contained in:
begoniezhao
2025-11-05 12:20:21 +08:00
parent c1f731e026
commit 1fd2de5a64
6 changed files with 12 additions and 11 deletions

View File

@@ -1,6 +1,9 @@
services:
app:
image: wechatopenai/weknora-app:latest
build:
context: .
dockerfile: docker/Dockerfile.app
container_name: WeKnora-app
ports:
- "${APP_PORT:-8080}:8080"

View File

@@ -6,7 +6,7 @@ import (
"os"
"time"
"github.com/Tencent/WeKnora/services/docreader/src/proto"
"github.com/Tencent/WeKnora/docreader/proto"
"google.golang.org/grpc"
"google.golang.org/grpc/credentials/insecure"
"google.golang.org/grpc/resolver"
@@ -16,10 +16,8 @@ const (
maxMessageSize = 50 * 1024 * 1024 // 50MB
)
var (
// Logger is the default logger used by the client
Logger = log.New(os.Stdout, "[DocReader] ", log.LstdFlags|log.Lmicroseconds)
)
// Logger is the default logger used by the client
var Logger = log.New(os.Stdout, "[DocReader] ", log.LstdFlags|log.Lmicroseconds)
// ImageInfo 表示一个图片的信息
type ImageInfo struct {

View File

@@ -7,7 +7,7 @@ import (
"testing"
"time"
"github.com/Tencent/WeKnora/services/docreader/src/proto"
"github.com/Tencent/WeKnora/docreader/proto"
)
func init() {

View File

@@ -16,6 +16,8 @@ import (
"strings"
"time"
"github.com/Tencent/WeKnora/docreader/client"
"github.com/Tencent/WeKnora/docreader/proto"
"github.com/Tencent/WeKnora/internal/application/service/retriever"
"github.com/Tencent/WeKnora/internal/config"
werrors "github.com/Tencent/WeKnora/internal/errors"
@@ -26,8 +28,6 @@ import (
"github.com/Tencent/WeKnora/internal/types"
"github.com/Tencent/WeKnora/internal/types/interfaces"
secutils "github.com/Tencent/WeKnora/internal/utils"
"github.com/Tencent/WeKnora/services/docreader/src/client"
"github.com/Tencent/WeKnora/services/docreader/src/proto"
"github.com/google/uuid"
"github.com/hibiken/asynq"
"go.opentelemetry.io/otel/attribute"

View File

@@ -20,6 +20,7 @@ import (
"gorm.io/driver/postgres"
"gorm.io/gorm"
"github.com/Tencent/WeKnora/docreader/client"
"github.com/Tencent/WeKnora/internal/application/repository"
elasticsearchRepoV7 "github.com/Tencent/WeKnora/internal/application/repository/retriever/elasticsearch/v7"
elasticsearchRepoV8 "github.com/Tencent/WeKnora/internal/application/repository/retriever/elasticsearch/v8"
@@ -39,7 +40,6 @@ import (
"github.com/Tencent/WeKnora/internal/tracing"
"github.com/Tencent/WeKnora/internal/types"
"github.com/Tencent/WeKnora/internal/types/interfaces"
"github.com/Tencent/WeKnora/services/docreader/src/client"
)
// BuildContainer constructs the dependency injection container

View File

@@ -13,6 +13,8 @@ import (
"sync"
"time"
"github.com/Tencent/WeKnora/docreader/client"
"github.com/Tencent/WeKnora/docreader/proto"
chatpipline "github.com/Tencent/WeKnora/internal/application/service/chat_pipline"
"github.com/Tencent/WeKnora/internal/config"
"github.com/Tencent/WeKnora/internal/errors"
@@ -23,8 +25,6 @@ import (
"github.com/Tencent/WeKnora/internal/models/utils/ollama"
"github.com/Tencent/WeKnora/internal/types"
"github.com/Tencent/WeKnora/internal/types/interfaces"
"github.com/Tencent/WeKnora/services/docreader/src/client"
"github.com/Tencent/WeKnora/services/docreader/src/proto"
"github.com/gin-gonic/gin"
"github.com/google/uuid"
"github.com/ollama/ollama/api"