Module 3: Incorporating policy and tribal knowledge with Solution Server

Back at ACME Corp, you’ve successfully demonstrated AI-accelerated code modernization. Your manager is impressed but has a concern: "This looks great, but how do we ensure the AI follows our company’s coding standards? We have specific patterns we use across all applications. Furthermore, how can we ensure junior software engineers, who will carryout the bulk of the migration efforts, will be guided by AI to follow these company standards and practices."

ACME needs to scale modernization across dozens of applications while maintaining consistency with company-specific policies and best practices. You’ve heard that Developer Lightspeed Solution Server can learn organizational knowledge, but you need to see how it works. You also need to ensure that Developer Lightspeed for MTA enforces these best practices and company standards on migration efforts carried out by junior developers, or recently onboarded developers, or even contractors.

In this module, you’ll experience how Solution Server captures company policies, learns tribal knowledge, and accelerates major migration waves by teaching AI your organization’s specific patterns.

In this module you move between two different roles. First you will be the senior architect or developer who based on an Archetype grouping of applications we covered in Module 1, works with a representative application, and at certain points adds into the code migration company policy code approaches, or tribal knowledge based upon company code libraries or practices.

You will then switch roles and as a junior developer will benefit from AI infused learned best practices.

Learning objectives

By the end of this module, you’ll be able to:

  • Understand Developer Lightspeed Solution Server architecture and capabilities

  • Configure Solution Server to learn company coding standards

  • Teach the AI system organizational best practices and policies

  • Apply learned patterns consistently across migration projects

  • Demonstrate how Solution Server accelerates large-scale migration waves

Exercise 1: Introduction to Developer Lightspeed Solution Server

You need to understand what Solution Server is and how it enables organizational knowledge capture for AI-assisted development.

You prepare to explore Solution Server’s capabilities and architecture.

  1. Understand Solution Server’s role:

    Developer Lightspeed Solution Server acts as an organizational knowledge repository that:

    • Captures company-specific coding patterns and standards

    • Learns from existing codebase examples

    • Stores best practices and policy rules

    • Provides context to AI models for consistent code generation

    • Enables knowledge sharing across development teams

  2. Review the Solution Server architecture:

    Solution Server is an MCP server that sits on top of MTA’s OpenShift installation. It listens and records into a database before and after code changes made by a developer during the migration process. These fixes are then centrally available through solution server for all developers connected to the MTA Hub and Solution Server. As developers invoke Analysis sessions, through the developers MTA Developer Lightspeed extension, and the static code rule enriched prompts are passed to the LLM, the LLM adds in relevant key insights based upon past fixes captured by solution server. These relevant insights are called Migration Hints and they are molded by the LLM into the returned suggested code fixes.

    Developer → Developer Lightspeed Extension → Solution Server → AI Models
                                                        ↓
                                                Knowledge Base
                                                (Policies, Patterns, Examples)

    This architecture ensures all AI-generated code reflects organizational standards.

  3. Explore key Solution Server capabilities:

    • Policy enforcement: Define rules that AI must follow

    • Pattern recognition: Learn from existing code examples

    • Context injection: Automatically include relevant organizational knowledge in AI requests

    • Consistency: Ensure all team members get AI assistance aligned with company standards

    • Knowledge evolution: Continuously improve as more patterns are added

  4. Consider ACME’s use cases:

    ACME can use Solution Server for:

    • Standardized error handling patterns

    • Logging conventions and formats

    • Security policies and requirements

    • Configuration management approaches

    • Testing standards and patterns

    • Documentation requirements

Verify

Confirm you understand Solution Server’s purpose:

✓ Solution Server captures organizational knowledge ✓ It provides context to AI models for better code generation ✓ Policies and patterns are applied consistently ✓ Teams share knowledge through centralized patterns

Exercise 2: Ensure access and configuration

Before you start, setup the module environment

Prerequisites

  • Understand Solution Server value and basic architecture

  • Able to access Workshop Application Tabs

