You first want to make sure your horse is used to big crowds, lots of horses, getting its pulse checked, and having water thrown over it. No amount of fitness is useful if your horse gets worked up at vet checks. A fail is a fail, regardless of why your horse's heart rate isn't dropping.
Make sure your horse is also able to drink and eat on the go. Some horses stop eating or drinking when tired.
Don't over work your horse. It's easy to think "oh we need to be fit" and work the horse 7 days a week. Every horse is different but aim to have at least 2 days rest a week.
Learn to pace yourself. A horse speeding off at the start and exhausted by the end is of no use to anyone.
Don't forget your own fitness! In order to allow your horse to do as little as possible, your own fitness needs to be high. This will allow you to walk beside your horse every so often, and also so that you're balanced and the horse doesn't have to spend energy compensating for you.
Look after your horse. This goes for any competitive animal but saddle checks, back checks, farrier and teeth all need to be kept on top off. It's a very physically demanding discipline and if you don't look after your horse's physical health, it will break down.
Know your horse. There is no shame in noticing your horse is too tired or not quite right, and pulling out of the race yourself. It will save your horse for another day. A vet will likely pull you at the next check anyway so you may as well save your horse that extra couple of miles riding.