Skip to content

Commit

Permalink
Refactor elasticjob-engine module‘s package name
Browse files Browse the repository at this point in the history
  • Loading branch information
terrymanu committed Oct 15, 2023
1 parent cf74040 commit cbb59f5
Show file tree
Hide file tree
Showing 182 changed files with 555 additions and 554 deletions.
2 changes: 1 addition & 1 deletion docs/content/faq/_index.cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ ElasticJob 已将 IP 地址等敏感信息过滤,导出的信息可在公网
ElasticJob 执行任务会获取本机IP,首次可能存在获取IP较慢的情况。尝试设置 `-Djava.net.preferIPv4Stack=true`.


## 10. Windows环境下,运行ShardingSphere-ElasticJob-UI,找不到或无法加载主类 org.apache.shardingsphere.elasticjob.engine.ui.Bootstrap,如何解决?
## 10. Windows环境下,运行ShardingSphere-ElasticJob-UI,找不到或无法加载主类 org.apache.shardingsphere.elasticjob.kernel.ui.Bootstrap,如何解决?

回答:

Expand Down
2 changes: 1 addition & 1 deletion docs/content/faq/_index.en.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ Answer:
ElasticJob will obtain the local IP when performing task scheduling, and it may be slow to obtain the IP for the first time. Try to set `-Djava.net.preferIPv4Stack=true`.


## 10. In Windows env, run ShardingSphere-ElasticJob-UI, could not find or load main class org.apache.shardingsphere.elasticjob.engine.ui.Bootstrap. Why?
## 10. In Windows env, run ShardingSphere-ElasticJob-UI, could not find or load main class org.apache.shardingsphere.elasticjob.kernel.ui.Bootstrap. Why?

Answer:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ elasticjob.reg-center.server-lists=localhost:6181
elasticjob:
jobs:
simpleJob:
elasticJobClass: org.apache.shardingsphere.elasticjob.engine.example.job.SpringBootSimpleJob
elasticJobClass: org.apache.shardingsphere.elasticjob.kernel.example.job.SpringBootSimpleJob
cron: 0/5 * * * * ?
timeZone: GMT+08:00
shardingTotalCount: 3
Expand All @@ -110,7 +110,7 @@ elasticjob:
**Properties**
```
elasticjob.jobs.simpleJob.elastic-job-class=org.apache.shardingsphere.elasticjob.engine.example.job.SpringBootSimpleJob
elasticjob.jobs.simpleJob.elastic-job-class=org.apache.shardingsphere.elasticjob.kernel.example.job.SpringBootSimpleJob
elasticjob.jobs.simpleJob.cron=0/5 * * * * ?
elasticjob.jobs.simpleJob.timeZone=GMT+08:00
elasticjob.jobs.simpleJob.sharding-total-count=3
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ Reference:
elasticjob:
jobs:
simpleJob:
elasticJobClass: org.apache.shardingsphere.elasticjob.engine.example.job.SpringBootSimpleJob
elasticJobClass: org.apache.shardingsphere.elasticjob.kernel.example.job.SpringBootSimpleJob
cron: 0/5 * * * * ?
timeZone: GMT+08:00
shardingTotalCount: 3
Expand All @@ -111,7 +111,7 @@ elasticjob:
**Properties**
```
elasticjob.jobs.simpleJob.elastic-job-class=org.apache.shardingsphere.elasticjob.engine.example.job.SpringBootSimpleJob
elasticjob.jobs.simpleJob.elastic-job-class=org.apache.shardingsphere.elasticjob.kernel.example.job.SpringBootSimpleJob
elasticjob.jobs.simpleJob.cron=0/5 * * * * ?
elasticjob.jobs.simpleJob.timeZone=GMT+08:00
elasticjob.jobs.simpleJob.sharding-total-count=3
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ ElasticJob 提供自定义的 Spring 命名空间,可以与 Spring 容器配

```xml

<bean id="oneOffJob" class="org.apache.shardingsphere.elasticjob.engine.example.job.simple.SpringSimpleJob"/>
<bean id="oneOffJob" class="org.apache.shardingsphere.elasticjob.kernel.example.job.simple.SpringSimpleJob"/>
<elasticjob:job id="oneOffJobBean" job-ref="oneOffJob" ... />
```
```java
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Trigger the job by invoking `execute()` method manually.

```xml

<bean id="oneOffJob" class="org.apache.shardingsphere.elasticjob.engine.example.job.simple.SpringSimpleJob"/>
<bean id="oneOffJob" class="org.apache.shardingsphere.elasticjob.kernel.example.job.simple.SpringSimpleJob"/>
<elasticjob:job id="oneOffJobBean" job-ref="oneOffJob" ... />
```
```java
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example;
package org.apache.shardingsphere.elasticjob.example;

import org.apache.curator.test.TestingServer;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.fixture.entity;
package org.apache.shardingsphere.elasticjob.example.fixture.entity;

import java.io.Serializable;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.fixture.repository;
package org.apache.shardingsphere.elasticjob.example.fixture.repository;

import org.apache.shardingsphere.elasticjob.engine.example.fixture.entity.Foo;
import org.apache.shardingsphere.elasticjob.example.fixture.entity.Foo;
import org.springframework.stereotype.Repository;

import java.util.ArrayList;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.fixture.repository;
package org.apache.shardingsphere.elasticjob.example.fixture.repository;

public final class FooRepositoryFactory {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job.dataflow;
package org.apache.shardingsphere.elasticjob.example.job.dataflow;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.dataflow.job.DataflowJob;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.entity.Foo;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.repository.FooRepository;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.repository.FooRepositoryFactory;
import org.apache.shardingsphere.elasticjob.example.fixture.entity.Foo;
import org.apache.shardingsphere.elasticjob.example.fixture.repository.FooRepository;
import org.apache.shardingsphere.elasticjob.example.fixture.repository.FooRepositoryFactory;

import java.text.SimpleDateFormat;
import java.util.Date;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job.dataflow;
package org.apache.shardingsphere.elasticjob.example.job.dataflow;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.dataflow.job.DataflowJob;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.entity.Foo;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.repository.FooRepository;
import org.apache.shardingsphere.elasticjob.example.fixture.entity.Foo;
import org.apache.shardingsphere.elasticjob.example.fixture.repository.FooRepository;

import javax.annotation.Resource;
import java.text.SimpleDateFormat;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job.simple;
package org.apache.shardingsphere.elasticjob.example.job.simple;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.simple.job.SimpleJob;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job.simple;
package org.apache.shardingsphere.elasticjob.example.job.simple;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.simple.job.SimpleJob;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.entity.Foo;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.repository.FooRepository;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.repository.FooRepositoryFactory;
import org.apache.shardingsphere.elasticjob.example.fixture.entity.Foo;
import org.apache.shardingsphere.elasticjob.example.fixture.repository.FooRepository;
import org.apache.shardingsphere.elasticjob.example.fixture.repository.FooRepositoryFactory;

import java.text.SimpleDateFormat;
import java.util.Date;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job.simple;
package org.apache.shardingsphere.elasticjob.example.job.simple;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.simple.job.SimpleJob;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.entity.Foo;
import org.apache.shardingsphere.elasticjob.engine.example.fixture.repository.FooRepository;
import org.apache.shardingsphere.elasticjob.example.fixture.entity.Foo;
import org.apache.shardingsphere.elasticjob.example.fixture.repository.FooRepository;

import javax.annotation.Resource;
import java.text.SimpleDateFormat;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,20 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example;
package org.apache.shardingsphere.elasticjob.example;

import org.apache.commons.dbcp2.BasicDataSource;
import org.apache.shardingsphere.elasticjob.api.JobConfiguration;
import org.apache.shardingsphere.elasticjob.dataflow.props.DataflowJobProperties;
import org.apache.shardingsphere.elasticjob.error.handler.dingtalk.DingtalkPropertiesConstants;
import org.apache.shardingsphere.elasticjob.error.handler.email.EmailPropertiesConstants;
import org.apache.shardingsphere.elasticjob.error.handler.wechat.WechatPropertiesConstants;
import org.apache.shardingsphere.elasticjob.example.job.dataflow.JavaDataflowJob;
import org.apache.shardingsphere.elasticjob.http.props.HttpJobProperties;
import org.apache.shardingsphere.elasticjob.engine.api.bootstrap.impl.OneOffJobBootstrap;
import org.apache.shardingsphere.elasticjob.engine.api.bootstrap.impl.ScheduleJobBootstrap;
import org.apache.shardingsphere.elasticjob.engine.example.job.dataflow.JavaDataflowJob;
import org.apache.shardingsphere.elasticjob.engine.example.job.simple.JavaOccurErrorJob;
import org.apache.shardingsphere.elasticjob.engine.example.job.simple.JavaSimpleJob;
import org.apache.shardingsphere.elasticjob.kernel.api.bootstrap.impl.OneOffJobBootstrap;
import org.apache.shardingsphere.elasticjob.kernel.api.bootstrap.impl.ScheduleJobBootstrap;
import org.apache.shardingsphere.elasticjob.example.job.simple.JavaOccurErrorJob;
import org.apache.shardingsphere.elasticjob.example.job.simple.JavaSimpleJob;
import org.apache.shardingsphere.elasticjob.reg.base.CoordinatorRegistryCenter;
import org.apache.shardingsphere.elasticjob.reg.zookeeper.ZookeeperConfiguration;
import org.apache.shardingsphere.elasticjob.reg.zookeeper.ZookeeperRegistryCenter;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example;
package org.apache.shardingsphere.elasticjob.example;

import org.springframework.context.support.ClassPathXmlApplicationContext;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
http://shardingsphere.apache.org/schema/elasticjob
http://shardingsphere.apache.org/schema/elasticjob/elasticjob.xsd
">
<context:component-scan base-package="org.apache.shardingsphere.elasticjob.engine.example" />
<context:component-scan base-package="org.apache.shardingsphere.elasticjob.example" />
<context:property-placeholder location="classpath:conf/*.properties"/>

<elasticjob:zookeeper id="regCenter" server-lists="${serverLists}" namespace="${namespace}"
Expand All @@ -45,8 +45,8 @@

<elasticjob:rdb-tracing id="elasticJobTrace" data-source-ref="elasticJobTracingDataSource" />

<bean id="simpleJob" class="org.apache.shardingsphere.elasticjob.engine.example.job.simple.SpringSimpleJob" />
<bean id="dataflowJob" class="org.apache.shardingsphere.elasticjob.engine.example.job.dataflow.SpringDataflowJob" />
<bean id="simpleJob" class="org.apache.shardingsphere.elasticjob.example.job.simple.SpringSimpleJob" />
<bean id="dataflowJob" class="org.apache.shardingsphere.elasticjob.example.job.dataflow.SpringDataflowJob" />

<elasticjob:job id="${simple.id}" job-ref="simpleJob" registry-center-ref="regCenter" tracing-ref="elasticJobTrace"
sharding-total-count="${simple.shardingTotalCount}" cron="${simple.cron}"
Expand All @@ -68,7 +68,7 @@


<!-- use One-off job-->
<!-- <bean id="oneOffJob" class="org.apache.shardingsphere.elasticjob.engine.example.job.simple.SpringSimpleJob" />-->
<!-- <bean id="oneOffJob" class="org.apache.shardingsphere.elasticjob.kernel.example.job.simple.SpringSimpleJob" />-->
<!-- <elasticjob:job id="oneOffJobBean" job-ref="oneOffJob" registry-center-ref="regCenter" tracing-ref="elasticJobTrace"-->
<!-- sharding-total-count="${simple.shardingTotalCount}"-->
<!-- sharding-item-parameters="${simple.shardingItemParameters}"-->
Expand All @@ -87,7 +87,7 @@
<!--</elasticjob:job>-->

<!-- use email error handler -->
<!-- <bean id="occurErrorNoticeEmailJob" class="org.apache.shardingsphere.elasticjob.engine.example.job.simple.JavaOccurErrorJob" />-->
<!-- <bean id="occurErrorNoticeEmailJob" class="org.apache.shardingsphere.elasticjob.kernel.example.job.simple.JavaOccurErrorJob" />-->
<!-- <elasticjob:job id="${occurErrorNoticeEmailJob.id}" job-ref="occurErrorNoticeEmailJob"-->
<!-- registry-center-ref="regCenter" tracing-ref="elasticJobTrace"-->
<!-- sharding-total-count="${occurErrorNoticeEmailJob.shardingTotalCount}"-->
Expand All @@ -109,7 +109,7 @@
<!-- </elasticjob:job>-->

<!-- use dingtalk error handler -->
<!-- <bean id="occurErrorNoticeDingtalkJob" class="org.apache.shardingsphere.elasticjob.engine.example.job.simple.JavaOccurErrorJob" />-->
<!-- <bean id="occurErrorNoticeDingtalkJob" class="org.apache.shardingsphere.elasticjob.kernel.example.job.simple.JavaOccurErrorJob" />-->
<!-- <elasticjob:job id="${occurErrorNoticeDingtalkJob.id}" job-ref="occurErrorNoticeDingtalkJob"-->
<!-- registry-center-ref="regCenter" tracing-ref="elasticJobTrace"-->
<!-- sharding-total-count="${occurErrorNoticeDingtalkJob.shardingTotalCount}"-->
Expand All @@ -131,7 +131,7 @@
<!-- </elasticjob:job>-->

<!-- use wechat error handler -->
<!-- <bean id="occurErrorNoticeWechatJob" class="org.apache.shardingsphere.elasticjob.engine.example.job.simple.JavaOccurErrorJob" />-->
<!-- <bean id="occurErrorNoticeWechatJob" class="org.apache.shardingsphere.elasticjob.kernel.example.job.simple.JavaOccurErrorJob" />-->
<!-- <elasticjob:job id="${occurErrorNoticeWechatJob.id}" job-ref="occurErrorNoticeWechatJob"-->
<!-- registry-center-ref="regCenter" tracing-ref="elasticJobTrace"-->
<!-- sharding-total-count="${occurErrorNoticeWechatJob.shardingTotalCount}"-->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example;
package org.apache.shardingsphere.elasticjob.example;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,16 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.controller;
package org.apache.shardingsphere.elasticjob.example.controller;

import javax.annotation.Resource;
import org.apache.shardingsphere.elasticjob.engine.api.bootstrap.impl.OneOffJobBootstrap;
import org.apache.shardingsphere.elasticjob.kernel.api.bootstrap.impl.OneOffJobBootstrap;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
public class OneOffJobController {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.entity;
package org.apache.shardingsphere.elasticjob.example.entity;

import java.io.Serializable;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job;
package org.apache.shardingsphere.elasticjob.example.job;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.dataflow.job.DataflowJob;
import org.apache.shardingsphere.elasticjob.engine.example.entity.Foo;
import org.apache.shardingsphere.elasticjob.engine.example.repository.FooRepository;
import org.apache.shardingsphere.elasticjob.example.entity.Foo;
import org.apache.shardingsphere.elasticjob.example.repository.FooRepository;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job;
package org.apache.shardingsphere.elasticjob.example.job;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.simple.job.SimpleJob;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job;
package org.apache.shardingsphere.elasticjob.example.job;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.simple.job.SimpleJob;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job;
package org.apache.shardingsphere.elasticjob.example.job;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.simple.job.SimpleJob;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.job;
package org.apache.shardingsphere.elasticjob.example.job;

import org.apache.shardingsphere.elasticjob.api.ShardingContext;
import org.apache.shardingsphere.elasticjob.engine.example.entity.Foo;
import org.apache.shardingsphere.elasticjob.engine.example.repository.FooRepository;
import org.apache.shardingsphere.elasticjob.example.entity.Foo;
import org.apache.shardingsphere.elasticjob.example.repository.FooRepository;
import org.apache.shardingsphere.elasticjob.simple.job.SimpleJob;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
* limitations under the License.
*/

package org.apache.shardingsphere.elasticjob.engine.example.repository;
package org.apache.shardingsphere.elasticjob.example.repository;

import org.apache.shardingsphere.elasticjob.engine.example.entity.Foo;
import org.apache.shardingsphere.elasticjob.example.entity.Foo;
import org.springframework.stereotype.Repository;

import java.util.ArrayList;
Expand Down
Loading

0 comments on commit cbb59f5

Please sign in to comment.