Decay microorganisms thrive in moist conditions. Dry or saturated will not support them.
Choose materials that don't rot...white, burr, live oak...cedar...black locust...redwood...etc.
Design...many balusters are mounted with the bottoms flush on the horizontal frame. Maybe a thick plastic or stainless washer to break the connection??? Paint all surfaces before assembly.
Not all decay resistant wood is uniform. I read an article that compared decay resistance to the number of growth increments per inch. In general, more the better. I HATE saying that old growth is best. Gotta have old trees more than old lumber. Dense second growth seems a good compromise.