How microsoft/azure-boards-estimate works
This project, “Azure Boards Estimate,” is an Azure DevOps extension designed to facilitate collaborative sprint planning using a Planning Poker mechanism within Azure DevOps. Its primary function is to enable teams to estimate work items in real time, streamlining the estimation process during sprint planning.
Main Components
• Extension/Frontend UI:
– The majority of the UI lives within the “src” directory, with a strong separation in components and pages.
– The “src/pages” directory is segmented by functionality (home, create, session, settings) that represent different screens or views in the application.
• State Management & Business Logic:
– The project employs Redux (with files like reducer.ts, initReducer.ts, and actions/sagas/selectors in various pages) to manage state and asynchronous actions.
– In “src/initSaga.ts” and individual pages (e.g., “src/pages/home/sessionsSaga.ts”, “src/pages/session/sessionSaga.ts”), sagas orchestrate side effects.
• Services & Communication Layer:
– The “src/services” folder contains modules responsible for interacting with Azure DevOps APIs and handling business logic (e.g., estimation, identity, workItems, sessions).
– Within “src/services/channels” there are multiple utilities (signalr, offline, etc.) managing real-time data and communication channels.
• Utilities & Shared Libraries:
– The “src/lib” directory includes helper functions (history management, URL management, CSS modules) which are re-used across the app.
– The “src/model” directory defines data models and types (cards, queries, sessions, work items) that form the application’s data structures.
• Configuration & Deployment:
– Top-level files like “.azure-pipelines/azure-pipeline.yml”, “.devcontainer”, “configs”, and various scripts indicate CI/CD pipelines, containerized development, and environment-specific configurations.
– The “package.json”, “tsconfig.json”, and lint/prettier configuration files define the development environment and build settings.
Relationships and Interactions
• UI Interactions:
– UI components render in the browser (using React as indicated by TypeScript JSX files) and interact with the Redux store.
– Pages act as containers routing and aggregating these components.
• Communication Flow:
– User actions on the UI trigger dispatches which are handled by Redux actions and sagas.
– Sagas then invoke services that perform calls to Azure DevOps APIs or manage real-time channels (signalr/offline) to update work items.
• Data Flow:
– Data models defined in “src/model” are used across actions, reducers, and components ensuring consistent type definitions.
• External Integration:
Architectural Patterns and Design Principles
• Modular Service Layer: Identify how “services” abstract away business logic and external communication.
• Redux Pattern: Represent the flow from UI to actions, followed by reducers and sagas.
• Separation of Concerns: Differentiate clearly between the UI layer (with presentational components), state management, and service/communication layers.
Relevant Technologies & Frameworks
• React with TypeScript: Indicated by .tsx files in “src”
• Redux for state management (actions, reducers, sagas)
• SignalR for real-time communication (within services/channels)
• Docker (from .devcontainer) and Azure Pipelines for CI/CD
• Azure DevOps Extension APIs referenced throughout