Skip to content

Commit 48bfad8

Browse files
committed
Merge branch '3.5.x'
2 parents f7a1277 + 07288ad commit 48bfad8

File tree

117 files changed

+2693
-33
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

117 files changed

+2693
-33
lines changed

framework/fel/java/pom.xml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,12 @@
2929
</developer>
3030
</developers>
3131

32+
<scm>
33+
<connection>scm:git:git://github.com/ModelEngine-Group/fit-framework.git</connection>
34+
<developerConnection>scm:git:ssh://github.com/ModelEngine-Group/fit-framework.git</developerConnection>
35+
<url>https://github.com/ModelEngine-Group/fit-framework</url>
36+
</scm>
37+
3238
<modules>
3339
<module>fel-community</module>
3440
<module>fel-core</module>
@@ -247,6 +253,15 @@
247253
</execution>
248254
</executions>
249255
</plugin>
256+
<plugin>
257+
<groupId>org.sonatype.central</groupId>
258+
<artifactId>central-publishing-maven-plugin</artifactId>
259+
<version>0.7.0</version>
260+
<extensions>true</extensions>
261+
<configuration>
262+
<publishingServerId>central</publishingServerId>
263+
</configuration>
264+
</plugin>
250265
</plugins>
251266
</build>
252267
</project>

framework/fit/java/fit-dependency/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<version>3.6.0-SNAPSHOT</version>
99
<packaging>pom</packaging>
1010

11-
<description>Dependency Management Of The Plugin-Based Programming Framework</description>
11+
<description>Dependency Management of The Plugin-Based Programming Framework</description>
1212
<url>https://github.com/ModelEngine-Group/fit-framework</url>
1313

1414
<licenses>

framework/fit/java/pom.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@
3535
<url>https://github.com/ModelEngine-Group/fit-framework</url>
3636
</scm>
3737

38-
3938
<modules>
4039
<module>fit-aop</module>
4140
<module>fit-api</module>
@@ -72,7 +71,7 @@
7271

7372
<!-- Maven plugin versions -->
7473
<maven.antrun.version>3.1.0</maven.antrun.version>
75-
<maven.compiler.version>3.9.0</maven.compiler.version>
74+
<maven.compiler.version>3.14.0</maven.compiler.version>
7675
<maven.dependency.version>3.6.1</maven.dependency.version>
7776
<maven.jar.version>3.3.0</maven.jar.version>
7877
<maven.javadoc.version>3.11.2</maven.javadoc.version>

framework/ohscript/pom.xml

Lines changed: 72 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,12 @@
3636
</developer>
3737
</developers>
3838

39+
<scm>
40+
<connection>scm:git:git://github.com/ModelEngine-Group/fit-framework.git</connection>
41+
<developerConnection>scm:git:ssh://github.com/ModelEngine-Group/fit-framework.git</developerConnection>
42+
<url>https://github.com/ModelEngine-Group/fit-framework</url>
43+
</scm>
44+
3945
<properties>
4046
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
4147
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
@@ -56,9 +62,17 @@
5662
<junit5.version>5.11.4</junit5.version>
5763
<mockito.version>5.15.2</mockito.version>
5864

59-
<maven.compiler.version>3.11.0</maven.compiler.version>
60-
<maven.surefire.version>3.1.2</maven.surefire.version>
61-
<jacoco-maven-plugin.version>0.8.10</jacoco-maven-plugin.version>
65+
<!-- Jacoco version -->
66+
<jacoco.version>0.8.10</jacoco.version>
67+
68+
<!-- Maven plugin versions -->
69+
<maven.antrun.version>3.1.0</maven.antrun.version>
70+
<maven.compiler.version>3.14.0</maven.compiler.version>
71+
<maven.dependency.version>3.6.1</maven.dependency.version>
72+
<maven.jar.version>3.3.0</maven.jar.version>
73+
<maven.javadoc.version>3.11.2</maven.javadoc.version>
74+
<maven.surefire.version>3.2.5</maven.surefire.version>
75+
<maven.source.version>3.3.0</maven.source.version>
6276
</properties>
6377

