]>
Piment Noir Git Repositories - e-mobility-charging-stations-simulator.git/commit
feat(ocpp20): add SetVariables handling with runtime + persistent var… (#1576)
* feat(ocpp20): add SetVariables handling with runtime + persistent variable support and tests
* refactor(ocpp20): unify validation messages and remove success reason codes
* feat(ocpp20): extend variable manager with EVSE support, runtime overrides + validation refactor
* chore(openspec): add EVSE AuthorizeRemoteStart support proposal and spec delta
* chore(openspec): mark EVSE AuthorizeRemoteStart tasks completed (except validation/archive)
* chore(openspec): archive add-evse-authorizeremotestart-support change
* chore(openspec): archive refactor-ocpp20-variable-proxy change
* refactor: drop resetRuntimeVariables\n\nBREAKING CHANGE: use resetRuntimeOverrides() instead
* refactor(config): enum comparisons with explicit string casting
* refactor(charging-station): conditionally reset OCPP 2.x runtime overrides
* refactor(tests): use date-fns helper for heartbeat interval conversion
* refactor(tests,config): replace manual heartbeat conversions and minor cleanups
* refactor: cleanup OCPP stack stop API
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* test(ocpp20): consolidate setVariables tests into main VariableManager suite
* refactor: variable namespace alignment
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* refactor(validation): simplify configuration value integer checks with Number.isInteger
* test(ocpp20): add edge case validation tests and rename trimmed variable
* refactor: cleanup configuration value validation
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* feat(validation): tighten positive integer checks for OCPP 2.0 variables
* test(ocpp20): simplify BootNotification interval
* feat(ocpp20): add variable metadata constraints
* refactor: cleanups variable value validation
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* refactor: ocpp2 spec alignment
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* fix: handle variables in a case incensitive way
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* feat(ocpp20): add Items/Bytes limits, ReportingValueSize, AuthCtrlr; adopt void tests
* refactor(ocpp20): wrap int parsing in VariableManager with tolerant toIntOrNaN
* refactor(ocpp20): use tolerant int parsing in IncomingRequestService for Items/Bytes limits
* refactor(ocpp20): centralize toIntOrNaN via shared util
* test(utils): add convertToIntOrNaN coverage and remove redundant aliases in OCPP20 services
* refactor: use getter to access configuration key
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* feat(ocpp20): integrate registry-driven characteristics & combined reboot logic in SetVariables
* refactor(ocpp20): restore variable manager logic; migrate to enums
* feat(ocpp20): add variable characteristics registry for enum-backed SetVariables
* refactor(ocpp20): migrate variable manager to unified registry and drop legacy metadata
* chore(lint): add JSDoc for variable registry helpers and whitelist deauthorize
* refactor(ocpp20): remove legacy alias/case-insensitive paths and relocate component variables
* refactor(ocpp20): harmonize variable metadata param naming (variableMetaData)
* refactor(ocpp20): standardize metadata identifier casing (variableMetadata)
* Apply suggestion from @Copilot
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* test(ocpp20): adjust SetVariables propagation tests and HeartbeatInterval component
* feat(ocpp20): enhance variable registry, size limits, MinSet/MaxSet
- Add MinSet/MaxSet overrides and retrieval
- Refine ConfigurationValueSize/ValueSize effective limit logic
- Skip auto-create for unset size limit vars and instance-scoped persistent vars
- Enrich FullInventory report with registry variable data
- Improve integer validation and reason codes (decimal, zero, bounds)
- Persist measurementTimeSeries (CircularBuffer to array) safely
- Adjust persistence (OrganizationName non-overwrite, instance-scoped skip)
- Refactor has() and validateUUID for broader type safety
- Use valid WebSocket URLs for ConnectionUrl size tests
- Add public accessors for base report status and data
* feat(ocpp20): set 2500 max value length; use TooLargeElement reason
* feat(ocpp20): add absolute max constant; align truncation logic and persistence tests
* refactor(ocpp20): use OCPP_VALUE_ABSOLUTE_MAX_LENGTH constant for size limit metadata
* chore(tests,ui): normalize comments, centralize UI timeout and size limit references
* refactor: cleanup variable namespace
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* feat(ocpp20): flatten MessageAttemptInterval instance for persistent config key
* chore(ocpp20): add TODO for generic instance flattening handling
* refactor: revert incorrects changes
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* refactor: align variable namespace
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* refactor: remove unneeded public wrappers for UTs only purpose
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* refactor: cleanup code comments
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* feat(ocpp20,get-variables): accept empty Target (B06.FR.13) and add edge case tests\ndocs(ocpp20): add GetVariables gap analysis, mark B06.FR.13 conformant
* fix: silence linter issues
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* test: remove incorrect tests
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* docs(ocpp20): update GetVariables gap analysis and simplify lint-staged cache usage
* chore: revert lint-staged caching removal
* feat(ocpp20): add write-only variable, MinSet/MaxSet support and instance auto-create skip
* fix(ocpp20): remove MinSet/MaxSet from ConnectionUrl supportedAttributes for spec compliance
* docs(ocpp20): clarify removal of MinSet/MaxSet from ConnectionUrl variable
* fix(ocpp20): remove HeartbeatInterval MinSet/MaxSet
* fix(ocpp20): restrict GetBaseReport and variable registry to Actual attribute only
* docs(changelog): add unreleased section for ocpp20 attribute restriction fix
* chore(ocpp20): remove obsolete comments after attribute restriction refactor
* test(ocpp20): adjust MessageAttemptInterval & GetBaseReport to Actual-only validation
* chore(ocpp20): streamline variable registry comments and group sections
* feat(ocpp20): add missing ChargingStation vars AvailabilityState Available SupplyPhases
* fix: refine variable registry
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* refactor: use existing enum
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* test: add configuration utils tests
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* docs: removed outdated markdown
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* refactor: factor out common logic
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* refactor: use builtin helpers
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
* refactor: remove unneeded comment
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
---------
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
44 files changed: