If you manually assign a patrol mission to a military ship it should continue patrolling the target indefinitely (i.e. until you stop it). If they are low on fuel, they will refuel and then return to patrol the target.
However automated ships work differently - after a time they may reassign themselves to new missions.