Commit Graph
68 Commits
Author SHA1 Message Date
Vickey 5131b37568 build(deploy): add postgres/rabbitmq dependency assets and regenerate openapi snapshots 2026-06-19 16:49:01 +08:00
pnoker 1811d4f8ff fix: support reactive wildcard permissions 2026-06-12 11:26:23 +08:00
pnoker ec68f0cb7c feat(rabbitmq): expose tls configuration 2026-06-11 18:03:30 +08:00
pnoker 7a2cc9b8fa chore(compose): streamline environment defaults 2026-06-11 15:04:01 +08:00
Vickey 27bcf1383b fix: address code review — security, thread safety, performance, and null safety
Security (CRITICAL):
- KeyUtil: read JWT signing key from DC3_SECURITY_KEY env/property
- UserPasswordServiceImpl: read default password from DC3_SECURITY_DEFAULT_PASSWORD env
- KeyLoader: read OPC-UA keystore password from OPCUA_KEYSTORE_PASSWORD env
- WebFilterConfig: return 401 on malformed X-Auth-User header
- AlgorithmConstant: document deprecated hardcoded constants

Thread safety (HIGH):
- Fix TOCTOU races in 4 driver connectors (computeIfAbsent)
- Fix PlcS7 lock leak, OpcUa connect timeout (5s)
- CoapClientManager: synchronize setURI to prevent URI race
- PointValueJob, MqttScheduleJob: add @DisallowConcurrentExecution
- SystemHealthServiceImpl: preserve interrupt flag
- WindowSampleBuffer: local AtomicInteger → int

Performance (MEDIUM):
- EntityStateExpiryScanner: batch alarm saves (saveBatch)
- ImportDeviceServiceImpl: batch config saves
- ResourceRegistrySyncServiceImpl: batch-load nodes, eliminate N+1 COUNTs
- DriverSenderServiceImpl: debug-gate hot-path logging
- PointServiceImpl: stream().count() → size()

Null safety (LOW):
- RegexUtil: null guards on isName/isPhone/isMail/isPassword/isHost
- HostUtil: null-check getNetworkInterfaces() return
- TimeUtil: log parse failures instead of silent null

Infrastructure:
- Add spring-boot-starter-cache + @EnableCaching CacheConfig
- Replace embedded modbus4j/plc-s7 jars with external Maven dependencies
- Add dc3-driver-modbus-rtu module
2026-05-26 08:40:25 +08:00
pnoker cb423056c7 security(auth): enable HMAC gateway-to-service signing by default
Set AUTH_HMAC_SECRET default to "io.github.pnoker.dc3" across .env
templates, compose files, and Java config properties so that X-Auth-User
header signing is active out of the box without manual configuration.
2026-05-19 23:15:34 +08:00
pnoker b9b2a47732 feat(docker): add web frontend and consolidate compose stacks
Add dc3-web frontend service to docker-compose.yml with nginx reverse
proxy as the sole user-facing entry point. Remove backend port mappings
since web now proxies to gateway.

Merge docker-compose-elasticsearch.yml and docker-compose-grafana.yml
into a single docker-compose-optional.yml that includes EMQX, ELK+APM,
and Prometheus+Grafana stacks.
2026-05-17 19:02:52 +08:00
pnoker 7847bffbd8 fix(agentic): preserve reasoning through tool loop 2026-05-17 00:59:46 +08:00
pnoker 285ed9273f feat(agentic): configure fallback provider and profile activation 2026-05-11 18:57:53 +08:00
pnoker d65fc715ff build(deploy): add agentic memory and tool-calling env variables to docker-compose
Expose AGENTIC_MEMORY_ENABLED, AGENTIC_TOOL_CALLING_ENABLED,
AGENTIC_MEMORY_MAX_MESSAGES, and AGENTIC_ATTACHMENT_STORAGE_PATH
in development and production compose files, with defaults in dev.env.

