vendredi 13 mars 2015

Deploy Backbone.js with Spring 4 MVC on a Tomcat Server

all, I was following this Spring 4 tutorial:http://ift.tt/18kuhlh, but my goal is NOT to use Spring Boot's embedded Tomcat for deployment. Currently, I was able to deploy the Spring MVC (RESTful API) part successfully (using WebMvcConfigurerAdapter & WebApplicationInitializer in my Configuration classes) use an external Tomcat: localhost:8080/appname/path-variable returns correct data sets. But how do I deploy the Backbone.js part - the Html, Javascript (Models, Views), where the Model calls out to these RESTful APIs above? (The Tutorial only shows how to use Spring Boot at another Port.) I have tried to start another instance of Tomcat (port 8081) and put the html/js under webapp/, but server does not seem to pick the even the Index.html. My final goal is to have the deployment environment set up so that when I can simply call the URL to index.html, which includes my js to backbone's model/view code files. Any tips about setting this up? Let me know if you need more background. Thanks.


Aucun commentaire:

Enregistrer un commentaire