I wouldn't shift the front derailleur under heavy pedaling force, but the rear should be okay. It's not so much that you are shifting at the wrong time or in the wrong way, but rather that your derailleurs badly need adjustment. The chain should catch each gear cleanly each time you shift, and there should be no noise after the shift.