I am using the following code to get a JCR Session inside my Magnolia module:
LifeTimeJCRSessionUtil.getSession("magicWorkspace");
I'm not using Guice to do IoC. Is this the best way to get hold of a JCR session in a Magnolia module?
The recommended way is using the static methods on MgnlContext. Like so:
Session session = MgnlContext.getJCRSession(RepositoryConstants.WEBSITE)
In RepositoryConstants
you'll find constants for the standard JCR workspaces used in Magnolia.