 |
|
|
Enterprise
solutions based on "Software Components"
and Not just applications in C++ |
| Overview
|
|
If you are a C++ professional
(expected to be the one of largest class of developers
worldwide) and wondered why there is no standard
component model for C++ as J2EE for Java?.
|
Also, did you wonder how to address the
challenges in building application by using
software components as contrary to mechanical
industry where applications are built by assembly
of pre-built components? For example, if there
is a problem in an automobile, say problem
in brake component, it can be easily replaced
by another equivalent working component without
affecting the entire assembly. The brake component
is readily available and replaced saving the
manufacturing time. |
|
Is this possible in software industry? This
is a daunting question for all architects,
designers, and developers.
In traditional C++ development,
as the number of functional units increases with
time, new lines of code to be written also increases.
Such dependency is mainly due to inability of
the designers and implementers to visualize the
systems effectively during its time of inception.
As the programmers add more functionality, upgrades
etc., the systems tend to become complex and difficult
to maintain, very often leading to a stovepipe
system. The figure describes the productivity
curve for C++ component based development.
|
| Productivity
curve for C++ development in 8-10 years of software
lifecycle |
|
It is found that cost of software
upgrade/maintenance during entire software life
cycle (compassing 8-10 years) is 3-4 times of
the cost of initial development (1-2 years). These
issues often pose a challenge to the CTOs/CIOs
to choose between new developments vs. upgrading
an existing system. To large extent, either you
totally rewrite your system or you are stuck with
your legacy system. There is a very little chance
of a partial adoption of the system
The biggest reason for these
shortcomings is that though object-oriented approach
with C++ changed the way applications were built,
but it didn't change the nature of the application
themselves as described in the figure below.
|