Steps

  1. Confirm access to DevSpaces workspace

    If you completed Module 2 you probably still have an active DevSpaces workspace browser window open.

    If so, navigate to it

    If you don’t, then click on the following linked instructions to initially open or reset your workspace browser window.
    Initially login or reestablish DevSpaces workspace

  2. Switch to the Module 3 Git branch

    • Create a new terminal window

    • Click on the hamburger icon on the right sidebar, Click on the Terminal menu item, click on New Terminal

    • A new terminal window will open at the bottom of the screen

    • Type git checkout module3 and hit return

  3. Confirm and open MTA VSCode extension (Developer Lightspeed for MTA)

    If you completed Module 2 you probably have the extension loaded and ready to work with

    If so, navigate to the Analysis View panel,

    If you don’t, or can’t locate it click on the following link and follow the instructions.
    Load MTA related VSCode extensions

  4. Connect to the MTA Hub and confirm access to the LLM

    The MTA Hub connection gives access to the Solution Server tooling, which is running as an MPC server

    • Confirm you are in the MTA Analysis View

      Depending upon your environment you may notice warning messages about connections. Ignore them for now.
    • Click on the configuration gear icon on the upper right of the pane.

    • A side panel will open Get Ready to Analyze

    • Notice Hub Configuration is not yet configured and Configure GenAI may not be configured yet also

    • Click on Configure Hub Settings

    • The MTA Hub Configuration tab will open

    • In General Settings , click the slider to Enable connection to Konveyor Hub (MTA Hub)

    • In Hub URL enter {mta_url}

    • Enable/Turn on Skip SSL certificate verification_

    • Under Features towards the bottom Enable Solution Server

    • Click Save

    • Close the MTA Hub Configuration tab

      If the Configure GenAI setting is not configured

    • Click on Configure GenAI Settings

      Configure Generative AI Settings
      Figure 1. Configure Generative AI Settings
    • The provider-settings.yaml file will open on a separate pane

      AI Model Settings
      Figure 2. AI Model Settings
    • Replace/Update from the word models: down through the first entry with the following

      This is yaml syntax so ensure to keep the indentions - just copy and paste over existing source
      models:
        OpenAI: &active
          environment:
            OPENAI_API_KEY: "{litellm_virtual_key}" # Required
          provider: ChatOpenAI
          args:
            model: llama-scout-17b # Required
            configuration:
              baseURL: "{litellm_api_base_url}"
    • Close the provider-settings.yaml file.

    • Navigate to the MTA Analysis View tab

    • Ensure that the Server Status shows Running

    • If it doesn’t, click on the Start button

  5. Review the Profile Settings

    In this module the Active Profile has been prebuilt for you. We will review it here.
    Normally you would have several profiles for different Analysis Scenarios. Each profile is specific to a certain type of application migration wave scenario: defining source technologies and frameworks, target technologies and frameworks, and categories of static rules to run.

    In this scenario we are working with the same Module 2 monolithic legacy JavaEE application running on OpenJDK 8. The Senior Architect/Developer is now going to engage Solution Server to capture their changes or adjustments after reviewing the suggested corrections initially generated by Developer Lightspeed.
    • Navigate to the MTA Analysis View tab

Exercise 2: Experience Solution Server learning company policies

Now you’ll see how Solution Server learns from ACME’s existing codebases and documentation to understand company standards.

Prerequisites

  • Access to Dev Spaces workspace

  • Understanding of ACME’s coding requirements

