Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

Base64 is a mechanism to enable representing and transferring binary data over mediums that allow only printable characters. The need for Base64 arose from the need to attach binary content to web services like images, videos or arbitrary binary content.

HexBinary is a built-in data type that represents binary data encoded in hexadecimal format.
Adeptia Suite now supports Base64 Binary or Hex Binary encoding in its web services provider and consumer activities.

   Web Service Provider Activity Using Base64 Binary and Hex Binary

In Web Service Provider activity, extract all the Base64 Binary or Hex Binary attachments from Web Service request and send attachments in Web Service response.
   Handling Base64 and Hex Binary Attachments in Request
When your web service provider activity receives a request that contains Base 64 and Hex Binary attachments then, please follow the below steps:

  1. While creating a web service provider, you need to check the Enable Attachment checkbox.

    Enable Attachment Property


  2. If the request has any Base64 Binary or Hex Binary attachments, then your web service provider stores them in the system and within the request it replaces the attachments with a cid:uniqueid unique ID.

    The web service provider stores these attachments at a base location that you can configure by the following steps:

    1. From the Adeptia Suite home page, click the Administer tab.
    2. On the Administer tab, click the Update System Properties link.
    3. On the Update System Properties screen, click on Services à Web Service Configuration.
    4. Change the value of the abpm.webservice.metro.soapattachment.location property by giving an absolute path. web/Attachments is the default value.


  3. You can find a list of all the names of the attachments and location of the attachments in the context info of the process flow within these variables:
  • SOAPAttachmentsList variable contains the names of the attachments
  • SOAPAttachmentsLocation variable contains the location of the attachments

    The binary data that you extract from a request is encoded only if, your client has not enabled the MTOM. Otherwise, the extracted data is not encoded. 

Sending Base64 and Hex Binary Attachments in Response
When your web service provider activity is sending response that has Base64 and Hex Binary attachments then, please follow the below steps:

  1. Check the Enable Attachment checkbox while creating web service provider activity.

    Enable Attachment Property

  2. In the process flow designer, create context variable BinaryAttachmentFolderPath.
  3. Mention an absolute folder path of the attachments in the BinaryAttachmentFolderPath variable.

    If the location of attachments has both attachments and other folders then, the web service provider would send only files in the root folder. It will not recursively scan all the other folders for attachments.

    Moreover the web service provider would attach files in the response by matching uniqueids with itself.

  4. Map the data to send a Base64 binary or Hex binary attachment with your response. Do the textual mapping by matching the Base64 or Hex binary element with cid:filename. Use this mapping activity in the Process Flow.
  5. The web service provider would then send its response with embedded attachments.

Web Service Consumer Activity Using Base64 Binary and Hex Binary

In Web Service Consumer activity, send Base64 Binary or Hex Binary attachments with Web Service request and extract all the attachments in Web Service response.
 

Sending Base 64 and Hex Binary Attachments in Request
When your web service consumer activity is sending a request that has Base64 Binary and Hex Binary attachments then, please follow the below steps:

  1. Create a Service.<entityName>.enableAttachment variable in the process designer of the process flow and set its value to True/Yes to send the attachment with your request.

    entityName is the name of the Web Service Consumer activity used in the process flow.

    Set the value to False/No if you don’t want to send attachments with your request.

  2. Mention an absolute folder path of the attachments in the Service.<entityName>.binaryAttachmentFolderPath variable.

    If the location of attachments has both attachments and other folders then, the web service consumer would send only files in the root folder. It will not recursively scan all the other folders for attachments.

  3. The web service consumer would then send its request with embedded attachments.


Handling Base 64 and Hex Binary Attachments in Response
When your web service consumer activity receives a response that has Base64 Binary and Hex Binary attachments then, please follow the below steps:

  1. Create a Service.<entityName>.enableAttachment variable in the process designer of the process flow and set its value to True/Yes to receive the attachment with your response. 

    entityName is the name of the Web Service Consumer activity used in the process flow.

    Set the value to False/No if you don’t want to receive the attachments with your response.

  2. If the response has any Base64 Binary or Hex Binary attachments, then your web service consumer stores them in the system and within the response it replaces the attachments with a cid:uniqueid unique ID.

    The web service consumer stores these attachments at a base location that you can configure by the following steps:

    1. From the Adeptia Suite home page, click the Administer tab.
    2. On the Administer tab, click the Update System Properties link.
    3. On the Update System Properties screen, click on Services a Web Service Configuration.
    4. Change the value of the abpm.webservice.metro.soapattachment.location property by giving an absolute path. web/Attachments is the default value.


  3. You can find a list of all the names of the attachments and location of the attachments in the context info of the process flow within these variables:

  • ConsumerSOAPAttachmentsList variable contains the names of the attachments
  • ConsumerSOAPAttachmentsLocation variable contains the location of the attachments

    MTOM (Message Transmission Optimization Mechanism) is a standard way for transmitting binary data, such as images, PDF files, and MS Word documents that uses SOAP protocol. The MTOM message format allows bit stream compression of binary data. This results in less transmission time as a large chunk of binary data takes up less space than its encoded representation.

    The Adeptia Suite enables you to use MTOM properties for Web Service Consumer activity to achieve the transmission of binary data through SOAP messages. For better performance you can Check the Enable MTOM checkbox to use the MTOM format in your Web Service Consumer Activity.

     

          Enable MTOM Property

    The binary data that you extract from a response is encoded only if you have not enabled the MTOM checkbox while creating consumer.

    However, if you have enabled the MTOM checkbox and the Web Service that you are trying to hit, also supports and has MTOM enabled at its end, the data that you extract will not be encoded.

  • No labels