refactored upload handler to infrastructure project