Beautiful but full of tourists
Dubrovnik is an absolutely beautiful city, but that does mean there will be lot's of other people there. During the daytime, loads of cruise ship travelers magically appear in the city, which is a little off-putting - that may be a good time to take a kayak tour or something. All in all, I'd say 2 full days, maybe 3 are what you need.
Insider Tip:There's a good, free, exhibit on the war (the 1990s one) in the fort at the top of the cable car ride. You have to walk outside of the cable car building and around the fort a little to find it.