Win a copy of Five Lines of Code this week in the OO, Patterns, UML and Refactoring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Spring Login Issues (Using Maven, spring-data-jpa, Hibernate and spring Security)

 
Rancher
Posts: 1170
18
IntelliJ IDE Hibernate Firefox Browser MySQL Database Spring Tomcat Server Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I already posted this question but on the wrong forum...

I'm experimenting a bit with spring and I tried to wright my first secured application.
Only the homepage, the loginpage and the sign-uppage are visitable without loging in an when you try to click on a button in the homepage you're redirected to the loginpage.
So far so good. I'm able to visit the homepage, I'm beïng redirected, I also can register (I checked with datagrip),
But when I try to log in, the page refeshes and nothing happens.
I don't even get a error, no tracestack nothing.
First I had a seperate entity and repository for my role table and had joined the to tables on users.id and role.userId, but then I thought maybe I joined them wrong or something, so I removed my roleEntity and repository and simply putted a extra fiels in my usersEntity but the result is the same.
How do you debug if you have no error or stacktrace?

My WebsecurityConfig:



My login controller:




My UsersEntity:




The sql statements to log in:

 
Nothing? Or something? Like this tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic