Tallan's Technology Blog

Tallan's Top Technologists Share Their Thoughts on Today's Technology Challenges

Working with Temporary Directories in Dell Boomi AtomSphere

Kevin Morillo

Dell Boomi’s AtomSphere integration platform provides a simple, yet very powerful feature – the ability to utilize temporary, and semi-temporary files system folders.  Coming from a Microsoft BizTalk integration background, the ability to store documents to a temporary directory is a huge advantage over storing into a database such as the BizTalk MessageBox, especially with larger files.  While BizTalk does provide the necessary mechanism to save files to a local folder through the use of the file adapter, Boomi provides an easier way of achieving this.

Boomi’s temporary file capability allows for specifying a folder or file using a relative path prefixed by the string ‘tmp/’ or ‘work/’.  Files saved within the ‘tmp’ directory are meant to be used within the scope of the given process execution.  Files saved to the ‘work’ directory can be used across process executions.  These temp directories can also be used within local Atoms, additionally, the java.io.tmpdir system property is preconfigured to point to the ‘tmp/’ directory.

Using either directory is pretty simple.  I will show a simple process which will save a string ‘test message from kevin’ within the file ‘work/TestKevin/relativeFile.txt’, then read it back out from the text file.

First, we will add a new process, with a branch shape, and a message shape within the first branch.  The message shape will contain ‘test message from kevin’ as the Message.

1

Then we will add a properties shape, specifying the property ‘Disk – File Name’ with a static value of ‘relativeFile.txt’

2

 

3

 

Next, we will create a new Disk Connector pointing to the directory ‘work/TestKevin’

4

We will then specify a new Disk Operation, making sure to select the ‘Create Directory if it Doesn’t Exist?’ checkbox.

5

The inclusion of a Stop shape will end this branch.

6

The second branch will contain a disk connector, reusing the connector created above, and with a new Get operation retrieving any files with any extensions, and deleting files once they are received.

After adding another Stop shape, our process should look like below.

7

We can then run a test through the ‘Test Atom Cloud

8

The result is all green!  Selecting the first disk shape ‘RelativePathDisk’ within the first branch will show us that a file with the name ‘relativeFile.txt’ was indeed saved to the directory /mnt/Test_Atom_Cloud_Store/…../work/TestKevin

9

Selecting the disk operation in the second branch shows the same file being retrieved and subsequently deleted.

10

We can also see, within the document viewer, the message text received within the disk shape in the second branch as ‘test message from kevin’

11

Relatively simple, yet very powerful.

The Boomi help site provides more information on the use of temp directories within the Boomi Atomsphere:

http://help.boomi.com/atomsphere/GUID-343FE204-D3A8-4AE7-9197-087CFBCF6235.html

No comments

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

\\\