Commit Graph

113 Commits

Author SHA1 Message Date
反编译工作区 83c3050ef2 fix: delete 7 orphan files + P0-P3 fixes
Orphan analysis: 134 files → 5+2 orphan files identified and removed:
- CpImageStoreServiceImpl, SelfRegistryHandler, AreaTypeServiceImpl
- ImgPersonBatchServiceImpl, ImgPersonBatchDetailServiceImpl
- OrganizationTypeServiceImpl, CpDeviceImagePersonServiceImpl

All 7 have NO callers in module or elevator app.

P0-P3 verified clean:
- CpOrgDevieKitServiceImpl (54→0)
- CpImageStorePersonValidateManager (36→0)
- OrganizationServiceImpl (32→0)
- CpImageStorePersonSynManager (38→10)

Remaining: 200 errors in service module (CFR systemic generic loss).
Interface + Data modules: BUILD SUCCESS.
2026-05-06 00:01:00 +08:00
反编译工作区 12846820dd fix: P1 partial — CpImageStorePersonSynManager 38→10
Fixed:
- RedisCallback cast on 6 execute() calls
- Set cast to Set<String> in checkHandleSynTaskException (4 locations)
- Removed (Object) from hasKey call
- Fixed Lists.newArrayList((Object[])new String[]{x}) → Lists.newArrayList(x) (2 locations)
- Added RedisCallback import

Remaining: 10 errors — lambda effectively-final violations (Java 8)
2026-05-05 23:49:16 +08:00
反编译工作区 50af6e739d fix: P0+P2+P3 — CpOrgDevieKit, ValidateManager, OrganizationServiceImpl clean
P0: CpOrgDevieKitServiceImpl (54→0)
- Fixed 10 $\$ artifacts with correct variable names
- Typed 7 raw Collection/List/Set declarations
- Removed (Object) casts from redisTemplate calls

P2: CpImageStorePersonValidateManager (36→0)
- Added RedisCallback cast for execute() ambiguity
- Typed Map.Entry for-each with proper generics
- Fixed ternary type mismatch (List<Object>→SyncPersonLocal)
- Typed waitAddValidateList as List<GroupPersonRef>

P3: OrganizationServiceImpl (32→0)
- Typed 7 raw List declarations (refDTOS, data, organizations, etc)
- Fixed ArrayList<> vs List<> assignment
- Typed passableArea/officeArea streams
2026-05-05 23:47:18 +08:00
反编译工作区 99ecbbd6f5 fix: for-each cast + methodref fixes in 5 service files
OrganizationServiceImpl: 62->32 errors (for-each casts + methodref lambdas)
CpImageStorePersonSynManager: 44->38 errors (for-each casts)
CpImageStorePersonValidateManager: 36->28 errors (explicit type casts + lambdas)
OrganizationUnitTypeServiceImpl: 28->14 errors (typed List declarations)
CpImageStorePersonTxHandler: methodref->lambda fix

All fixes are decompile artifacts - explicit (List<Type>) casts at
for-each loops and method reference conversions to lambdas.
2026-05-05 23:15:50 +08:00
反编译工作区 01218394f0 fix: auto-fix decompile type errors in component-org service module
- Delete 5 duplicate Java files in wrong nested cn/ directory
- Fix 15 raw List declarations with generic type params in OrganizationServiceImpl
- Apply (CloudwalkResult) raw cast to 107 fail() + 165 success() calls
  across all 46 service files via ast-grep