Steps

  1. Define ACME’s coding policies:

    Create a policy document that describes ACME’s standards:

    # In Dev Spaces terminal, create a policies directory
    mkdir -p .devlightspeed/policies
  2. Create a logging policy:

    cat > .devlightspeed/policies/logging-standard.md << 'EOF'
    # ACME Corp Logging Standard
    
    ## Policy
    All application logs must use SLF4J with Logback.
    
    ## Requirements
    - Use SLF4J Logger interface, not System.out or printStackTrace()
    - Include correlation IDs in all log statements
    - Use appropriate log levels: ERROR, WARN, INFO, DEBUG
    - Include context information (user, request ID, operation)
    
    ## Example
    ```java
    import org.slf4j.Logger;
    import org.slf4j.LoggerFactory;
    
    private static final Logger logger = LoggerFactory.getLogger(MyClass.class);
    
    public void processRequest(String requestId, String userId) {
        logger.info("Processing request - requestId: {}, userId: {}", requestId, userId);
        try {
            // business logic
            logger.debug("Request processed successfully - requestId: {}", requestId);
        } catch (Exception e) {
            logger.error("Failed to process request - requestId: {}, error: {}",
                         requestId, e.getMessage(), e);
        }
    }
    ```
    
    ## Anti-patterns to avoid
    - System.out.println() - never use in production code
    - e.printStackTrace() - use logger.error() instead
    - Missing context - always include requestId and userId
    EOF
  3. Create a configuration policy:

    cat > .devlightspeed/policies/configuration-standard.md << 'EOF'
    # ACME Corp Configuration Standard
    
    ## Policy
    All configuration must be externalized for OpenShift deployment.
    
    ## Requirements
    - Use Spring Boot @ConfigurationProperties
    - Never hardcode URLs, credentials, or environment-specific values
    - Support environment variable override
    - Provide sensible defaults for development
    
    ## Example
    ```java
    import org.springframework.boot.context.properties.ConfigurationProperties;
    import org.springframework.context.annotation.Configuration;
    
    @Configuration
    @ConfigurationProperties(prefix = "acme.app")
    public class AcmeAppConfig {
    
        private String apiEndpoint = "http://localhost:8080"; // default
        private int timeout = 30;
        private String environment = "dev";
    
        // getters and setters
    }
    ```
    
    ## OpenShift Deployment
    ```yaml
    env:
      - name: ACME_APP_API_ENDPOINT
        value: "https://api.production.acme.com"
      - name: ACME_APP_TIMEOUT
        value: "60"
      - name: ACME_APP_ENVIRONMENT
        value: "production"
    ```
    EOF
  4. Create a security policy:

    cat > .devlightspeed/policies/security-standard.md << 'EOF'
    # ACME Corp Security Standard
    
    ## Policy
    All applications must follow secure coding practices.
    
    ## Requirements
    - Never log sensitive data (passwords, tokens, PII)
    - Validate all user input
    - Use parameterized queries (never string concatenation for SQL)
    - Encrypt data in transit and at rest
    - Follow principle of least privilege
    
    ## Example: Input Validation
    ```java
    import org.springframework.util.StringUtils;
    
    public void processUserInput(String input) {
        if (!StringUtils.hasText(input)) {
            throw new IllegalArgumentException("Input cannot be empty");
        }
    
        if (input.length() > 255) {
            throw new IllegalArgumentException("Input exceeds maximum length");
        }
    
        // Validate format (e.g., email, phone number)
        if (!input.matches("^[a-zA-Z0-9_-]+$")) {
            throw new IllegalArgumentException("Input contains invalid characters");
        }
    
        // Process validated input
    }
    ```
    
    ## What NOT to do
    ```java
    // NEVER DO THIS - SQL Injection vulnerability
    String query = "SELECT * FROM users WHERE name = '" + userName + "'";
    
    // NEVER DO THIS - Logging sensitive data
    logger.info("User login: username={}, password={}", username, password);
    ```
    EOF
  5. Register policies with Solution Server:

    In the Developer Lightspeed extension:

    • Open Solution Server panel

    • Click Add Policy Source

    • Select directory: .devlightspeed/policies

    • Click Index Policies

      Solution Server will analyze the policy documents and learn ACME’s standards.

  6. Verify policies are loaded:

    # List indexed policies
    ls -la .devlightspeed/policies/

Verify

Confirm Solution Server has learned the policies:

✓ Policy documents created in .devlightspeed/policies/ ✓ Solution Server indexed the policies ✓ Policies appear in Solution Server panel ✓ Each policy includes requirements and examples

Exercise 3: Apply learned patterns to code generation

With ACME’s policies loaded, you’ll now test how Solution Server applies these organizational standards to AI-generated code.

