Metastability for nonlinear parabolic equations with application to scalar viscous conservation laws