An Azure machine learning service for building and deploying models.
For low-latency, reliable, and scalable integration between on-premises Windows apps (VB6 / .NET) and Azure ML models, use a service-oriented, event-driven, and secure architecture rather than calling the model directly from each client.
Key architectural patterns and components:
- Expose the ML model via a managed API layer
- Deploy the Azure ML model as a web service (online endpoint) in Azure.
- Front it with API management to provide:
- A stable, versioned API surface for legacy apps.
- Centralized authentication, throttling, and monitoring.
- This aligns with the recommendation to use API management for secure and scalable access to AI services and data.
- Use asynchronous, event-driven integration where possible
- For near real-time but not strictly synchronous scenarios, use asynchronous integration patterns:
- Message queues or publish-subscribe topics for prediction requests and responses.
- Benefits:
- Decouples legacy apps from the ML service.
- Improves resiliency and scalability under load.
- Typical flow:
- Legacy app sends a prediction request message (with key data) to a queue/topic.
- A cloud service (Function, container, or web app) consumes the message, calls the Azure ML endpoint, and writes back the result to another queue or directly to SQL Server / a shared store.
- The legacy app either polls for the result or is notified via a lightweight mechanism.
- For near real-time but not strictly synchronous scenarios, use asynchronous integration patterns:
- Event-driven AI application design
- Treat the prediction as an event-driven operation: user input in the on-premises app triggers an event that leads to a prediction.
- Event-driven architecture is recommended for AI workloads to keep components decoupled and responsive.
- MLOps and model lifecycle management
- Implement MLOps practices so that the integration remains stable as models evolve:
- Use model versioning so the API layer can route to specific model versions while maintaining backward compatibility for legacy apps.
- Monitor model performance and data drift; retrain and redeploy models without changing the client integration contract.
- This ensures compliance, reproducibility, and controlled rollouts.
- Implement MLOps practices so that the integration remains stable as models evolve:
- Data security and access control
- Ensure data security for sensitive business data sent from on-premises apps:
- Use TLS for all calls to Azure.
- Enforce authentication and authorization at the API management layer.
- Apply encryption and access controls on any intermediate storage used for requests/responses.
- Ensure data security for sensitive business data sent from on-premises apps:
- Hybrid integration considerations
- Treat the solution as a hybrid system: on-premises clients with cloud-based AI.
- Use established integration patterns for hybrid architectures (for example, message-based integration and clear service boundaries) to keep the legacy apps thin and the cloud side responsible for heavy compute.
- Scalability and reliability practices
- Scale the ML endpoint and the API layer independently based on load.
- Use retry policies and circuit breakers in the integration layer (not in each VB6/.NET client) to handle transient failures.
- For high-volume scenarios, batch prediction requests where acceptable to reduce per-call overhead.
- Client-side integration strategy (VB6 / .NET)
- Encapsulate all Azure calls in a small .NET integration library or service that:
- Exposes simple methods (e.g.,
GetForecast(inputs)) to VB6/.NET apps. - Handles serialization, authentication, and communication with the API management endpoint or message queue.
- Exposes simple methods (e.g.,
- This minimizes changes in legacy code and centralizes integration logic.
- Encapsulate all Azure calls in a small .NET integration library or service that:
Summary pattern:
- On-premises Windows apps → call a local integration component → send request (sync or async) to an API/queue in Azure → integration service calls Azure ML endpoint → returns prediction via API/queue → legacy app reads and displays result.
- Govern the ML lifecycle with MLOps, secure the data path, and use event-driven patterns for resilience and scalability.
References: