You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by da...@apache.org on 2021/05/26 12:00:59 UTC

[skywalking] branch dmsolr-patch-1 created (now f6f5af1)

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

daming pushed a change to branch dmsolr-patch-1
in repository https://gitbox.apache.org/repos/asf/skywalking.git.


      at f6f5af1  Update MeterSystem.java

This branch includes the following new commits:

     new f6f5af1  Update MeterSystem.java

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


[skywalking] 01/01: Update MeterSystem.java

Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

daming pushed a commit to branch dmsolr-patch-1
in repository https://gitbox.apache.org/repos/asf/skywalking.git

commit f6f5af1b437bd1f65d0f4452fb54429c2ee6e617
Author: Daming <zt...@foxmail.com>
AuthorDate: Wed May 26 20:00:34 2021 +0800

    Update MeterSystem.java
---
 .../skywalking/oap/server/core/analysis/meter/MeterSystem.java    | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/analysis/meter/MeterSystem.java b/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/analysis/meter/MeterSystem.java
index 8a40066..9930155 100644
--- a/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/analysis/meter/MeterSystem.java
+++ b/oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/analysis/meter/MeterSystem.java
@@ -58,7 +58,7 @@ public class MeterSystem implements Service {
     private static final String METER_CLASS_PACKAGE = "org.apache.skywalking.oap.server.core.analysis.meter.dynamic.";
     private ModuleManager manager;
     private ClassPool classPool;
-    private Map<String, Class<? extends MeterFunction>> functionRegister = new HashMap<>();
+    private Map<String, Class<? extends AcceptableValue>> functionRegister = new HashMap<>();
     /**
      * Host the dynamic meter prototype classes. These classes could be create dynamically through {@link
      * Object#clone()} in the runtime;
@@ -87,7 +87,7 @@ public class MeterSystem implements Service {
                 }
                 functionRegister.put(
                     metricsFunction.functionName(),
-                    (Class<? extends MeterFunction>) functionClass
+                    (Class<? extends AcceptableValue>) functionClass
                 );
             }
         }
@@ -105,7 +105,7 @@ public class MeterSystem implements Service {
     public synchronized <T> void create(String metricsName,
         String functionName,
         ScopeType type) throws IllegalArgumentException {
-        final Class<? extends MeterFunction> meterFunction = functionRegister.get(functionName);
+        final Class<? extends AcceptableValue> meterFunction = functionRegister.get(functionName);
 
         if (meterFunction == null) {
             throw new IllegalArgumentException("Function " + functionName + " can't be found.");
@@ -144,7 +144,7 @@ public class MeterSystem implements Service {
         /**
          * Create a new meter class dynamically.
          */
-        final Class<? extends MeterFunction> meterFunction = functionRegister.get(functionName);
+        final Class<? extends AcceptableValue> meterFunction = functionRegister.get(functionName);
 
         if (meterFunction == null) {
             throw new IllegalArgumentException("Function " + functionName + " can't be found.");