Hello StackOverflow Community,
Background:
I have a Spring MVC portlet project. I want to provide a JAX-RS web service on a class. I came across the below guides to understand rest services in Liferay,
Liferay documentation
Surekha Technology blog - creates a project using rest template. I've created a project using spring-mvc template
I'm using maven and creating a WAR package
Attempted:
Configuring Endpoints and Extenders with the Control Panel, as described in Liferay documentation
Annotated the class with #ApplicationPath, #Component. Annotated the method with #GET, #Path, #Produces; as described in Liferay documentation
Deployed the WAR
Issue:
When I invoke the url - http://server:port/o/context-path/app-path/ I get the message in the browser 'No services have been found.' What am I missing here?
You can use rest module of liferay to develop rest api.
https://portal.liferay.dev/docs/7-1/tutorials/-/knowledge_base/t/jax-rs
Related
I have written a Spring web app for baseball umpires using Spring Boot and Thymeleaf. I like Spring Boot because it resolves dependency w/o a lot of configuration. Now I want to add Sprng WebFlow so umpires can order uniforms, a typical "shopping cart" application. There are many examples on the web but none using Spring Boot. They all are the traditional xml config with jsp and jstl. Has anyone used Spring Boot and WebFlow? There are WebFlow examples on the official Spring web site but very complicated. Thanks Rob
Spring Roo 2.0.0.M3 generates Spring Boot applications and integrates Spring Web Flow easier than ever.
The reference guide includes detailed descriptions of all the features, plus an extensive user guide for main use cases.
I'm doing a training in computer consulting company.
The project manager gave me an exercise to do with spring web mvc where do I get the data sent from a form and I need to display them on another page. I did it, all right, and I used the annotation of spring mvc.
Now the project manager told me to do the reengineering exercise,
doing it without using the annotation.
I searched on 10 sites including:
tutorialspoint, html.it, mykong, and documentation of spring mvc web and I saw that spring web mvc only works with the annotation, the annotation that I used are nell'esrcizio # RequestMapping, # Controller, # ModelAttribute.
Thank you
You can use xml configuration refer this link, if it helps you then up vote please
http://examples.javacodegeeks.com/enterprise-java/spring/beans-spring/spring-3-hello-world-example/
http://www.mkyong.com/spring-mvc/spring-mvc-hello-world-example/
I have web app which is already developed based on Spring MVC. I need to re-implement that web app in Mule.
Can I develop the mule application based on Spring MVC?
Can I declare the Spring MVC dispatcher servlet inside a mule's servlet endpoint and take things further from there?
The web app has web.xml where it defines the DispatcherServlet, the contextparams, the listener classes and so on. How can we remodel that in a mule application?
Any examples where a mule application is developed based on SpringMVC would be great.
Thanks to its embedded Jetty container, you can deploy any JavaEE web application in Mule. So there's no need to remodel anything.
The "Boosktore" example application demonstrates running web-apps within Mule: https://github.com/mulesoft/mule/tree/mule-3.x/examples/bookstore
Mule ESB is not an MVC Framework. It is developed using enterprise integration patterns in mind.
Please go through this blog, to know when to use ESB.
spring mvc can be integrated with mule.
Define all your spring related configuration in separate xml file and include it in mule configuration file.
You can write your custom transformers ,in the custom transformations you can inject or do an autowire of your service classes and from service object you can interact with dao layers.
In my job there was a debate about using Spring MVC portlet with IBM WPS, and architect is insisting it is have problem to use it without providing any reference, anyone have any input in this discussion based on actual experience, or any reference talking about issue of using Spring MVC portlet with IBM WPS, or have any reference can I use to show comparison of using Spring MVC portlet or other frameworks?
The standard Spring portlet MVC portlets work well. However they don't offer the fancy components offered by JSF frameworks.
Check out the spring documentation for getting started. You can check the outdated pet portal, not sure if it is working with 3.2 though.
I can create a minimal web application by using the maven-archetype-webapp .
Now I want to make my webapp Spring-Web-MVC powered.
Can I directly modify my POM, and how?
What's the best practices for the folder structure, and so on?
Can you show me a spring web mvc archetype, or a hello world example?
The STS (Spring Source Tool Suite) ships with the Spring Template Project, this project wizard will create a simple Spring MVC webapp + maven support.
Hope this helps
You can refer the step-by-step instructions, under the below link.
http://webapptutorials.wordpress.com/category/spring-mvc/
Maven Overlays document describes in great detail how web application should be structured using Maven. Here you'll find my simple Spring MVC showcase (REST-oriented).
Of course you are allowed to modify pom.xml (if the file is so complicated that users are afraid to modify it, then there must be something wrong with Maven...)
The only Spring-specific convention is to place general applicationContext.xml file under /WEB-INF - but this can be easily overridden.
You may also want to look using appfuse to bootstrap your spring-mvc application.