New-age Transactional Systems - Not Your Grandpa's OLTP
John Hugg discusses high volume transaction processing applications with high and low frequency profiles, and how VoltDB can be used for that purpose.
The content has been bookmarked!
There was an error bookmarking this content! Please retry.
Posted by Hartmut Wilms on Oct 09, 2007
MindTouch offers a programming library and standalone server for developing and publishing RESTful web services. Dream "Denim" 1.4.1 has been released last week.
MindTouch Dream is on Open Source Project covered by the Gnu Lesser General Public License Agreement (LGPL). It is written in C# entirely and runs on Microsoft .NET 2.0 as well as Novell Mono 1.2.5. According to Steve Bjorg, co-founder of MindTouch, "the best way to describe it is in guise of a question: 'What would a web-centric programming environment look like if it were built from ground up for a service-oriented world?'”:
There are several key features that set Dream apart from other frameworks for .Net, such as Windows Communication Foundation:
- it’s lightweight
- it’s cross-platform
- it’s built to comply with industry standards
- it’s open source
- and it’s devoid of SOAPiness!
The key concept of Dream is the web service. A web service gets instantiated by the runtime and provides entry points, called "features". Features are invoked by issuing an HTTP request, consisting of the Dream Host base address extended by the service name and a URI pattern as well as an HTTP verb such as GET, PUT, POST, DELETE. A feature is mapped to a CLR method by a Dream Attribute, which defines the verb and the URI pattern:
[DreamFeature("GET:addresses", "Get all addresses")]
public Yield GetAddresses(DreamContext context, DreamMessage request, TaskYieldresponse) {
}
The first parameter of the DreamFeature Attribute defines the verb and the pattern, separated by a colon. Dream services and consumers exchange data in form of XML or binary streams. Normally Dream services expect and deliver XML documents. These documents are wrapped by DreamMessage instances.
The Dream SDK provides an easy to use XDoc class, which wraps the .NET XML classes, in order to alleviate the use and creation of XML documents:
XDoc is the Swiss army knife for all things XML. It is a lightweight wrapper around the XmlDocument, XmlElement, XmlText, and XmlNodeList classes, making it easy to create, query, and compose XML documents. With XDoc, you don't have to know any of the .Net XML classes because all operations result in new XDoc instances, which keeps everything really simple!
Dream provides a set of generic features, available to all services and a core service library "that address common problems when writing any kind of interesting web-services or web-applications".
Dream services can be hosted in a console host application or a custom environment, e.g. NT Service. The console host application provides a command line interface to create a new Dream hosting environment. The Dream hosting environment is implemented by the Dream Host. The runtime might also be hosted within IIS6. Requests will be handled by the included Dream HTTPHandler. The Dream runtime
is responsible for orchestrating all interactions. It is built using the HttpListener class and thus requires no web-server to be pre-installed on the target device. It is responsible for instantiating services, routing messages to them, and short-circuiting service-to-service communication when both are co-located (meaning they are loaded inside the same AppDomain).
Plugs are a convenience feature that allow to switch from HTTP communication to in-memory communication when services are co-located inside the same AppDomain:
Plugs greatly simplifies talking to web resources. Besides replacing WebRequest, plugs also detect when a service is co-located (i.e. hosted inside the same AppDomain). In that case, instead of using expensive serialization/deserialization operations, plugs use direct in-memory communication. Plugs also make it easy to adjust the URI of the target service to specify the desired feature or processing options.
The MindTouch Wiki provides a presentation on the concepts of Dream, an introduction to Service-Oriented Distributed Architecture (SODA), which describes the application programming pattern promoted by MindTouch Dream, and a general introduction to REST web services.
Thanks for this wonderful write-up. It really made my day! I posted about it on our blog: www.mindtouch.com/blog/2007/10/09/infoq-mindtou...
Cheers,
- Steve
John Hugg discusses high volume transaction processing applications with high and low frequency profiles, and how VoltDB can be used for that purpose.
Kevlin Henney examines code samples to see what can be learned from them starting from the premise that one won’t write great code unless he knows how to read it.
Jason Ayers share the observations he made watching a team of developers collaborating in real time on the same code base, pushing XP, pair programming and continuous integration to their extremes.
Michael Snoyman presents Yesod, a web framework written in Haskell and containing a web server, templating, ORM, libraries (templating, gravatar, etc.).
Richard Kreuter and Kyle Banker on how to avoid classical RDBMS transactional systems by using compensation mechanisms, transactional messaging or transactional procedures.
Attila Szegedi talks about performance tuning Java and Scala programs at Twitter: how to approach GC problems, the importance of asynchronous I/O, when to use MySQL/Cassandra/Redis, and much more.
One category of risk that project teams need to ensure they address is business value failure – delivering a product that fails to provide value for the business investor.
InfoQ spoke to the authors of Software Systems Architecture on a couple of new topics, the System Context viewpoint and Agile, which have been added to the second edition.
1 comment
Watch Thread Reply