Added a setting under the caching settings on whether the doctrine's proxy class auto generation is enabled or not.

As suggested by @aembler in #1469.