Chapter 8. Compressed File Adapter Patterns

In this chapter, we will cover:

  • Implement GZIP wrapper for OSB
  • Reading compressed files with OSB
  • Writing compressed files with OSB

Introduction

A reasonably common interface convention is to compress the contents of exchanged files, to reduce the impact on network traffic and archiving requirements. This is particularly common in Business-to-Business (B2B) scenarios, where network bandwidth is more of a constraint, as illustrated in the following figure:

Introduction

Although the Oracle Service Bus does not support such interfaces "out of the box," it is reasonably straightforward to piece together a simple adapter using existing tools.

In this chapter, we will cover recipes that enable us to read/write a GZIP file using the Oracle Service Bus.

GZIP is a data compression software application, most commonly encountered as the version implemented by the GNU Project. GZIP only natively supports the compression of one file at a time (although, of course, that file may itself be the combination of several smaller files), and has a simple format consisting of compressed binary content between a standard header and footer.

J2SE includes a standard library of compression/decompression utilities in the java.util.zip package, which, among other things, includes functionality for working with the GZIP data compression algorithm.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.146.178.165