I'm a huge believer in crate training. Saved my carpet, saved my furniture (from chewing)., saved my sanity!
As Lightplum said, the length of time really depends on the age of the pups.
By 4 or 5 months old, 4 hours is fine. My pups are 11 months old and I still crate them during the day. Though I come home at lunchtime, I really don't need to. They could happily and easily go the entire day. Even when I come home at lunch, most times they just kinda look at me...."Mom, can't you see I'm enjoying my nap!" Neither one of them has accidents, unless sick. At night, I bring their crates up to my bedroom and it's their choice as to whether to sleep in the crate or on the bed. Indy almost always sleeps most of the night in the crate. I think pups do better sleeping with their humans, but that's my personal opinion.
Remember, crates aren't cruel. They are safe havens. My dogs crawl in on their own all the time, just because.