6478
<dependencies>
@@ -178,13 +192,42 @@
178192
<artifactId>maven-compiler-plugin</artifactId>
179193
<version>${maven.compiler.version}</version>
180194
<configuration>
181-
<source>1.8</source>
182-
<target>1.8</target>
195+
<source>${java.version}</source>
196+
<target>${java.version}</target>
197+
<encoding>${project.build.sourceEncoding}</encoding>
198+
<showWarnings>true</showWarnings>
199+
<showDeprecation>true</showDeprecation>
183200
<compilerArgs>
184201
<arg>-parameters</arg>
185202
</compilerArgs>
186203
</configuration>
187204
</plugin>
205+
<plugin>
206+
<groupId>org.apache.maven.plugins</groupId>
207+
<artifactId>maven-javadoc-plugin</artifactId>
208+
<version>${maven.javadoc.version}</version>
209+
<executions>
210+
<execution>
211+
<id>attach-javadocs</id>
212+
<goals>
213+
<goal>jar</goal>
214+
</goals>
215+
</execution>
216+
</executions>
217+
</plugin>
218+
<plugin>
219+
<groupId>org.apache.maven.plugins</groupId>
220+
<artifactId>maven-source-plugin</artifactId>
221+
<version>${maven.source.version}</version>
222+
<executions>
223+
<execution>
224+
<id>attach-sources</id>
225+
<goals>
226+
<goal>jar-no-fork</goal>
227+
</goals>
228+
</execution>
229+
</executions>
230+
</plugin>
188231
<plugin>
189232
<groupId>org.apache.maven.plugins</groupId>
190233
<artifactId>maven-surefire-plugin</artifactId>
@@ -193,7 +236,7 @@
193236
<plugin>
194237
<groupId>org.jacoco</groupId>
195238
<artifactId>jacoco-maven-plugin</artifactId>
196-
<version>${jacoco-maven-plugin.version}</version>
239+
<version>${jacoco.version}</version>
197240
<configuration>
198241
<destFile>target/coverage-reports/jacoco-unit.exec</destFile>
199242
<dataFile>target/coverage-reports/jacoco-unit.exec</dataFile>
@@ -214,6 +257,29 @@
214257
</execution>
215258
</executions>
216259
</plugin>
260+
<plugin>
261+
<groupId>org.apache.maven.plugins</groupId>
262+
<artifactId>maven-gpg-plugin</artifactId>
263+
<version>3.0.1</version>
264+
<executions>
265+
<execution>
266+
<id>sign-artifacts</id>
267+
<phase>deploy</phase>
268+
<goals>
269+
<goal>sign</goal>
270+
</goals>
271+
</execution>
272+
</executions>
273+
</plugin>
274+
<plugin>
275+
<groupId>org.sonatype.central</groupId>
276+
<artifactId>central-publishing-maven-plugin</artifactId>
277+
<version>0.7.0</version>
278+
<extensions>true</extensions>
279+
<configuration>
280+
<publishingServerId>central</publishingServerId>
281+
</configuration>
282+
</plugin>
217283
</plugins>
218284
</build>
219285
</project>

