It sounds like sclerosing lymphangitis. I’m dealing with it too right now. Like a lumpy cord, or hardened string of pearls, running the circumference of the shaft just below the glans. Often on one side only.
Here is the thread about it.
Thombosed Vein vs Clogged Lymph Vessels
The short version is that if you catch it right away, you may be able to massage it out. But if not, then the best course is to leave it alone until it drains on its own, which could take anywhere from days to months. Good news is other than being annoying and slightly uncomfortable, it is otherwise benign. Bad news is that it tends to recur once you’ve had it. There is some weakness, damage, fibrosis, or sclerosis happening to the valve of the lymph vessel there. Nobody knows for sure the medical cause at this point. I’m currently on I think my 4th time having it. I will need to find what exercises cause it and avoid those. My current guesses are vac hanging and jelqing that cause it for me.