Skip to content
Advertisement

Tag: spring-mvc

Spring MVC web application: No default constructor found

Project ZIP: http://goo.gl/ddhLg5 Spring web app cannot be executed giving HTTP Status 500 error. It also writes out that No default constructor found for DSLR but in fact there is a default constructor. Maybe it has to do with application context or the way my beans declared? What is the reason my application cannot start? DSLR: web.xml DSLRServletController-servlet.xml: mvc-dispatcher-servlet.xml ERROR:

mvn spring-boot:run doesn’t start spring

ANSWER: I changed the version tag from 0.0.1-SNAPSHOT to 1.0.2.RELEASE and it worked, see answer below. I am following this documentation and have created the Example.java as instructed. When I run mvn spring-boot:run spring doesn’t start it just says BUILD SUCCESS. It’s my understanding that Spring should start and Tomcat serving up the page. Here are some details: Example.java located

Why we shouldn’t make a Spring MVC controller @Transactional?

There are already a few questions about the topic, but no response at all really provides arguments in order to explain why we shouldn’t make a Spring MVC controller Transactional. See: Transaction not working correctly – Spring/MyBatis For web MVC Spring app should @Transactional go on controller or service? Making Spring 3 MVC controller method Transactional Spring MVC Controller Transactional

How to fix Hibernate LazyInitializationException: failed to lazily initialize a collection of roles, could not initialize proxy – no Session

In the custom AuthenticationProvider from my spring project, I am trying read the list of authorities of the logged user, but I am facing the following error: Reading other topics from here in StackOverflow, I understand this happens due the way this type of atribute is handled by the framework, but i can’t figure out any solution for my case.

how to capture connection event in my webSocket server with Spring 4?

I did a simple web socket communication with spring 4,STOMP and sock.js, following this https://github.com/rstoyanchev/spring-websocket-portfolio and this http://assets.spring.io/wp/WebSocketBlogPost.html well, I want to know if is possible capture connection events like when a new client was connected to my server or when a client was disconnected, is that possible in Spring 4.0.0? Answer This an be done with a connection handshake

Add context path to Spring Boot application

I am trying to set a Spring Boot applications context root programmatically. The reason for the context root is we want the app to be accessed from localhost:port/{app_name} and have all the controller paths append to it. Here is the application configuration file for the web-app. Here is the index controller for the main page. The new root of the

Failed to load Main-Class manifest attribute while running java -jar

I have successfully built my Spring MVC project with mvn clean package by following this tutorial. Now I am trying to run the service with: But I get this error: Failed to load Main-Class manifest attribute from target/gs-serving-web-content-0.1.0.jar Am I missing something? Answer If you are working with Spring Boot this will solve your problem: Reference Guide | Spring Boot

Advertisement