Faxtomail-commits
Threads by month
- ----- 2026 -----
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
June 2014
- 6 participants
- 194 discussions
Build failed in Jenkins: faxtomail-ci » FaxToMail :: UI #87
by admin+ci-codelutin.com@codelutin.com 02 Jun '14
by admin+ci-codelutin.com@codelutin.com 02 Jun '14
02 Jun '14
See <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>
------------------------------------------
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building FaxToMail :: UI 0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (2 KB at 50.0 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (2 KB at 46.7 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (7 KB at 248.2 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (7 KB at 302.2 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (57 KB at 1483.9 KB/sec)
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/j…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (2 KB at 53.7 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (2 KB at 51.7 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (4 KB at 139.4 KB/sec)
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/j…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (4 KB at 139.4 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/j…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (2 KB at 73.0 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (2 KB at 69.8 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (5 KB at 213.4 KB/sec)
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/j…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (5 KB at 213.4 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/j…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (2 KB at 66.5 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (2 KB at 60.7 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (5 KB at 230.0 KB/sec)
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/j…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (5 KB at 219.5 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/j…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (2 KB at 63.9 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (2 KB at 58.6 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (6 KB at 236.3 KB/sec)
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/j…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (6 KB at 216.6 KB/sec)
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/topia/…
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/nuiton…
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/j…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (73 KB at 1545.1 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (96 KB at 1425.8 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (385 KB at 3886.8 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (505 KB at 4271.6 KB/sec)
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ faxtomail-ui-swing ---
[INFO] Deleting <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>
[INFO]
[INFO] --- maven-enforcer-plugin:1.3.1:enforce (check-project-files) @ faxtomail-ui-swing ---
[INFO]
[INFO] --- jaxx-maven-plugin:2.8.6-SNAPSHOT:generate (default) @ faxtomail-ui-swing ---
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (2 KB at 51.9 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (2 KB at 50.1 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (4 KB at 160.5 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (4 KB at 168.2 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (2 KB at 63.5 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (2 KB at 60.8 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (5 KB at 194.8 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/groups/faxtomail-group/org/nuiton/jax… (5 KB at 194.8 KB/sec)
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloading: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax…
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (401 KB at 4218.0 KB/sec)
[INFO] Downloaded: http://nexus.nuiton.org/nexus/content/repositories/snapshots/org/nuiton/jax… (493 KB at 4978.5 KB/sec)
[INFO] use project compile scope class-path
[INFO] Detects 26 modified jaxx file(s).
[INFO] Generated 26 file(s) in 3.558s
[INFO]
[INFO] --- i18n-maven-plugin:3.1:parserJava (scan-sources) @ faxtomail-ui-swing ---
[INFO]
[INFO] --- i18n-maven-plugin:3.1:parserValidation (scan-sources) @ faxtomail-ui-swing ---
[INFO] Load rules file validation.rules
[INFO]
[INFO] >>> i18n-maven-plugin:3.1:gen (scan-sources) @ faxtomail-ui-swing >>>
[INFO]
[INFO] --- i18n-maven-plugin:3.1:get (get) @ faxtomail-ui-swing ---
[INFO] Copying faxtomail-ui-swing.properties to <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>
[INFO]
[INFO] <<< i18n-maven-plugin:3.1:gen (scan-sources) @ faxtomail-ui-swing <<<
[INFO]
[INFO] --- i18n-maven-plugin:3.1:gen (scan-sources) @ faxtomail-ui-swing ---
[WARNING] bundle fr_FR contains 27/287 empty entries! (use -Di18n.showEmpty to see these entries)
[INFO]
[INFO] >>> i18n-maven-plugin:3.1:bundle (make-bundle) @ faxtomail-ui-swing >>>
[INFO]
[INFO] --- i18n-maven-plugin:3.1:collect-i18n-artifacts (collect-i18n-artifacts) @ faxtomail-ui-swing ---
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/topia/…
[INFO] Downloading: http://repository.springsource.com/maven/bundles/external/org/nuiton/jaxx/2…
[INFO] collected 10 i18n artifacts for locale fr_FR stored in <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>
[INFO]
[INFO] <<< i18n-maven-plugin:3.1:bundle (make-bundle) @ faxtomail-ui-swing <<<
[INFO]
[INFO] --- i18n-maven-plugin:3.1:bundle (make-bundle) @ faxtomail-ui-swing ---
[WARNING] bundle fr_FR contains 62/534 empty entries! (use -Di18n.showEmpty to see these entries)
[INFO]
[INFO] --- license-maven-plugin:1.7:update-project-license (attach-licenses) @ faxtomail-ui-swing ---
[INFO]
[INFO] --- license-maven-plugin:1.7:add-third-party (attach-licenses) @ faxtomail-ui-swing ---
[INFO] Load missing file <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>
[INFO] Missing file <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…> is up-to-date.
[INFO] Writing third-party file to <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>
[INFO] Writing bundled third-party file to <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>
[INFO] Will attach third party file from <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ faxtomail-ui-swing ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO] Copying 45 resources
[INFO] Copying 3 resources
[INFO] Copying 4 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ faxtomail-ui-swing ---
[INFO] Compiling 107 source files to <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>
[INFO] -------------------------------------------------------------
[WARNING] COMPILATION WARNING :
[INFO] -------------------------------------------------------------
[WARNING] <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>: Some input files use unchecked or unsafe operations.
[WARNING] <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>: Recompile with -Xlint:unchecked for details.
[INFO] 2 warnings
[INFO] -------------------------------------------------------------
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] <http://ci.codelutin.com/jenkins/job/faxtomail-ci/com.franciaflex.faxtomail$…>:[272,29] unreported exception java.io.IOException; must be caught or declared to be thrown
[INFO] 1 error
[INFO] -------------------------------------------------------------
[JENKINS] Archiving disabled
1
8
r120 - in trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing: . content
by kmorin@users.forge.codelutin.com 02 Jun '14
by kmorin@users.forge.codelutin.com 02 Jun '14
02 Jun '14
Author: kmorin
Date: 2014-06-02 13:05:24 +0200 (Mon, 02 Jun 2014)
New Revision: 120
Url: http://forge.codelutin.com/projects/faxtomail/repository/revisions/120
Log:
fix swing session new exception thrown
Modified:
trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/RunFaxToMail.java
trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/content/MainUIHandler.java
Modified: trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/RunFaxToMail.java
===================================================================
--- trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/RunFaxToMail.java 2014-06-02 10:34:39 UTC (rev 119)
+++ trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/RunFaxToMail.java 2014-06-02 11:05:24 UTC (rev 120)
@@ -170,7 +170,14 @@
handler.onCloseUI();
//close context
- context.getSwingSession().save();
+ try {
+ context.getSwingSession().save();
+
+ } catch (IOException e) {
+ if (log.isErrorEnabled()) {
+ log.error("error while saving the swing session", e);
+ }
+ }
context.close();
if (exitCode != null) {
Modified: trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/content/MainUIHandler.java
===================================================================
--- trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/content/MainUIHandler.java 2014-06-02 10:34:39 UTC (rev 119)
+++ trunk/faxtomail-ui-swing/src/main/java/com/franciaflex/faxtomail/ui/swing/content/MainUIHandler.java 2014-06-02 11:05:24 UTC (rev 120)
@@ -54,6 +54,7 @@
import java.beans.PropertyChangeEvent;
import java.beans.PropertyChangeListener;
import java.beans.PropertyChangeListenerProxy;
+import java.io.IOException;
import java.util.Locale;
import static org.nuiton.i18n.I18n.t;
@@ -145,8 +146,15 @@
// Init SwingSession
SwingSession swingSession = getContext().getSwingSession();
swingSession.add(ui);
- swingSession.save();
+ try {
+ swingSession.save();
+ } catch (IOException e) {
+ if (log.isErrorEnabled()) {
+ log.error("error while saving the swing session", e);
+ }
+ }
+
// SwingUtil.getLayer(ui.getBody()).setUI(new BetaLayerUI());
changeTitle();
@@ -307,8 +315,15 @@
FaxToMailUI<?, ?> body = (FaxToMailUI<?, ?>) currentBody;
body.getHandler().onCloseUI();
- getContext().getSwingSession().save();
+ try {
+ getContext().getSwingSession().save();
+ } catch (IOException e) {
+ if (log.isErrorEnabled()) {
+ log.error("error while saving the swing session", e);
+ }
+ }
+
ui.getBody().remove(currentBody);
currentBody = null;
1
0
02 Jun '14
Author: kmorin
Date: 2014-06-02 12:34:39 +0200 (Mon, 02 Jun 2014)
New Revision: 119
Url: http://forge.codelutin.com/projects/faxtomail/repository/revisions/119
Log:
add transfert tables
Modified:
trunk/faxtomail-persistence/src/main/xmi/faxtomail.zargo
Modified: trunk/faxtomail-persistence/src/main/xmi/faxtomail.zargo
===================================================================
(Binary files differ)
1
0
01 Jun '14
Author: echatellier
Date: 2014-06-01 23:07:49 +0200 (Sun, 01 Jun 2014)
New Revision: 118
Url: http://forge.codelutin.com/projects/faxtomail/repository/revisions/118
Log:
Retreive user from ldap
Added:
trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/FakeLdapProvider.java
trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/LdapProvider.java
Modified:
trunk/faxtomail-persistence/src/main/java/com/franciaflex/faxtomail/FaxToMailConfiguration.java
trunk/faxtomail-persistence/src/main/java/com/franciaflex/faxtomail/FaxToMailConfigurationOption.java
trunk/faxtomail-persistence/src/main/xmi/faxtomail.properties
trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ConfigurationService.java
trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/LdapService.java
trunk/faxtomail-ui-web/src/main/java/com/franciaflex/faxtomail/web/action/admin/UserFolderAction.java
trunk/faxtomail-ui-web/src/main/java/com/franciaflex/faxtomail/web/job/EDIManagementJob.java
trunk/faxtomail-ui-web/src/main/webapp/WEB-INF/content/admin/user-folder-input.jsp
trunk/faxtomail-ui-web/src/main/webapp/js/user-folder.js
Modified: trunk/faxtomail-persistence/src/main/java/com/franciaflex/faxtomail/FaxToMailConfiguration.java
===================================================================
--- trunk/faxtomail-persistence/src/main/java/com/franciaflex/faxtomail/FaxToMailConfiguration.java 2014-05-30 21:01:38 UTC (rev 117)
+++ trunk/faxtomail-persistence/src/main/java/com/franciaflex/faxtomail/FaxToMailConfiguration.java 2014-06-01 21:07:49 UTC (rev 118)
@@ -251,6 +251,10 @@
public String getLdapPassword() {
return applicationConfig.getOption(FaxToMailConfigurationOption.LDAP_PASSWORD.getKey());
}
+
+ public boolean isLdapMock() {
+ return applicationConfig.getOptionAsBoolean(FaxToMailConfigurationOption.LDAP_MOCK.getKey());
+ }
public String getInstanceUrl() {
return applicationConfig.getOption(FaxToMailConfigurationOption.INSTANCE_URL.getKey());
Modified: trunk/faxtomail-persistence/src/main/java/com/franciaflex/faxtomail/FaxToMailConfigurationOption.java
===================================================================
--- trunk/faxtomail-persistence/src/main/java/com/franciaflex/faxtomail/FaxToMailConfigurationOption.java 2014-05-30 21:01:38 UTC (rev 117)
+++ trunk/faxtomail-persistence/src/main/java/com/franciaflex/faxtomail/FaxToMailConfigurationOption.java 2014-06-01 21:07:49 UTC (rev 118)
@@ -94,7 +94,7 @@
LDAP_PORT(
"faxtomail.ldap.port",
"Port du serveur LDAP", "389", Integer.class),
-
+
LDAP_USER(
"faxtomail.ldap.user",
"Nom d'utilisateur pour la connexion au serveur ldap", null, String.class),
@@ -103,6 +103,10 @@
"faxtomail.ldap.password",
"Mot de passe pour la connexion au serveur LDAP", null, String.class),
+ LDAP_MOCK(
+ "faxtomail.ldap.mock",
+ "Use mock ldap provider for test purpose", "false", Boolean.class),
+
// TRANSIENT CONFIG
VERSION(
"faxtomail.version",
Modified: trunk/faxtomail-persistence/src/main/xmi/faxtomail.properties
===================================================================
--- trunk/faxtomail-persistence/src/main/xmi/faxtomail.properties 2014-05-30 21:01:38 UTC (rev 117)
+++ trunk/faxtomail-persistence/src/main/xmi/faxtomail.properties 2014-06-01 21:07:49 UTC (rev 118)
@@ -66,11 +66,16 @@
com.franciaflex.faxtomail.persistence.entities.MailFilter.attribute.mailFolder.tagvalue.notNull=true
com.franciaflex.faxtomail.persistence.entities.MailFilter.attribute.position.tagvalue.unique=true
-# FaxToMailGroup
-com.franciaflex.faxtomail.persistence.entities.FaxToMailUserGroup.attribute.name.tagvalue.naturalId=true
-
# Email
com.franciaflex.faxtomail.persistence.entities.Email.attribute.mailFolder.tagvalue.notNull=true
# History
com.franciaflex.faxtomail.persistence.entities.History.attribute.type.tagvalue.notNull=true
+
+
+
+# FaxToMailUser
+com.franciaflex.faxtomail.persistence.entities.FaxToMailUser.attribute.login.tagvalue.naturalId=true
+
+# FaxToMailUserGroup
+com.franciaflex.faxtomail.persistence.entities.FaxToMailUserGroup.attribute.name.tagvalue.naturalId=true
Modified: trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ConfigurationService.java
===================================================================
--- trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ConfigurationService.java 2014-05-30 21:01:38 UTC (rev 117)
+++ trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ConfigurationService.java 2014-06-01 21:07:49 UTC (rev 118)
@@ -41,6 +41,8 @@
import com.franciaflex.faxtomail.persistence.entities.EmailAccount;
import com.franciaflex.faxtomail.persistence.entities.EmailAccountImpl;
import com.franciaflex.faxtomail.persistence.entities.EmailAccountTopiaDao;
+import com.franciaflex.faxtomail.persistence.entities.FaxToMailUser;
+import com.franciaflex.faxtomail.persistence.entities.FaxToMailUserTopiaDao;
import com.franciaflex.faxtomail.persistence.entities.MailFilter;
import com.franciaflex.faxtomail.persistence.entities.MailFilterTopiaDao;
import com.franciaflex.faxtomail.services.FaxToMailServiceSupport;
@@ -169,4 +171,9 @@
emailAccountTopiaDao.deleteAll(emailAccountMap.values());
getPersistenceContext().commit();
}
+
+ public List<FaxToMailUser> getAllUsers() {
+ FaxToMailUserTopiaDao faxToMailUserDao = getPersistenceContext().getFaxToMailUserDao();
+ return faxToMailUserDao.findAll();
+ }
}
Modified: trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/LdapService.java
===================================================================
--- trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/LdapService.java 2014-05-30 21:01:38 UTC (rev 117)
+++ trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/LdapService.java 2014-06-01 21:07:49 UTC (rev 118)
@@ -1,77 +1,43 @@
package com.franciaflex.faxtomail.services.service;
-import java.util.ArrayList;
import java.util.Collection;
-import java.util.List;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
+import org.nuiton.util.beans.Binder;
+import org.nuiton.util.beans.BinderFactory;
+import com.franciaflex.faxtomail.FaxToMailConfiguration;
+import com.franciaflex.faxtomail.persistence.entities.FaxToMailUser;
+import com.franciaflex.faxtomail.persistence.entities.FaxToMailUserGroup;
+import com.franciaflex.faxtomail.persistence.entities.FaxToMailUserGroupTopiaDao;
+import com.franciaflex.faxtomail.persistence.entities.FaxToMailUserImpl;
+import com.franciaflex.faxtomail.persistence.entities.FaxToMailUserTopiaDao;
import com.franciaflex.faxtomail.services.FaxToMailServiceSupport;
+import com.franciaflex.faxtomail.services.service.ldap.FakeLdapProvider;
+import com.franciaflex.faxtomail.services.service.ldap.LdapProvider;
import com.franciaflex.faxtomail.services.service.ldap.LdapUser;
-import com.unboundid.ldap.sdk.LDAPConnection;
-import com.unboundid.ldap.sdk.LDAPException;
-import com.unboundid.ldap.sdk.SearchResult;
-import com.unboundid.ldap.sdk.SearchResultEntry;
-import com.unboundid.ldap.sdk.SearchScope;
public class LdapService extends FaxToMailServiceSupport {
private static final Log log = LogFactory.getLog(LdapService.class);
- /**
- * Get ldap connection.
- *
- * @return
- * @throws LDAPException
- */
- protected LDAPConnection getLDAPConnection() throws LDAPException {
- // host, port, username and password
- return new LDAPConnection(getApplicationConfig().getLdapHost(),
- getApplicationConfig().getLdapPort(),
- getApplicationConfig().getLdapUser(),
- getApplicationConfig().getLdapPassword());
- }
+ protected LdapProvider ldapProvider;
- /**
- * Get all user from ldap.
- *
- * @return ldap users with group infos
- * @throws LDAPException
- */
- protected Collection<LdapUser> getAllLdapUsers() throws LDAPException {
- Collection<LdapUser> results = new ArrayList<>();
-
- // ldapsearch -h ldap.codelutin.home -b "ou=People,DC=codelutin,DC=home" "objectClass=posixGroup"
- // ldapsearch -h ldap.codelutin.home -b "ou=People,DC=codelutin,DC=home" "objectClass=account"
- String baseDN = "ou=People,DC=codelutin,DC=home";
- String filter = "(objectClass=account)";
-
- LDAPConnection connection = null;
- try {
- connection = getLDAPConnection();
- if (connection.isConnected()) {
- SearchResult searchResult = connection.search(baseDN, SearchScope.ONE, filter);
-
- List<SearchResultEntry> searchEntries = searchResult.getSearchEntries();
- for (SearchResultEntry searchEntry : searchEntries) {
- LdapUser user = new LdapUser();
- user.setLogin(searchEntry.getAttributeValue("uid"));
- user.setLogin(searchEntry.getAttributeValue("uid"));
- user.setLogin(searchEntry.getAttributeValue("uid"));
-
- results.add(user);
+ protected LdapProvider getLdapProvider() {
+ if (ldapProvider == null) {
+ FaxToMailConfiguration config = getApplicationConfig();
+ if (config.isLdapMock()) {
+ ldapProvider = new FakeLdapProvider();
+ if (log.isInfoEnabled()) {
+ log.info("Using fake ldap provider");
}
+ } else {
+ ldapProvider = new LdapProvider(config);
}
- } finally {
- if (connection != null) {
- connection.close();
- }
}
-
-
- return results;
+ return ldapProvider;
}
/**
@@ -82,8 +48,52 @@
if (log.isDebugEnabled()) {
log.debug("Ldap service not configured !");
}
+ return;
+ } else {
+ if (log.isDebugEnabled()) {
+ log.debug("Updating user data from ldap");
+ }
}
+
+ Collection<LdapUser> ldapUsers = getLdapProvider().getAllLdapUsers();
+
+ FaxToMailUserTopiaDao faxtomailUserDao = getPersistenceContext().getFaxToMailUserDao();
+ FaxToMailUserGroupTopiaDao faxToMailUserGroupDao = getPersistenceContext().getFaxToMailUserGroupDao();
+ Binder<FaxToMailUser, FaxToMailUser> userBinder = BinderFactory.newBinder(FaxToMailUser.class);
+ for (LdapUser ldapUser : ldapUsers) {
+
+ // manage user from login
+ FaxToMailUser user = faxtomailUserDao.forLoginEquals(ldapUser.getLogin()).findUniqueOrNull();
+ if (user == null) {
+ user = new FaxToMailUserImpl();
+ }
+
+ // FIXME echatellier 20140601 : it's not necessary to save user in database if information didn't change
+ userBinder.copyExcluding(ldapUser, user,
+ FaxToMailUser.PROPERTY_TOPIA_ID,
+ FaxToMailUser.PROPERTY_TOPIA_CREATE_DATE,
+ FaxToMailUser.PROPERTY_TOPIA_VERSION,
+ FaxToMailUser.PROPERTY_FAX_TO_MAIL_USER_GROUP);
+
+ // manage user group
+ Collection<String> groups = ldapUser.getGroups();
+ user.clearFaxToMailUserGroup();
+ for (String group : groups) {
+ FaxToMailUserGroup userGroup = faxToMailUserGroupDao.forNameEquals(group).findUniqueOrNull();
+ if (userGroup == null) {
+ userGroup = faxToMailUserGroupDao.create(FaxToMailUserGroup.PROPERTY_NAME, group);
+ }
+ user.addFaxToMailUserGroup(userGroup);
+ }
+
+ // persist user
+ if (user.isPersisted()) {
+ faxtomailUserDao.update(user);
+ } else {
+ faxtomailUserDao.create(user);
+ }
+ }
-
+ getPersistenceContext().commit();
}
}
Added: trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/FakeLdapProvider.java
===================================================================
--- trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/FakeLdapProvider.java (rev 0)
+++ trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/FakeLdapProvider.java 2014-06-01 21:07:49 UTC (rev 118)
@@ -0,0 +1,33 @@
+package com.franciaflex.faxtomail.services.service.ldap;
+
+import java.util.Arrays;
+import java.util.Collection;
+
+import com.unboundid.ldap.sdk.LDAPException;
+
+/**
+ * Fake ldap provider for test/demo purpose.
+ *
+ * @author Eric Chatellier
+ */
+public class FakeLdapProvider extends LdapProvider {
+
+ @Override
+ public Collection<LdapUser> getAllLdapUsers() {
+
+ LdapUser ldapUser1 = new LdapUser();
+ ldapUser1.setLogin("user1");
+ ldapUser1.addGroup("Groupe 1");
+
+ LdapUser ldapUser2 = new LdapUser();
+ ldapUser2.setLogin("user2");
+ ldapUser2.addGroup("Groupe 1");
+
+ LdapUser ldapUser3 = new LdapUser();
+ ldapUser3.setLogin("user3");
+ ldapUser3.addGroup("Groupe 2");
+
+ return Arrays.asList(ldapUser1, ldapUser2, ldapUser3);
+ }
+
+}
Property changes on: trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/FakeLdapProvider.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/LdapProvider.java
===================================================================
--- trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/LdapProvider.java (rev 0)
+++ trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/LdapProvider.java 2014-06-01 21:07:49 UTC (rev 118)
@@ -0,0 +1,85 @@
+package com.franciaflex.faxtomail.services.service.ldap;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.List;
+
+import com.franciaflex.faxtomail.FaxToMailConfiguration;
+import com.unboundid.ldap.sdk.LDAPConnection;
+import com.unboundid.ldap.sdk.LDAPException;
+import com.unboundid.ldap.sdk.SearchResult;
+import com.unboundid.ldap.sdk.SearchResultEntry;
+import com.unboundid.ldap.sdk.SearchScope;
+
+/**
+ * Real ldap provider.
+ *
+ * @author Eric Chatellier
+ */
+public class LdapProvider {
+
+ protected FaxToMailConfiguration config;
+
+ protected LdapProvider() {
+
+ }
+
+ public LdapProvider(FaxToMailConfiguration config) {
+ this();
+ this.config = config;
+ }
+
+ /**
+ * Get ldap connection.
+ *
+ * @return
+ * @throws LDAPException
+ */
+ protected LDAPConnection getLDAPConnection() throws LDAPException {
+ // host, port, username and password
+ return new LDAPConnection(config.getLdapHost(),
+ config.getLdapPort(),
+ config.getLdapUser(),
+ config.getLdapPassword());
+ }
+
+ /**
+ * Get all user from ldap.
+ *
+ * @return ldap users with group infos
+ */
+ public Collection<LdapUser> getAllLdapUsers() {
+ Collection<LdapUser> results = new ArrayList<>();
+
+ // ldapsearch -h ldap.codelutin.home -b "ou=People,DC=codelutin,DC=home" "objectClass=posixGroup"
+ // ldapsearch -h ldap.codelutin.home -b "ou=People,DC=codelutin,DC=home" "objectClass=account"
+ String baseDN = "ou=People,DC=codelutin,DC=home";
+ String filter = "(objectClass=account)";
+
+ LDAPConnection connection = null;
+ try {
+ connection = getLDAPConnection();
+ if (connection.isConnected()) {
+ SearchResult searchResult = connection.search(baseDN, SearchScope.ONE, filter);
+
+ List<SearchResultEntry> searchEntries = searchResult.getSearchEntries();
+ for (SearchResultEntry searchEntry : searchEntries) {
+ LdapUser user = new LdapUser();
+ user.setLogin(searchEntry.getAttributeValue("uid"));
+ user.setLogin(searchEntry.getAttributeValue("uid"));
+ user.setLogin(searchEntry.getAttributeValue("uid"));
+
+ results.add(user);
+ }
+ }
+ } catch (LDAPException ex) {
+ throw new RuntimeException("Can't connect to ldap", ex);
+ } finally {
+ if (connection != null) {
+ connection.close();
+ }
+ }
+
+ return results;
+ }
+}
Property changes on: trunk/faxtomail-service/src/main/java/com/franciaflex/faxtomail/services/service/ldap/LdapProvider.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/faxtomail-ui-web/src/main/java/com/franciaflex/faxtomail/web/action/admin/UserFolderAction.java
===================================================================
--- trunk/faxtomail-ui-web/src/main/java/com/franciaflex/faxtomail/web/action/admin/UserFolderAction.java 2014-05-30 21:01:38 UTC (rev 117)
+++ trunk/faxtomail-ui-web/src/main/java/com/franciaflex/faxtomail/web/action/admin/UserFolderAction.java 2014-06-01 21:07:49 UTC (rev 118)
@@ -24,9 +24,6 @@
* #L%
*/
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.InputStream;
import java.util.Collections;
import java.util.List;
@@ -34,10 +31,10 @@
import org.apache.commons.logging.LogFactory;
import org.apache.struts2.convention.annotation.Result;
+import com.franciaflex.faxtomail.persistence.entities.FaxToMailUser;
import com.franciaflex.faxtomail.persistence.entities.MailFolder;
import com.franciaflex.faxtomail.services.service.ConfigurationService;
import com.franciaflex.faxtomail.services.service.MailFolderService;
-import com.franciaflex.faxtomail.services.service.ReferentielService;
import com.franciaflex.faxtomail.web.FaxToMailActionSupport;
public class UserFolderAction extends FaxToMailActionSupport {
@@ -50,7 +47,7 @@
protected List<MailFolder> mailFolders;
- protected List<String> groupNames;
+ protected List<FaxToMailUser> users;
public void setConfigurationService(ConfigurationService configurationService) {
this.configurationService = configurationService;
@@ -64,7 +61,7 @@
@org.apache.struts2.convention.annotation.Action("user-folder-input")
public String input() throws Exception {
mailFolders = mailFolderService.getAllMailFolders();
- groupNames = Collections.emptyList(); //FIXME: configurationService.getAllGroups();
+ users = configurationService.getAllUsers();
return INPUT;
}
@@ -81,7 +78,7 @@
return mailFolders;
}
- public List<String> getGroupNames() {
- return groupNames;
+ public List<FaxToMailUser> getUsers() {
+ return users;
}
}
Modified: trunk/faxtomail-ui-web/src/main/java/com/franciaflex/faxtomail/web/job/EDIManagementJob.java
===================================================================
--- trunk/faxtomail-ui-web/src/main/java/com/franciaflex/faxtomail/web/job/EDIManagementJob.java 2014-05-30 21:01:38 UTC (rev 117)
+++ trunk/faxtomail-ui-web/src/main/java/com/franciaflex/faxtomail/web/job/EDIManagementJob.java 2014-06-01 21:07:49 UTC (rev 118)
@@ -28,7 +28,6 @@
import com.franciaflex.faxtomail.services.service.EmailService;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
-import org.quartz.Job;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
Modified: trunk/faxtomail-ui-web/src/main/webapp/WEB-INF/content/admin/user-folder-input.jsp
===================================================================
--- trunk/faxtomail-ui-web/src/main/webapp/WEB-INF/content/admin/user-folder-input.jsp 2014-05-30 21:01:38 UTC (rev 117)
+++ trunk/faxtomail-ui-web/src/main/webapp/WEB-INF/content/admin/user-folder-input.jsp 2014-06-01 21:07:49 UTC (rev 118)
@@ -39,7 +39,7 @@
angular.module('UserFolderModule', ['FaxToMail'])
.value('UserFolderData', {
'mailFolders': <s:property value="toJson(mailFolders)" escapeHtml="false"/>,
- 'groupNames': <s:property value="toJson(groupNames)" escapeHtml="false"/>
+ 'users': <s:property value="toJson(users)" escapeHtml="false"/>
});
</script>
</head>
@@ -61,8 +61,8 @@
</tr>
</thead>
<tbody>
- <tr ng-repeat="groupName in groupNames">
- <th>{{groupName}}</th>
+ <tr ng-repeat="user in users">
+ <th>{{user.login}}</th>
<td>
<input type="text" />
</td>
Modified: trunk/faxtomail-ui-web/src/main/webapp/js/user-folder.js
===================================================================
--- trunk/faxtomail-ui-web/src/main/webapp/js/user-folder.js 2014-05-30 21:01:38 UTC (rev 117)
+++ trunk/faxtomail-ui-web/src/main/webapp/js/user-folder.js 2014-06-01 21:07:49 UTC (rev 118)
@@ -29,8 +29,8 @@
function($scope, $http, UserFolderData) {
//{Array} mail folders
$scope.mailFolders = UserFolderData.mailFolders;
- // {Array} Liste des groupes ldap
- $scope.groupNames = UserFolderData.groupNames;
+ // {Array} Liste des utilisateurs ldap
+ $scope.users = UserFolderData.users;
// method privée recursive pour retourner l'ensemble des dossiers
var recursiveAddMailFolder = function(result, mailFolders) {
1
0