@Chris
Please see my updated original post.
Worth noting is that I even tried putting my SomeView class inside the same package as the MainUI, but that didn’t work.
@Roger: You cannot use autowired beans in constructor so that will never work. The method annotated with @PostConstruct should work but only if the view has been instantiated by Spring. How do you navigate to the view (Navigator-related code is not shown in the code snipped of MainUI)?
@Mika: Of course not. My bad. Please see the updated original post where I have added the Navigator-related code. As you can see I am using the DiscoveryNavigator, just like in the github-sample.
Thanks for your answer, but I think i have a diferent problem because the application don’t show the MainUI, i’m trying to put this line in my security.xml
to force the URL but i got this message
Estado HTTP 500 - com.vaadin.server.ServiceException: org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named ‘sv.com.vaadin.MainUI’ is defined
so I think the MainUI don’t load and i don’t know where can i defined that.
I just upload the same Alexander Federov’s spring security project, with the only changed that I put all the dependecies in the pom.xml, I’m run it in a tomcat 7 and I use STS IDE.
The login page load fine.
When I complete the username and the password and click in the login button, the next error show up
Hi,
Running “sping-integration” report following error :
2013-09-03T11:40:35.679+0200 javax.enterprise.system.container.web.com.sun.enterprise.web
WARNING: StandardWrapperValve[Vaadin Sample Application]
: PWC1406: Servlet.service() for servlet Vaadin Sample Application threw exception
org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'myUI' is defined
at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanDefinition(DefaultListableBeanFactory.java:570)
at org.springframework.beans.factory.support.AbstractBeanFactory.getMergedLocalBeanDefinition(AbstractBeanFactory.java:1108)
at org.springframework.beans.factory.support.AbstractBeanFactory.isPrototype(AbstractBeanFactory.java:431)
at org.springframework.context.support.AbstractApplicationContext.isPrototype(AbstractApplicationContext.java:1141)
at ru.xpoft.vaadin.SpringUIProvider.isSessionScopedUI(SpringUIProvider.java:69)
I’m using the sample available under
vaadin-samples with vaadin 7.1.3, Spring Vaadin Integration 2.0.1, Spring 3.2.4, Glassfish 3.1.2. In Eclipse debug mode, I cannot get bean from type using Spring methods. This is strange. Any idea ?
Thanks for help me up Alexander, what you said in this post i get it, i can see the login page, my problem is after, when you click in the login button you get forwared to the same login page and not to my MenuView. How can i get forwared to my MenuView??
Really??? I still get forwarded to the same login page the only changed is the “jsessionid” in the url, but i can’t get forwarded to the MainUI and then to the MenuView, i put a breakpoint in the MainUI and i debug the project but never enter to the MainUI. Can you send me the project you’re running??? maybe had something different. Sorry for bother you so much.
i have a question about autowiring.
i succeeded in developing.
but i can autowired at mainUI only. that means some view class(extended vaadin view) can`t autowried.
the property is null.
so… how can i autowiring with sub view pages?
i want to use DAO classes in sub view pages…
i can. by using mainUI. and when make sub view pages i assiged the dao instance.