Pressure tanks are usually filled with air. Some have bladders in them so the air is trapped. However many do not have bladders and over time the air gets absorbed into the water so there is no air, or very little. So when the pump comes on it takes only a few seconds to compress the air and activate the switch to shut it off. If your tank does not have a bladder in it, you just need to drain the water out of it. Turn off the power to the pump. Open the drain valve and also open something on the top side so it can get air in to replace the water that is running out the bottom.
With the tank empty close the valves and turn the pump on. What happens is the tank begins to fill and compresses the air. When the design pressure is reached, the pressure switch shuts the power off. Of course the compressed air will push water out when you open a water valve and the pump will not come on again until the pressure falls to the preset point. Then the pump comes on.
On tanks with no bladder, draining them periodically is just routine maintenance.
If your tank is the type with a bladder and the bladder failed, you need to replace the tank.
Gardening at 5000 feet elevation, zone 4/5 Northern Utah, Frost free from May 25 to September 8 +/-