Commit Graph
280 Commits
Author SHA1 Message Date
“Naeel” ab1e47bd35 style(shared-sqs): fix indentation in tenant_store.go 2026-04-09 20:43:17 +03:00
“Naeel” 570d1e3a60 fix(shared-sqs): populate URL and ARN for seeded queues (v0.1.10) 2026-04-09 20:13:36 +03:00
“Naeel” f878c4cc6f feat(shared-sqs): fixed demo credentials + BYOC foundation (v0.1.9)
- seed.go: CreateFixed с хардкод credentials для demo-service
  AccessKey=SSAK-demo-shared-sqs (постоянные, README всегда актуален)
- tenant_store: добавлен CreateFixed для задания произвольных credentials
- deployment.yaml: v0.1.9
- doc/byoc-credentials.md: полная документация BYOC фичи (TODO для API+UI)
2026-04-09 20:05:02 +03:00
“Naeel” 990a89e7aa style(shared-sqs): fix formatting in goaws.go (blank lines) 2026-04-09 19:46:20 +03:00
“Naeel” 2c5871ab87 feat(shared-sqs): seed demo data on startup (SHARED_SQS_SEED_DEMO=true, v0.1.8) 2026-04-09 19:42:21 +03:00
“Naeel” 0ec7c2fbbb test(shared-sqs): add quick_test.sh (19 tests), extend hardcore_test.sh (groups 24-28, UI API) 2026-04-09 19:32:42 +03:00
“Naeel” 67817d5480 fix(shared-sqs): remove default startup queues from goaws.yaml 2026-04-09 19:23:48 +03:00
“Naeel” bab90f6947 docs: update thinking log + progress for v0.1.6 2026-04-09 19:09:58 +03:00
“Naeel” 610c604b69 feat(shared-sqs): queue CRUD + message peek/send/purge in UI (v0.1.6)
- admin.go: 5 new endpoints: create/delete queue, peek/send/purge messages
- index.html: expandable message rows, send modal, msg detail modal, create queue modal
- deployment.yaml: update image to naeel/shared-sqs:v0.1.6
- Docker image pushed: naeel/shared-sqs:v0.1.6
2026-04-09 19:08:10 +03:00
“Naeel” a4fe253768 docs(thinking): update session log with UI deployment and shared-SQS repo creation 2026-04-09 18:25:49 +03:00
“Naeel” 70c276b4e7 feat(shared-sqs): remove auth from UI, add public /ui/api/ routes (v0.1.5)
- Public routes /ui/api/* without bearer token for demo
- UI loads dashboard immediately, no login required
- Admin API /admin/* still requires bearer token
- For demo purposes only — auth will be restored later
2026-04-09 18:23:17 +03:00
“Naeel” 12b3bb9bf3 feat(shared-sqs): add SQS Console UI (v0.1.4)
- Embedded SPA with Nubes branding (go:embed)
- Admin dashboard: health stats, tenant CRUD, queue listing
- New API: GET /admin/tenants/{id}/queues — tenant queue list with counts
- Route /ui/ serves built-in console
- Auto-refresh every 10s, responsive design
2026-04-09 18:01:12 +03:00
Naeel 2c1b7d042e test: fix output handling + patterns → 83/86 PASS
- head -3 → head -10 in check() to show full error messages
- Group 16: 100KB instead of 250KB to avoid argv overflow
- Batch 11+, dupID: add pattern "Maximum" and "Two.or.more"
- QueueNotFound: add pattern "specified"
- ChangeVisibility: fix pattern for "in flight" vs "not.in"
- 3 FAILs remain: AWS client-side validation (VT<0), WaitTime>20, no server-side validation
2026-04-09 17:34:26 +03:00
Naeel 7d7bc7e063 test: add 9 edge-case groups (86 tests total, 76/86 PASS)
- Group 15: boundary cases (long names, empty bodies)
- Group 16: large messages (250KB)
- Group 17: invalid params (negative timeout, waitTime>20)
- Group 18: batch boundary cases (1/10/11+ messages, duplicate IDs)
- Group 19: MaxMessages parameter
- Group 20: double delete, fake ReceiptHandle
- Group 21: duplicate queue names
- Group 22: operations on non-existent queues
- Group 23: special characters and encodings

Note: 10 FAILs are test/CLI issues (error in stderr, bash Argument list too long), not server bugs.
2026-04-09 17:23:47 +03:00
Naeel 5ecf2782fa fix: JSON protocol for Batch ops + CMV test (61/61 PASS)
- SendMessageBatch/DeleteMessageBatch: JSON tags Successful/Failed for AWS CLI v2
- Fix CMV test: capture receipt handle from same receive that checks visibility
2026-04-09 17:12:26 +03:00
Naeel 6c1aadd886 fix: InvalidClientTokenId panic + VT defaults + Dockerfile config + hardcore tests (58/61)
- Add InvalidClientTokenId, ValidationError to SqsErrors (was causing panic: WriteHeader code 0)
- Extract applyEnvironmentDefaults() with defer in LoadYamlConfig (VT=30 even without config file)
- Dockerfile: copy goaws.yaml to /conf/, pass --config flag
- Fix SendMessageBatch form parsing for AWS Query Protocol
- Add hardcore_test.sh (61 tests, 14 groups)
- Remove temp debug logs from delete_message.go
2026-04-09 16:11:32 +03:00
Naeel e5b1845acf shared-sqs: registry Docker Hub (naeel/shared-sqs), не pearlharbor 2026-04-09 14:09:58 +03:00
Naeel c4879d53de shared-sqs: деплой в K8s — qu.kube5s.ru, ingress, TLS 2026-04-09 13:58:41 +03:00
Naeel 33a075ab5c shared-sqs: Этап 9 — интеграционные тесты 28/28 PASS 2026-04-09 13:35:26 +03:00
Naeel 65dea8aa6b shared-sqs: doc thinking — итог сессии 2 (этапы 4-8) 2026-04-09 13:17:42 +03:00
Naeel 2c9a2b2ebf shared-sqs: Этапы 7+8 — Dockerfile, K8s manifests, Makefile 2026-04-09 13:16:58 +03:00
Naeel 073683250c shared-sqs: Этапы 5+6 — Admin API, auth middleware, graceful shutdown 2026-04-09 12:59:53 +03:00
Naeel 08053ca8e5 shared-sqs: Этап 4 — изоляция очередей по тенанту 2026-04-09 12:53:10 +03:00
Naeel f4352a17b1 shared-sqs: Этап 1 — клон GoAWS, удаление SNS, go build OK 2026-04-09 12:25:02 +03:00
Naeel d1d1bffd7c v0.1.13: Strategy Recreate + preStop + liveness fix (ERR-SQS-06 root cause)
- ensureDeployment: Strategy Recreate (not RollingUpdate) — prevents H2 file lock
  when two pods mount same PVC simultaneously during rollout restart
- preStop: sleep 3 — graceful H2 shutdown before SIGTERM
- livenessProbe timeoutSeconds: 3 — prevents false positive on GC pause
- terminationGracePeriodSeconds: 15
- doc: thinking log, ERR-SQS-06, progress.md, architecture SVG schema
2026-04-09 07:49:11 +03:00
Naeel 6b7b60db1b doc: sqs-operator v0.1.7-v0.1.12 — UI fixes, errors, thinking log 2026-04-08 2026-04-09 06:25:38 +03:00
Naeel 3adc0d8323 sqs-operator v0.1.12: ingress /queues/* -> elasticmq-ui (Next.js basePath fixes) 2026-04-09 06:17:21 +03:00
Naeel 516a5a209b sqs-operator: test suite fixes -- E03/E05 WONTFIX, MT05 60s, SH06 wait_qs_phase 2026-04-08 22:26:27 +03:00
Naeel a04d72052e sqs-operator v0.1.11: fix ensureService UI port, FILE_LOCK=NO for H2 2026-04-08 22:17:41 +03:00
Naeel 7ea7e9b360 sqs-operator v0.1.9: fix SQS_ENDPOINT context-path, add sidecar to source
- ensureDeployment: sidecar elasticmq-ui добавлен в Go-код (не Python патч)
- SQS_ENDPOINT=http://localhost:9324/sqs/{tenantID} — с context-path
- ElasticMQ не отвечает на root /, только на /sqs/{tenantID}
- Sidecar условный: добавляется только при spec.enableUI=true
2026-04-08 20:08:25 +03:00
Naeel 657fc33119 sqs-operator v0.1.8: fix UI assets ingress (/_next/ path-based routing)
- ensureIngressUIAssets: Prefix ingress /_next/ без rewrite -> UI port 3000
- Next.js basePath="" захардкожен — static assets идут без тенантного префикса
- Решение через отдельный ingress объект (один на тенант, контент идентичен)
2026-04-08 19:40:42 +03:00
Naeel 64626659a9 sqs-operator v0.1.7: web UI sidecar, auto-create-queues, fix A06 long polling
- api/v1alpha1: добавлены поля EnableUI, AutoCreateQueues в QueueServiceSpec
- elasticmq_config.go: GenerateConfig принимает autoCreateQueues, добавляет HOCON блок
- controller.go: sidecar elasticmq-ui (port 3000), ensureIngressUI, ensureService UI port
- test_v2_suite.sh: A06 теперь PASS — PurgeQueue перед long polling тестом
- CRD обновлён: make install применён в кластере

Test run v0.1.7: 35 PASS / 3 FAIL / 4 WARN / 2 SKIP(WONTFIX)
2026-04-08 19:11:26 +03:00
Naeel c4efc5c960 sqs-operator: docs + third test results (41 PASS, 0 OOM, 0 infra errors) 2026-04-07 20:44:56 +03:00
Naeel c132c68d74 sqs-operator v0.1.6: SH02/SH03/SH04 fix + test_v2_suite + v2 test results
- v0.1.5: ensureHealthy checks all 4 resources (Deployment/Service/ConfigMap/Ingress)
  Service/ConfigMap/Ingress now auto-recreate in 2-4s when manually deleted
- v0.1.6: revert MT03 configuration-snippet (nginx blocks risky annotations by default)
  Tenant isolation deferred to Keycloak JWT in production
- test_v2_suite.sh: 8 phases, 52 tests, timing/resources/concurrent/30min marathon
- Results: 40 PASS / 4 FAIL / 7 WARN (known: OOM restart under burst load)
  SH recovery: Deployment=48s Service=2s ConfigMap=4s Ingress=2s All3=2s
  Marathon: 11815 iter, 10830 sent, 2 pod restarts (OOM under load)
2026-04-07 19:14:00 +03:00
Naeel 18e57cadc7 test(sqs-operator): полный тест-сьют 30мин — результаты + 2 новых бага (MT03, SH02) 2026-04-07 16:54:42 +03:00
Naeel 336ee7b869 fix(sqs-operator): persistence, OOM, Ingress routing (v0.1.2→v0.1.4)
Problem 1: elasticmq-native does not support H2 JDBC persistence
- GraalVM native build excludes H2 driver
- Fix: switch to softwaremill/elasticmq:1.7.1 (JVM image)

Problem 2: OOMKilled — JVM requires >150MB, spec.MemoryMB=64 too low
- Fix: enforce minimum 256Mi for JVM; add -Xmx (75% of limit)

Problem 3: AccessDeniedException on /data — PVC mounted as root:root
- JVM image runs as uid=999 (elasticmq)
- Fix: add fsGroup=999 to PodSecurityContext

Problem 4: 404 through HTTPS — nginx rewrite stripped context-path
- ElasticMQ JVM listens at context-path (/sqs/{tenantId})
- Native image tolerated /, JVM does not
- Fix: remove rewrite-target annotation, use plain Prefix path

Result: S6 PASS — 8 queues + messages survived graceful pod kill
2026-04-07 15:34:15 +03:00
Naeel f8be5c8af1 feat(sqs-operator): v0.1.0 deployed and tested
- Fix Dockerfile: COPY internal/config/ and internal/elasticmq/, Go 1.22
- config/manager/manager.yaml: add SQS_EXTERNAL_HOST env, imagePullSecrets
- config/default/kustomization.yaml: disable kube-rbac-proxy (gcr.io N/A)
- config/samples/sqs_v1alpha1_queueservice.yaml: real test CR (test001)
- doc/progress.md: updated with deployment results

Smoke test: QueueService test-tenant-001 Phase=Ready in 27s
ElasticMQ pod 1/1 Running in sless-fn-test001
SQS CreateQueue via https://sqs.kube5s.ru/sqs/test001 OK
2026-04-07 14:43:41 +03:00
Naeel 52e9511d50 doc: план для Sonnet (sqs-operator deploy), обновлён progress.md 2026-04-07 14:30:34 +03:00
Naeel 66dcd99465 refactor(sqs-operator): переделка через Operator SDK v1.37.0
- operator-sdk init + create api (QueueService kind, group sqs, v1alpha1)
- Стандартная kubebuilder структура: cmd/, internal/controller/, config/
- CRD types с kubebuilder маркерами (validation, defaults, printcolumns)
- Reconciler перенесён из ручного кода в internal/controller/
- controller-gen v0.17.0 (совместимость с Go 1.26.1)
- Автогенерация: deepcopy, CRD YAML, RBAC ClusterRole
- Удалены все ручные файлы (controllers/, main.go, deployments/)
2026-04-07 14:25:14 +03:00
Naeel cbe61d9f62 feat: sqs-operator — CRD QueueService, контроллер, ElasticMQ per-tenant 2026-04-07 13:56:53 +03:00
Naeel a22a37bef3 doc: SQS Operator plan — ElasticMQ per-tenant, 10 этапов 2026-04-07 13:24:40 +03:00
Naeel 7220fe5b8b feat: IoT Admin Stats page — /iot-admin (v0.1.70)
- GET /iot-admin — HTML страница администратора (go:embed)
- GET /iot-admin/stats — JSON API с данными (Bearer ADMIN_STATS_TOKEN)
- Источники: Kafka consumer lag, K8s pod statuses, PostgreSQL per-tenant stats
- Авторизация: ADMIN_STATS_TOKEN env var
- Auto-refresh каждые 30 секунд
- Nubes brand style
2026-04-06 19:14:57 +03:00
Naeel 69451007f6 test: re-test v0.1.69 — все 8 тестов PASS, 1000/1000 при нагрузке 2026-04-06 18:45:57 +03:00
Naeel 387932ce10 fix: bridge Kafka write async (v0.1.69) — MQTT callback не блокируется 2026-04-06 18:26:03 +03:00
Naeel c0a08ae78d test: полное суровое тестирование IoT pipeline — 7 сценариев, 4 критических находки 2026-04-06 18:14:50 +03:00
Naeel 815b861417 docs: Kafka pipeline v0.1.68 — полная документация, race condition fix, тесты 2026-04-06 17:42:44 +03:00
Naeel 07ada8e362 fix: kafka race condition — ensureKafkaTopic in consumer before group join (v0.1.68) 2026-04-06 17:31:19 +03:00
Naeel 63f834da2b feat: Kafka pipeline v0.1.67 (mqtt-bridge→kafka→consumer→postgres) 2026-04-06 16:41:31 +03:00
Naeel e46a8bb3e3 doc: 2026-04-06 thinking log + kafka integration plan 2026-04-06 16:03:57 +03:00
Naeel 184f5ceb91 doc: session 2026-04-05 thinking log + progress update (v0.1.66, incident) 2026-04-05 17:37:38 +03:00