feature: translate COACTUPC account update transaction to Spring Boot service - #199
Open
devin-ai-integration[bot] wants to merge 2 commits into
Open
devin-ai-integration[bot] wants to merge 2 commits into
devin-ai-integration[bot] wants to merge 2 commits into
Conversation
Co-Authored-By: Rush Cromer II <rush.cromerii@cognition.ai>
Co-Authored-By: Rush Cromer II <rush.cromerii@cognition.ai>
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
java/coactupc-service/, a Spring Boot 2.7 (Java 11) module that re-implements the CICS transactionCAUP/ programCOACTUPC(account + customer update) with the same business rules, and documents the translation indocs/COACTUPC-field-mapping.md.Shape of the translation
CVACT01Y→AccountRecord,CVCUS01Y→CustomerRecord,CVACT03Y→CardXrefRecord(theCXACAIXalternate index becomesfindFirstByAcctId).S9(10)V99→BigDecimal(12,2);X(10)dates stayYYYY-MM-DDstrings. FILLER dropped.ACUP-OLD/NEW-DETAILS(the COMMAREA screen snapshot) →AccountUpdateDetails, all-Stringfields with dates split Y/M/D, SSN split 3/2/4, phones split(AAA)BBB-CCCC, exactly as the COBOL stores them.AccountUpdateService/FieldEditor(1200-EDIT-MAP-INPUTS→editMapInputs,1205-COMPARE-OLD-NEW→compareOldNew,9600-WRITE-PROCESSING→writeProcessing,1220-EDIT-YESNO→editYesNo, …). Edit order, first-error-wins (WS-RETURN-MSG-OFF) semantics, per-field VALID/NOT_OK/BLANK flags, and message literals are preserved.CSLKPCDYlookup lists (general-purpose area codes, state codes, state+zip2 combos) are generated intolookup/*.ACUP-CHANGE-ACTION→ChangeActionenum (S/E/N/C/L/F);WS-INFO-MSG/WS-RETURN-MSG88s →Messages.READ→findById,READ UPDATE→@Lock(PESSIMISTIC_WRITE),9700-CHECK-CHANGE-IN-RECoptimistic check →DATA_CHANGED,REWRITE×2 +SYNCPOINT ROLLBACK→ one@Transactionalmethod.HTTP surface (
AccountUpdateController)PF3/PF12 are pure navigation (PF12 = client re-issues GET) and are documented rather than implemented.
Deliberate deviations (all in doc §7)
ACCT-UPDATE-RECORDin the COBOL omitsACCT-ADDR-ZIP, soACCT-UPDATE-GROUP-IDlands at offset 102 — the REWRITE overwrites the zip with the group id and blanks the real group id. The Java writesgroupIdto the right column and leavesaddrZipuntouched (intent-preserving, defect not reproduced).MOVE.WS-RETURN-MSG88 texts are used.999is accepted as an area code because it is present in the copybook'sVALID-GENERAL-PURP-CODElist.Tests: 76 JUnit 5 tests —
CobolNumericTest(NUMVAL-C),FieldEditorTest(each edit paragraph incl. century/leap-year/DOB rules),AccountUpdateServiceTest(H2: fetch, not-found paths, no-change, first-error ordering, confirm+persist formats, stale-record 409, lock errors),AccountUpdateControllerTest(status mapping).Run:
cd java/coactupc-service && mvn testDevin-Org: engineering
Link to Devin session: https://app.devin.ai/sessions/01a88c7fe88b4a1882290d650c00b721
Open in Devin Desktop: https://app.devin.ai/desktop/session/01a88c7fe88b4a1882290d650c00b721?variant=devin
Requested by: @rushcromer
Note
Devin errored when opening this Pull Request as rushcromer.
As a fallback, Devin opened this PR as itself.