Hacker News new | ask | show | jobs
by aidanr 1880 days ago
UML as a way of detailing the low level implementation of a system was, IMHO, a really bad idea. I say that as someone who once drew up all the GoF patterns in UML in Borland Together and then tweaked the generated Java code to do have running Java code for what the patterns said.

But there is a world of difference between "UML as a sketch" and using a diagram to constrain what actual code your co-workers actually write.

Sure – Fowlers’ UML Distilled is still handily placed on my bookshelf but even from when I first read it, I knew that I was never going to draw class diagrams from three perspectives (conceptual, specification ad implementation – leaving aside the GoF practice above). And in the 20+ years experience since UML became a standard I don’t think I ever did.

But turning it around, what diagrams do you draw when - You are in front of a whiteboard and are trying to communicate with half a dozen (maybe microservce based) teams that you need X to happen before Y but the daft business require you to pass a new bit of data through 3 of the systems to implement this. - You are in front of whiteboard with some of the newer members of your development team trying to work through what parts of their development can run in parallel and what parts must be serial (because the product owner is new and can’t get to that level of detail in words or drawings) - You want to explain to the business that one of "these" will own many of "those" unless (and if you are getting ambitious in your whiteboarding) the guard condition is that it is a pink moon or its aries ascendant

Me – I want one "diagramming language" to realise my witterings in. And that one "language" was always sketched UML for the last 20 years.

Sure – if I was a database designer implementing a problem with a relational database I might well use a ER diagram. But that is simply acknowledging diagrams are so much better than words for sharing ideas and the diagrams should be appropriate to the level of abstraction being dealt with.

As a previously enthusiastic Scala user, I'd say that the role for UML has been _very slightly_ decreased by the shift to functional from OO. But not much. The functional example of "map X to Y except when ..." is really about implementation detail and I think most people are happy not diagramming at that level now.