Here's a great workbench snippet that uploads a file geodatabase to AGOL, publishes it, updates the view to switch it to your new service, then deletes the old service.
Here's a great workbench snippet that uploads a file geodatabase to AGOL, publishes it, updates the view to switch it to your new service, then deletes the old service.