The Resource Environment and Microbial Associations Mediate Adaptation to Environmental Heterogeneity in Drosophila Melanogaster