Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Feature available in Helium 6.0.1 release


HTML
<style>
.release-box {
	height: 30px; 
	width: 100px; 
	padding-top: 8px;
	text-align: center; 
	border-radius: 5px; 
	font-weight: bold; 
	background-color: #DDA0DD; 
	border-color: #FCE28A;
}

.release-box:hover {
  	cursor: hand;
    cursor: pointer;
    opacity: .9; 
}
</style>
<html>
	<div class="release-box" id="release-box">
		<a href="https://docs.perspectium.com/display/Helium" style="text-decoration: none; color: #FFFFFF; display: block;">
			Helium
		</a>
	</div>
	<br>
</html>


Attachments are stored in ServiceNow in two separate tables, sys_attachment and sys_attachment_doc. One holds information about the attachment, while the other contains the actual byte data of the attachment. Thus, sending attachment(s) to your database with the DataSync Agent will store the attachment(s) in the two tables mentioned. By including a SysAttachmentHandler in the DataSync Agent configuration, the attachment(s) will no longer be left unprocessed in the sys_attachment and sys_attachment_doc, but instead be built and stored in a new table called attachments.

Prerequisites


(warning) First, you will need to set up one of the Perspectium DataSync Agents.

(warning) You should also stop running your DataSync Agent before making any Agent configuration changes.


Procedure

To handle attachments for your DataSync integration, follow these steps:



UI Steps
sizesmall


UI Step

Navigate to the directory where you saved your agent.xml file when installing your DataSync Agent.


UI Step

Open your agent.xml file in a text editing application. Then, add the following directives: 

DirectiveDescriptionRequired?Example Value
<handler>

Name of the Java handler class. In this case, the value for this directive will be com.perspectium.replicator.sql.subscriber.edge.SysAttachmentHandler.


Code Block
<handler>com.perspectium.replicator.sql.subscriber.edge.SysAttachmentHandler</handler>


Yescom.perspectium.replicator.sql.subscriber.edge.SysAttachmentHandler
<skip_queue/>Self-closing tag that will post the attachment directly to the new attachment table, rather than MBS. Yes
<edge_encryption>

Decrypts messages that have been published from a ServiceNow instance that is leveraging the ServiceNow Edge Encryption feature.

See Edge Encryption/Decryption for DataSync Agent.

Yes, if the attachments are edge encrypted.

Otherwise, NOT required. 

See example below.


Example snippet of agent.xml: 

Code Block
languagexml
themeEclipse
<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>
<config>
    <agent>
        <subscribe>
            <task>
 				<task_name>attachment_processor</task_name>
            	<handler>com.perspectium.replicator.sql.subscriber.edge.SysAttachmentHandler</handler>
				<skip_queue/>              
                .
                .
                .
                 <edge_encryption
                    keystore=""
                    vault_tenant=""
                    vault_url=""
                    vault_principal=""
                    principal_secret=""
                    secret_name=""
                    keystore_password=""
                    keystore_alias=""
                    alias_password="">true</edge_encryption>
            </task>
        </subscribe>
    </agent>
</config>


UI Text Box
typetip

NOTE: To see other defined tasks in the agent.xml, see DataSync Agent configurations.



UI Step

After configuring your agent.xml, start running your DataSync Agent again.