- Remaining: 106 Object->cast and other manual-context errors
2026-05-05 22:50:58 +08:00
反编译工作区 18810ef9c6 feat: add component-organization decompiled Maven module
- Reactor POM with 4 sub-modules (interface/data/service/web)
- all-lib/ with 255 extracted JARs from original fat JAR
- .m2-isolated/ repo with 252 installed JARs
- interface module: BUILD SUCCESS (325 classes)
- data module: BUILD SUCCESS (120 classes)
- service module: 200 type errors (CFR decompilation artifacts)
- install-libs.sh for isolated repo setup
- Feign fallback inner classes separated
2026-05-05 22:36:52 +08:00
反编译工作区 3cc487cd3b chore: final comment cleanup 2026-05-05 20:13:57 +08:00
反编译工作区 018f1d1a93 chore: add chinese comments to all 564 component-org files
- Auto-generate class-level Chinese comments based on annotations
  and package paths (@RestController → Web控制器, @FeignClient → Feign客户端, etc.)
- Remove redundant // comments where /** Javadoc already exists
- Preserve existing hand-written Chinese Javadoc
2026-05-05 20:13:41 +08:00
反编译工作区 c817f5785d chore: convert unicode escapes to chinese (123 files)
- Convert \uXXXX (single backslash) to actual Chinese characters
- Preserve \uXXXX (double backslash) regex patterns
- All logger messages, enum descriptions, and constants now readable
2026-05-05 20:09:17 +08:00
反编译工作区 d134b5c4a7 chore: cleanup decompilation artifacts, add chinese comments
- Fix Objects.equals → direct .equals for 00000000 code checks (11 files)
- Remove (Throwable)e casts (158 occurrences)
- Add Chinese Javadoc to: ImgPersonServiceImpl, PersonController,
  ImgStorePersonBaseResult, ElevatorFeignClient, ElevatorAppFeignClient,
  CrkAccessFeignClient
- JAR comparison verified: 56 methods match, structural equivalence
- Cleanup script removed
2026-05-05 20:06:25 +08:00
反编译工作区 9749e7531e docs: add policy redesign doc with sequence diagrams
- Full business logic redesign with UC-01/UC-02 sequence diagrams
- Policy ALWAYS evaluated, intersect candidate with allow
- Scenario matrix covering all combinations
- v2.0.19 implementation with intersection fix
2026-05-05 20:05:37 +08:00
反编译工作区 2310d3f059 chore: remove decompilation artifacts from component-organization src
- Strip CFR header comments (Decompiled with CFR, Could not load)
- Remove redundant (Throwable)e casts in logger and throw calls
- Cleanup script removed after use
2026-05-05 20:01:32 +08:00
反编译工作区 5c7c540e74 chore: add maven-ninca-common-component-organization module
- Decompiled from ninca-common-component-organization-V2.9.2_20210730.jar
- 4 sub-modules: web, service, data, interface (564 Java files)
- Contains POST /component/person/detail implementation
- floorList assembled via elevatorFeignClient.listByImageId()
2026-05-05 19:58:34 +08:00
反编译工作区 1cac12d940 docs: add initialization flow analysis to policy design doc
- Add §7 initialization flow: /component/person/detail call chain
  from decompiled component-organization source
- Document floorList assembly in ImgPersonServiceImpl (via
  elevatorFeignClient.listByImageId)
- Analyze init vs submit consistency: gap when policy exists
2026-05-05 19:57:01 +08:00
反编译工作区 d52babe2c9 fix: policy replaces floors (not intersection)
When tenant policy exists and enabled, allow_zone_ids REPLACES
the candidate floor list entirely. Phase 3 simplified.
Bump v2.0.20
2026-05-05 19:49:31 +08:00
反编译工作区 f7da04caea fix: policy always checked regardless of caller-provided floors
Redesign addVisitor four-phase flow:
- Phase1: ALWAYS query person detail (orgIds for policy lookup)
- Phase2: candidate = caller floors or org floorList
- Phase3: ALWAYS check policy; intersect candidate with allow
- Phase4: empty set validation
Fixes UC-02 bypass: policy was entirely skipped when caller
provided floorIds. Now policy always constrains.
Bump v2.0.19
2026-05-05 19:47:01 +08:00
反编译工作区 c5febc9905 docs: fix stale references post v2.0.17 alignment
- Update deploy/README.md: remove NincaCrkStdRibbonConfiguration ref,
  update JAR naming, add v2.0.17 config instructions