Steps

  1. Create a new Java class that needs proper logging:

    # Create a simple service class
    cat > src/main/java/org/springframework/samples/petclinic/service/OrderService.java << 'EOF'
    package org.springframework.samples.petclinic.service;
    
    public class OrderService {
    
        public void processOrder(String orderId, String userId) {
            // TODO: Implement order processing with proper logging
        }
    }
    EOF
  2. Ask Developer Lightspeed to implement the method:

    • Open the OrderService.java file

    • Select the processOrder method

    • Right-click → Developer LightspeedImplement Method

    • Provide prompt: "Implement order processing following ACME logging standards"

  3. Review the AI-generated code:

    Solution Server should guide the AI to generate code that:

    • Uses SLF4J Logger (not System.out)

    • Includes requestId and userId in log statements

    • Uses appropriate log levels

    • Includes try-catch with proper error logging

    • Follows the pattern from ACME’s logging policy

  4. Verify policy compliance:

    Check that the generated code matches ACME’s logging standard:

    private static final Logger logger = LoggerFactory.getLogger(OrderService.class);
    
    public void processOrder(String orderId, String userId) {
        logger.info("Processing order - orderId: {}, userId: {}", orderId, userId);
        try {
            // business logic here
            logger.debug("Order processed successfully - orderId: {}", orderId);
        } catch (Exception e) {
            logger.error("Failed to process order - orderId: {}, error: {}",
                         orderId, e.getMessage(), e);
        }
    }
  5. Test configuration policy compliance:

    Create a configuration class:

    • Ask Developer Lightspeed: "Create a configuration class for API settings following ACME standards"

    • Verify it uses @ConfigurationProperties

    • Check that it supports environment variable override

    • Confirm no hardcoded values

  6. Test security policy compliance:

    Ask Developer Lightspeed to create an input validation method:

    • Prompt: "Create a method to validate user email input following ACME security standards"

    • Verify it includes validation

    • Check that it doesn’t log sensitive data

    • Confirm it throws appropriate exceptions

Verify

Test that all AI-generated code follows ACME policies:

# Compile to ensure code is syntactically correct
./mvnw compile

# Run checkstyle or code analysis if available
./mvnw checkstyle:check

✓ AI-generated code uses SLF4J logging per policy ✓ Configuration follows externalization standards ✓ Security validation is implemented correctly ✓ All code matches ACME’s documented patterns

Solution Server Policy Application

Exercise 4: Review how Solution Server accelerates migration waves

Now that Solution Server understands ACME’s standards, you’ll see how this accelerates large-scale migration efforts across multiple applications.

Steps

  1. Consider the migration wave scenario:

    ACME has identified 15 applications in Wave 1 that all need similar modernization:

    • Add health check endpoints

    • Externalize configuration

    • Update logging to company standards

    • Apply security best practices

  2. Calculate traditional effort:

    Without Solution Server:

    • Each application requires manual coding standard enforcement

    • Developers must reference policy documents repeatedly

    • Inconsistencies arise between applications

    • Code review catches policy violations late

    • Estimated: 5-7 days per application × 15 apps = 75-105 days

  3. Calculate AI-accelerated effort with Solution Server:

    With Solution Server:

    • AI automatically applies ACME patterns consistently

    • Policies are enforced during code generation

    • No manual reference to policy documents needed

    • Consistency is automatic across all applications

    • Estimated: 1-2 days per application × 15 apps = 15-30 days

  4. Understand the velocity improvement:

    • Traditional approach: 75-105 days

    • AI with Solution Server: 15-30 days

    • Acceleration: 5-7x faster

    • Time saved: 45-90 days for Wave 1 alone

  5. Consider the quality benefits:

    Beyond speed, Solution Server provides:

    • Consistency: All 15 apps follow identical patterns

    • Maintainability: Standardized code is easier to support

    • Onboarding: New developers learn ACME patterns through examples

    • Compliance: Policy enforcement is automated, not manual

  6. Document the business case:

    Create a summary for ACME’s stakeholders:

    cat > migration-wave-analysis.md << 'EOF'
    # ACME Corp Migration Wave 1 Analysis
    
    ## Scope
    - 15 legacy applications requiring modernization
    - Target: OpenShift containerization
    - Standards: ACME coding policies and best practices
    
    ## Approach Comparison
    
    ### Traditional Manual Approach
    - Developer manually codes each modernization
    - References policy documents repeatedly
    - Code review ensures compliance
    - **Estimated time**: 75-105 days
    - **Risk**: Inconsistencies between applications
    
    ### AI-Accelerated with Solution Server
    - AI generates code following ACME policies automatically
    - Solution Server ensures consistency
    - Policies embedded in code generation
    - **Estimated time**: 15-30 days
    - **Quality**: Guaranteed consistency across all apps
    
    ## Business Impact
    - **Time savings**: 45-90 days
    - **Cost reduction**: 60-85% less developer effort
    - **Quality improvement**: Zero policy violations
    - **Scalability**: Approach proven for future waves
    
    ## Recommendation
    Adopt Developer Lightspeed with Solution Server for all migration waves.
    EOF

