lesscode.org


03 Oct 05
12
36

The New “Application Server”  14

By Ryan Tomayko under Then you win.

I haven’t had as much time to follow the press as I’d like but they seem to be catching on at a frantic pace. Phil Wainewright (of Loosely Coupled fame) has an article up on ZDNet entitled How AJAX kills the Application Server:

An unnoticed side-effect of implementing rich internet application platforms — whether they’re AJAX or anything else — is that this ‘client-service’ architecture eliminates the need for an application server to connect the Web client to back-end resources. Sure, if you’re a company like Zimbra implementing a new resource at the back-end, in its case an email server, then obviously that server is a new addition. But it’s still devolving more processing to the client, so it requires far less horsepower than it would to deliver the same functionality to a wholly web-based client.

The new “Application Server” is a web server, a dynamic language, and templating.

I also like how we’ve decided to call this setup “rich internet application platforms”. Personally, I think “The Web” is a better term, but you can call it “Sponge Bob Square Pants” for all I care. Let’s get on with it.

The industry is realizing that there are very few business applications that you cannot build with this basic set of components. What’s more is that all that is needed to transform the basic setup into an integration platform is to stop thinking about the web as a bunch of “pages” and start using HTTP for what it’s worth.

People everywhere are asking themselves what this mess of crap of technology they’ve accumulated is really doing for them. It’s about time.

14 Comments...

02 Oct 05
00
27

Shared Data and Mobile Data  3

By Alex Bunardzic under Talk

I’ve branched off into the new thread (from Should Database Manage The Meaning? thread ) in order to start from a clean slate. The previous thread still has a number of unanswered questions lingering, and I didn’t want to introduce new ones.

What the lively debate in the ‘database and meaning’ thread revealed to me is that a number of people appear steeped in the shared data model/architecture. They’re all talking about multiple applications hitting a single database, and how that peculiar situation dictates stringent demands on what the database must be and how it must behave.

I come from a different world. In my world, the data is not sedentary, it is mobile. It travels places. As such, it is not shared, it gets to be exchanged.

Now, as you will no doubt have no problem imagining, if two or more apps are exchanging data, they don’t care where is that data coming from. Let’s say they all exchange the data using some sort of a schema (XML schema, most likely). What ends up happening is that data starts travelling back and forth (mobile data). The receiving apps have no way of ’sniffing’, or figuring out whether the data that had just arrived is coming from a fuly normalized RDBMS, or from a flat file, or from an email server, or from a legacy data store (Domino), or from some hairy brained hierarchical mainframe database, or what have you.

So, this is the reason why I’m so befuddled upon learning that so many people regard RDBMS as a holly grail. What difference does it make, once the mobile data hit the street?

3 Comments...

29 Sep 05
16
10

Should Database Manage The Meaning?  51

By Alex Bunardzic under Talk, Theory

I couldn’t resist jumping into the Choose a single layer of cleverness discussion, that is raging on David Heinemeier Hansson’s blog. The majority of the challenges to David’s thesis were so widly off mark, that it had left me completely bewildered. What’s even more bewildering, to me at least, is that many of the misplaced comments seem to be coming from established Ruby and Rails practitioners.

Anywho, the comment that got my particular attention is quoted below; my full reply is reproduced below the quoted comment:

“Just like I’d expect my operating system to respond if I try to write to a file I don’t have permission on, I want my database server to manage the basic rules of the DATA, ie, what relates to what, and which columns should be unique. This is to prevent anything out of the ordinary from affecting the consistancy of the database. The minute you let bad data get in there is the minute any maintainability you love in your application tier goes to hell.”

Bzzzt! Right here, we have the crux of the problem.

I think the cognitive discrepancy lies in equating RDBMS with an operating system. Nothing justifies that parallel.

If we step back and look at what RDBMS is, we’ll no doubt be able to conclude that, as its name suggests (i.e. Relational Database Management System), it is a system that specializes in managing the data in a relational fashion. Nothing more.

Folks, it’s important to keep in mind that it manages the data, not the MEANING of the data!

And if you really need a parallel, RDBMS is much more akin to a word processor than to an operating system.

A word processor (such as the much maligned MS Word, or a much nicer WordPress, for example) specializes in managing words. It does not specialize in managing the meaning of the words.

So who is then responsible for managing the meaning of the words? It’s the author, who else?

Same is with Rails. Rails is the author of the data. As an author, it uses the RDBMS to manage that data in a relational fashion. But, just as we, as the authors of the words, do not expect WordPress to manage the meaning of our words, Rails does not expect the RDBMS to manage the meaning of its data.

As a matter of fact, it would be really terrible if those tools would assume the management of the meaning of the information that is being fed into them. Imagine typing up a letter, only to be jolted when your favorite editor refuses to take the word you’ve just typed, deeming it ‘incoherent’, or ‘not complying with certain constraints’. You’d toss that piece of junk out the window in no time.

