Identification of the Microbial Community Structure and Potential Mechanism of Environmental Adaptation in Contaminated Environments