mirror of
https://bitbucket.org/wisemapping/wisemapping-open-source.git
synced 2024-11-22 14:17:57 +01:00
Fix error when the connections in the pool has been closed.
This commit is contained in:
parent
e5e2e86fce
commit
9067a6cff2
@ -52,9 +52,6 @@ public class UsersController {
|
||||
@Autowired
|
||||
private UserService userService;
|
||||
|
||||
@Value("${registration.email.enabled}")
|
||||
boolean emailConfirmEnabled;
|
||||
|
||||
@Autowired
|
||||
private ReCaptcha captchaService;
|
||||
|
||||
@ -111,11 +108,13 @@ public class UsersController {
|
||||
user.setFirstname(userBean.getFirstname());
|
||||
user.setLastname(userBean.getLastname());
|
||||
user.setPassword(userBean.getPassword());
|
||||
userService.createUser(user, emailConfirmEnabled);
|
||||
|
||||
boolean confirmRegistrationByEmail = false;
|
||||
userService.createUser(user, confirmRegistrationByEmail);
|
||||
|
||||
// Forward to the success view ...
|
||||
result = new ModelAndView("userRegistrationSuccess");
|
||||
result.addObject("confirmByEmail", emailConfirmEnabled);
|
||||
result.addObject("confirmByEmail", confirmRegistrationByEmail);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
@ -9,6 +9,8 @@
|
||||
#database.hibernate.dialect=org.hibernate.dialect.MySQL5Dialect
|
||||
#database.username=wisemapping
|
||||
#database.password=password
|
||||
#database.validation.enabled=true
|
||||
#database.validation.query=SELECT 1
|
||||
|
||||
# HSQL Configuration properties
|
||||
database.url=jdbc:hsqldb:file:target/db/wisemapping
|
||||
@ -16,6 +18,8 @@ database.driver=org.hsqldb.jdbc.JDBCDriver
|
||||
database.hibernate.dialect=org.hibernate.dialect.HSQLDialect
|
||||
database.username=sa
|
||||
database.password=
|
||||
database.validation.enabled=false
|
||||
database.validation.query=
|
||||
|
||||
##################################################################################
|
||||
# Mail configuration. Must be configured to enable user registration confirmation.
|
||||
@ -60,9 +64,6 @@ mail.errorReporterEmail=
|
||||
# Users Registration Configuration
|
||||
##################################################################################
|
||||
|
||||
# Enable/Disable user registration confirmation by e-mail. If it's enabled, mail must be configured.
|
||||
registration.email.enabled = false
|
||||
|
||||
# Enable captcha confirmation
|
||||
google.recaptcha.enabled = true
|
||||
|
||||
|
@ -11,6 +11,8 @@
|
||||
<property name="url" value="${database.url}"/>
|
||||
<property name="username" value="${database.username}"/>
|
||||
<property name="password" value="${database.password}"/>
|
||||
<property name="testOnBorrow" value="${database.validation.enabled}"/>
|
||||
<property name="validationQuery" value="${database.validation.query}"/>
|
||||
</bean>
|
||||
|
||||
<!--Descoment this lines for production environments -->
|
||||
|
Loading…
Reference in New Issue
Block a user