- Update elevator-v1-v2-init-timing-config-audit.md: add baseline note
- Update org-policy-verify-manual.md: JAR path + AppApplication class
- Update release script comment with current baseline version
- docs/AGENTS.md and service-discovery spec already updated in v2.0.17
2026-05-05 19:08:33 +08:00
反编译工作区 ec05aa777d docs: record v2.0.17 as baseline, update service discovery doc
- Mark v2.0.17 as current production baseline in AGENTS.md
- Update service discovery architecture design doc: add §6-10 for
  actual implementation state, preserve original as history (§1-5)
- Document key decisions: no ZK discovery, ConfigurationBasedServerList,
  bootstrap aligned with V1
2026-05-05 19:01:33 +08:00
反编译工作区 1c5e60f690 fix: remove ZK discovery dep, bootstrap identical to V1
- Remove spring-cloud-starter-zookeeper-discovery from POM
  (V1 doesn't have it, causes zookeeperRibbonClientConfiguration error)
- Remove ZK exclusions from AppApplication.java (no longer needed)
- bootstrap.properties now 100% identical to V1 production
- PersonFeignClient restored to placeholder-based name (no hardcoded URL)
- Remove NIWSServerListClassName/listOfServers (ConfigurationBasedServerList)
Bump version to 2.0.17
2026-05-05 18:53:32 +08:00
反编译工作区 d838dd0897 fix: align bootstrap with production config, disable ZK ribbon
- Restore bootstrap to match production (discovery.enabled=false,
  consul.host=371bfca4972c43d2aefcf302d0a4a277)
- Add spring.cloud.zookeeper.enabled=false to prevent
  zookeeperRibbonClientConfiguration runtime error (child context)
- Remove ConfigurationBasedServerList overrides from app properties
  (no longer needed with proper config alignment)
- Revert PersonFeignClient url hardcode back to placeholder name
Bump version to 2.0.16
2026-05-05 18:39:49 +08:00
反编译工作区 7d52fd5d0b release: v2.0.14 with fixed JAR name matching V1
- JAR name fixed to cw-elevator-application-V1.0.0.20211103.jar
  matching V1 production naming convention exactly
- Release bundle directory uses version+date for identification
- Update release script and POM finalName accordingly
2026-05-05 18:23:08 +08:00
反编译工作区 6f1cd21a5b refactor: rename main class to AppApplication to match V1 naming
- V1 main class: cn.cloudwalk.elevator.AppApplication
- V2 was ElevatorApplication, now aligned to AppApplication
- Also update reference in test script
2026-05-05 18:17:38 +08:00
反编译工作区 9c2edc09c9 fix: also exclude ZookeeperServiceRegistryAutoConfiguration
Second Registration bean conflict: ServiceRegistryEndpoint also needs
single bean. Exclude both ZK auto-configuration classes for ServiceRegistry.
- ZookeeperAutoServiceRegistrationAutoConfiguration (already excluded)
- ZookeeperServiceRegistryAutoConfiguration (added)
Bump version to 2.0.13
2026-05-05 18:05:20 +08:00
反编译工作区 6dd03b573b fix: exclude ZK auto-registration, rebuild v2.0.12
- ElevatorApplication startup failed: Registration bean conflict between
  ZookeeperAutoServiceRegistration and ConsulAutoServiceRegistration
- Exclude ZookeeperAutoServiceRegistrationAutoConfiguration (ZK for
  discovery only, not registration; Consul handles registration)
- Bump version to 2.0.12, rebuild deployment package
2026-05-05 17:54:01 +08:00
反编译工作区 7aa534ec00 release: cw-elevator-application v2.0.11 built
- Bump version to 2.0.11, rebuild deployment package (JAR + ZIP)
- Add property mgmt visitor floor policy SQL to release bundle
- Sync corrected guangfa fund SQL to docs/sql/ (org_id + zone_id fix)
- Exclude deploy JARs from git tracking (build artifacts >100MB)
2026-05-05 17:39:12 +08:00
反编译工作区 da0a82cd24 fix(elevator): correct guangfa visitor floor policy SQL and DB record
- Add missing org_id column (488b8ad049bb43408a6fbcc50bcb89ac)
- Fix allow_zone_ids to use snowflake zone_id 605560545117995008 (28F)
  instead of orphan UUID that matched no known zone table
- Fix DB record: update zone_id + add org_id, bump policy_version to 2
2026-05-05 16:28:18 +08:00
反编译工作区 a2cdb15fdb feat(elevator): add property mgmt visitor default floor policy (6F)
Insert tenant_visitor_floor_policy for 7 property management orgs:
visitor default floor set to zone 605560541473144832 (6F).
SQL idempotent via ON DUPLICATE KEY UPDATE.
2026-05-05 16:21:36 +08:00
反编译工作区 82875a95dd chore: gitignore large binary artifacts (BFG cleaned) 2026-05-05 16:03:47 +08:00
反编译工作区 b7b678782a docs: add ConsulServerList static/IP discovery analysis
Document the investigation into how ConsulServerList was replaced by
ConfigurationBasedServerList with hardcoded IPs for Feign client service
discovery. Covers V1 vs V2 config gap, three upstream services, and
P0-P2 investigation items.


Former-commit-id: 15a0d8567de43f8741d50cbcddc2599383942754
2026-05-05 15:25:56 +08:00
反编译工作区 4f4627fdb3 docs: update AGENTS.md with architecture and discovery details
Former-commit-id: 8c461e527ca6a9297a8ccf8fd6ea2546a6de1ec7
2026-05-03 20:11:28 +08:00
反编译工作区 452a4a16ec feat(deps): add spring-cloud-starter-zookeeper-discovery for Dubbo/ZK service discovery
- Add ZK discovery dep to parent POM (v1.1.0.RELEASE, Edgware-compatible)
- Add ZK discovery dep to starter POM for runtime classpath inclusion
- Architecture: discovery.enabled=false → Consul registration only
  ZK DiscoveryClient → service lookup for Feign → Ribbon → ServerList
  Closes gap between architecture design doc and implementation


Former-commit-id: 6b5898d0e07ca6ebf2ccbb69ace5fa77ac6f0749
2026-05-03 20:10:28 +08:00
反编译工作区 43c7da2300 docs: add v2 deployment plan; gitignore: exclude generated test-env files
- Add full-deploy-and-compare implementation plan
- Add application-test.properties (generated test config template)
- Ignore scripts/test-env/logs/, services/, *.jar.bak


Former-commit-id: d8139e3dc14d0b00f5b9d7fd74b9f45b6db0c84f
2026-05-03 16:20:08 +08:00
反编译工作区 ffbc8614b4 fix(test): hardcode PersonFeignClient url to local stub for test env, add Ribbon comp-org route
- PersonFeignClient: add url=http://127.0.0.1:33011 to bypass Ribbon/Consul discovery
- application.properties: add ninca-common-component-organization.ribbon.listOfServers
- Add stub-person-service.py for simulating component-organization person/detail
  Returns PersonResult with floorList and organizationIds for policy testing
NOTE: PersonFeignClient url change is test-only, revert before production

Former-commit-id: ff9a9ed68ec81fc2de68cc74cd22edcf38b510cb
2026-05-03 14:44:53 +08:00
反编译工作区 5513b635e5 fix: _parity_full_rows → _parity_rows in parity test
Former-commit-id: 989f7952d2719650edf535793314162fd76932c2
2026-05-02 06:08:55 +08:00
反编译工作区 fbd30a7b4e feat: robust stop-all (pgrep kill) + start-all skip-if-running detection
Former-commit-id: 6ffcf5714ef663afa22f891bdb566950e4c47b60
2026-05-01 23:21:13 +08:00
反编译工作区 7a7bf42165 fix: use wildcard JAR matching for any version, fix health endpoints to /health (Boot 1.x)
Former-commit-id: 20071a784e3c5c1f8b392fd5ec8d44b500810359
2026-05-01 23:18:31 +08:00
反编译工作区 31ec44e21a fix: reuse existing ybs-kafka/ybs-zookeeper, move Consul to 9517, remove ZK/Kafka from compose
Former-commit-id: c7aff428fd4b259c9795da76ce4a53be29f9fe4d
2026-05-01 22:57:47 +08:00
反编译工作区 ef9f38587c fix: use Redis port 6380 to avoid conflict with existing ybs-redis on 6379
Former-commit-id: e8adb090f9ed0d0ac1b4845f8271428bc4ddb386
2026-05-01 22:55:24 +08:00
反编译工作区 2c2d30038e fix: force remove all conflicting containers before docker compose up
Former-commit-id: b9996801db2592eeb4454789cdf8ec1fa6c642ee
2026-05-01 22:54:08 +08:00
反编译工作区 57c639cbf1 fix: clean existing containers before Docker compose up to avoid port conflicts
Former-commit-id: 90c1c5d29595bf7f59b66a7de23b7ff89834c6c5
2026-05-01 22:52:33 +08:00
反编译工作区 65fb32d97f fix: restore ZK, use confluentinc/cp-zookeeper:7.5.0 + cp-kafka:7.5.0 (both locally available)
Former-commit-id: 8fffa72c508a4008e2d7790a307eb1e2e4602cde
2026-05-01 22:51:33 +08:00
反编译工作区 fa6f5fad37 fix: remove ZK port from conflict check (Kafka now uses KRaft)
Former-commit-id: 088ef1707668288a81ce245ce13015f5681bb81e
2026-05-01 22:49:47 +08:00
反编译工作区 d5af622220 fix: use local confluentinc/cp-kafka:7.5.0 with KRaft (no ZK) to avoid Docker Hub rate limit
Former-commit-id: ef796a125d08573dc75e4636b042a2e08a94d311
2026-05-01 22:49:18 +08:00
反编译工作区 52fa9c7bab feat: add idempotency check — skip DB restore/DDL if already populated
Former-commit-id: 9db5bc17dcaaefc7148625f081bdb845cc6820d0
2026-05-01 22:33:53 +08:00
反编译工作区 282b4f1c54 fix: use multi-line sed range to strip GTID_PURGED statements from SQL dumps
Former-commit-id: a9ab3ad575a151fa423fc3ea4f9568c512db124c
2026-05-01 22:31:05 +08:00
反编译工作区 72040cdce6 fix: filter GTID_PURGED from SQL imports to avoid MySQL error 1840
Former-commit-id: 3d9d223cdb274faf74d5ee138dd76608415b77e5
2026-05-01 20:57:38 +08:00
反编译工作区 83dafde6ca fix: escape MySQL backtick quotes in prepare-db.sh (double-backslash -> single)
Former-commit-id: 0ffd939b7bc3ddeb9810bbdd31fb2768189d2309
2026-05-01 20:56:21 +08:00
反编译工作区 7a642e6c02 feat: add one-click test environment setup script (setup.sh)
Former-commit-id: 3f2a6bcb61d5219b5b3ab54c809ab4a16f21a7ef
2026-05-01 19:50:57 +08:00
反编译工作区 3788f23850 feat: add health-check, verify-functional, start/stop orchestration scripts
Former-commit-id: 889cae9583861690b94f7fbc99dda36f6e38c446
2026-05-01 19:49:45 +08:00
反编译工作区 fd20618314 feat: add service start/stop orchestration scripts (start-all.sh, stop-all.sh) in 源码 path
Former-commit-id: 2dea59a89d7bff85268a6545c35b7aa74a499eb9
2026-05-01 19:48:50 +08:00