Google Sign-In Required

Use your company Google account to access the BetterFleet private content.

Back to private home

BetterFleet Support Private
Skip to content
BetterFleet Dev Wiki
bf-bnl-settings
Initializing search
    bf-dev
    • Home
    • Product Capabilities
    • Process
    • Current Work
    • System Design
    • Software Reference
    • Operations
    bf-dev
    • Home
      • Overview
      • Manage
      • Overview
      • Product Engineering Workflow
      • Product Engineering Delivery
      • Product Engineering Workflow in Linear
        • GitLab Feature Flags
        • In-App Docs Authoring
        • Release Notes
      • Templates
      • Publishing
      • Workflow Companions
      • Overview
      • Active Artifacts
      • Backlog Artifacts
      • Archived Artifacts
      • Overview
      • Microgrid
      • OSCP
        • Challenge
        • Specification
        • Spec
        • Architecture
        • Overview
        • Script Runtime Model
        • Compose Profiles and Modes
        • Repo Topology
        • CI and Release Integration
        • Overview
        • Internal Application Diagrams
          • Overview
          • Web Model
          • Core Model
        • Service Interaction Flows
        • Data and State
          • Index
          • bf-manage-web
          • bf-manage-core
          • bf-manage-connect
          • bf-manage-sitepwrmon
          • bf-manage-incidents
          • bf-telematics
          • bf-depot-sim
          • bf-manage-roaming
          • bf-support-microsite
          • bf-digital-twin
          • bf-schedule-creator
        • Overview
        • Internal Application Diagrams
        • Migration and Flags
        • Simulation Request Lifecycle
          • Index
          • bf-bnl-ui
          • bf-bnl-settings
            • What this service is
            • Code anatomy
            • Architectural characteristics
            • Documentation and tests in-repo
            • Internal request lifecycle
            • Cloud dependency map
          • bf-bnl-schedule-analysis-compute
          • bf-route-modelling
          • bf-schedule-creator
          • bf-digital-twin
        • Overview
        • Secrets and Env Strategy
        • Vendors and Local Dependencies
        • ADRs
        • Service Matrix
        • Cloud Dependencies
        • Ports and URLs
      • Onboarding
      • Daily Operations Runbook
        • Overview
        • Staging Hotfix Release
        • Production Hotfix Release
        • Terraform Plan Dry Runs
      • Troubleshooting
      • Testing Guide
    • What this service is
    • Code anatomy
    • Architectural characteristics
    • Documentation and tests in-repo
    • Internal request lifecycle
    • Cloud dependency map

    bf-bnl-settings¶

    What this service is¶

    bf-bnl-settings is the legacy Plan orchestration backend. It exposes resource and simulation APIs and coordinates downstream compute and digital twin interactions.

    Code anatomy¶

    • src/main.py: FastAPI factory and routing.
    • src/resources/*: resource domains (vehicle, charger, location, energy).
    • src/settings_v2/*: v2 API domain modules and evolving endpoint contracts.
    • src/scheduleAnalysisScenario/* and src/scheduleAnalysisSettings/*: simulation scenario/config orchestration.
    • src/report/*: reporting outputs.

    Architectural characteristics¶

    • Legacy orchestrator pattern with multiple downstream API dependencies.
    • Transitional architecture where settings_v2 and scenario modules coexist.

    Documentation and tests in-repo¶

    • README is generic/stale; tests provide stronger architecture signal.
    • Test suites include scenario, settings_v2 domain, resources, report, and location coverage.

    Internal request lifecycle¶

    sequenceDiagram
      participant UI
      participant Router as settings router
      participant Scenario as scenario orchestrator
      participant Compute as compute service
      participant Twin as digital twin service
    
      UI->>Router: simulation request
      Router->>Scenario: build scenario inputs
      Scenario->>Compute: run compute stages
      Compute-->>Scenario: compute outputs
      Scenario->>Twin: run depot emulation when needed
      Twin-->>Scenario: emulation outputs
      Scenario-->>Router: merged response
      Router-->>UI: http response

    Cloud dependency map¶

    flowchart LR
      Settings[bf-bnl-settings] --> S3[(aws s3)]
      Settings --> DDB[(aws dynamodb)]
      Scenarios[schedule analysis scenarios] --> S3
      Scenarios --> DDB
      Gtfs[gtfs domain resources] --> S3
      Settings --> Scenarios
      Settings --> Gtfs
    Made with Material for MkDocs