The exception basically tells you that ${user} is regular java.lang.String . According to javadoc , it really does not have a getUserid() method representing the userid property.
Make sure you create a specific instance of User in the required area, and not just plain vanilla String . Since you have not indicated anywhere in the question how you prepare a variable with a scope, it is impossible to give a focused answer to it, but it should look something like this:
User user = userService.find(id); request.setAttribute("user", user); // and thus not eg setAttribute("user", "user") or something.
source share