[FIXED JENKINS-19739] When installing a plugin and the needed dependencies have compatibility issues, warn the user

(cherry picked from commit de9816ee7a80f27477be73ec9a0abc05f3dd2702)
Use @Restricted(NoExternalUse.class) for new API members