Commit Graph

14818 Commits

Author SHA1 Message Date
hongwei
85463319a8 test/(Http4s700): add UserNotLoggedIn error response to API info
- Add $UserNotLoggedIn to the error response list in apiInfoJSON
- Include authentication error handling in API v7.0.0 documentation
- Improve API error response completeness for unauthenticated requests
2026-01-16 14:26:11 +01:00
hongwei
7011677a64 refactor/(http4s): enhance ResourceDocMiddleware authentication flow and logging
- Add debug logging for authentication requirements and error response bodies
- Extract needsAuthentication check into variable for clarity and reusability
- Improve anonymous access handling to gracefully handle auth errors without failing
- Add detailed logging for anonymous access success and failure cases
- Update Http4s700 root endpoint to use correct authentication message flag
- Remove misleading comment about $UserNotLoggedIn triggering automatic auth check
- Enhance error handling in anonymous access path to allow unauthenticated endpoints to function properly
2026-01-16 14:21:22 +01:00
hongwei
bae97edc79 refactor/(http4s): improve ResourceDoc matching and error handling
- Strip API prefix (/obp/vX.X.X) from request paths before matching against ResourceDoc templates
- Add apiPrefixPattern regex to ResourceDocMatcher for consistent path normalization
- Refactor ResourceDocMiddleware.apply to properly handle OptionT wrapping
- Enhance authentication error handling with proper error response conversion
- Improve bank lookup error handling with ErrorResponseConverter integration
- Replace manual Response construction with ErrorResponseConverter.createErrorResponse calls
- Add JSON parsing fallback for exception messages in authentication flow
- Simplify validation chain logic by removing redundant comments and consolidating code paths
- Fix flatMap usage in authentication and bank lookup to properly handle IO operations
2026-01-16 14:10:57 +01:00
hongwei
2c9af4e851 feature/ (http4s): add comprehensive Http4s utilities and middleware support
- Add ErrorResponseConverter for converting OBP errors to http4s Response[IO]
- Add Http4sSupport with CallContext builder and vault keys for request attributes
- Add ResourceDocMiddleware for validation chain middleware in http4s
- Add Http4sSupport package object with utility functions and type aliases
- Update Http4s700 to integrate new middleware and error handling utilities
- Remove Http4sResourceDocSupport in favor of consolidated Http4sSupport module
- Consolidate Http4s-related utilities into dedicated util/http4s package for better organization and reusability
2026-01-16 09:33:43 +01:00
hongwei
f58fb77c5d refactor/(api): update CallContext logic and introduce Http4s utilities
- Refactor `getUserAndSessionContextFuture` to prioritize `CallContext` fields over `S.request` for http4s compatibility
- Introduce `Http4sResourceDocSupport` with utilities for validation, middleware, and error handling
- Remove redundant middleware and unused `CallContext` definition in `Http4s700`
- Improve modularity and enable http4s request handling in v7.0.0 API routes
2026-01-15 11:08:14 +01:00
hongwei
59ae64b4a0 rafactor/(.gitignore): add .kiro to ignored files list 2026-01-15 10:41:57 +01:00
Simon Redfern
c2e225471c feature/(Http4s700): set JSON content type for API responses
- Add `Content-Type: application/json` header to all API response mappings in Http4s700
- Use a shared `jsonContentType` value for consistent configuration across routes
2026-01-13 11:54:00 +01:00
Simon Redfern
5d0ed75231
Merge pull request #2657 from hongwei1/develop
feature/update the run_all_test script
2026-01-09 18:35:50 +01:00
hongwei
3c9ecdfbfa refactor/(pom.xml): increase Scala compiler JVM memory allocation
- Increase initial heap size from 1G to 4G (-Xms)
- Increase maximum heap size from 3G to 12G (-Xmx)
- Increase metaspace size from 1G to 4G (-XX:MaxMetaspaceSize)
- Improve compilation performance and reduce out-of-memory errors during large-scale builds
2026-01-09 14:40:18 +01:00
hongwei
8b39edb618 refactor/(run_all_tests.sh): fix grep pattern quoting for consistency
- Change double quotes to single quotes in grep regex pattern
- Improve shell script best practices for pattern matching
- Ensure consistent quoting style with grep -E flag usage
2026-01-09 14:29:16 +01:00
hongwei
e9f1ea2167 refactor/(run_all_tests.sh): enhance port management and add timeout support
- Make script executable by updating file permissions
- Remove global `set -e` to prevent grep failures and handle errors explicitly
- Add `--timeout=<minutes>` command line argument for test execution timeout
- Enhance command line argument parsing to support multiple arguments via case statement
- Improve port availability checking with fallback to alternative ports
- Add `find_available_port()` function to search for available ports in range
- Implement dynamic port configuration when primary port is unavailable
- Add error handling with `2>/dev/null` redirects to grep commands in summary generation
- Improve stale process cleanup with safer command substitution
- Add timeout variable initialization for future timeout implementation
- Enhance logging messages with variable port numbers instead of hardcoded values
- Improve robustness of port killing and verification logic with explicit checks
2026-01-09 14:02:24 +01:00
hongwei
3703ab1a00 refactor/(pom.xml): disable parallel test execution to prevent database conflicts
- Disable parallel test execution in obp-api module to avoid shared H2 database state issues
- Disable parallel test execution in obp-commons module for consistency
- Set parallel configuration to false across both modules
- Comment out threadCount configuration as it is no longer needed
- Tests share an in-memory H2 database which causes conflicts when run concurrently
- This resolves intermittent test failures caused by database state contamination between parallel test runs
2026-01-09 13:30:45 +01:00
hongwei
b575771d2e refactor/ fix(pom.xml): enforce test failure detection in Maven build
- Change maven.test.failure.ignore property from true to false
- Enable Maven to fail the build when tests fail instead of ignoring failures
- Ensure build pipeline properly detects and reports test failures
- This change restores strict test failure handling for CI/CD pipelines
2026-01-09 13:25:03 +01:00
hongwei
fa57525093 refactor/(run_all_tests.sh): enhance HTML report generation with asset copying
- Update surefire report filename from surefire-report.html to surefire.html
- Add copying of CSS, JS, images, fonts, and img directories for proper report rendering
- Copy report assets for both obp-api and obp-commons modules
- Add error suppression for missing asset directories to prevent script failures
- Clarify alternative naming convention in site reports location comment
- Ensure HTML reports render correctly with all required static assets
2026-01-09 12:57:15 +01:00
hongwei
5251d79051 rafactor/ perf(pom.xml): optimize Scala compiler JVM memory configuration
- Reduce initial heap size from 4G to 1G for faster startup
- Lower maximum heap size from 12G to 3G for resource efficiency
- Add stack size configuration (-Xss4m) for thread optimization
- Reduce metaspace size from 4G to 1G to minimize memory overhead
- Improve build performance on resource-constrained environments while maintaining compilation stability
2026-01-09 12:27:51 +01:00
hongwei
2f68e00c2a refactor/(run_all_tests.sh): add HTML report generation and display functionality
- Add HTML report generation step using mvn surefire-report:report-only
- Create dedicated html-reports directory in test results for organized report storage
- Copy surefire HTML reports from both obp-api and obp-commons modules
- Check multiple report locations (target/surefire-reports and target/site)
- Display generated HTML report paths in final test summary output
- Improve test result accessibility by centralizing HTML reports in one location
2026-01-09 12:27:16 +01:00
hongwei
f2b9b2a33d rafactor/ ci(workflows): update branch pattern matching for container build
- Change branch filter pattern from '*' to '**' for improved glob matching
- Ensures workflow triggers on all branches except develop with correct pattern syntax
- Improves CI/CD pipeline reliability by using proper wildcard pattern matching
2026-01-09 11:34:47 +01:00
hongwei
31e39e3773 refactor(build): optimize JVM memory allocation and enable parallel test execution
- Increase JVM heap memory from 512m to 2-4G for faster test execution
- Add G1GC garbage collector and tiered compilation for improved performance
- Enable parallel test execution with threadCount=4 to avoid shared state issues
- Add incremental recompilation mode and Zinc server for faster builds
- Increase Scala compiler JVM memory from 64m/1024m to 512m/2G
- Add language feature flags to suppress compiler warnings
- Add test-results directory to .gitignore for cleaner repository
- Apply optimizations consistently across obp-api, obp-commons, and root pom.xml
- These changes reduce build and test execution time while maintaining stability
2026-01-09 02:51:18 +01:00
hongwei
1428b52905 refactor/(run_all_tests.sh): enhance logging to write to detail log file
- Update log_message function to write messages to both summary and detail log files
- Add output redirection to DETAIL_LOG in addition to existing SUMMARY_LOG
- Improve logging documentation comment to reflect dual log file writes
- Ensures comprehensive logging across all test execution phases
2026-01-09 02:50:28 +01:00
hongwei
ead4bf349c refactor/ (run_all_tests.sh): enhance terminal styling and add phase timing
- Update set_terminal_style() to use phase-specific background colors (gray for starting, orange for building, blue for testing, green for complete)
- Add get_time_ms() function to capture millisecond timestamps across macOS and Linux platforms
- Implement record_phase_time() function to track duration of each test execution phase (starting, building, testing, complete)
- Store phase timing data in temporary file for performance analysis
- Replace grep -P (PCRE) with sed-based parsing for macOS compatibility in generate_summary()
- Update test statistics extraction to sum values across all modules instead of just the last run
- Add cleanup for stale phase_timing.tmp file during initialization
- Improve parsing of Maven output for duration, test counts, and test results using portable sed commands
2026-01-09 02:50:27 +01:00
tesobe-daniel
38ffc46155
Merge pull request #2656 from hongwei1/develop
feature/added test report in github actions
2026-01-07 17:20:23 +01:00
tesobe-daniel
517f39e9c5
Update cosign-installer action version 2026-01-07 17:19:20 +01:00
tesobe-daniel
b902ad19be
Update cosign-installer action version 2026-01-07 17:17:59 +01:00
Simon Redfern
aa736284f4
Merge pull request #2655 from hongwei1/develop-Simon
test/fixed failed tests
2026-01-07 16:26:23 +01:00
hongwei
f14c7b00a9 Merge remote-tracking branch 'Hongwei/develop-Simon' into develop 2026-01-07 15:26:39 +01:00
hongwei
e7a13797af reafctor/add test failure ignore property to maven config
Add maven.test.failure.ignore property to control test execution behavior
2026-01-07 11:23:31 +01:00
hongwei
6eea791193 feature/enhance test reporting and build logging in workflows
Add surefire report plugin and test report artifact uploads
Enable pipefail in maven builds and upload build logs
Remove redundant scala-test-compile execution
2026-01-06 21:39:42 +01:00
hongwei
9e9abdf16a test/fixed failed tests 2026-01-06 21:34:28 +01:00
simonredfern
e545069bbf flushall build and run runs http4s as well 2026-01-06 15:48:02 +01:00
simonredfern
7927558f19 Add apiTagLogCache tag to log cache endpoints 2026-01-06 15:48:02 +01:00
simonredfern
415e22f5a2 Log cache separate endpoints and different Role names 2026-01-06 15:48:02 +01:00
simonredfern
aa823e1ee3 Resource doc yaml respects content parameter 2026-01-06 15:48:02 +01:00
tesobe-daniel
1542593e0e Ignore GitHub directory in .gitignore 2026-01-06 15:48:02 +01:00
simonredfern
bb5c413aaa bugfix: support multiple oauth2.jwk_set.url 2026-01-06 15:48:02 +01:00
simonredfern
275baf6244 System Cache Config fields fix tests 2026-01-06 15:48:01 +01:00
simonredfern
5c2f6b6fdc System Cache Config fields fix 2026-01-06 15:48:01 +01:00
simonredfern
f94a9cf73f System Cache Config fields 2026-01-06 15:48:01 +01:00
simonredfern
31a277dace Cache info storage_location 2026-01-06 15:48:01 +01:00
simonredfern
2e46a93ae3 Tests for cache info etc 2026-01-06 15:48:01 +01:00
Simon Redfern
876985325c
Merge pull request #2653 from hongwei1/refactor/AddedResourceDocs
Refactor/added resource docs
2026-01-06 12:22:21 +01:00
hongwei
c99cb73cfd refactor/code clean 2026-01-06 12:20:39 +01:00
hongwei
9844051a85 docfix/tweaked the default port for http4s 2026-01-06 12:16:57 +01:00
hongwei
0459b154d5 Merge remote-tracking branch 'Simon/develop' into develop 2026-01-05 15:59:57 +01:00
karmaking
bbc440170e fix restore build pipeline 2026-01-05 13:24:15 +01:00
hongwei
d5ba4ea03e Merge remote-tracking branch 'Simon/develop' into develop 2026-01-05 10:09:34 +01:00
simonredfern
4a20168da7 Added GET system cache config and GET system cache info 2025-12-31 17:18:08 +01:00
simonredfern
423a6000b0 Cache invalidation WIP 2025-12-31 08:16:59 +01:00
simonredfern
69c10545aa Redis startup test 2025-12-31 07:08:07 +01:00
simonredfern
c5bfb7ae72 rate limiting enabled by default. 2025-12-31 06:34:17 +01:00
simonredfern
5f5409e34a call counter prefix 2025-12-31 06:06:07 +01:00