Despite the lessons from DC-10 planes in 70s, why didn't Boeing ensure their cargo doors didn't fail even until the end of the 80s? In the early 70s, DC-10 planes had disastrous failures with cargo doors. It proved how massive a havoc faulty cargo doors can have on the planes. Despite those two incidents with Boeing 747 planes in the 80s prove that Boeing were not careful enough to avoid problem with the cargo doors. In fact, there is a striking similarity with what happened to DC planes in 1972(a warning) and in 1974(not learned from the warning) and what happened to Boeing 747 in 1985(warning) and in 1987(not learned from warning).

Why didn't Boeing learn from what happened to DC-10 planes?
Most probably because the failure modes were very different. In the DC-10 case the door could appear closed even though the locking mechanism was not properly engaged. On 747 that was not a problem; instead the electric motors opening the door had enough power to break the locking mechanism if electric power somehow made it around the switch that was part of the locking mechanism.

And then, 2 years are not really enough to analyse a problem like this, develop a fix, test it and deploy it. The NTSB investigations alone often take longer than 2 years.