framework/ohscript/src/main/java/modelengine/fit/ohscript/external/FitExecutionException.java

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,33 @@
1616
* @since 2023-12-18
1717
*/
1818
public class FitExecutionException extends ScriptExecutionException {
19+
/**
20+
* 表示泛服务的唯一标识。
21+
*/
1922
private final String genericableId;
2023

24+
/**
25+
* 表示泛服务实现的唯一标识。
26+
*/
2127
private final String fitableId;
2228

29+
/**
30+
* 通过泛服务唯一标识和错误信息来初始化 {@link FitExecutionException} 的新实例。
31+
*
32+
* @param genericableId 表示泛服务的唯一标识的 {@link String}。
33+
* @param message 表示错误信息的 {@link String}。
34+
*/
2335
public FitExecutionException(String genericableId, String message) {
2436
this(genericableId, StringUtils.EMPTY, message);
2537
}
2638

39+
/**
40+
* 通过泛服务唯一标识、错误信息和异常原因来初始化 {@link FitExecutionException} 的新实例。
41+
*
42+
* @param genericableId 表示泛服务的唯一标识的 {@link String}。
43+
* @param message 表示错误信息的 {@link String}。
44+
* @param cause 表示异常原因的 {@link Throwable}。
45+
*/
2746
public FitExecutionException(String genericableId, String message, Throwable cause) {
2847
this(genericableId, StringUtils.EMPTY, message, cause);
2948
}

framework/ohscript/src/main/java/modelengine/fit/ohscript/external/HttpExecutionException.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,14 @@
1515
* @since 2023-12-21
1616
*/
1717
public class HttpExecutionException extends ScriptExecutionException {
18+
/**
19+
* 表示 Http 调用的方法。
20+
*/
1821
private final String method;
1922

23+
/**
24+
* 表示 Http 调用的地址。
25+
*/
2026
private final String url;
2127

2228
/**

framework/ohscript/src/main/java/modelengine/fit/ohscript/external/HttpExecutor.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ static HttpExecutor create(HttpClassicClient httpClient) {
5252

5353
/**
5454
* 使用 Http 客户端,向指定地址发送请求。
55-
* <p>参数中可能出现的参数如下:
55+
* <p>参数中可能出现的参数如下:</p>
5656
* <ul>
5757
* <li>{@link #REQUEST_HEADERS}:表示消息头</li>
5858
* <li>{@link #REQUEST_ENTITY}:表示消息体</li>
@@ -74,7 +74,6 @@ static HttpExecutor create(HttpClassicClient httpClient) {
7474
* };
7575
* };
7676
* </pre>
77-
* </p>
7877
*
7978
* @param method 表示 Http 调用的方法的 {@link String}。
8079
* @param url 表示 Http 调用地址的 {@link String}。

framework/ohscript/src/main/java/modelengine/fit/ohscript/external/support/DefaultFitExecutor.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,12 @@ public class DefaultFitExecutor implements FitExecutor {
6161

6262
private final BrokerClient brokerClient;
6363

64+
/**
65+
* 通过 Bean 容器和 FIT 调用代理来初始化 {@link DefaultFitExecutor} 的新实例。
66+
*
67+
* @param container 表示 Bean 容器的 {@link BeanContainer}。
68+
* @param brokerClient 表示 FIT 调用代理的 {@link BrokerClient}。
69+
*/
6470
public DefaultFitExecutor(BeanContainer container, BrokerClient brokerClient) {
6571
this.beanContainer = notNull(container, "The bean container cannot be null.");
6672
this.brokerClient = notNull(brokerClient, "The fit broker client cannot be null.");

framework/ohscript/src/main/java/modelengine/fit/ohscript/external/support/DefaultHttpExecutor.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,11 @@ public class DefaultHttpExecutor implements HttpExecutor {
4646

4747
private final HttpClassicClient httpClient;
4848

49+
/**
50+
* 通过 Http 客户端来初始化 {@link DefaultHttpExecutor} 的新实例。
51+
*
52+
* @param httpClient 表示 Http 客户端的 {@link HttpClassicClient}。
53+
*/
4954
public DefaultHttpExecutor(HttpClassicClient httpClient) {
5055
this.httpClient = notNull(httpClient, "The http classic client cannot be null.");
5156
}

framework/ohscript/src/main/java/modelengine/fit/ohscript/script/engine/OhScript.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ public class OhScript {
2626

2727
private Serializer<AST> serializer;
2828

29+
/**
30+
* 构造函数,创建一个新的OhScript实例
31+
* 初始化解析器构建器
32+
*/
2933
public OhScript() {
3034
this.parserBuilder = new ParserBuilder();
3135
}
@@ -102,6 +106,7 @@ public Object execute(String code) throws OhPanic {
102106
*
103107
* @param object 要扩展的对象
104108
* @param code ohscript代码
109+
* @param <T> 表示要扩展的对象的类型的 {@link T}。
105110
* @return 扩展后的对象
106111
* @throws Exception 异常
107112
*/
@@ -115,6 +120,7 @@ public <T> T extend(T object, String code) throws Exception {
115120
*
116121
* @param clazz 要实现的类
117122
* @param code ohscript代码
123+
* @param <T> 表示实现的类型的 {@link T}。
118124
* @return 一个实现类的对象
119125
* @throws Exception 异常
120126
*/

0 commit comments

Comments
 (0)