| 72 | |
| 73 | = other old stuff = |
| 74 | |
| 75 | === Adding new !ComputationResources === |
| 76 | It is possible to add new types of ComputationResource, places where jobs can be executed. |
| 77 | |
| 78 | The Java interface ComputationResource is located at /xgap_1_4_distro/handwritten/java/plugins/cluster/interfaces/ComputationResource.java in your checked-out project and can be implemented. |
| 79 | |
| 80 | In the folder /xgap_1_4_distro/handwritten/java/plugins/cluster/implementations/ you can find two implementations that we currently provide: [http://www.xgap.org/svn/xgap_1_4_distro/handwritten/java/plugins/cluster/implementations/LocalComputationResource.java LocalComputationResource.java] and [http://www.xgap.org/svn/xgap_1_4_distro/handwritten/java/plugins/cluster/implementations/ClusterComputationResource.java ClusterComputationResource.java]. |
| 81 | |
| 82 | They implement the following functions: |
| 83 | |
| 84 | {{{ |
| 85 | public boolean installDependencies() |
| 86 | }}} |
| 87 | |
| 88 | Install the needed R-packages on this ComputationResource. |
| 89 | |
| 90 | {{{ |
| 91 | public boolean cleanupJob(int jobIs) |
| 92 | }}} |
| 93 | |
| 94 | Remove job files and generated data from this ComputationResource. |
| 95 | |
| 96 | {{{ |
| 97 | public String executeCommand(Command command) |
| 98 | }}} |
| 99 | |
| 100 | Execute a system command on this ComputationResource. |
| 101 | |
| 102 | {{{ |
| 103 | public List<String> executeCommands(List<Command> commands) |
| 104 | }}} |
| 105 | |
| 106 | Execute multiple system commands. Not a wrapper for executeCommand, because it can behave differently. |
| 107 | |
| 108 | At the moment, extending the system is not trivial because there are many ComputationResource specific parts in the core workings of '''ClusterPlugin.java'''. In further development, we will gradually make this more generic and easily extendable. |