Problem
Cannot import javax.enterprise.context.SessionScoped
Webserver: Glassfish 4.1
IDE: Eclipse Luna
Cause
default Eclipse Luna dont add cdi-api.jar package into build path. So, you cannot import javax.enterprise.context.SessionScoped class.
Solution
Add cdi-api.jar to build path. You can find it in <glassfins-install-dir>/glassfish/modules
No comments:
Post a Comment