Data Replication with SQL Remote
PART 3. SQL Remote Administration
CHAPTER 10. SQL Remote Administration
As messages pass through e-mail and other message systems, there is a danger of them becoming corrupted. For example, some message systems use certain characters or character combinations as control characters.
Message size affects the efficiency with which messages pass through a system. Compressed messages can be processed more efficiently by a message system than uncompressed messages. On the other hand, carrying out compression can itself take a significant amount of time.
SQL Remote has a message encoding and compression scheme built in to the Message Agent. The scheme provides the following features:
Compatibility The system can be set up to be compatible with previous versions of the software.
Compression You can select a level of compression for your messages.
Encoding SQL Remote encodes messages to ensure that they pass through message systems uncorrupted. The encoding scheme can be customized to provide extra features.
To be compatible with previous versions of the software, you should set the database option COMPRESSION to be -1 (minus one) at each database running the Version 6 software. This setting ensures that messages are sent out in a format compatible with older versions of the software.
If you upgrade the consolidated database Message Agent first, you should set its COMPRESSION database option to -1. As each remote site in your replication system is upgraded to Version 6, you can change its setting of the COMPRESSION option to a value between 0 (no compression) and 9 (maximum compression). This allows you to take advantage of compression features on messages being sent to the consolidated database. Once all remote sites are upgraded, you can set the consolidated site Message Agent COMPRESSION option to a value other than -1.
In addition, setting COMPRESSION to a value other than -1 allows you to take advantage of the Version 6 message encoding improvements.
The default message-encoding behavior of SQL Remote is as follows:
For message systems that can use binary message formats, no encoding is carried out.
Some message systems, including SMTP, VIM, and MAPI, require text-based message formats. For these systems, an encoding DLL (dbencod.dll and ssencod.dll) translates messages into a text format before sending. The message format is unencoded at the receiving end using the same DLL.
You can instruct SQL Remote to use a custom encoding scheme. The tools for building a custom encoding scheme are described in the following section.
If the COMPRESSION database option is set to -1, then a Version 5 compatible encoding is carried out for all message systems.
You can implement a custom encoding scheme by building a custom encoding DLL. You could use this DLL to apply special features required for a particular messages system, or to collect statistics, such as how many messages or how many bytes were sent to each user.
The header file dbrmt.h, installed into the h subdirectory of your installation directory, provides an application programming interface for building such a scheme.
To instruct SQL Remote to use your DLL for a particular message system, you must make a registry entry for that system. The registry entry should be made in the following location:
Software \Sybase \SQL Remote \message-system \encode_dll
where message-system is one of the SQL Remote message systems (file, smtp, and so on). You should set this registry entry to the name of your encoding DLL.
Encoding and decoding must be compatible |