Domain Modelling in Vide

August 19th, 2009

I recently discovered Vide (www.vide-ist.eu/index.html), an academic project funded by the EEC. It is meant to cover all of model development from domain modelling all the way down to code generation. It’s based on MDA – Model Driven Architecture (from OMG) – and since MDA is in turn based on UML, and I have been a tad critical of UML, you might guess that I am not a fan. But the top level modelling – called CIM (Computation Independent Model) by OMG and domain modelling by everybody else – more or less covers the area of Polyphony and has little or no dependence on UML, so I was interested in how they would do this.

Domain modelling in Vide has four parts – data view, organization view, business rule view and process view. The data view shows data entities like Polyphony except they call them data objects not data entities. The organization view has roles like Polyphony, but also you can add organization units and actual individual people. I can’t see the point of putting individual people in the model or organization units. If the project needs this information it is inconceivable that the information is not already in the Human Resources system so what’s the point of putting them in the domain description of the IT application.

The big difference lies in how the activity is modelled. They use business rules and processes while I use processes, tasks, screens and screen actions. I have several problems with their approach.

  • It is hard to see the tasks in their scheme. Tasks are a fundamental building block in businesses and it is hard to understand error handling without understanding the tasks.
  • It is possible for the process definition and the business rules to overlap – i.e. define the same thing. Deciding how detailed to make the process definition I don’t think will be easy. You can define an action in two ways; you can define how you do it or you can define the outcomes. Process flows take the former approach and business rules take the later approach. I feel uneasy about mixing the two approaches in one specification.
  • It is hard to see where data is created, updated or deleted. There are no diagrams to show any of this.
  • It is hard to understand 100+ business rules. 1000+ (perhaps 10,000+) is a more probably figure for a real life application. There has to be some way of organizing the rules.

They no doubt have several problems with my approach and I suspect that one of them is that I don’t use a formal language for expressions – just plain old English (French, etc). There are several reasons for my approach. One is that I suspect some actions or expressions are complex and can be more easily expressed in English than boolean logic. Another is that it allows the user to mark uncertainty or add a comment – they can leave the precise specification for later. At some time in the future I plan to extend Polyphony model to generate code, but instead of using a formal specification language, I will only generate skeleton code and have the programmers look at the English in the action specification and write Java (or whatever) directly.

The Twenty Year Gap

August 18th, 2009

When I started programming in the 1970s, my boss told me how much he loved the days when he used to program in machine code. You could never make a syntax error, he told me. Every instruction was valid. And even better, the machine had a loud speaker and played a note for every instruction, so you could make it play tunes! I thought he was batty. In those days, it was a palpable sense of progress. You could see the progression from machine code (1GL – first generation languages), to assemblers (2GLs), to programming languages (3GLs) like COBOL and Algol.  Then in the 1980s 4GLs came in. Whereas almost all 2GLs programs were replaced by 3GLs programs, only a proportion of 3GLs were replaced by 4GLs. No 4GL became dominant like COBOL had become dominant. In the 1980s there was much talk of 5GLs. These would be based on AI technology. Except for reports in the press, these had practically no impact on the commercial programming world.

In database technology the story was the same. In the 1970s were hierarchical and network database systems. In the 1980s they slowly started being replaced by SQL database.

In distributed technology, we moved from a single machine attached to terminals in the 1970s to distributed systems in the 1980s, albeit usually in a star-like configuration with branch or departmental servers attached through to the central big iron machines. There were many distributed architectures defined in the 1980s (SNA, OSI, etc). In the 1990s there was DCE, OSF, UI, CORBA, thick clients – frankly all commercial failures.

Data dictionaries were developed in the 1980s. They were rebadged as repositories a decade later. Grand ideas – and many good ideas – but they died with a whimper.

OO programming came into the fore in the 1990s (they had been invented over twenty years earlier). We all learnt new programming languages and absorbed the OO concepts. I now think and design with objects, but actually in most significant ways I always did, because I have always let the program design be driven by the data structures rather than the processing requirements.

So how much has changed over the last twenty plus years. Of course, there is the internet and all that, and hardware is much, much faster. But let’s suppose someone ported the Algol compiler and the editors I used in the early 1980s and added an interface to Windows graphs, and let’s suppose I wrote WeaverBird in this rather than in C++. How much more inefficient would I be using the old tools? I suspect at most 5%. It may even have been easier using the old tools. I miss a good program dump – an analysed copy of the program’smemory when it fails – and I miss the hardware catching index errors caught on individual arrays rather than pointing outside the program memory. So while there have been enormous changes in IT, in the core discipline of programming not much has changed at all. We got stuck in the early 1980s and haven’t moved much since.

New paper on agile development

July 9th, 2009

I have written a new white paper on making agile development more scalable by using a Polyphony model to pin down the business requirements. See the link on the right hand side to download the paper.

Paper on Coherent Design

July 7th, 2009

I have published a paper on the concept of coherent design. I have a belief that it is possible to turn application development into an engineering discipline, but that will only happen if we start making coherents designs. A coherent design is complete, consistent and testable. This paper discusses the principles of a coherent design and why it is important.

The paper can be found under the Design Papers list.

New UML Paper

July 7th, 2009

I have published a critical paper on UML. It can be found by following the link in the Design Papers category. The major problems with UML is that it doesn’t help the design team communicate either with the stakeholders or with the programmers.

WeaverBird Code Reloaded

June 24th, 2009

I have had to reload the WeaverBird software to fix some installation problems. What was happening was that some people were getting a “Side by side configuration error” when they tried to run WeaverBird. After some research, I decided this was probably because I put a debug version of the code on the web site. I think, the error means that a library is missing, and this was because the debug code requires a library that is installed with the Microsoft C++ compiler. Which, of course, explains why it worked for me.

I am of course to blame – but naturally I also think Microsoft could included the libraries in the standard operating system release. So why did I do it? I have come from a tradition where if you run a program twice with exactly the same data, the program does exactly the same thing. This isn’t true in C++. More precisely it isn’t true in the release version of C++, it is true for the debug version! The reason is that debug code fills all variables with (I think) all bits on, and also, when you delete an object, it smears the memory area with another fixed bit pattern. In the release version, this isn’t done, therefore before you put a value in a variable, the variable takes the value of whatever happens to be in memory. In the debug version, the value is consistent – all booleans are “true” and all integers are a large negative number. I think the concept of random defaults has little to commend it; as well as me and Microsoft being at fault so are the C++ standards committees.

So when I compiled WeaverBird again using a release setting, did it fail? Of course it did. They were stupid, trivial errors but they took a day and a bit to fix because debugging in release mode is painful. So sorry – but Arrrggghhh.

Welcome

June 5th, 2009

Welcome to my new blog. It gives me a chance to comment on the what’s happening in IT, and it gives you a chance to put me to rights.