Cloud Computing and SOA Convergence in Your Enterprise: A Step ...
Cloud Computing and SOA Convergence in Your Enterprise: A Step ...
Cloud Computing and SOA Convergence in Your Enterprise: A Step ...
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
Test<strong>in</strong>g from the <strong>Enterprise</strong> to the <strong>Cloud</strong>s <strong>and</strong> Back 169<br />
logical service. In some cases, we may be test<strong>in</strong>g a service that calls a service<br />
that calls a service, where some of the services are developed <strong>and</strong><br />
managed <strong>in</strong>-house <strong>and</strong> some exist on cloud-based systems that we do<br />
not control. All use cases <strong>and</strong> configurations must be considered.<br />
Services should be tested with a high degree of autonomy. They should execute<br />
without dependencies, if at all possible, <strong>and</strong> be tested as <strong>in</strong>dependent<br />
units of code us<strong>in</strong>g a s<strong>in</strong>gle design pattern that fits with<strong>in</strong> other<br />
systems that use many design patterns. While all services cannot be all<br />
th<strong>in</strong>gs to all conta<strong>in</strong>ers, it is important to spend time underst<strong>and</strong><strong>in</strong>g<br />
their foreseeable use <strong>and</strong> make sure those are built <strong>in</strong>to the test cases.<br />
Services should have the appropriate granularity. Do not focus on toof<strong>in</strong>e-gra<strong>in</strong>ed<br />
or too-coarse-gra<strong>in</strong>ed services. Focus on the correct granularity<br />
for the purpose <strong>and</strong> use with<strong>in</strong> the <strong>SOA</strong> us<strong>in</strong>g cloud comput<strong>in</strong>g.<br />
The issues related to test<strong>in</strong>g are along the l<strong>in</strong>es of performance more<br />
than anyth<strong>in</strong>g else. Too-f<strong>in</strong>e-gra<strong>in</strong>ed services have a tendency to bog<br />
down because of the communications overhead required when deal<strong>in</strong>g<br />
with so many services. Too-coarse-gra<strong>in</strong>ed services do not provide the<br />
proper values to support their reuse. We must work with the service designer<br />
as well as developers on this one.<br />
What do we test for with<strong>in</strong> services It is important to follow a few basic<br />
pr<strong>in</strong>ciples.<br />
First, services should be tested for reuse (reusability). Services become a<br />
part of any number of other applications <strong>and</strong> thus must be tested so they<br />
properly provide behavior <strong>and</strong> <strong>in</strong>formation but are not application or technology<br />
specific. This is a difficult paradigm for many developers, s<strong>in</strong>ce custom<br />
one-off software that digs deeply <strong>in</strong>to native features is what they have<br />
used for most of their careers. Thus, the patterns must be applicable to more<br />
than a s<strong>in</strong>gle problem doma<strong>in</strong>, application, or st<strong>and</strong>ard, mean<strong>in</strong>g we must<br />
have use for our reusable service, <strong>and</strong> it must be <strong>in</strong> good work<strong>in</strong>g order.<br />
To test for reusability, we create a list of c<strong>and</strong>idate uses for the service—<br />
for <strong>in</strong>stance, a shipp<strong>in</strong>g service that plugs <strong>in</strong>to account<strong>in</strong>g, <strong>in</strong>ventory, <strong>and</strong><br />
sales systems (see Figure 9.2). Then, the service should be consumed by the<br />
client, through either a real application (<strong>in</strong> a test<strong>in</strong>g doma<strong>in</strong>) or a simulator,<br />
<strong>and</strong> the results noted.<br />
In addition, the service should be tested for heterogeneity. Web services<br />
should be built <strong>and</strong> tested so there are no calls to native <strong>in</strong>terfaces or platforms.