Вопрос

I have an Oracle database and another replicated (the both database are synchronized).

For availability reason, I want when the initial database is inactive, I go to another through my Java program.

What is the driver to use? How?

Это было полезно?

Решение

For this you create services in the database and make the application connect using the service name instead of the physical connect items like ORACLE_SID or instance name.

The connect string should contain the backup connection[s]. The application will connect to the first possible database where the requested service runs. If that database fails, sql*net will failover the connection to one of the remaining databases, provided that the service also runs there, or that the service has been relocated to one of the remaining databases.

There are lot's of options for this. Start reading Oracle Maximum Availability Architecture - MAA Lookout for global package state variables ...

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top