You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by zh...@apache.org on 2020/07/20 02:29:31 UTC

[shardingsphere-elasticjob] branch master updated: For 1179 local-executor.en.md (#1181)

This is an automated email from the ASF dual-hosted git repository.

zhangliang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere-elasticjob.git


The following commit(s) were added to refs/heads/master by this push:
     new 031a268  For 1179 local-executor.en.md (#1181)
031a268 is described below

commit 031a268e4122c6978b437a7b6c788f1609b8e4fb
Author: 于玉桔 <zh...@apache.org>
AuthorDate: Mon Jul 20 10:29:22 2020 +0800

    For 1179 local-executor.en.md (#1181)
---
 .../elasticjob-cloud/usage/local-executor.en.md          | 16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/docs/content/user-manual/elasticjob-cloud/usage/local-executor.en.md b/docs/content/user-manual/elasticjob-cloud/usage/local-executor.en.md
index a2925dd..cd3a97f 100755
--- a/docs/content/user-manual/elasticjob-cloud/usage/local-executor.en.md
+++ b/docs/content/user-manual/elasticjob-cloud/usage/local-executor.en.md
@@ -4,4 +4,18 @@ weight = 2
 chapter = true
 +++
 
-TODO
+When developing ElasticJob-Cloud jobs, developers can leave the Mesos environment to run and debug jobs locally.
+The local operating mode can be used to fully debug business functions and unit tests, and then deploy to the Mesos cluster after completion.
+
+There is no need to install the Mesos environment to run jobs locally.
+
+```java
+// Create job configuration
+JobConfiguration jobConfig = JobConfiguration.newBuilder("myJob", 3).cron("0/5 * * * * ?").build();
+
+// Configure the fragmentation item of the currently running job
+int shardingItem = 0;
+
+// Create a local executor
+new LocalTaskExecutor(new MyJob(), jobConfig, shardingItem).execute();
+```