Verify

Review the business case for Solution Server:

cat migration-wave-analysis.md

✓ Velocity improvement is quantified (5-7x faster) ✓ Quality benefits are documented ✓ Business case is clear for stakeholders ✓ Approach is scalable to future waves

Troubleshooting

Issue: Solution Server doesn’t seem to apply policies to generated code Solution: Verify policies are properly indexed:

# Check that policy files exist
ls -la .devlightspeed/policies/

# Verify policy format is correct (Markdown with examples)
cat .devlightspeed/policies/logging-standard.md

# Re-index policies in Developer Lightspeed panel
# Solution Server → Refresh Policy Index

Issue: AI generates code that violates ACME security standards Solution: Make policy requirements more explicit in the policy document:

## MUST DO
- Validate all user input before processing
- Never concatenate SQL queries

## NEVER DO
- System.out.println() in production
- Log passwords or tokens

Provide clear examples of both correct and incorrect patterns.

Issue: Policies conflict with each other Solution: Review all policies for consistency:

# List all policies
find .devlightspeed/policies/ -name "*.md"

# Review for conflicts
# Resolve by updating policy priority or merging related policies

Issue: Solution Server performance is slow with many policies Solution: Organize policies hierarchically:

# Structure policies by topic
.devlightspeed/policies/
  ├── logging/
  │   └── logging-standard.md
  ├── configuration/
  │   └── config-standard.md
  └── security/
      └── security-standard.md

# Index only relevant policies for specific tasks

Issue: New team members don’t know policies exist Solution: Document Solution Server usage in onboarding:

# ACME Developer Onboarding

## Coding Standards
All code must follow ACME policies:
- Stored in: .devlightspeed/policies/
- Automatically applied by Developer Lightspeed
- Review policies before starting development

## How to Use
1. Use Developer Lightspeed for all code generation
2. AI automatically follows ACME standards
3. Review generated code to learn patterns

Learning outcomes checkpoint

Before moving forward, confirm you can:

  • Explain what Developer Lightspeed Solution Server is and its purpose

  • Create policy documents that capture organizational standards

  • Configure Solution Server to learn company-specific patterns

  • Verify that AI-generated code follows organizational policies

  • Demonstrate how Solution Server accelerates migration waves

  • Quantify business benefits of organizational knowledge capture

  • Understand scalability advantages for large migration portfolios

If you can check all these boxes, you’re ready to proceed. If not, review the exercises where you need more practice.

Module summary

You’ve successfully demonstrated how Solution Server captures organizational knowledge and accelerates large-scale migration efforts.

What you accomplished for ACME: * Created comprehensive policy documents for logging, configuration, and security * Configured Solution Server to learn ACME’s organizational standards * Verified that AI-generated code automatically follows company policies * Quantified 5-7x velocity improvement for migration waves

Business impact realized: * Consistency: All applications follow identical patterns and standards * Velocity: Migration waves accelerate from 75-105 days to 15-30 days * Quality: Policy compliance is automated, not manual * Scalability: Proven approach works across entire application portfolio

Your journey progress: You now understand how to scale AI-assisted modernization across ACME’s entire organization by teaching the AI your company’s specific standards and best practices.

Next steps: Module 4 will complete the migration journey by deploying your modernized application to OpenShift, proving the end-to-end workflow from legacy code to production-ready container.