Why should Rails developers be any different? Why should we tolerate RDBMS opinions on our data? We’re the masters, RDBMS is the servant, it should shut up and serve. End of discussion.

As for the ongoing ‘the sky is falling’ discussion about what if some other device accesses the RDBMS, it’s the same dilemma as ‘what if some other person accesses our document, and starts changing it?’ There are ways to manage that. Yes, we’re always exposed, always vulnerable to all kinds of attacks, but that’s how life is. You should start getting used to it by now.

51 Comments...

28 Sep 05
20
09

Lesscode using Domain Specific Languages (DSL)  16

By Mitch Barnett under Talk

Having spent some time in the VS2005 environment, I can say the following about DSL’s:

A domain-specific language (DSL) is a language designed to be useful for a specific task in a fixed problem domain, in contrast to a general-purpose language. DSLs are gaining popularity in the field of software engineering to enhance productivity, maintainability, and reusability of software artifacts, and enable expression and validation of concepts at the level of abstraction of the problem domain.

Using domain-specific languages, one can build customized modeling tools and essentially define a new modeling language and implement it very simply. For example, a specialized language may be used to describe a user interface, a business process, a database, or the flow of information, and then used to generate code from those descriptions.

I built a (small) DSL for modeling application integration scenarios, which is always an issue in the IT business world. First, I defined all of the specific domain model terms used in application integrations scenarios such as XML messages, source – destination applications, XSL maps, business units, protocols, business rules, etc. Then I described the designer definitions that make up the visualization tool. Once the meta data was defined in a supplied Visual Studio template, you build the solution and another instance of Visual Studio fires up with your visual designer implemented.

You then use the visual designer you just created to draw/model the application integration scenario and when you run this solution, it code generates the solution.

Of course, I have left out a lot of detail and it was not easy the first couple of times. I have left out a set of code generators, which take a domain model definition and a designer definition as input, and produce code that implements both of the components as output. The code generators also validate the domain model and designer definition, and raise errors and warnings accordingly. But eventually, you get the hand of it.

Think of it this way, DSL is a tool for building tools :-) For example, anyone that has used the Class Designer in Visual Studio is using a DSL outputted visual designer, specifically designed for building classes.

The process has been quite the learning experience for me and has proven to be very enlightening. I am an old guy, been writing code for 15 years. Quite frankly, I don’t give a hoot about which programming language I use cause I see them all as being the same, some better than others, but still hand crafting code. I don’t want to hand craft code anymore – every time I get involved in a software development project I a) have done it before and b) oh man, this is going to take 6 months of grinding it out. In other words, it’s gonna hurt.

I see DSL’s as a evolution in our software industry to use higher level abstractions in the way of visual designers to so that I can spend time “designing” the solution and have most of the infrastructure code generated for me, that I otherwise would have to grind it out.

If anyone is interested in more information about DSL’s and don’t mind reading it from Microsoft, download the DSL Toolkit and have a read of the documents at: Microsoft Domain-Specific Language (DSL) Tools

16 Comments...

15
29

Lesscode Is Not About Quantity  13

By Alex Bunardzic under Talk

A number of people that are making the painful transition to lesscode seem to misunderstand the underlying philosophy of the movement. For some reason, some of them get hung up on the quantity (read: number of lines of code). But, by doing that, I’m afraid they are completely missing the boat.

Let me state it in no uncertain terms: lesscode is not about the number of lines of code. In other words, we can revisit some legacy app and rewrite it so that in the end it results in dramatically smaller amount of lines of code, and still not produce an app that would qualify as being ‘lesscode’ worthy.

So if not the number of lines of code metric, what then would qualify an app as being a bona fide lesscode product?

The thing that often gets overlooked when we’re talking about the lesscode discipline is that there is a qualitative aspect to it. Yes, the most obvious factor that hits us upon inspecting a typical lesscode app is the drastically reduced number of lines of code, but that phenomenon is merely the outcome of some deeper, less visible causes and conditions underlying the discipline. We need to now expose and examine those causes and conditions (and stop fixating on mere symptoms):

  1. Je ne sais quoi (“I know not what”) – the indefinable quality. Christopher Alexander calls it Quality Without A Name

    This sounds like a bailout answer; however, it’s actually very true. Lesscode is qualified by something that is utterly satisfying, yet no one can put their finger on it.

  2. Language choice – the language we choose for writing the code determines how we think about designing and programming. Choosing to write code in Assembler or in COBOL would not be very conducive to producing the lesscode app that would be utterly satisfying.

  3. Smart Servant – if the platform/language of our choice is very needy, very fussy and expects us to exert exorbitant amounts of effort just to keep it from throwing a fit any time something changes, that situation will not be very conducive to producing a lesscode worthy product.

What we really need if we are to practice the discipline of lesscode is a Smart Servant product. What that means is that such a product must be very non-intrusive and very supportive of our flakey short term memory. The only realistic way to develop a truly lesscode app is to work in an environment that minimizes the cognitive friction.

13 Comments...