I think you let yourself fall into a dangerous situation here. By only making a small raise with your As you gave ample oporunity for a lot of hands to call you for a flop. If you'd have bet harder then all you'd likely have had to worry about is trips. I'd have also made a more hefty bet on the flop too.
Hopefully then you'd not find yourself in that situation you were in.