Hello: If flow rate is unaffected, two possibilities come to mind. One is the thermostat misbehaving and the other is a cross connection in the plumbing. I’d check for a cross connection first to see if it can be ruled out. Do this by shutting off the water to the heater and opening a hot tap. (don’t leave the shut off closed for more than it takes to do the test) If water continues to run from the tap with any flow beyond a dribble, either the heater shut off doesn’t work, or there is a cross connection. A cross connection is simply a way for cold water to jump over into the hot side, cooling it down. If you determine it is not a cross connection, replacing the control becomes the right thing to do next. Modern controls have a wide “dead band”. This is the difference between on and off points. It is purposely wide to prevent overheating in the event of frequent small draws of water, but can create the problem, particularly in the morning, of the water not being hot enough. If, after one small draw, the tank heats up properly, deadband is suspect. Hope that ramble helps.