Hello, i have this problem. When i try to login in my project with incorect name i have this error: Error invoking constructor com.htc.identity.entities.User(long, String, String) (at User.java:36) (for service 'ApplicationStateManager'): No service implements the interface long.
On line 36 in User class i have: public User(final long id, final String username, final String password) { this.setId(id); this.setUsername(username); this.setPassword(password); } My Login.java public class Login { @Inject private UserService userService; @SessionState private User user; @Property private String username; @Property private String password; @Log public Object onSubmitFromLoginForm() throws SQLException { user = userService.getUser(username, password); if (user != null) { return Home.class; } else return null; } } UserService: public class UserServiceImpl implements UserService { private Map<String, User> users; public UserServiceImpl(String userList, String passwordList) { users = new HashMap<String, User>(); try { String[] us = userList.split(","); String[] pws = passwordList.split(","); for(int i = 0; i < Math.max(us.length, pws.length); i++) { users.put(us[i], new User(i, us[i], pws[i])); } } catch (Exception e) { e.printStackTrace(); } } public User getUser(String username, String password) { User user = users.get(username); if (user != null && StringUtils.equals(user.getPassword(), password)) return user; return null; } } Thanks for your help. -- View this message in context: http://tapestry.1045711.n5.nabble.com/ApplicationStateManager-No-service-implements-the-interface-long-tp4891217p4891217.html Sent from the Tapestry - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org