# High Availability and Scale Deployment considerations

For Production environments, ensure that all components and its dependencies are deployed in a High Availability architecture. These includes:

* API Instances:
  * Deploy with a Load Balancing front end
  * Have at least 2 machine instances running the API services
  * You can configure Load Balancing with several methods
    * IIS Web Server with ARR as mentioned [here](https://docs.microsoft.com/en-us/iis/extensions/configuring-application-request-routing-arr/http-load-balancing-using-application-request-routing)
    * Use Windows Server [Network Load Balancing](https://docs.microsoft.com/en-us/windows-server/networking/technologies/network-load-balancing)&#x20;
    * Or use dedicated load balancers like F5.
  * Though the API calls are stateless, in order to give a better experience and performance, configure load balancing with sticky sessions (requests from the same client/IP during the same session goes to the same backend API node).
* Agent Services (Windows NT Service)
  * Install Agent Service on the first machine, configure and ensure its running. The first machine will become the primary (master).
  * Install Agent Service on a second machine, configure and ensure its running. The second machine will register itself as a secondary and will take over as primary (master) if the first agent stopped.
* SQL Server&#x20;
  * Deploy with Always ON / Fail over cluster.
  * Read more on SQL Server Business continuity overview [here](https://docs.microsoft.com/en-us/sql/database-engine/sql-server-business-continuity-dr?view=sql-server-ver15).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cloudassert.com/azure-stack-billing/2010/installation/deployment/installation/high-availability-and-scale-deployment-considerations.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
