E. V. d. B.
E. V. d. B.

Reputation: 815

AngularJS + Spring MVC with security - where to start?

I'm trying to build the front-end part of a project with Angular and a basic REST backend that also handles security.

I have very basic knowledge of Spring but haven't really worked with Spring Security.

I'm trying to find a way to build a simple REST backend that is secured. I have searched online a lot and the main thing i found was this tutorial: https://spring.io/guides/tutorials/spring-security-and-angular-js/ . After reading it I still don't understand how I should get started.

Also, this tutorial example works with Spring Boot and it has like a class you have to run and such, but I would like the more 'classic' Spring approach combined with maven where it's java-based configs and it runs on a Tomcat, I don't really understand the main class of the Spring Boot-way anyways.

I know how to set up a Spring project with REST controllers and I can get this to work without a problem, so that's something I don't need to figure out. I do need to figure out how to add security as simple as possible. I need user authentication and all that, but I really really have not a single clue how to go about is. What is all needed for this? Are there any better (non Spring Boot) tutorials out there?

Any help will be much appreciated!

Upvotes: 12

Views: 19777

Answers (3)

Deepa
Deepa

Reputation: 950

For BackEnd - Learn basic simple spring boot first and try with sample project..
For Frontend - Using Grunt and Yoeman, you can create angular project.. Have a look at this site..
https://www.sitepoint.com/kickstart-your-angularjs-development-with-yeoman-grunt-and-bower/

Configure backend port in gruntfile.js.. Now You can start working on both front end and backend independently..

Upvotes: 0

OmarAsifShaikh
OmarAsifShaikh

Reputation: 174

You can take a look at this open source Spring + AngularJS generator JHipster

Main site: http://jhipster.github.io/

quick slides: http://jhipster.github.io/presentation/#/

Upvotes: 3

Abdelghani Roussi
Abdelghani Roussi

Reputation: 2817

  1. First of all

    It will be a good thing that you know what is Spring boot ( Advantage of spring boot )

  2. secondly

    Here is some helpful resources :

    2.1 This is about the architecture Web App Architecture - the Spring MVC - AngularJs stack

    2.2 Spring Restful Web Service Example with JSON, Jackson and Client Program

    2.3 CRUD using Spring MVC 4.0 RESTful Web Services and AngularJS

    2.4 And for the security example Spring Data REST + Spring Security

Upvotes: 13

Related Questions