Execution time for PackageId packageId = eslClient.createPackage(documentPackage
Sunday, June 19, 2016 at 03:25pmHello Michael,
During the processing in an application a client noticed that below statement takes few seconds (5-10) to execute:
PackageId packageId = eslClient.createPackage(documentPackage);
Can you please let us know how much time this should ideally take? OR if there is any updated library which the client should use.
Here is the actual code:
//Initialize EslClient.
EslClient eslClient = new EslClient(CommonUtil.getPropertyValue(ServiceContractsConstants.PROJECT_PROPERTY_FILE, AssetConstants.API_KEY), AssetConstants.API_URL);
// Register the callback URL for DOCUMENT_SIGNED_EVENT.
eslClient.getEventNotificationService().register(
newEventNotificationConfig(CommonUtil.getPropertyValue(ServiceContractsConstants.PROJECT_PROPERTY_FILE,
AssetConstants.SERVLET_URL)).forEvent(AssetConstants.DOCUMENT_SIGNED_EVENT));
eventNotificationConfig = eslClient.getEventNotificationService().getEventNotificationConfig();
//Create Document Package with the needed information
//Document name, Id, First name, Last name, signing order, with Signer
DocumentPackage documentPackage =newPackageNamed("AssetContractPDF").withSigner(newSignerWithEmail("[email protected] ")
.withFirstName(dealerFName).withLastName(dealerLName)
.withCustomId("Test").signingOrder( 1 ) )
.withSigner(newSignerWithEmail("[email protected] ")
.withFirstName(customerFName).withLastName(customerLName)
.withCustomId(signerId).signingOrder( 2 ) )
.withDocument(newDocumentWithName(AssetConstants.E_SIGN_DOC).fromFile("PDF_FILE")
.withSignature(SignatureBuilder.signatureFor("[email protected] ").onPage(0).atPosition(
Double.parseDouble(Dealer[AssetConstants.ZERO_INT].trim()),
Double.parseDouble(Dealer[AssetConstants.ONE_INT].trim())))
.withSignature(captureFor("[email protected] ").onPage(0).atPosition(
Double.parseDouble(Customer[AssetConstants.ZERO_INT].trim()),
Double.parseDouble(Customer[AssetConstants.ONE_INT].trim()))).withId(pdfName.trim())).build();
// Perform some changes desired as per the application.
DocumentPackageSettings documentPackageSettings = newDocumentPackageSettings();
documentPackageSettings.setEnableInPerson(true);
documentPackageSettings.setShowDialogOnComplete(false);
documentPackageSettings.setHideWatermark(true);
documentPackageSettings.setShowPackageOwnerInPerson(false);
documentPackage.setSettings(documentPackageSettings);
// generate Package Id.
PackageId packageId = eslClient.createPackage(documentPackage);
packageInfoId = packageId.getId();
// Send Package Id to EslClient.
eslClient.sendPackage(packageId);
// Set the session Token into our Variable as per the Package ID.
sellingProductMgtView.setSessionToken("https://sandbox.e-signlive.com/access?sessionToken=" + eslClient.getSessionService().createSessionToken(packageInfoId, "Test"));
Please advise.
Reply to: Execution time for PackageId packageId = eslClient.createPackage(documentPackage
Monday, June 20, 2016 at 11:53am