What is the difference between error and warning?

What is the difference between error and warning?

An error is a validation failure associated with a rejected document, while a warning is a validation failure associated with an accepted document. If a submitted document has even one error, it will be rejected entirely.