Constraints on cosmological models and reconstructing the acceleration history of the Universe with gamma-ray burst distance indicators