When I get a cramp like that, I take it easy for at least 3-4 days. If I ride, it is of the flat, recovery ride variety. 1st day, I apply ice. 2nd-4th day, I use mainly heat. If you have access to a jacuzzi/spa, that helps too.
Best of luck and get well soon.