Skip to content

Commit 8516299

Browse files
committed
refactor: rename jfinal-3.6 to jfinal-3.2 and update package references
- Changed minimum supported version from 3.6 to 3.2 to extend compatibility - Renamed instrumentation module from jfinal-3.6 to jfinal-3.2 - Updated all package names from v3_6 to v3_2 - Added classLoader matcher to distinguish between JFinal 3.2 and 3.6+ - Changed HandleAdvice class visibility from private to public - Updated documentation to reflect new version support Change-Id: If3a9bc00c0e0ee59328971f3e9cc0152d7defe67
1 parent 85ce47f commit 8516299

File tree

10 files changed

+11
-10
lines changed

10 files changed

+11
-10
lines changed

docs/supported-libraries.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ These are the supported libraries and frameworks:
9696
| [JBoss Log Manager](https://github.com/jboss-logging/jboss-logmanager) | 1.1+ | N/A | none |
9797
| [JDBC](https://docs.oracle.com/javase/8/docs/api/java/sql/package-summary.html) | Java 8+ | [opentelemetry-jdbc](../instrumentation/jdbc/library) | [Database Client Spans], [Database Client Metrics] [6] |
9898
| [Jedis](https://github.com/xetorthio/jedis) | 1.4+ | N/A | [Database Client Spans], [Database Client Metrics] [6] |
99-
| [JFinal](https://github.com/jfinal/jfinal) | 3.6+ | N/A | Provides `http.route` [2], Controller Spans [3] |
99+
| [JFinal](https://github.com/jfinal/jfinal) | 3.2+ | N/A | Provides `http.route` [2], Controller Spans [3] |
100100
| [JMS](https://javaee.github.io/javaee-spec/javadocs/javax/jms/package-summary.html) | 1.1+ | N/A | [Messaging Spans] |
101101
| [Jodd Http](https://http.jodd.org/) | 4.2+ | N/A | [HTTP Client Spans], [HTTP Client Metrics] |
102102
| [JSP](https://javaee.github.io/javaee-spec/javadocs/javax/servlet/jsp/package-summary.html) | 2.3.x only | N/A | Controller Spans [3] |

instrumentation/jfinal-3.6/javaagent/build.gradle.kts renamed to instrumentation/jfinal-3.2/javaagent/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ muzzle {
66
pass {
77
group.set("com.jfinal")
88
module.set("jfinal")
9-
versions.set("[3.6,)")
9+
versions.set("[3.2,)")
1010
assertInverse.set(true)
1111
}
1212
}
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6-
package io.opentelemetry.javaagent.instrumentation.jfinal.v3_6;
6+
package io.opentelemetry.javaagent.instrumentation.jfinal.v3_2;
77

8-
import static io.opentelemetry.javaagent.instrumentation.jfinal.v3_6.JFinalSingletons.instrumenter;
8+
import static io.opentelemetry.javaagent.instrumentation.jfinal.v3_2.JFinalSingletons.instrumenter;
99
import static net.bytebuddy.matcher.ElementMatchers.named;
1010
import static net.bytebuddy.matcher.ElementMatchers.takesArgument;
1111
import static net.bytebuddy.matcher.ElementMatchers.takesArguments;
@@ -40,7 +40,7 @@ public void transform(TypeTransformer transformer) {
4040
}
4141

4242
@SuppressWarnings("unused")
43-
private static class HandleAdvice {
43+
public static class HandleAdvice {
4444

4545
public static class AdviceScope {
4646
private final Context context;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6-
package io.opentelemetry.javaagent.instrumentation.jfinal.v3_6;
6+
package io.opentelemetry.javaagent.instrumentation.jfinal.v3_2;
77

88
import static net.bytebuddy.matcher.ElementMatchers.named;
99

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,11 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6-
package io.opentelemetry.javaagent.instrumentation.jfinal.v3_6;
6+
package io.opentelemetry.javaagent.instrumentation.jfinal.v3_2;
77

88
import static io.opentelemetry.javaagent.extension.matcher.AgentElementMatchers.hasClassesNamed;
99
import static java.util.Arrays.asList;
10+
import static net.bytebuddy.matcher.ElementMatchers.not;
1011

1112
import com.google.auto.service.AutoService;
1213
import io.opentelemetry.javaagent.extension.instrumentation.InstrumentationModule;
@@ -22,7 +23,7 @@ public JFinalInstrumentationModule() {
2223

2324
@Override
2425
public ElementMatcher.Junction<ClassLoader> classLoaderMatcher() {
25-
return hasClassesNamed("com.jfinal.core.ActionMapping");
26+
return hasClassesNamed("com.jfinal.core.ActionMapping").and(not(hasClassesNamed("com.jfinal.core.TypeConverter")));
2627
}
2728

2829
@Override
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6-
package io.opentelemetry.javaagent.instrumentation.jfinal.v3_6;
6+
package io.opentelemetry.javaagent.instrumentation.jfinal.v3_2;
77

88
import com.jfinal.core.Action;
99
import com.jfinal.core.Controller;

settings.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ include(":instrumentation:jetty-httpclient:jetty-httpclient-9.2:testing")
383383
include(":instrumentation:jetty-httpclient:jetty-httpclient-12.0:javaagent")
384384
include(":instrumentation:jetty-httpclient:jetty-httpclient-12.0:library")
385385
include(":instrumentation:jetty-httpclient:jetty-httpclient-12.0:testing")
386-
include(":instrumentation:jfinal-3.6:javaagent")
386+
include(":instrumentation:jfinal-3.2:javaagent")
387387
include(":instrumentation:jms:jms-1.1:javaagent")
388388
include(":instrumentation:jms:jms-3.0:javaagent")
389389
include(":instrumentation:jms:jms-common:bootstrap")

0 commit comments

Comments
 (0)