Also mark OpenAI base-url config as deprecated in application-agentic.yml.
2026-05-11 00:44:44 +08:00
Vickey 9d7e238eb1 refactor(config): update default AI model to deepseek-v4-flash and agentic env variables 2026-05-10 21:43:58 +08:00
Vickey 0e92643d54 feat(config): add AUTH_HMAC_SECRET to all deployment configurations
The HMAC signing feature was dormant because no deployment config
set the shared secret. Add AUTH_HMAC_SECRET to .env.example, dev
env files, both compose stacks (all 12 services), and document it
in ENVIRONMENT.md.
2026-05-10 01:48:51 +08:00
pnoker 6cf9b43c30 docs(env): align runtime environment variables 2026-05-09 20:14:16 +08:00
pnoker 8fa1f0c152 refactor(container): deduplicate aliyun compose stacks 2026-05-09 18:49:52 +08:00
pnoker a45f2f5ec1 fix(container): include agentic compose service 2026-05-09 18:49:52 +08:00
pnoker ca38651909 feat: add .env file for Docker Compose configuration and update usage instructions 2026-04-21 01:11:59 +08:00
pnoker e33dcc1573 fix: update Docker images to version 2026.5 across all docker-compose files 2026-04-20 03:16:30 +08:00
Vickey a9e8d05631 feat: update version 2025-10-05 17:16:37 +08:00
Vickey 7302107c56 chore: bump all module versions to 2025.9.2 2025-09-11 17:02:24 +08:00
Vickey 2051d42847 refactor(common): remove hutool dependency and replace usages with native utilities 2025-09-11 14:57:02 +08:00
Vickey 8cc7365293 build: bump all module versions to 2025.6.6 and update compose image tags 2025-08-26 22:38:53 +08:00
Vickey 64c6f911fe chore: replace Apache-2.0 license headers with AGPL-3.0 in compose files and gateway config 2025-08-26 22:03:42 +08:00
Vickey f415207088 build: bump project version to 2025.6.5 across all modules 2025-07-15 14:58:51 +08:00
Vickey 31a6a275ed build: bump project version to 2025.6.4 across all modules 2025-07-15 12:01:43 +08:00
Vickey 886b212793 build: bump project version to 2025.6.1 across all modules 2025-06-21 16:21:18 +08:00
Vickey 877be41317 build: bump project version to 2025.6.0 and remove unused job/register dependencies 2025-06-09 15:48:22 +08:00
Vickey 6898041ab5 feat(docker): add APM agent env vars and dc3-apm service to all Dockerfiles and compose files 2025-05-06 21:19:03 +08:00
Vickey b01412f460 chore(docker): change NODE_ENV from dev to test in all Dockerfiles and compose files 2025-05-06 16:55:20 +08:00
Vickey a0ed920ba2 feat(compose): split db stack into docker-compose-db.yml and expand dev/aliyun services 2025-05-06 01:11:46 +08:00
pnoker 083a7e748c chore(docker): standardize string quotes and add new compose files
Standardized the use of double quotes in docker-compose files for consistency. Added new docker-compose files for optional and Aliyun configurations to support different deployment environments.
2025-04-25 20:46:30 +08:00
pnoker 43e78d6a40 build(compose): add Aliyun mirror compose files for dev and grafana stacks 2025-04-21 19:19:08 +08:00
Vickey 3bd3717bac build(docker): bump base image version in all Dockerfiles and slim docker-compose.yml 2025-03-05 01:13:36 +08:00
Vickey 0f13d020b0 feat(compose): add docker-compose-grafana.yml with full Grafana service definition 2025-02-09 13:38:47 +08:00
zzi666 4d5e7e166a refactor(driver): rename attribute config fields and clean up attribute builders 2025-02-07 01:33:14 +08:00
pnoker 722b6e396a refactor(common): switch MybatisGenerator datasource to postgres and extend GroupBO fields 2024-12-09 12:23:24 +08:00
pnoker 559d78fa78 fix(config): fix postgres JDBC URL connection params and add missing default constants 2024-12-09 11:48:24 +08:00
pnoker 834a30bf86 feat(common): add postgres datasource support to auth MybatisGenerator 2024-12-05 11:09:10 +08:00
pnoker 198820c2ec feat(dc3): extend docker-compose-dev with additional services and port mappings 2024-12-04 21:10:50 +08:00
pnoker 9faa287480 build: restructure Dockerfiles and compose files for all services 2024-12-04 19:49:38 +08:00
pnoker 480250f565 chore: update base image tag in all Dockerfiles and compose files 2024-06-19 00:56:17 +08:00
pnoker b52aaf550a build: remove legacy Dockerfiles, compose files, and update scripts 2024-06-11 20:15:12 +08:00
pnoker 652224eb67 feat: optimize bulk import across auth, data, and manager services 2024-05-26 17:52:48 +08:00
pnoker 661cc8fcf4 build(dc3): update service configs in dev and optional compose files 2024-05-24 19:49:44 +08:00
pnoker a11caad0f6 refactor: apply broad compatibility fixes across auth, data, manager and drivers 2024-04-30 22:13:13 +08:00
pnoker 9c0aa2f91b fix(compat): apply JDK 17 compatibility fixes to modbus4j, opc-da, and compose configs 2024-04-16 16:43:28 +08:00
ennian001 2383f694d7 build(compose): add influxdb service to docker-compose-option.yml and drop version key 2024-04-14 20:58:22 +08:00
pnoker 930c974d3b refactor(builder): add boToVo/voToBo conversion methods to all entity builders 2024-02-29 22:26:16 +08:00
pnoker 263df0e1c1 feat(scheduler): add hourly and daily scheduled jobs to data and manager centers 2024-02-07 13:28:30 +08:00
Vickey 05c1fef1df refactor: replace shared Group/Label/LabelBind BO/VO with module-scoped variants 2023-12-24 19:02:32 +08:00
pnoker adb67967b2 build(dc3): update service image versions in dev compose file 2023-12-18 00:22:13 +08:00