I've had several knots on my rib cage and they've been there for over a year. I never was concerned about them, but I get muscle spasms sometimes too. Is it from weight lifting?
There are likely a number of things that could contribute to what you describe and the best person to consult is your doctor. None of the people who answer questions here are doctors, so when not really able to give you any kind of good, solid advice on this issue. I would recommend you make an appointment to see your doctor as soon as possible to get things checked out.