BlpBridge is an open source bridge implementation. It gives the ability of OpenMAMA client application
to subscribe for Market Data and/or request Reference Data from Bloomber Data Server.
git repository:
#> git clone git://git.code.sf.net/p/blpbridge/code blpbridge
archive:
#> wget http://sourceforge.net/projects/blpbridge/files/blpbridge-1.0.tar.bz2
#> tar -jxf blpbridge-1.0.tar.bz2
| Tree | Description |
|---|---|
| CMakeLists.txt | CMake file |
| README | this file |
| LICENSE | License |
| openmama.patch | patch file for OpenMAMA |
| bridge | bridge library source and header files |
| payload | payload library source and header files |
| cmake | CMake files |
In BlpBridge source package you will find openmama.patch file. Extract OpenMAMA archive and
apply patch file openmama.patch. Usually:
#> cd OpenMAMA-2.1.1.2
#> patch -p1 < /path/to/blpbridge/source/dir/openmama.patch
Follow up the instructions from README file in OpenMAMA source directory in order to build
and install patched version.
BlpBridge depends on OpenMAMA (patched) and Blpapicpp.
If OpenMAMA patched version installed (see previous section) is not in /usr:/usr/local then export OPENMAMA_DIR variable:
#> export OPENMAMA_DIR=/path/to/openmama/install/dir
If Blpapicpp is not extracted in /usr:/usr/local or BlpapiSimul (see BlpapiSimul section) is not installed in /usr:/usr/local, then export BLPAPI_CPP_DIR variable
with Blpapicpp:
#> export BLPAPI_CPP_DIR=/path/to/blpapicpp/source/dir
#> cd ${BLPAPI_CPP_DIR}/Linux
#> ln -s libblpapi3_XX.so libblpapi3.so
or with BlpapiSimul:
#> export BLPAPI_CPP_DIR=/path/to/blpapisimul/install/dir
Create build directory:
#> mkdir build-dir && cd build-dir
Prepare build direcotry:
#> cmake /path/to/blpbridge/source/dir [-DCMAKE_INSTALL_PREFIX=/path/to/install/dir] [-DCMAKE_BUILD_TYPE=Release]
(Use ccmake or other tool to setup build options and correct directories.)
Build and install:
#> make
#> make install
#> export WOMBAT_PATH=${OPENMAMA_DIR}/examples/mama/c
Edit ${WOMBAT_PATH}/mama.properties. Append the following line:
mama.blp.transport.blp_tport.url=host[:port]
#> cd ${OPENMAMA_DIR}
mamalistenc. Market Data subscription:
#> bin/mamalistenc -m blp -tport blp_tport -B -S MktData -s "VOD LN Equity"
with field filter:
#> bin/mamalistenc -m blp -tport blp_tport -B -S MktData -s "VOD LN Equity [BID, ASK, BEST_BID, BEST_ASK]"
with update interval option set to 5 sec.:
#> bin/mamalistenc -m blp -tport blp_tport -B -S MktData -s "VOD LN Equity {interval=5.0}"
with field filter and interval option:
#> bin/mamalistenc -m blp -tport blp_tport -B -S MktData -s "VOD LN Equity [BID, ASK, BEST_BID, BEST_ASK]{interval=5.0}"
mamalistenc. Reference Data subscription:
#> bin/mamalistenc -m blp -tport blp_tport -B -S RefData -s "VOD LN Equity [PX_ASK, PX_BID]"
mamaproxyc. Market Data subscription published on Avis Router.
#> bin/mamaproxyc -ms blp -mp avis -SS MktData -s "VOD LN Equity" -SP MktData
and then multiple mamalistenc client connected to Avis Router:
#> bin/mamalistenc -m avis -B -S MktData -s "VOD LN Equity"
The last example shows how BlpBridge may be used in conjunction with Avis implementation. The result is all data coming from
Bloomber Terminal is published on Avis Router and then multiple clients can subscribe for it with Avis bridge.
BlpapiSimul is developed for testing purposes of BlpBridge. The library is replacement of original Blpapicpp library.
libblpapi3_XX.so => libblpapi3.so
#> wget http://sourceforge.net/projects/blpbridge/files/blpapisimul-1.0.tar.bz2
#> tar -jxf blpapisimul-1.0.tar.bz2
Note: If you are using git, it is in same directory as BlpBridge
Create build directory:
#> mkdir build-dir && cd build-dir
Prepare build directory:
#> cmake /path/to/blpapisimul/source/dir -DBLPAPI_CPP_INCLUDE_DIR=/path/to/blpapicpp/source/dir/include [-DCMAKE_INSTALL_PREFIX=/path/to/install/dir] [ -DCMAKE_BUILD_TYPE=Release]
(Use ccmake or other tool to setup build options and correct directories.)
Build and install:
#> make
#> make install