-
Notifications
You must be signed in to change notification settings - Fork 140
Closed
Description
This is a bit of an edge case, and there is a workaround. It just took me a while to track down today.
I've set up a repo with a test case to demonstrate this: https://github.com/mjclemente/fw1alias
Steps to reproduce:
- Set the application flag
reloadApplicationOnEveryRequest=true - Use a loadlistener to set an alias for a service
beanFactory.addAlias("alsoKnownAs", "existingService") - If you try to access a subsystem page (?action=module:main.default), it errors with "Element existingService is undefined in a CFML structure referenced as part of an expression." Examining
beanfactory.getbeaninfo()shows that only the subsystem controller objects have been added at this point. - You are able to access pages within the default subsystem without issue.
- You can work around it by declaring the bean before setting the alias
beanFactory.declareBean( "departmentService", "model.services.department" ).