optional = true

Also the maven dependency should be set as optional in the pom