You are here: Foswiki>Service Web>RDAstartingPage (21 Dec 2016, ErwinWagner)Edit Attach

Common Middleware (CMW) at GSI

About

The Common Middleware (CMW) Framework developed by CERN provides a Middleware Solution for the communication between Frontend tier (FECs) in form of the FESA Device Classes and the Application tier, e.g. JAPC. CMW consist of multiple packages and components, each adding a particular function to the framework. An overview over the framework can be found here (accessible only form the CERN Network): http://wikis.cern.ch/display/MW/Home.

This section mainly concentrates on Remote Device Access (RDA) messaging layer of CMW, but also presents some topics regarding other CMW related utilities.

RDA2

RDA 2 is an older CORBA based version of RDA layer, which is now replaced by RDA3. All new developments should use RDA3 unless there is an urgent need to RDA2.

The version is not supported at GSI anymore, so old devices (if there are any) should switch to RDA3 (FESA3). Information about the older version can be found here.

RDA3

In Juli 2014 the CERN Middleware team has released a new version of RDA libraries called RDA 3, which is a completely new development. The main motivation for a new version was the replacement of old CORBA messaging layer by the newer ZeroMQ layer. Natively the new RDA library is not compatible with the older one, however using so called proxies it is possible to enable the communication between RDA 2 and RDA 3. Those proxies require resources, dependent libraries (omniORB) and additional effort to set up. Today there is no plans and need to set up such proxies at GSI, so there will be (probably) no compatibility. Note that this incompatibility is considering only the actual RDA to RDA communication. Frameworks build on top of RDA (FESA, JAPC) still can provide such compatibility and user transparency.
Package overview (GSI)

The following figure provides the overview of CMW packages used and installed at GSI in order to run RDA3. It also shows dependencies between those packages.

RDA3-Dependencies.png

RDA3 installation location at GSI

To reduce dependencies to specific libraries a lab-specific package was introduced to RDA 3 packaging structure. The GSI package is called cmw-rda3-gsi. Basically this package allows the usage of the "pure" RDA3 functionality with the standard interface, while CERN package does also provide additional compatibility (RDA2) and security (RBAC) functions and depends on according libraries.

On acc cluster the C++ RDA3-GSI package can be fould here: /opt/gsi/cmw/cmw-rda3-gsi/<versionnumer>

The version of the rda3-gsi package corresponds to the version of the according RDA3 libraries. Packaging also include symbolic liks to all additional cmw libraries, which are required to run an RDA3 applications.

RDA3 C++ libraries themselfs can be found here:/opt/cern/cmw/

The Java JARs are deployed to the nexus server and can be bound to the projects using maved dependecy management.
Using of libraries in own projects

C++

Using the RDA3 library on acc cluster will require adding of following dependencies to your makefile.

PARENT_MAKEFILE ?= /opt/cern/buildsystem/cmw/2.0.1/Make.gsi
CMW_MAKEFILE_VERSION=2.0.1

# Include the parent CMW makefile
include $(PARENT_MAKEFILE)

# Location of RDA3-GSI
RDA3_GSI_VERSION ?= _<VERSION>_
RDA3_GSI_HOME ?= /opt/gsi/cmw/cmw-rda3-gsi/$(RDA3_GSI_VERSION)

# 3rd Party library locations
ZMQ_HOME = $(THIRD_PARTY_LOCATION)/zeromq/$(ZMQ_VERSION)
BOOST_HOME = $(THIRD_PARTY_LOCATION)/boost/$(BOOST_VERSION)

# Compiler options
DEPENDENT_COMPILER_OPTIONS = -I$(RDA3_GSI_HOME)/$(INCLUDE_LOCATION)

DEPENDENT_LINKER_OPTIONS =   $(RDA3_GSI_HOME)/$(LIB_LOCATION)/libcmw-directory-client.a \
            $(RDA3_GSI_HOME)/$(LIB_LOCATION)/libcmw-data.a \
            $(RDA3_GSI_HOME)/$(LIB_LOCATION)/libcmw-log.a \
                                $(RDA3_GSI_HOME)/$(LIB_LOCATION)/libcmw-util.a \
                                $(ZMQ_HOME)/$(LIB_LOCATION)/libzmq.a \
                                $(BOOST_HOME)/$(LIB_LOCATION)/$(BOOST_CHRONO_LIB_NAME) \
                                $(BOOST_HOME)/$(LIB_LOCATION)/$(BOOST_SYSTEM_LIB_NAME) \
                                $(BOOST_HOME)/$(LIB_LOCATION)/$(BOOST_THREAD_LIB_NAME) \
                                $(BOOST_HOME)/$(LIB_LOCATION)/$(BOOST_ATOMIC_LIB_NAME) \
                                $(BOOST_HOME)/$(LIB_LOCATION)/$(BOOST_FILESYSTEM_LIB_NAME) \
                                -lrt

Java (Maven)

To use the Java version of RDA3 with Maven, following need to be added to the dependencies in the pom file:
<dependency>
  <groupId>cern.cmw</groupId>
  <artifactId>cmw-rda3</artifactId>
  <version>1.2.6</version>
  <exclusions>
     <exclusion>
       <groupId>org.zeromq</groupId>
       <artifactId>zeromq</artifactId>
     </exclusion>
  </exclusions>
</dependency>

<dependency>
   <groupId>cmmnbuild</groupId>
   <artifactId>zeromq</artifactId>
   <version>4.0.4</version>
</dependency>

<dependency>
   <groupId>de.gsi.cs.co.sv.zmq</groupId>
   <artifactId>gsi-jzmq-native-sl6</artifactId>
   <version>3.1.0</version>
</dependency>

-- VitaliyRapp - 09 Dec 2015
Topic revision: r6 - 21 Dec 2016, ErwinWagner
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback