Welcome to the world of machine vision, I've got a little experience in this. A couple of thoughts.
Unless you use optics designed for measuring your magnification (and calibration) will be different at the sides of the image than in the center.
If you use telecentric optics you will not see the sides of the hole when it is off center.
Cheapo sensors are CMOS color devices. These use a color filter to split the RGB across 3 photosites. Because of this the measuring capability is less than than the sensor resolution.
Your sensor will not be square. Be aware that you will need different calibrations for X and Y.
Edmund Optics is the best source for optics and calibration masters. Get one of their catalogs. Full of good information on lenses, calibration, and lighting techniques.
Yes, this is very doable. I'll be interested to hear about your progress.