|
Before the birth of object
oriented technologies the end user would
receive a monolithic application built say
using COBOL.
When developed using object oriented
technologies, the end user would still receive
a monolithic application, only this time
built, say using C++.
Either way, it was a monolithic
application. The end user had no way to
tell how the application was implemented
nor did it make any real difference to him/her.
|
|
| In
case of Object-oriented, users still receive the
monolithic application |
|
Just like structure programming,
the object-oriented approach is at the service
of the functional developer, not the end user.
Moreover, the development using object-oriented
approach with C++ allows for only "development-time"
reuse i.e. developers could use the pieces designed
and coded (classes and objects) by other developers.
It didn't address the issues related to assembly
and deployment aspects.
Here, is the good news! The new specification
from OMG®, CORBA3.0 component model (CCM)
supports components in C++ as well as leverages
and enables the concept of application development
by assembly of prebuilt software components. Note
that such a business component is the software
implementation (binary) of a single business concept
(or business process) and it is treated as unit
of deployment.
Now, you can develop standard-based,
cross-platform components in C++ with development
and deployment environment based on CORBA3.0 Component
Model (CCM).
The component based development
is a comprehensive approach to software manufacturing.
It covers all aspects of software development,
from conceiving and building individual components
to the cost effective assembly of components into
systems. It also provides an excellent way to
partition of business domain.
In component based approach,
both developers and users have same viewpoint
of the application as described below:
|
| In CBD,
both developers and the users have common viewpoint
of the application |
|
The components and assembly are highly visible
at runtime. This will help the end user
to understand how the software is built, assembled,
deployed and evolved. This helps to resolve the
limitations posed by object-oriented techniques
as mentioned earlier.
The 3-tier component based architecture
implemented with configurable C++ CCM components
will solve a number of problems that are inherent
to rich client architectures. The 100% componentization
of the enterprise architecture will support :
-
Clear separation of user-interface-control
and data presentation from application-logic.
Componentization also supports further splitting
of "application logic" tier into two parts.
Through this separation more clients are able
to have access to a wide variety of server
applications. The two main advantages for
client-applications are: quicker development
through the reuse of pre-built business-logic
components and a shorter test phase, because
the server-components have already been tested.
-
In contrast to the 2-tier
model, where only data is accessible to the
public, business-components can place applications-logic
or "services" on the net enabling service-oriented
architecture (SOA)
-
As a rule, servers are "trusted"
systems. Their authorization is simpler than
that of thousands of "un-trusted" client-PCs.
Data protection and security is simpler to
obtain. Therefore it makes sense to run critical
business processes that work with security
sensitive data, on the server.
-
Dynamic load balancing, fail-over:
if bottlenecks in terms of performance occur
or system failure, the server process can
be moved to other servers at runtime.
-
Re-definition of the storage
strategy won't influence the clients. RDBMS'
offer a certain independence from storage
details for the clients. However, cases like
changing table attributes make it necessary
to adapt the client's application. With CCM,
even radical changes, like let's say switching
form an RDBMS to an OODBS, won't influence
the client. In well designed systems, the
client still accesses data over a stable and
well designed interface which encapsulates
all the storage details.
-
Change management: of course
it's easy and faster to exchange a component
on the server than to furnish numerous PCs
with new program versions
-
It is relatively simple to
use wrapping techniques in 3-tier architecture.
As implementation changes are transparent
from the viewpoint of the client, a forward
strategy can be developed to integrate with
third-party systems smoothly.
With CCM, next generation C++
applications can adopt component based development
to ensure cost reduction and productivity enhancement.
The K2 Component Server combines the runtime performance,
code size of C++ with the component/container
model of CCM. K2 is well suited for addressing
the high performance need of engineering applications.
These component-based systems are built
for future upgrades, web enabling, integration
with legacy systems, service oriented architecture
(SOA) etc. The systems with component
architecture based on CCM/C++ will reduce the
software maintenance cost and ensure software
longevity.
|
| CCM
as a component model for C++ |
|
CCM vs. J2EE
CCM provides several advanced
component features over EJB. In fact, CCM joins
together the best of NET and J2EE component models.
The table below explains the language support
by CCM and J2EE.
| # |
Component
Model
|
Language
supported
|
|
C/C++
|
Java
|
| 1. |
J2EE |
X
|
ü
|
| 2. |
CCM |
ü
|
ü
|
Note: * Even FORTRAN, COBOL code could be
made available as component using CCM.
CCM overview
CCM supports the framework for
component definition, code generation, packaging,
assembly and deployment C++ components. It supports
four types of C++ components i.e. Session, Service,
Process and Entity. It is important to note that
C++ components itself are not " executables "
anymore i.e. they are DLLs which can only be executed
within the CCM server. The figure below describes
a component.
Ports
There are four types of ports defined in CCM
which are explained below:
| # |
Ports |
Definition |
Symbol |
| 1. |
Facets |
Facets
are distinct named interfaces provided by
the component for client interaction. i.e.,
Components exposes named interface as surface
feature using which other client applications
can interact by explicit connection. Using
facets a component can give multiple object
references. |
|
| 2. |
Receptacles |
Receptacles
are named connection points that describe
the component's ability to use a reference
supplied by some external agent. Receptacles
make use of the reference provided by the
Facets. |
|
| 3. |
Event
Source |
Event
Source are named connection points that emit
events of a specified type to one or more
interested event consumers, or to an event
channel. |
|
| 4. |
Event
Sink |
Event
sink are named connection points into which
events of a specified type may be pushed. |
|
Note : The facets and receptacles
can be connected together to provide synchronous
connections. The emitters (events source) and
consumers (event sink) also can be connected together
to provide asynchronous connections between two
components. The above process of composing components
is known as component assembly. The assembly can
be achieved using graphical user interface tool
that interacts with user to capture assembly information.
The tool can be used to deploy the component assembly
into a runtime environment, which handles automatic
connection of components.
Now, UML 2.0 also supports the
component diagrams for business application development.
UML 2.0 component diagrams are great for initial
architectural modeling efforts as they enable
you to model the high-level software components,
and more importantly the interfaces to those components.
Once the interfaces are defined, and agreed to
by the team, it helps in organizing the development
effort between subteams.
|
| K2
Component Server |
|
K2 tools help in complete process of component based
development (CBD) of C++ components i.e. designing,
developing, packaging, assembly, deployment, management
and execution of distributed C++ components.
No other products have CORBA3.0
Component Model capabilities, like K2. K2 provides
the technology advantages that customers expect
such as support for component-based development,
component composability, component reuse savings,
and component isolation for architecture integrity.
|
| Develop
Mission Critical Applications as assembly of re-usable
components |
|
There are several mission critical
applications developed and deployed using C++.
K2 CCM enhances the capability of such C++ application
further via component architecture. There is growing
interest to use CCM for high performance, component
solution in domains such as Aerospace, Telecom/Wireless,
Banking/Finance and Manufacturing etc. for solving
problems related to High Performance Computing
(HPC) applications, Workflow applications, large-scale
legacy integration and large data volume applications.
The CCM based component architecture
will enable application development by "assembly
of components". Such applications (i.e. assembly
of components) could be further used as a "component"
in other applications. So that, the resulting
application consists of "assembly of assemblies".
The figure below defines the
component architecture for a " Satellite
Managed System " consisting of assembly of
components where each components is autonomous
deployment units.
|
| Runtime
view of component architecture for a mission critical
application |
|
K2 Component Server provides
development & deployment of C++ components
in high performance component runtime environment.
It also provides QoS capability to meet operational
requirements of mission critical applications
such as clustering, multi-level fault tolerance,
load-balancing, logging etc., ensuring performance,
reliability, scalability and high availability.
In addition, K2 provides unified
platform for component based development and "integration"
supporting both synchronous and asynchronous programming
model. Now, the enterprises could integrate their
systems by "componentizing" the application around
K2 CCM. With K2, enterprises can use component
assembly instead of complex "integration" techniques.
CCM supports concept called "ports" which are
useful for assembly purposes. This makes out of
the box integration possible with "K2 Assembly
Tool" i.e. no coding is required for making inter-connections
between components (written in different languages
such as Java, C++ even COBOL) for developing applications
supporting both synchronous and asynchronous communications.
|
| Component
development process for C++ components |
|
The K2 CCM supports a highly
reuse-focused development lifecycle throughout
all stages of development. When the business component
approach is fully applied, a new project should
be able to reuse various levels of software artifacts
at defined points in the lifecycle. This includes
business component system models and business
components, including their design models, the
source code, the executables (fully tested), and
even guides for deployment and use.
The figure below, describes the
overall component development process consisting
of architecture, design, implementation, assembly
and deployment.
|
| Process
of developing & deploying C++ components |
|
Also, this development process
ensures testing at different levels such as interfaces,
components, assembly etc. Assembly (integration)
is no longer planned at the end of the implementation
phase, but planned early and be continually managed
throughout the development process.
This approach enables high level
of concurrency in all phases of development, due
to partitioning of the project into business components
and the separation of concerns allowed by a strong
architecture-centric approach.
The functional specification,
analysis, design, implementation, and testing
of business components can be done to a large
extent independently from each other. For example,
the most used (and reused) business components
in the system can be fully stabilized, so providing
for better quality control from the bottom up.
And the application developers will focus entirely
on their core competence, developing functional
components, while technical developers focus on
evolving the technical architecture.
|
| Component
& Assembly Deployment Model |
|
CCM provides the most advanced
component and assembly deployment model for C++
components. K2 CCM provides a container based
deployment model for C++ components which provides
a high performance runtime environment. The "collocation"
mechanism is used to improve the performance and
predictability of communication among collocated
components of the assembly application. The term
"collocation" can be treated as a unit
of deployment. This unit could be
-
"Process collocation" i.e.
group of components which have to be deployed
on the same CCM server process
-
"Host collocation" i.e. group
of components that have to be deployed on
the same hosts
-
"Free" components which are
not part of "process collocation" or "host
collocation" and could be deployed in any
manner
The deployer can group components
that are to be deployed on a particular CCM server
i.e. process collocation or on a particular node
i.e. host collocation. The components may be free
or partitioned to a generic set of hosts and processes.
As it's clear by definition of collocation, all
the components that are part of any collocation
definition (deployment unit) must support the
target destination, i.e. host (Windows/Linux)
or CCM servers or as programming language (C++)
etc.. The table summarizes the various collocation
(deployment) definitions such as:
| # |
Collocation
Definition |
Description |
| 1. |
Two
prcess collocation and single host collocation
In
this deployment strategy, all the components
of the assembly are put into two process
and one host as described in the figure.
|
|
| 2. |
Six
process collocation and Three hosts collocation
In
this collocation definition, components
of the assembly are put into six processes
across three nodes as described in the figure.
|
|
The K2 CCM deployment model extends a sophisticated
runtime environment to migrate from library based
deployment model to container based deployment
model.
|
| Evolution,
Customization and maintenance of C++/CCM based component
systems |
|
Organizing the whole development
process around components is a powerful mechanism
for reducing the complexity and costs for all
phases of development. Such a reduction is particularly
noticeable in system evolution, since many system
changes or corrections affect only a singly component.
In fact, it's quite common for
the system built using traditional approaches
go through a cycle as described below. A modification
request may affect only one module, but implementation
of the modification ends up impacting several
modules. Sometimes, the entire application needs
to be re-deployed.
Source: Business Component Factory
Using C++/CCM component-based
approach, the same cycle becomes as shown below.
In this case, the modification usually impacts
only the component that is affected by the modification
request and it is possible to re-deploy only the
impacted component. This is a great benefit that
is particularly important for large systems.
CCM supports the concept of ports
(such as facets, receptacles, event source and
event sinks), which are used for assembly. During
an upgrade or replacement of a component in an
assembly, assembler uses these ports for configuration
without worrying about the underlying implementation.
The "maintenance by parts substitution"
is possible to achieve in C++/CCM environment
as applications are developed as "assembly of
components".
|
| Key
Benefits of Component Based Development with C++ |
|
The enterprise-wide use of CCM and K2 will help
in realizing the ideas such as "Component Factory"
and "Component Repository". The repository can
be used to set up an efficient software development
capability-the business component factory-and
enhance the ability to manufacture quality software
at industrial levels quickly and cost-effectively.
This will also ensure reusable components for
future uses.
In contrast to the 2-tier model,
where only data is accessible to the client, component
architecture with business-components can place
applications-logic or "services" for the client
applications.
The component based system is
designed and built to ensure software upgrade
and maintenance capability. These capabilties
include support for dynamically adding new features,
web enabling, integration with legacy systems
and support for SOA. These are the key factors
which will ensure the longevity for component
based systems beyond the life of a tradional software
system.
Moreover, it will also help in reduced
time to market, reduced skills requirements wih
enhanced focus of expertise on domain problems.
The CIOs and CTOs of the Fortune
Global 2000 companies are finding that K2 CCM
based applications is enabling "Reuse" and "Assembly".
It is possible for the enterprises to implement
the component architecture with C++/CCM for large-scale
projects to ensure software longevity and cost
reductions.
Is your organization ready to
transition to the business component approach
to achieve cost-effective software manufacturing?
Write to us if you would like
to use component based approach (using C++/CCM)
to develop IT facilities for your strategic business
needs. Please feel free to ask for a demonstration
by our engineers or a prototype. Our team is equipped
to help your team with onsite training & mentoring
as well as joint-development.
|
| References |
- Business Component Factory by Peter Herzum
and Oliver Sims
- CORBA 3.0 fundamentals and Programming by
John Siegel
- Software Architect Bootcamp by Raphael Malvaeu
and Thomas Mowbray
- OMG CORBA 3.0 Specification
- K2 Component Server white paper
|
|
|
| |
| |
|
|
 |
|