08.01.2015 Views

Beginning Web Development, Silverlight, and ASP.NET AJAX

Beginning Web Development, Silverlight, and ASP.NET AJAX

Beginning Web Development, Silverlight, and ASP.NET AJAX

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

160<br />

CHAPTER 7 ■ .<strong>NET</strong> 3.0: WINDOWS COMMUNICATION FOUNDATION<br />

WS-Transactions<br />

The WS-Transactions specifications define the mechanism for how applications running<br />

across <strong>Web</strong> Services domains can interoperate in a transactable manner. It is also<br />

designed to provide a means of composing transactional quality-of-service attributes<br />

into <strong>Web</strong> Services applications. The transaction st<strong>and</strong>ards are built on a number of other<br />

st<strong>and</strong>ards, including WS-Coordination for an extensible coordination framework, <strong>and</strong><br />

specific types for different types of transactions, such as short-term atomic ones (WS-<br />

AtomicTransaction) <strong>and</strong> longer-running business transactions (WS-BusinessActivity).<br />

WCF aims to allow these diverse specifications to be programmable using a single attribute-driven<br />

API. Later in this chapter, you’ll build some simple WCF applications that<br />

implement security, reliability, <strong>and</strong> transactability under the hood so you won’t have to<br />

worry about the complexity of dealing with their messaging structure manually.<br />

WCF <strong>and</strong> Service Orientation<br />

Software as a Service (SAAS) is a major initiative for the future of the <strong>Web</strong>. This is an evolution<br />

of Service-Oriented Architecture (SOA), where a paradigm shift in how software is<br />

developed is taking place. Instead of thinking of traditional application development,<br />

developers are encouraged to think about small, nimble, reusable components, <strong>and</strong> to<br />

build these as services that can be exposed reliably <strong>and</strong> securely across the network.<br />

These components can then be assembled into distributed applications. Using next-generation<br />

presentation technology, these applications can provide a great user experience.<br />

At the heart of it all is the question of how we reuse the code that we write. We want<br />

long-term returns on our investments in building software assets—but how do we<br />

achieve this<br />

In the 1980s, object orientation was the craze. It was based on the idea of building<br />

reusable abstract definitions of functionality (called classes), which provided the template<br />

for objects, <strong>and</strong> for more complex inherited objects. So, for example, a class that<br />

defines a type of object called a “car” could be defined, <strong>and</strong> a more sophisticated object<br />

called a “sports car” could derive from this, inheriting (<strong>and</strong> thus reusing) the attributes of<br />

the original “car” class. In a world where code was written procedurally, <strong>and</strong> most reuse<br />

was in cutting <strong>and</strong> pasting code from one routine to another, this was revolutionary. It<br />

brought about new benefits such as polymorphism, where dynamic binding to methods<br />

<strong>and</strong> events could happen at runtime, <strong>and</strong> encapsulation, the facility to hide <strong>and</strong> expose<br />

certain parts of your code to the outside world. However, the drawback was that once an<br />

application was built, it was built, <strong>and</strong> it was static. There was no easy way to put new<br />

functionality into an application other than to recode, rebuild, <strong>and</strong> redeploy it.<br />

Later, the concept of components evolved from object orientation. It was designed to<br />

make the developer think about the external interface of their application <strong>and</strong> how other<br />

people could use it. Now an application could load <strong>and</strong> bind to new functionality at

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!