High Availability is major usability for OSB. Consider we need to consume an 3rd party Billing service, consider billing service exposes three different endpoint URI for achieving hight availability. To make use of high avaiabily in the transport layer of OSB we can provide all three endpoint URI of 3rd party services.
Download Busines Service Source: https://drive.google.com/file/d/0B1o4dd3z33rESzJ2SC1SbkdhV28/edit?usp=sharing
Steps:
1. In the General tab point the 3rd party business service wsdl file
2. In the transport tab in default we will be seeing an end point uri once step 1 is completed. Since 3rd part has exposed three service we need to add additional two services endpoint uri.
3. Now need change the retry count. This is very important. Default value of this is zero. if its zero then it will just try to hit the first endpoint url and OSB wont try with other two endpoint uri! Hence we need to set this value to the required amount. Below example I have set to "1", it means if the first url fails then second url will be fired.
From Reference Docs:
You
can define the retry option for business services. The retry option
specifies the maximum number of times a business service can attempt to
access endpoint URIs after an initial failure. For example, consider the
behavior of a business service B with endpoint URIs
eu1
, eu2
, and eu3
, when the retry count is set to 1
, 2
, and 4
.
When Retry Count = 1 – If business service B fails to process a request or is unable to access the endpoint URI
eu1
, it tries to process the request with eu2
(retry 1). If the retry fails then the business service returns failure. The business service does not retry the third endpoint URI eu3
.
When Retry Count = 2 – If business service B fails to process a request or is unable to access the endpoint URI
eu1
, it tries to process the request with eu2
(retry 1). If the retry fails then the business service tries to process the request with eu3
(retry 2). If the retry fails then the business service returns failure.
When Retry Count = 4 – If business service B fails to process a request or is unable to access the endpoint URI
eu1
, it tries to process the request with eu2
(retry 1). If the retry fails then the business service tries to process the request with eu3
(retry 2). Then the business service waits for a interval you have configured for retry iteration interval (in seconds) before trying eu1
(retry 3). If this fails the business service retries eu2
(retry 4). If the retry fails then the business service returns failure.
If the retry count is set to
http://docs.oracle.com/cd/E23943_01/admin.1111/e15867/endpointurimgmt.htm 0
, then the business service does not retry after the failure.