Hi all,
I have created an application which is using vaadin-push. I have annotated my UI with @Push annotation.
When I deploy my EAR to wildfly, it gives the following error:
[code]
Caused by: java.lang.NoClassDefFoundError: com/vaadin/shared/communication/PushMode
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
at java.lang.Class.getDeclaredMethods(Class.java:1975)
at sun.reflect.annotation.AnnotationType$1.run(AnnotationType.java:112)
at sun.reflect.annotation.AnnotationType$1.run(AnnotationType.java:109)
at java.security.AccessController.doPrivileged(Native Method)
at sun.reflect.annotation.AnnotationType.(AnnotationType.java:109)
at sun.reflect.annotation.AnnotationType.getInstance(AnnotationType.java:85)
at sun.reflect.annotation.AnnotationParser.parseAnnotation2(AnnotationParser.java:266)
at sun.reflect.annotation.AnnotationParser.parseAnnotations2(AnnotationParser.java:120)
at sun.reflect.annotation.AnnotationParser.parseAnnotations(AnnotationParser.java:72)
at java.lang.Class.createAnnotationData(Class.java:3521)
at java.lang.Class.annotationData(Class.java:3510)
at java.lang.Class.getAnnotation(Class.java:3415)
at org.apache.deltaspike.core.impl.exclude.extension.ExcludeExtension.extractExcludeAnnotation(ExcludeExtension.java:185)
at org.apache.deltaspike.core.impl.exclude.extension.ExcludeExtension.vetoBeans(ExcludeExtension.java:156)
at sun.reflect.GeneratedMethodAccessor11.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:90)
… 16 more
Caused by: java.lang.ClassNotFoundException: com.vaadin.shared.communication.PushMode from [Module "deployment.example-exchange-ear.ear.example-exchange-web.war:main" from Service Module Loader]
at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:213)
at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:459)
at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:408)
at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:389)
at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:134)
... 36 more
[/code]My application class is defined as follows:
[code]
@CDIUI(“”)
@Theme(“valo”)
@Push
public class ApplicationUI extends UI {
@Inject
private CDIViewProvider viewProvider;
@Override
protected void init(VaadinRequest vaadinRequest) {
Navigator navigator = new Navigator(this, this);
navigator.addProvider(this.viewProvider);
navigator.navigateTo(MyView.NAME);
}
}
[/code]Can you please advise? I am not sure what I am doing wrong. Does Vaadin need to be added to Wildfly as a module?
Thanks,
Jose