Fix Memoizer injection (Fix #11934)

Once a ctor was added with the same number of arguments,
Spring was incorrectly taking the `${omero...wait}` property
as a string. Casting it first to a Long prevents this.
Merge pull request #2021 from joshmoore/11934-bfmemoizer-dir

Fix Memoizer injection (Fix #11934)