Skip to content

Commit 7e26be7

Browse files
committed
readme changes
1 parent 82b03dc commit 7e26be7

2 files changed

Lines changed: 30 additions & 16 deletions

File tree

README.md

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,13 @@ keytool -list -v -keystore <Your_keystore_name>`
157157
- Second entry should be for `CyberSource_SJC_US` certificate with alias name as CyberSource_SJC_US
158158

159159
## PoolingHttpClient
160-
To get more information please refer wiki.
160+
PoolingHttpClient is built using the apache's PoolingHttpClientConnectionManager class. It comes with retry functionality which is very much needed in case if
161+
SDK receives an I/O error/exception, when executing a request over a connection that has been closed at the server side. However there might be some cases when
162+
transaction has reached server and similar or some other exception has occurred. It is not recommended to retry on non-idempotent methods, so we are considering
163+
`merchantTransactionIdentifier` as idempotent key. Hence if you want to use PoolingHttpClient, merchantTransactionIdentifier field is mandatory in the payload(nvp or xml).
164+
165+
166+
To get more information related to connection pooling please refer wiki.
161167

162168
## Message Level Encryption
163169
CyberSource supports Message Level Encryption (MLE) for Simple Order API. Message level encryption conforms to the SOAP Security 1.0 specification published by the OASIS standards group.
@@ -215,7 +221,9 @@ _______________________________
215221

216222
3)Changed retry interval from second to millisecond
217223

218-
4)Added one more request header "v-c-client-computetime" to calculate time taken to send request to cybersource
224+
4)Added one more request header "v-c-client-computetime" to calculate time taken to send request to Cybersource
225+
226+
5) Added troubleshooting section in README.
219227

220228
Version Cybersource-sdk-java 6.2.9 (APR,2020)
221229
_______________________________
@@ -313,7 +321,7 @@ _______________________________
313321
}
314322

315323
## Documentation
316-
- For more information about CyberSource services, see <http://www.cybersource.com/developers/documentation>.
317-
- For all other support needs, see <http://www.cybersource.com/support>.
324+
- For more information about CyberSource services, see <https://www.cybersource.com/en-us/support/technical-documentation.html>.
325+
- For all other support needs, see <https://support.cybersource.com/>.
318326

319327

zip/README

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -148,15 +148,13 @@ try {
148148
e.getInnerException().printStackTrace();
149149
}
150150

151-
##PoolingHttpClientShutdown
152-
In case of PoolingHttpClient Connection, we need to close the connection manager, http client and idle connection cleaner thread when application got shutdown abruptly or gracefully.
153-
If "enabledShutdownHook" is true, then JVM runtime addShutdownHook method will be initialized.
154-
Shutdown Hooks are a special construct that allows developers to plug in a piece of code to be executed when the JVM is shutting down. This comes in handy in cases where we need to do special clean up operations in case the VM is shutting down.
155-
private void addShutdownHook() {
156-
Runtime.getRuntime().addShutdownHook(this.createShutdownHookThread());
157-
}
158-
createShutdownHookThread will call static shutdown api to close connectionManager, httpClient and IdleCleanerThread.
151+
##PoolingHttpClient
152+
PoolingHttpClient is built using the apache's PoolingHttpClientConnectionManager class. It comes with retry functionality which is very much needed in case if SDK receives
153+
an I/O error/exception, when executing a request over a connection that has been closed at the server side. However there might be some cases when transaction has reached
154+
server and similar or some other exception has occurred. It is not recommended to retry on non-idempotent methods, so we are considering `merchantTransactionIdentifier` as
155+
idempotent key. Hence if you want to use PoolingHttpClient, merchantTransactionIdentifier field is mandatory in the payload(nvp or xml).
159156

157+
To get more information related to connection pooling please refer wiki.
160158

161159
##Message Level Encryption
162160

@@ -249,7 +247,8 @@ _______________________________
249247
1)MerchantConfig Object Caching based on KeyAlias/Merchant Id
250248
2)Added PoolingHttpClientConnection implementation
251249
3)Changed retry interval from second to millisecond
252-
4)Added one more request header "v-c-client-computetime" to calculate time taken to send request to cybersource
250+
4)Added one more request header "v-c-client-computetime" to calculate time taken to send request to Cybersource
251+
5)Added troubleshooting section in README.
253252

254253
Version Cybersource-sdk-java 6.2.9 (APR,2020)
255254
_______________________________
@@ -333,11 +332,18 @@ _______________________________
333332
for appropriate JAVA version. I meant if merchant are using java 6 then download these policy file only for java6.
334333
You need to copy security jars (US_export_policy.jar, local_policy.jar) in the $JAVA_HOME/jre/lib/security directory not in $JAVA_HOME/jre/lib/ext/).
335334

336-
##Documentation
335+
- Put below block of code to handle the ClientException to print the complete stacktrace.
336+
337+
try{
338+
Client.runTransaction(requestMap, merchantProperties);
339+
}catch (ClientException e){
340+
e.getInnerException().printStackTrace();
341+
}
337342

338-
For more information about CyberSource services, see <http://www.cybersource.com/developers/documentation>
343+
##Documentation
339344

340-
For all other support needs, see <http://www.cybersource.com/support>
345+
For more information about CyberSource services, see <https://www.cybersource.com/en-us/support/technical-documentation.html>
346+
For all other support needs, see <https://support.cybersource.com/>
341347

342348

343349

0 commit comments

Comments
 (0)