what I have been doing with upgrading is taking more expensive ships that have served there usefulness and instead transforming them on the spot into something that is more regionally useful to me.
Taking ships and changing them into either a constructor, transport, or colony ship. Usually I'm getting free ships from anomolies, so I xfer those ships into one of the other 3 types previously mentioned when needed.
The ship I am xfering to is a bare bones ship with nothing fancy on it but the component part and maybe 1 engine, if that. I'm presuming that the ship got to where it needs to go and needs to activate that ability where its at.
If I have a small ship, and want to xfer it into one of the above types, I can redesign a specific ship just for this purpose, that is a small class ship. This upgrading because I'm not adding all the other parts that make the ship expensive is why its so cheap.
I recently got doom phasers in my game, which do amazing dmg and I got a survey ship that didn't have weapons. So I made a ship that was all decked out and its manufacturing cost was like 1800 to build it, and would of cost me like 6 K to xfer that survey ship into it. I looked at how expensive it was and even though I could afford it I felt it was a waste of money, instead paying like 388 credits to upgrade the survey ship with passable weapons.
If your trying to get all the bells and whistles or upgrade your old ships, it could get prohibitively expensive fast, I find it easier to just keep the old designs out there and remake the ships in the shipyard if I need more.