7

The image of decoupled (two train cars separated) is clear. In computer science, writing "decoupled" code is a Good Thing, it implies breaking code into discrete pieces that can be tested independently, but put together easily.

What would be the opposite, in this context? Coupled is an obvious answer, but that seems to be more the fact of pieces being put together. I'm looking for something that represents bad design, such that pieces are too tightly integrated and can't be split apart.

Monolithic is the best I can come up with, but isn't great. Monolithic could be something that can/should be broken up, but could also mean something that can't/shouldn't be broken up. I'd ideally like something that is unambiguously negative, if possible.

4
  • 10
    "Tightly-coupled" would be the other extreme. (And I'm not sure you can find something that is unambiguously negative since tight coupling is often a good thing.)
    – Hot Licks
    Commented Jul 18, 2015 at 19:29
  • Another term that maybe fits your needs better and is generally considered negative is "poorly structured".
    – Hot Licks
    Commented Jul 18, 2015 at 19:32
  • The connotation of any potential answer will vary greatly depending on the context. Given a particular programming paradigm, language, platform, and level of abstraction (i.e., the entire application vs. the subcomponents thereof), a term like "monolithic" or "tightly coupled" might have implications ranging from inevitable to practical to outrageously awful. Commented Jul 19, 2015 at 20:37
  • 1
    "Coupled" in this context is more than putting pieces together, it's not being able to pull them apart. Commented Jul 19, 2015 at 22:17

8 Answers 8

11

I had considered suggesting spaghetti coding as accurately characterising something which was hugely entangled and not easily disentangled, but I found that it appears as part of an even better term.

Jeff Attwood quoted a 1997 paper by Brian Foote and Josef Yoder:

The architecture that actually predominates in practice is the Big Ball of Mud.

A Big Ball of Mud is haphazardly structured, sprawling, sloppy, duct-tape and bailing wire, spaghetti code jungle. We've all seen them. These systems show unmistakable signs of unregulated growth, and repeated, expedient repair. Information is shared promiscuously among distant elements of the system, often to the point where nearly all the important information becomes global or duplicated. The overall structure of the system may never have been well defined. If it was, it may have eroded beyond recognition. Programmers with a shred of architectural sensibility shun these quagmires. Only those who are unconcerned about architecture, and, perhaps, are comfortable with the inertia of the day-to-day chore of patching the holes in these failing dikes, are content to work on such systems.

"Big Ball of Mud" and "spaghtetti coding" are unambiguously negative and rather pejorative; calling something "entangled" is probably a diplomatic understatement.

10
  • "Big Ball of Mud" is certainly negative and descriptive. I've never seen it used before, though. You mentioned disentangled, which brings up "entangled" which seems very appropriate. Can you add entangled as part of your answer? Commented Jul 18, 2015 at 16:15
  • 4
    "Spaghetti coding" is something else. And I've never (in 50 years in the industry) seen "big ball of mud".
    – Hot Licks
    Commented Jul 18, 2015 at 19:30
  • 3
    My only criticism of this response is that code does not have to be spaghettified to exhibit tight coupling; any two pieces of code that share state through globals are tightly coupled, even if the individual pieces are otherwise well-structured.
    – John Bode
    Commented Jul 19, 2015 at 14:07
  • 1
    The Big Ball of Mud, while often exhibiting tight coupling, is not itself a synonym thereof. This answer is simply incorrect, though evocative. Commented Jul 19, 2015 at 16:52
  • 1
    As a programmer (10+ years) I've never heard of the Big Ball of Mud! I have heard of spaghetti code (a term much more popular than Big Ball of Mud according to Google). However, in normal (semi-formal) conversations I would always use "tightly coupled." So again, as other have in these comments, I would recommend against using big ball of mud!
    – Roy T.
    Commented Jul 20, 2015 at 7:12
22

I've only ever heard "tightly coupled", used as a criticism of systems like this, usually to justify the integration of some "dependency injection" framework.

4
  • Me too, I was hoping someone had a more creative word/phrase! ;-) Commented Jul 18, 2015 at 16:20
  • 2
    Terms like "dependency injection" make me cringe more than "tightly coupled".
    – Hot Licks
    Commented Jul 18, 2015 at 19:30
  • @HotLicks why ? DI is great for testing large code bases. Commented Jul 20, 2015 at 9:34
  • @NimChimpsky - Because it's too often used as a substitute for good design. And at least half the time that someone claims to have used the [insert buzzword here] technology they haven't, but have only abused the terminology.
    – Hot Licks
    Commented Jul 20, 2015 at 11:53
11

Coupled is indeed the opposite. More commonly, however, one speaks of the different degree of coupling (Wikipedia) between given pieces of code. A and B are loosely coupled. C and D are tightly coupled. E and F are completely decoupled.

Search for "coupled" on the same Wikipedia page, to see how it is used.

2

Blob
It is a well known antipattern and sounds unambiguously negative.

http://www.antipatterns.com/briefing/sld024.htm
https://sourcemaking.com/antipatterns/the-blob

1

I don't know if there's a jargon term, but "interdependent" might work.

(of two or more people or things) dependent on each other.

1

The tightest coupling pattern is known as "Content Coupling", in which code unit A relies on the internal workings of another code unit, B, making it difficult to change B without breaking A.

There is something of a continuum, listed below from strong/tight (worst) to weak/loose.

  • Content coupling
  • Common coupling
  • External coupling
  • Control coupling
  • Stamp (or Data-structured) coupling
  • Data coupling
  • Message coupling
  • No coupling

No useful system can be written without some coupling. The objective is to write in as weakly coupled a manner as possible while still making the system do something useful.

The term "coupling" goes back at least to 1974, when Stevens, Myers and Constantine wrote about it in the IBM Systems Journal (doi:10.1147/sj.132.0115). There are a number of type or degrees of coupling rather than a single synonym/antonym relationship. Yourdan and Constantine developed the concept further in 1975 and then 1979 ( ISBN 0-13-854471-9).

The Wikipedia article mentioned by @Drew (in English at https://en.wikipedia.org/wiki/Coupling_%28computer_programming%29) is a good resource.

1

How about 'legacy system' or 'entangled legacy system'.

This implies that it's been there a long time, and has got... intertwined.

Potentially usefully, it also clearly states that it's not your fault...

...because it's been there a long time, right?

And implies perhaps, that that management should pay, to sort it out...

😊

It's quite an adult, mature expression, it doesn't point the finger at anyone, (just - away from you!) and it is clear enough and formal enough, to use in business.

0

You perhaps could try "conflated"

3
  • "Conflated" means combined, which is not the same as linked.
    – deadrat
    Commented Jul 19, 2015 at 5:52
  • You should consider adding a definition to your answer.
    – Dog Lover
    Commented Jul 19, 2015 at 8:37
  • The question was about computer coding. If two pieces of code are decoupled, they are independent and are not combined. If they are combined by linking (deadrat's example) or by any other means such as merging or shared dependencies they are no longer independent and may be considered as combined. Hence, conflated is appropriate.
    – Anton
    Commented Jul 20, 2015 at 12:02

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .