Feature #20
Daemon mode for continuous synchronization
| Status: | Feedback | Start: | 02/01/2009 | |
|---|---|---|---|---|
| Priority: | Low | Due date: | ||
| Assigned to: | Sébastien Bahloul | % Done: | 100% |
|
| Category: | Core | |||
| Target version: | 1.4.x branch |
Description
This would be nice, one day.
History
Updated by Jonathan Clarke about 1 year ago
- Target version set to Sometime in the future
Updated by Jonathan Clarke about 1 year ago
- We could use the JVM's -server mode to leave it running permanently, and just connect to it to launch a sync task (from cron)
- We could use a scheduler
Updated by Sébastien Bahloul about 1 month ago
- File lsc-jmx.diff added
As daemon mode is requiring a communication with the server, you will find attached a JMX binding to get the status and force a synchronization either by starting / stopping a asynchronous task, or by forcing a synchronous task on a dedicated id.
Updated by Rémy-Christophe Schermesser about 1 month ago
First of all, great Job ! The code is quite clear, and I like the Task object which simplifies SimpleSynchronize !
I have some minor comments :- Where are the tests ? :)
- Why did you create the class src/main/java/org/lsc/MapEntry.java ?
- In src/main/java/org/lsc/AbstractSynchronize.java
- You should no write that LOGGER.error("Tasks terminated according to time limit: " + e.toString(), e) but : LOGGER.error("Tasks terminated according to time limit"); LOGGER.debug(e.toString(), e);
- Try not to concatenate constants Strings (line 331)
- I think the class src/main/java/org/lsc/Task.java should be in the org.lsc.configuration packagen, what do you think ?
- In src/main/java/org/lsc/jmx/LscAgent.java :
- Why did you wrote System.out.println/error ?
- The line LOGGER.error("Unknown attribute name=value couple in \"" + token + "\". Please check your parameters !") should be replace by something like that : LOGGER.error("Unknown attribute name=value couple in \"{}\". Please check your parameters !", token); (There are more lines like that)
- In src/main/java/org/lsc/SimpleSynchronize.java
- You should not use keySet but entrySet (line 141) and pleaaaaaaaaaaaaase do not use Iterators if you can, it is very very awful
Updated by Sébastien Bahloul about 1 month ago
- Tests will be contributed next week.
- MapEntry.java is required because I can't find an simple Entry implementation. Do you known any other implementation that could be use for that ?
- Task.java moved to org.lsc.configuration package
- logging fixed through sl4j
- keySet usage fixed
- other proposed minor fixes applied
Updated by Rémy-Christophe Schermesser about 1 month ago
Sébastien Bahloul wrote:
- Tests will be contributed next week.
Great ;)
- MapEntry.java is required because I can't find an simple Entry implementation. Do you known any other implementation
that could be use for that ?
But why did you need an implementation of this specific interface, you should only use it with the .entrySet of a Map
Updated by Sébastien Bahloul about 1 month ago
I do not want to use an existing map because it would require to retrieve the pivots complete list. I need to build my own independant Map.Entry at this time. As I'm writing this, it make me notice that it is probably not the good parameter type ...
Updated by Sébastien Bahloul about 1 month ago
- Category set to Core
- Status changed from New to Assigned
- Assigned to set to Sébastien Bahloul
- Target version changed from Sometime in the future to 1.4.x branch
- % Done changed from 0 to 70
Commited as r784. Now writing corresponding tests.
Please notice that I force a JDK 1.6 compatibility level because of JMX MXBean support.
Updated by Sébastien Bahloul about 1 month ago
- Status changed from Assigned to Feedback
- Priority changed from Normal to Low
- % Done changed from 70 to 100
Test committed through r785. Feedback required :)
Updated by Sébastien Bahloul about 1 month ago
And the documentation :) : http://lsc-project.org/wiki/documentation/future/configuration/jmx