oracle
单节点的URL:jdbc:oracle:thin:@127.0.0.1:1521:orcl
多节点的URL(集群):
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.131)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.132)(PORT = 1521))
(LOAD_BALANCE = no)(FAILOVER=YES)
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = CLDB)
)
)
字符串URL:
jdbc:oracle:thin:@(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = 148.16.28.181)(PORT = 1521))(ADDRESS = (PROTOCOL = TCP)(HOST = 148.16.28.182)(PORT = 1521))(ADDRESS = (PROTOCOL = TCP)(HOST = 148.16.28.183)(PORT = 1521))(LOAD_BALANCE = on)(FAILOVER = on))(CONNECT_DATA = (SERVER = hblthxcx)(FAILOVER_MODE = (TYPE = SELECT)(METHOD = BASIC))(SERVICE_NAME = hblthxcx)));