Skip to content

Conversation

@rsafaie
Copy link
Contributor

@rsafaie rsafaie commented Jan 30, 2026

Summary

  • Adds ProfilePropertyLoader utility for loading configuration from external properties files at runtime
  • Introduces JdbcSimulationExecutor and XmlaSimulationExecutor for profile-based simulation execution
  • Enables flexible deployment without code changes via -Datscale.profileFile=<path>
  • Properties are now passed as strongly-typed HashMap<String, String> for better type safety

Features

  • External configuration: Load task settings from properties files on filesystem or classpath
  • Property precedence: System properties (-D flags) override file values
  • File loading order: Filesystem first, then classpath fallback
  • Type-safe properties: Configuration passed as HashMap<String, String> via setAdditionalProperties()
  • Example profiles: Includes example JDBC and XMLA profile configurations

Implementation Details

  • ProfilePropertyLoader.getProfileProperties() returns HashMap<String, String> for type safety
  • Executors use setAdditionalProperties() to directly pass configuration map to tasks
  • Properties are safely converted from Properties object using stringPropertyNames()

Usage

# Run JDBC simulation with profile
mvn exec:java -Dexec.mainClass="executors.JdbcSimulationExecutor" \
    -Datscale.profileFile=example_jdbc_profile.properties

# Run XMLA simulation with profile
mvn exec:java -Dexec.mainClass="executors.XmlaSimulationExecutor" \
    -Datscale.profileFile=example_xmla_profile.properties

🤖 Generated with Claude Code

rsafaie and others added 3 commits January 28, 2026 14:06
Enables loading task properties (model, runId, runLogFileName, runDescription)
from profile-specific properties files at runtime.

- Add profile property: -Datscale.closedsimulation.profile=<profile_name>
- Loads <profile_name>_systems.properties for all task settings
- Property lookup order: system props -> profile file -> systems.properties
- Throws exception if required property not found

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
…sed config

- Add JdbcSimulationExecutor for running JDBC-only simulations
- Add XmlaSimulationExecutor for running XMLA-only simulations
- Add ProfilePropertyLoader utility for loading properties from filesystem or classpath
- Create example profile properties files (example_jdbc_profile.properties, example_xmla_profile.properties)
- Revert ClosedStepSequentialSimulationExecutor to original hardcoded configuration
- Rename and update documentation to RUNTIME_PROFILE_OVERRIDES.md

Configuration via -Datscale.profileFile=<filename> with properties:
- atscale.task.name, atscale.task.model, atscale.task.runId
- atscale.task.runLogFileName, atscale.task.runDescription

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Fix Javadoc in JdbcSimulationExecutor and XmlaSimulationExecutor
- Update example_systems.properties comment to reference new executors

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@rsafaie rsafaie requested a review from stevejhall January 30, 2026 22:56
- Add getProfileProperties() method to ProfilePropertyLoader that returns HashMap<String, String>
- Update JdbcSimulationExecutor and XmlaSimulationExecutor to use setAdditionalProperties() instead of setAlternatePropertiesFileName()
- This provides better type safety and direct property access for task configuration
- Add /.metals to .gitignore for Scala IDE files

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Copy link
Collaborator

@stevejhall stevejhall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change for additional properties usage looks like it completes the goal.

@rsafaie rsafaie merged commit 68b9ab2 into main Feb 10, 2026
@rsafaie rsafaie deleted the feature/runtime-profile-loading branch February 10, 2026 22:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants