What should you do when the pattern is crowded?
As PIC if you don't feel comfortable entering congested airspace at a beehive airport, dont enter it.  It's that simple.  Divert to another airfield and attempt to return to the original airfield when the congestion abates. 

If you anticipate high density traffic at an untowered airport, you should let other pilots know your intentions on the CTAF well in advance, generally at least 10NM from the field.  Closely monitor other CTAF pilot reports and start building a mental picture of traffic reporting their positions in the pattern, entering the pattern, or leaving it and begin to adjust your entry speed and position for appropriate separation and traffic flow.  Most other pilots will work with you on this and make changes to their traffic pattern to accommodate you as well.

If you have a fuel emergency or any other emergency for that matter and no other alternative is available, declare an emergency on the CTAF, indicate your position, altitude and intentions.  All other traffic in the pattern, by federal law, MUST give way for you