feat: Update .env.example and Docker Compose configurations to enhance service performance and health checks. Adjust OCR settings for improved document processing efficiency, and refine API Gateway health checks for better service monitoring. Revise desktop application documentation to reflect new API Gateway URL and installation instructions.
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"io"
|
||||
"log"
|
||||
"net/http"
|
||||
"os"
|
||||
"path/filepath"
|
||||
@@ -49,6 +50,7 @@ func (s *Server) Router() http.Handler {
|
||||
r := chi.NewRouter()
|
||||
r.Use(middleware.RequestID)
|
||||
r.Use(middleware.RealIP)
|
||||
r.Use(middleware.Logger)
|
||||
r.Use(middleware.Recoverer)
|
||||
|
||||
r.Get("/health", s.health)
|
||||
@@ -106,6 +108,8 @@ func (s *Server) countSync(w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
log.Printf("POST /v1/count: %d archivo(s), include_rejected=%v", len(files), includeRejected)
|
||||
|
||||
type fileInput struct {
|
||||
filename string
|
||||
data []byte
|
||||
@@ -169,6 +173,8 @@ func (s *Server) countSync(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
wg.Wait()
|
||||
|
||||
log.Printf("POST /v1/count completado: %d procesados, %d fallidos", len(results)-failed, failed)
|
||||
|
||||
writeJSON(w, http.StatusOK, domain.CountResponse{
|
||||
Results: results,
|
||||
Processed: len(results) - failed,
|
||||
|
||||
Reference in New Issue
Block a user