diff --git a/.artifacts b/.artifacts
index 7711cde1ea..3f3d84b604 100644
--- a/.artifacts
+++ b/.artifacts
@@ -120,3 +120,7 @@ dubbo-tracing
dubbo-xds
dubbo-plugin-proxy-bytebuddy
dubbo-plugin-loom
+dubbo-rest-jaxrs
+dubbo-rest-servlet
+dubbo-rest-spring
+
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/extension/ExtensionAccessor.java b/dubbo-common/src/main/java/org/apache/dubbo/common/extension/ExtensionAccessor.java
index 14c4882b60..c9ed110845 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/extension/ExtensionAccessor.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/extension/ExtensionAccessor.java
@@ -16,6 +16,9 @@
*/
package org.apache.dubbo.common.extension;
+import java.util.Collections;
+import java.util.List;
+
/**
* Uniform accessor for extension
*/
@@ -24,7 +27,7 @@ public interface ExtensionAccessor {
ExtensionDirector getExtensionDirector();
default ExtensionLoader getExtensionLoader(Class type) {
- return this.getExtensionDirector().getExtensionLoader(type);
+ return getExtensionDirector().getExtensionLoader(type);
}
default T getExtension(Class type, String name) {
@@ -41,4 +44,21 @@ public interface ExtensionAccessor {
ExtensionLoader extensionLoader = getExtensionLoader(type);
return extensionLoader != null ? extensionLoader.getDefaultExtension() : null;
}
+
+ default List getActivateExtensions(Class type) {
+ ExtensionLoader extensionLoader = getExtensionLoader(type);
+ return extensionLoader != null ? extensionLoader.getActivateExtensions() : Collections.emptyList();
+ }
+
+ default T getFirstActivateExtension(Class type) {
+ ExtensionLoader extensionLoader = getExtensionLoader(type);
+ if (extensionLoader == null) {
+ throw new IllegalArgumentException("ExtensionLoader for [" + type + "] is not found");
+ }
+ List extensions = extensionLoader.getActivateExtensions();
+ if (extensions.isEmpty()) {
+ throw new IllegalArgumentException("No activate extensions for [" + type + "] found");
+ }
+ return extensions.get(0);
+ }
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/io/StreamUtils.java b/dubbo-common/src/main/java/org/apache/dubbo/common/io/StreamUtils.java
index b0badff64e..9e10135d87 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/io/StreamUtils.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/io/StreamUtils.java
@@ -16,8 +16,13 @@
*/
package org.apache.dubbo.common.io;
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.InputStream;
+import java.io.OutputStream;
+import java.nio.charset.Charset;
+import java.nio.charset.StandardCharsets;
/**
* Stream utils.
@@ -229,4 +234,51 @@ public class StreamUtils {
is.skip(is.available());
}
}
+
+ public static void copy(InputStream in, OutputStream out) throws IOException {
+ if (in.getClass() == ByteArrayInputStream.class) {
+ copy((ByteArrayInputStream) in, out);
+ return;
+ }
+ byte[] buffer = new byte[4096];
+ int bytesRead;
+ while ((bytesRead = in.read(buffer)) != -1) {
+ out.write(buffer, 0, bytesRead);
+ }
+ }
+
+ public static void copy(ByteArrayInputStream in, OutputStream out) throws IOException {
+ int len = in.available();
+ byte[] buffer = new byte[len];
+ in.read(buffer, 0, len);
+ out.write(buffer, 0, len);
+ }
+
+ public static byte[] readBytes(InputStream in) throws IOException {
+ if (in.getClass() == ByteArrayInputStream.class) {
+ return readBytes((ByteArrayInputStream) in);
+ }
+ ByteArrayOutputStream out = new ByteArrayOutputStream();
+ byte[] buffer = new byte[4096];
+ int bytesRead;
+ while ((bytesRead = in.read(buffer)) != -1) {
+ out.write(buffer, 0, bytesRead);
+ }
+ return out.toByteArray();
+ }
+
+ public static byte[] readBytes(ByteArrayInputStream in) throws IOException {
+ int len = in.available();
+ byte[] bytes = new byte[len];
+ in.read(bytes, 0, len);
+ return bytes;
+ }
+
+ public static String toString(InputStream in) throws IOException {
+ return new String(readBytes(in), StandardCharsets.UTF_8);
+ }
+
+ public static String toString(InputStream in, Charset charset) throws IOException {
+ return new String(readBytes(in), charset);
+ }
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/json/JsonUtil.java b/dubbo-common/src/main/java/org/apache/dubbo/common/json/JsonUtil.java
index cc94b77eba..b03092ab7a 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/json/JsonUtil.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/json/JsonUtil.java
@@ -40,6 +40,10 @@ public interface JsonUtil {
Map getObject(Map obj, String key);
+ Object convertObject(Object obj, Type type);
+
+ Object convertObject(Object obj, Class> clazz);
+
Double getNumberAsDouble(Map obj, String key);
Integer getNumberAsInteger(Map obj, String key);
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/FastJson2Impl.java b/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/FastJson2Impl.java
index f7741b229c..09c795bb6e 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/FastJson2Impl.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/FastJson2Impl.java
@@ -36,4 +36,14 @@ public class FastJson2Impl extends AbstractJsonUtilImpl {
public String toJson(Object obj) {
return com.alibaba.fastjson2.JSON.toJSONString(obj, JSONWriter.Feature.WriteEnumsUsingName);
}
+
+ @Override
+ public Object convertObject(Object obj, Type type) {
+ return com.alibaba.fastjson2.util.TypeUtils.cast(obj, type);
+ }
+
+ @Override
+ public Object convertObject(Object obj, Class> clazz) {
+ return com.alibaba.fastjson2.util.TypeUtils.cast(obj, clazz);
+ }
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/FastJsonImpl.java b/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/FastJsonImpl.java
index 756dc9457c..a44291cc6e 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/FastJsonImpl.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/FastJsonImpl.java
@@ -19,6 +19,7 @@ package org.apache.dubbo.common.json.impl;
import java.lang.reflect.Type;
import java.util.List;
+import com.alibaba.fastjson.parser.ParserConfig;
import com.alibaba.fastjson.serializer.SerializerFeature;
public class FastJsonImpl extends AbstractJsonUtilImpl {
@@ -37,4 +38,14 @@ public class FastJsonImpl extends AbstractJsonUtilImpl {
public String toJson(Object obj) {
return com.alibaba.fastjson.JSON.toJSONString(obj, SerializerFeature.DisableCircularReferenceDetect);
}
+
+ @Override
+ public Object convertObject(Object obj, Type type) {
+ return com.alibaba.fastjson.util.TypeUtils.cast(obj, type, ParserConfig.getGlobalInstance());
+ }
+
+ @Override
+ public Object convertObject(Object obj, Class> clazz) {
+ return com.alibaba.fastjson.util.TypeUtils.cast(obj, clazz, ParserConfig.getGlobalInstance());
+ }
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/GsonImpl.java b/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/GsonImpl.java
index 2a0cad78fa..39586cb19e 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/GsonImpl.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/GsonImpl.java
@@ -42,6 +42,18 @@ public class GsonImpl extends AbstractJsonUtilImpl {
return getGson().toJson(obj);
}
+ @Override
+ public Object convertObject(Object obj, Type type) {
+ Gson gson = getGson();
+ return gson.fromJson(gson.toJsonTree(obj), type);
+ }
+
+ @Override
+ public Object convertObject(Object obj, Class> clazz) {
+ Gson gson = getGson();
+ return gson.fromJson(gson.toJsonTree(obj), clazz);
+ }
+
private Gson getGson() {
if (gsonCache == null || !(gsonCache instanceof Gson)) {
synchronized (this) {
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/JacksonImpl.java b/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/JacksonImpl.java
index 3e21416dcf..686f176ea7 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/JacksonImpl.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/json/impl/JacksonImpl.java
@@ -59,6 +59,17 @@ public class JacksonImpl extends AbstractJsonUtilImpl {
}
}
+ @Override
+ public Object convertObject(Object obj, Type type) {
+ JsonMapper mapper = getJackson();
+ return mapper.convertValue(obj, mapper.constructType(type));
+ }
+
+ @Override
+ public Object convertObject(Object obj, Class> clazz) {
+ return getJackson().convertValue(obj, clazz);
+ }
+
private JsonMapper getJackson() {
if (jacksonCache == null || !(jacksonCache instanceof JsonMapper)) {
synchronized (this) {
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/ArrayUtils.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/ArrayUtils.java
index 92efcc2619..ddc8095e80 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/ArrayUtils.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/ArrayUtils.java
@@ -76,4 +76,8 @@ public final class ArrayUtils {
public static T[] of(T... values) {
return values;
}
+
+ public static T first(T[] data) {
+ return isEmpty(data) ? null : data[0];
+ }
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Assert.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Assert.java
index f7a88f033b..8a8cd1d8e1 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Assert.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Assert.java
@@ -28,6 +28,12 @@ public abstract class Assert {
}
}
+ public static void notNull(Object obj, String format, Object... args) {
+ if (obj == null) {
+ throw new IllegalArgumentException(String.format(format, args));
+ }
+ }
+
public static void notEmptyString(String str, String message) {
if (StringUtils.isEmpty(str)) {
throw new IllegalArgumentException(message);
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/ClassUtils.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/ClassUtils.java
index 88eca7a2e4..6c0656dae6 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/ClassUtils.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/ClassUtils.java
@@ -327,6 +327,10 @@ public class ClassUtils {
return type != null && (type.isPrimitive() || isSimpleType(type));
}
+ public static boolean isPrimitiveWrapper(Class> type) {
+ return PRIMITIVE_WRAPPER_TYPE_MAP.containsKey(type);
+ }
+
/**
* The specified type is simple type or not
*
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/CollectionUtils.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/CollectionUtils.java
index df6388c936..3514011e60 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/CollectionUtils.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/CollectionUtils.java
@@ -24,11 +24,14 @@ import java.util.Collections;
import java.util.Comparator;
import java.util.HashMap;
import java.util.HashSet;
+import java.util.LinkedHashMap;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.TreeSet;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.function.Function;
import java.util.stream.Collectors;
import static java.util.Collections.emptySet;
@@ -404,13 +407,19 @@ public class CollectionUtils {
return null;
}
if (values instanceof List) {
- List list = (List) values;
- return list.get(0);
+ return ((List) values).get(0);
} else {
return values.iterator().next();
}
}
+ public static T first(List values) {
+ if (isEmpty(values)) {
+ return null;
+ }
+ return values.get(0);
+ }
+
public static Set toTreeSet(Set set) {
if (isEmpty(set)) {
return set;
@@ -420,4 +429,78 @@ public class CollectionUtils {
}
return set;
}
+
+ public static Set newHashSet(int expectedSize) {
+ return new HashSet<>(capacity(expectedSize));
+ }
+
+ public static Set newLinkedHashSet(int expectedSize) {
+ return new LinkedHashSet<>(capacity(expectedSize));
+ }
+
+ public static Map newHashMap(int expectedSize) {
+ return new HashMap<>(capacity(expectedSize));
+ }
+
+ public static Map newLinkedHashMap(int expectedSize) {
+ return new LinkedHashMap<>(capacity(expectedSize));
+ }
+
+ public static Map newConcurrentHashMap(int expectedSize) {
+ if (JRE.JAVA_8.isCurrentVersion()) {
+ return new SafeConcurrentHashMap<>(capacity(expectedSize));
+ }
+ return new ConcurrentHashMap<>(capacity(expectedSize));
+ }
+
+ public static Map newConcurrentHashMap() {
+ if (JRE.JAVA_8.isCurrentVersion()) {
+ return new SafeConcurrentHashMap<>();
+ }
+ return new ConcurrentHashMap<>();
+ }
+
+ public static int capacity(int expectedSize) {
+ if (expectedSize < 3) {
+ if (expectedSize < 0) {
+ throw new IllegalArgumentException("expectedSize cannot be negative but was: " + expectedSize);
+ }
+ return expectedSize + 1;
+ }
+ if (expectedSize < 1 << (Integer.SIZE - 2)) {
+ return (int) (expectedSize / 0.75F + 1.0F);
+ }
+ return Integer.MAX_VALUE;
+ }
+
+ public static class SafeConcurrentHashMap extends ConcurrentHashMap {
+ private static final long serialVersionUID = 1L;
+
+ public SafeConcurrentHashMap() {}
+
+ public SafeConcurrentHashMap(int initialCapacity) {
+ super(initialCapacity);
+ }
+
+ public SafeConcurrentHashMap(Map extends K, ? extends V> m) {
+ super(m);
+ }
+
+ @Override
+ public V computeIfAbsent(K key, Function super K, ? extends V> mappingFunction) {
+ V value = get(key);
+ if (value != null) {
+ return value;
+ }
+ value = mappingFunction.apply(key);
+ if (value == null) {
+ return null;
+ }
+ V exists = putIfAbsent(key, value);
+ if (exists != null) {
+ return exists;
+ }
+ return value;
+ }
+ }
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/DateUtils.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/DateUtils.java
new file mode 100644
index 0000000000..764ed3ce46
--- /dev/null
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/DateUtils.java
@@ -0,0 +1,259 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.common.utils;
+
+import java.time.Instant;
+import java.time.LocalDate;
+import java.time.ZoneId;
+import java.time.ZonedDateTime;
+import java.time.format.DateTimeFormatter;
+import java.time.temporal.ChronoField;
+import java.time.temporal.TemporalAccessor;
+import java.util.Calendar;
+import java.util.Date;
+import java.util.List;
+import java.util.Locale;
+import java.util.Map;
+import java.util.TimeZone;
+import java.util.concurrent.CopyOnWriteArrayList;
+
+public final class DateUtils {
+
+ public static final ZoneId GMT = ZoneId.of("GMT");
+ public static final ZoneId UTC = ZoneId.of("UTC");
+
+ public static final String DATE = "yyyy-MM-dd";
+ public static final String DATE_MIN = "yyyy-MM-dd HH:mm";
+ public static final String DATE_TIME = "yyyy-MM-dd HH:mm:ss";
+ public static final String JDK_TIME = "EEE MMM dd HH:mm:ss zzz yyyy";
+ public static final String ASC_TIME = "EEE MMM d HH:mm:ss yyyy";
+ public static final String RFC1036 = "EEE, dd-MMM-yy HH:mm:ss zzz";
+
+ public static final DateTimeFormatter DATE_FORMAT = DateTimeFormatter.ofPattern(DATE);
+ public static final DateTimeFormatter DATE_MIN_FORMAT = DateTimeFormatter.ofPattern(DATE_MIN);
+ public static final DateTimeFormatter DATE_TIME_FORMAT = DateTimeFormatter.ofPattern(DATE_TIME);
+ public static final DateTimeFormatter JDK_TIME_FORMAT = DateTimeFormatter.ofPattern(JDK_TIME, Locale.US);
+ public static final DateTimeFormatter ASC_TIME_FORMAT = DateTimeFormatter.ofPattern(ASC_TIME, Locale.US);
+ public static final DateTimeFormatter RFC1036_FORMAT = DateTimeFormatter.ofPattern(RFC1036, Locale.US);
+
+ private static final Map CACHE = new LRUCache<>(64);
+ private static final List CUSTOM_FORMATTERS = new CopyOnWriteArrayList<>();
+
+ private DateUtils() {}
+
+ public static void registerFormatter(String pattern) {
+ CUSTOM_FORMATTERS.add(DateTimeFormatter.ofPattern(pattern));
+ }
+
+ public static void registerFormatter(DateTimeFormatter formatter) {
+ CUSTOM_FORMATTERS.add(formatter);
+ }
+
+ public static Date parse(String str, String pattern) {
+ if (DATE_TIME.equals(pattern)) {
+ return parse(str, DATE_TIME_FORMAT);
+ }
+ DateTimeFormatter formatter = getFormatter(pattern);
+ return parse(str, formatter);
+ }
+
+ public static Date parse(String str, DateTimeFormatter formatter) {
+ return toDate(formatter.parse(str));
+ }
+
+ public static String format(Date date) {
+ return format(date, DATE_TIME_FORMAT);
+ }
+
+ public static String format(Date date, String pattern) {
+ if (DATE_TIME.equals(pattern)) {
+ return format(date, DATE_TIME_FORMAT);
+ }
+ DateTimeFormatter formatter = getFormatter(pattern);
+ return format(date, formatter);
+ }
+
+ public static String format(Date date, DateTimeFormatter formatter) {
+ return formatter.format(ZonedDateTime.ofInstant(date.toInstant(), ZoneId.systemDefault()));
+ }
+
+ public static String format(Date date, DateTimeFormatter formatter, ZoneId zone) {
+ return formatter.format(ZonedDateTime.ofInstant(date.toInstant(), zone));
+ }
+
+ public static String formatGMT(Date date, DateTimeFormatter formatter) {
+ return formatter.format(ZonedDateTime.ofInstant(date.toInstant(), GMT));
+ }
+
+ public static String formatUTC(Date date, DateTimeFormatter formatter) {
+ return formatter.format(ZonedDateTime.ofInstant(date.toInstant(), UTC));
+ }
+
+ public static String formatHeader(Date date) {
+ return DateTimeFormatter.RFC_1123_DATE_TIME.format(ZonedDateTime.ofInstant(date.toInstant(), GMT));
+ }
+
+ private static DateTimeFormatter getFormatter(String pattern) {
+ return CACHE.computeIfAbsent(pattern, DateTimeFormatter::ofPattern);
+ }
+
+ public static Date parse(Object value) {
+ if (value == null) {
+ return null;
+ }
+ if (value instanceof Date) {
+ return (Date) value;
+ }
+ if (value instanceof Calendar) {
+ return ((Calendar) value).getTime();
+ }
+ if (value.getClass() == Instant.class) {
+ return Date.from((Instant) value);
+ }
+ if (value instanceof TemporalAccessor) {
+ return Date.from(Instant.from((TemporalAccessor) value));
+ }
+ if (value instanceof Number) {
+ return new Date(((Number) value).longValue());
+ }
+ if (value instanceof CharSequence) {
+ return parse(value.toString());
+ }
+ throw new IllegalArgumentException("Can not cast to Date, value : '" + value + "'");
+ }
+
+ public static Date parse(String value) {
+ if (value == null) {
+ return null;
+ }
+ String str = value.trim();
+ int len = str.length();
+ if (len == 0) {
+ return null;
+ }
+
+ boolean isIso = true;
+ boolean isNumeric = true;
+ boolean hasDate = false;
+ boolean hasTime = false;
+ for (int i = 0; i < len; i++) {
+ char c = str.charAt(i);
+ switch (c) {
+ case ' ':
+ isIso = false;
+ break;
+ case '-':
+ hasDate = true;
+ break;
+ case 'T':
+ case ':':
+ hasTime = true;
+ break;
+ case '0':
+ case '1':
+ case '2':
+ case '3':
+ case '4':
+ case '5':
+ case '6':
+ case '7':
+ case '8':
+ case '9':
+ continue;
+ default:
+ }
+ if (isNumeric) {
+ isNumeric = false;
+ }
+ }
+ DateTimeFormatter formatter = null;
+ if (isIso) {
+ if (hasDate) {
+ formatter = hasTime ? DateTimeFormatter.ISO_DATE_TIME : DateTimeFormatter.ISO_DATE;
+ } else if (hasTime) {
+ formatter = DateTimeFormatter.ISO_TIME;
+ }
+ }
+ if (isNumeric) {
+ long num = Long.parseLong(str);
+ if (num > 21000101 || num < 19700101) {
+ return new Date(num);
+ }
+ formatter = DateTimeFormatter.BASIC_ISO_DATE;
+ }
+ switch (len) {
+ case 10:
+ formatter = DATE_FORMAT;
+ break;
+ case 16:
+ formatter = DATE_MIN_FORMAT;
+ break;
+ case 19:
+ formatter = DATE_TIME_FORMAT;
+ break;
+ case 23:
+ case 24:
+ formatter = ASC_TIME_FORMAT;
+ break;
+ case 27:
+ formatter = RFC1036_FORMAT;
+ break;
+ case 28:
+ formatter = JDK_TIME_FORMAT;
+ break;
+ case 29:
+ formatter = DateTimeFormatter.RFC_1123_DATE_TIME;
+ break;
+ default:
+ }
+
+ if (formatter != null) {
+ try {
+ return toDate(formatter.parse(str));
+ } catch (Exception ignored) {
+ }
+ }
+ for (DateTimeFormatter dtf : CUSTOM_FORMATTERS) {
+ try {
+ return parse(str, dtf);
+ } catch (Exception ignored) {
+ }
+ }
+ throw new IllegalArgumentException("Can not cast to Date, value : '" + value + "'");
+ }
+
+ public static Date toDate(TemporalAccessor temporal) {
+ if (temporal instanceof Instant) {
+ return Date.from((Instant) temporal);
+ }
+ long timestamp;
+ if (temporal.isSupported(ChronoField.EPOCH_DAY)) {
+ timestamp = temporal.getLong(ChronoField.EPOCH_DAY) * 86400000;
+ } else {
+ timestamp = LocalDate.now().toEpochDay() * 86400000;
+ }
+ if (temporal.isSupported(ChronoField.MILLI_OF_DAY)) {
+ timestamp += temporal.getLong(ChronoField.MILLI_OF_DAY);
+ }
+ if (temporal.isSupported(ChronoField.OFFSET_SECONDS)) {
+ timestamp -= temporal.getLong(ChronoField.OFFSET_SECONDS) * 1000;
+ } else {
+ timestamp -= TimeZone.getDefault().getRawOffset();
+ }
+ return new Date(timestamp);
+ }
+}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/JsonUtils.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/JsonUtils.java
index 2b47ee3ed5..767ea5a42e 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/JsonUtils.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/JsonUtils.java
@@ -53,6 +53,7 @@ public class JsonUtils {
case "jackson":
instance = new JacksonImpl();
break;
+ default:
}
if (instance != null && instance.isSupport()) {
jsonUtil = instance;
@@ -123,6 +124,14 @@ public class JsonUtils {
return getJson().getObject(obj, key);
}
+ public static Object convertObject(Object obj, Type targetType) {
+ return getJson().convertObject(obj, targetType);
+ }
+
+ public static Object convertObject(Object obj, Class> targetType) {
+ return getJson().convertObject(obj, targetType);
+ }
+
public static Double getNumberAsDouble(Map obj, String key) {
return getJson().getNumberAsDouble(obj, key);
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LRU2Cache.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LRU2Cache.java
index 2a725e9334..b17674ffc0 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LRU2Cache.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LRU2Cache.java
@@ -19,13 +19,14 @@ package org.apache.dubbo.common.utils;
import java.util.LinkedHashMap;
import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReentrantLock;
+import java.util.function.Function;
/**
* LRU-2
- *
+ *
* When the data accessed for the first time, add it to history list. If the size of history list reaches max capacity, eliminate the earliest data (first in first out).
* When the data already exists in the history list, and be accessed for the second time, then it will be put into cache.
- *
+ *
* TODO, consider replacing with ConcurrentHashMap to improve performance under concurrency
*/
public class LRU2Cache extends LinkedHashMap {
@@ -33,8 +34,8 @@ public class LRU2Cache extends LinkedHashMap {
private static final long serialVersionUID = -5167631809472116969L;
private static final float DEFAULT_LOAD_FACTOR = 0.75f;
-
private static final int DEFAULT_MAX_CAPACITY = 1000;
+
private final Lock lock = new ReentrantLock();
private volatile int maxCapacity;
@@ -94,6 +95,16 @@ public class LRU2Cache extends LinkedHashMap {
}
}
+ @Override
+ public V computeIfAbsent(K key, Function super K, ? extends V> fn) {
+ V value = get(key);
+ if (value == null) {
+ value = fn.apply(key);
+ put(key, value);
+ }
+ return value;
+ }
+
@Override
public V remove(Object key) {
lock.lock();
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LRUCache.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LRUCache.java
index 76d6c19cb7..079fb0766a 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LRUCache.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/LRUCache.java
@@ -19,6 +19,7 @@ package org.apache.dubbo.common.utils;
import java.util.LinkedHashMap;
import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReentrantLock;
+import java.util.function.Function;
/**
* A 'least recently used' cache based on LinkedHashMap.
@@ -31,8 +32,8 @@ public class LRUCache extends LinkedHashMap {
private static final long serialVersionUID = -5167631809472116969L;
private static final float DEFAULT_LOAD_FACTOR = 0.75f;
-
private static final int DEFAULT_MAX_CAPACITY = 1000;
+
private final Lock lock = new ReentrantLock();
private volatile int maxCapacity;
@@ -110,6 +111,20 @@ public class LRUCache extends LinkedHashMap {
}
}
+ @Override
+ public V computeIfAbsent(K key, Function super K, ? extends V> fn) {
+ V value = get(key);
+ if (value == null) {
+ lock.lock();
+ try {
+ return super.computeIfAbsent(key, fn);
+ } finally {
+ lock.unlock();
+ }
+ }
+ return value;
+ }
+
public void lock() {
lock.lock();
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Pair.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Pair.java
new file mode 100644
index 0000000000..d719ff3061
--- /dev/null
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/Pair.java
@@ -0,0 +1,138 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.common.utils;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import java.util.Objects;
+
+public final class Pair implements Map.Entry, Comparable>, Serializable {
+
+ private static final long serialVersionUID = 1L;
+
+ @SuppressWarnings("rawtypes")
+ private static final Pair NULL = new Pair<>(null, null);
+
+ public final L left;
+ public final R right;
+
+ public static Pair of(L left, R right) {
+ return left == null && right == null ? nullPair() : new Pair<>(left, right);
+ }
+
+ @SuppressWarnings("unchecked")
+ public static Pair nullPair() {
+ return NULL;
+ }
+
+ @SafeVarargs
+ public static Map toMap(Pair... pairs) {
+ if (pairs == null) {
+ return Collections.emptyMap();
+ }
+ return toMap(Arrays.asList(pairs));
+ }
+
+ public static Map toMap(Collection> pairs) {
+ if (pairs == null) {
+ return Collections.emptyMap();
+ }
+ Map map = CollectionUtils.newLinkedHashMap(pairs.size());
+ for (Pair pair : pairs) {
+ map.put(pair.getLeft(), pair.getRight());
+ }
+ return map;
+ }
+
+ public static List> toPairs(Map map) {
+ if (map == null) {
+ return Collections.emptyList();
+ }
+ List> pairs = new ArrayList<>(map.size());
+ for (Map.Entry entry : map.entrySet()) {
+ pairs.add(of(entry.getKey(), entry.getValue()));
+ }
+ return pairs;
+ }
+
+ public Pair(L left, R right) {
+ this.left = left;
+ this.right = right;
+ }
+
+ public L getLeft() {
+ return left;
+ }
+
+ public R getRight() {
+ return right;
+ }
+
+ public boolean isNull() {
+ return this == NULL || left == null && right == null;
+ }
+
+ @Override
+ public L getKey() {
+ return left;
+ }
+
+ @Override
+ public R getValue() {
+ return right;
+ }
+
+ @Override
+ public R setValue(R value) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public int compareTo(Pair other) {
+ return left.equals(other.left)
+ ? ((Comparable) right).compareTo(other.right)
+ : ((Comparable) left).compareTo(other.left);
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hashCode(left) ^ Objects.hashCode(right);
+ }
+
+ @Override
+ public boolean equals(Object other) {
+ if (this == other) {
+ return true;
+ }
+ if (other instanceof Map.Entry) {
+ Map.Entry, ?> that = (Map.Entry, ?>) other;
+ return Objects.equals(left, that.getKey()) && Objects.equals(right, that.getValue());
+ }
+ return false;
+ }
+
+ @Override
+ public String toString() {
+ return "(" + left + ", " + right + ')';
+ }
+}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/StringUtils.java b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/StringUtils.java
index 0a8cba4bcd..2b86d0e256 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/common/utils/StringUtils.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/common/utils/StringUtils.java
@@ -1256,10 +1256,6 @@ public final class StringUtils {
/**
* Test str whether starts with the prefix ignore case.
- *
- * @param str
- * @param prefix
- * @return
*/
public static boolean startsWithIgnoreCase(String str, String prefix) {
if (str == null || prefix == null || str.length() < prefix.length()) {
@@ -1268,4 +1264,102 @@ public final class StringUtils {
// return str.substring(0, prefix.length()).equalsIgnoreCase(prefix);
return str.regionMatches(true, 0, prefix, 0, prefix.length());
}
+
+ public static String defaultIf(String str, String defaultStr) {
+ return isEmpty(str) ? defaultStr : str;
+ }
+
+ /**
+ * Returns a substring from 'str' between 'start' and 'end', or to the end if 'end' is -1
+ */
+ public static String substring(String str, int start, int end) {
+ if (str == null) {
+ return null;
+ }
+ return end == INDEX_NOT_FOUND ? str.substring(start) : str.substring(start, end);
+ }
+
+ /**
+ * Extracts a substring from the given string that precedes the first occurrence of the specified character separator.
+ * If the character is not found, the entire string is returned.
+ */
+ public static String substringBefore(String str, int separator) {
+ if (isEmpty(str)) {
+ return str;
+ }
+ int index = str.indexOf(separator);
+ return index == INDEX_NOT_FOUND ? str : str.substring(0, index);
+ }
+
+ /**
+ * Extracts a substring from the given string that precedes the first occurrence of the specified string separator.
+ * If the separator is not found or is null, the entire string is returned.
+ */
+ public static String substringBefore(String str, String separator) {
+ if (isEmpty(str) || separator == null) {
+ return str;
+ }
+ if (separator.isEmpty()) {
+ return EMPTY_STRING;
+ }
+ int index = str.indexOf(separator);
+ return index == INDEX_NOT_FOUND ? str : str.substring(0, index);
+ }
+
+ /**
+ * Tokenize the given String into a String array.
+ * Trims tokens and omits empty tokens.
+ */
+ public static String[] tokenize(String str, char... separators) {
+ if (isEmpty(str)) {
+ return EMPTY_STRING_ARRAY;
+ }
+ return tokenizeToList(str, separators).toArray(EMPTY_STRING_ARRAY);
+ }
+
+ public static List tokenizeToList(String str, char... separators) {
+ if (isEmpty(str)) {
+ return Collections.emptyList();
+ }
+ if (separators == null || separators.length == 0) {
+ separators = new char[] {','};
+ }
+ List tokens = new ArrayList<>();
+ int start = -1, end = 0;
+ int i = 0;
+ out:
+ for (int len = str.length(), sLen = separators.length; i < len; i++) {
+ char c = str.charAt(i);
+ for (int j = 0; j < sLen; j++) {
+ if (c == separators[j]) {
+ if (start > -1) {
+ tokens.add(str.substring(start, end + 1));
+ start = -1;
+ }
+ continue out;
+ }
+ }
+ switch (c) {
+ case ' ':
+ case '\t':
+ case '\n':
+ case '\r':
+ break;
+ default:
+ if (start == -1) {
+ start = i;
+ }
+ end = i;
+ break;
+ }
+ }
+ if (start > -1) {
+ String part = str.substring(start, end + 1);
+ if (tokens.isEmpty()) {
+ return Collections.singletonList(part);
+ }
+ tokens.add(part);
+ }
+ return tokens;
+ }
}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/config/RestConfig.java b/dubbo-common/src/main/java/org/apache/dubbo/config/RestConfig.java
new file mode 100644
index 0000000000..6a3674e119
--- /dev/null
+++ b/dubbo-common/src/main/java/org/apache/dubbo/config/RestConfig.java
@@ -0,0 +1,118 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.config;
+
+import java.io.Serializable;
+
+/**
+ * Configuration for triple rest protocol.
+ */
+public class RestConfig implements Serializable {
+
+ private static final long serialVersionUID = 1L;
+
+ /**
+ * Maximum allowed size for request bodies.
+ * Limits the size of request to prevent excessively large request.
+ *
The default value is 8MiB.
+ */
+ private Integer maxBodySize;
+
+ /**
+ * Maximum allowed size for response bodies.
+ * Limits the size of responses to prevent excessively large response.
+ *
The default value is 8MiB.
+ */
+ private Integer maxResponseBodySize;
+
+ /**
+ * Whether path matching should be match paths with a trailing slash.
+ * If enabled, a method mapped to "/users" also matches to "/users/".
+ *
The default value is {@code true}.
+ */
+ private Boolean trailingSlashMatch;
+
+ /**
+ * Whether path matching should be case-sensitive.
+ * If enabled, a method mapped to "/users" won't match to "/Users/".
+ *
The default value is {@code false}.
+ */
+ private Boolean caseSensitiveMatch;
+
+ /**
+ * Whether path matching uses suffix pattern matching (".*").
+ * If enabled, a method mapped to "/users" also matches to "/users.*".
+ *
This also enables suffix content negotiation, with the media-type
+ * inferred from the URL suffix, e.g., ".json" for "application/json".
+ *
The default value is {@code true}.
+ */
+ private Boolean suffixPatternMatch;
+
+ /**
+ * The parameter name that can be used to specify the response format.
+ *
The default value is 'format'.
+ */
+ private String formatParameterName;
+
+ public Integer getMaxBodySize() {
+ return maxBodySize;
+ }
+
+ public void setMaxBodySize(Integer maxBodySize) {
+ this.maxBodySize = maxBodySize;
+ }
+
+ public Integer getMaxResponseBodySize() {
+ return maxResponseBodySize;
+ }
+
+ public void setMaxResponseBodySize(Integer maxResponseBodySize) {
+ this.maxResponseBodySize = maxResponseBodySize;
+ }
+
+ public Boolean getTrailingSlashMatch() {
+ return trailingSlashMatch;
+ }
+
+ public void setTrailingSlashMatch(Boolean trailingSlashMatch) {
+ this.trailingSlashMatch = trailingSlashMatch;
+ }
+
+ public Boolean getCaseSensitiveMatch() {
+ return caseSensitiveMatch;
+ }
+
+ public void setCaseSensitiveMatch(Boolean caseSensitiveMatch) {
+ this.caseSensitiveMatch = caseSensitiveMatch;
+ }
+
+ public Boolean getSuffixPatternMatch() {
+ return suffixPatternMatch;
+ }
+
+ public void setSuffixPatternMatch(Boolean suffixPatternMatch) {
+ this.suffixPatternMatch = suffixPatternMatch;
+ }
+
+ public String getFormatParameterName() {
+ return formatParameterName;
+ }
+
+ public void setFormatParameterName(String formatParameterName) {
+ this.formatParameterName = formatParameterName;
+ }
+}
diff --git a/dubbo-common/src/main/java/org/apache/dubbo/config/TripleConfig.java b/dubbo-common/src/main/java/org/apache/dubbo/config/TripleConfig.java
index a10d909fbc..1b7469ee21 100644
--- a/dubbo-common/src/main/java/org/apache/dubbo/config/TripleConfig.java
+++ b/dubbo-common/src/main/java/org/apache/dubbo/config/TripleConfig.java
@@ -55,6 +55,11 @@ public class TripleConfig implements Serializable {
*/
private String maxHeaderListSize;
+ /**
+ * Whether to pass through standard HTTP headers, default is false.
+ */
+ private Boolean passThroughStandardHttpHeaders;
+
public String getHeaderTableSize() {
return headerTableSize;
}
@@ -102,4 +107,12 @@ public class TripleConfig implements Serializable {
public void setMaxHeaderListSize(String maxHeaderListSize) {
this.maxHeaderListSize = maxHeaderListSize;
}
+
+ public Boolean getPassThroughStandardHttpHeaders() {
+ return passThroughStandardHttpHeaders;
+ }
+
+ public void setPassThroughStandardHttpHeaders(Boolean passThroughStandardHttpHeaders) {
+ this.passThroughStandardHttpHeaders = passThroughStandardHttpHeaders;
+ }
}
diff --git a/dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/deploy/DefaultApplicationDeployer.java b/dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/deploy/DefaultApplicationDeployer.java
index e1e0938153..e4b37d2ad4 100644
--- a/dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/deploy/DefaultApplicationDeployer.java
+++ b/dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/deploy/DefaultApplicationDeployer.java
@@ -1218,6 +1218,7 @@ public class DefaultApplicationDeployer extends AbstractDeployer
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
- 4.0.0
-
- org.apache.dubbo
- dubbo-parent
- ${revision}
- ../../pom.xml
-
- dubbo-all-shaded
- jar
- dubbo-all-shaded
- The all in one project of dubbo with dependencies prone to conflict shaded
-
- false
-
-
-
-
- org.apache.dubbo
- dubbo-cluster
- ${project.version}
- compile
- true
-
+ 4.0.0
+
+ org.apache.dubbo
+ dubbo-parent
+ ${revision}
+ ../../pom.xml
+
+ dubbo-all-shaded
+ jar
+ dubbo-all-shaded
+ The all in one project of dubbo with dependencies prone to conflict shaded
+
+ false
+
+
+
+
+ org.apache.dubbo
+ dubbo-cluster
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-common
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-common
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-compatible
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-compatible
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-config-api
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-config-spring
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-config-api
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-config-spring
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-configcenter-zookeeper
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-configcenter-apollo
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-configcenter-nacos
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-configcenter-zookeeper
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-configcenter-apollo
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-configcenter-nacos
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-filter-cache
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-filter-validation
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-filter-cache
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-filter-validation
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-rest-jaxrs
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-rest-servlet
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-rest-spring
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-kubernetes
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-kubernetes
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-metadata-api
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-metadata-report-zookeeper
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-metadata-report-nacos
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-metadata-report-redis
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-metadata-definition-protobuf
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-metadata-api
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-metadata-report-zookeeper
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-metadata-report-nacos
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-metadata-report-redis
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-metadata-definition-protobuf
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-metrics-api
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-metrics-default
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-metrics-registry
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-metrics-prometheus
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-metrics-metadata
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-metrics-config-center
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-metrics-api
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-metrics-default
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-metrics-registry
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-metrics-prometheus
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-metrics-metadata
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-metrics-config-center
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-auth
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-qos-api
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-qos
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-security
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-reactive
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-auth
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-qos-api
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-qos
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-security
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-reactive
+ ${project.version}
+ compile
+ true
+
-
- org.apache.dubbo
- dubbo-spring-security
- ${project.version}
- compile
- true
-
+
+ org.apache.dubbo
+ dubbo-spring-security
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-registry-api
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-registry-multicast
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-registry-multiple
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-registry-nacos
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-registry-zookeeper
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-registry-api
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-registry-multicast
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-registry-multiple
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-registry-nacos
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-registry-zookeeper
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-remoting-api
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-remoting-http
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-remoting-netty
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-remoting-netty4
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-remoting-zookeeper
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-remoting-zookeeper-curator5
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-remoting-api
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-remoting-http
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-remoting-netty
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-remoting-netty4
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-remoting-zookeeper
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-remoting-zookeeper-curator5
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-rpc-api
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-rpc-dubbo
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-rpc-injvm
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-rpc-rest
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-rpc-api
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-rpc-dubbo
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-rpc-injvm
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-rpc-rest
+ ${project.version}
+ compile
+ true
+
-
- org.apache.dubbo
- dubbo-rpc-triple
- ${project.version}
- compile
- true
-
+
+ org.apache.dubbo
+ dubbo-rpc-triple
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-serialization-api
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-serialization-hessian2
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-serialization-fastjson2
- ${project.version}
- compile
- true
-
-
- org.apache.dubbo
- dubbo-serialization-jdk
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-serialization-api
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-serialization-hessian2
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-serialization-fastjson2
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-serialization-jdk
+ ${project.version}
+ compile
+ true
+
-
-
- org.apache.dubbo
- dubbo-xds
- ${project.version}
- compile
- true
-
+
+
+ org.apache.dubbo
+ dubbo-xds
+ ${project.version}
+ compile
+ true
+
-
-
- io.netty
- netty-all
- compile
- true
-
-
- org.springframework
- spring-context
-
-
- com.alibaba.spring
- spring-context-support
-
-
- org.javassist
- javassist
-
-
- org.yaml
- snakeyaml
-
-
- com.alibaba
- hessian-lite
-
-
- com.alibaba.fastjson2
- fastjson2
-
-
-
+
+
+ io.netty
+ netty-all
+ compile
+ true
+
+
+ org.springframework
+ spring-core
+
+
+ org.springframework
+ spring-beans
+
+
+ org.springframework
+ spring-context
+
+
+ com.alibaba.spring
+ spring-context-support
+
+
+ org.javassist
+ javassist
+
+
+ org.yaml
+ snakeyaml
+
+
+ com.alibaba
+ hessian-lite
+
+
+ com.alibaba.fastjson2
+ fastjson2
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-shade-plugin
+
+
+ package
+
+ shade
+
+
+ true
+ true
+ false
+
+
+ org.apache.dubbo:dubbo-auth
+ org.apache.dubbo:dubbo-cluster
+ org.apache.dubbo:dubbo-common
+ org.apache.dubbo:dubbo-compatible
+ org.apache.dubbo:dubbo-config-api
+ org.apache.dubbo:dubbo-config-spring
+ org.apache.dubbo:dubbo-configcenter-apollo
+ org.apache.dubbo:dubbo-configcenter-nacos
+ org.apache.dubbo:dubbo-configcenter-zookeeper
+ org.apache.dubbo:dubbo-filter-cache
+ org.apache.dubbo:dubbo-filter-validation
+ org.apache.dubbo:dubbo-metadata-api
+ org.apache.dubbo:dubbo-metadata-definition-protobuf
+ org.apache.dubbo:dubbo-metadata-report-nacos
+ org.apache.dubbo:dubbo-metadata-report-redis
+ org.apache.dubbo:dubbo-metadata-report-zookeeper
+ org.apache.dubbo:dubbo-metrics-api
+ org.apache.dubbo:dubbo-metrics-default
+ org.apache.dubbo:dubbo-metrics-registry
+ org.apache.dubbo:dubbo-metrics-metadata
+ org.apache.dubbo:dubbo-metrics-config-center
+ org.apache.dubbo:dubbo-metrics-prometheus
+ org.apache.dubbo:dubbo-qos
+ org.apache.dubbo:dubbo-qos-api
+ org.apache.dubbo:dubbo-security
+ org.apache.dubbo:dubbo-reactive
+ org.apache.dubbo:dubbo-spring-security
+ org.apache.dubbo:dubbo-registry-api
+ org.apache.dubbo:dubbo-registry-multicast
+ org.apache.dubbo:dubbo-registry-multiple
+ org.apache.dubbo:dubbo-registry-nacos
+ org.apache.dubbo:dubbo-registry-zookeeper
+ org.apache.dubbo:dubbo-remoting-api
+ org.apache.dubbo:dubbo-remoting-http
+ org.apache.dubbo:dubbo-remoting-netty4
+ org.apache.dubbo:dubbo-remoting-netty
+ org.apache.dubbo:dubbo-remoting-zookeeper
+ org.apache.dubbo:dubbo-remoting-zookeeper-curator5
+ org.apache.dubbo:dubbo-rpc-api
+ org.apache.dubbo:dubbo-rpc-dubbo
+ org.apache.dubbo:dubbo-rpc-injvm
+ org.apache.dubbo:dubbo-rpc-rest
+ org.apache.dubbo:dubbo-rpc-triple
+ org.apache.dubbo:dubbo-rest-jaxrs
+ org.apache.dubbo:dubbo-rest-servlet
+ org.apache.dubbo:dubbo-rest-spring
+ org.apache.dubbo:dubbo-serialization-api
+ org.apache.dubbo:dubbo-serialization-hessian2
+ org.apache.dubbo:dubbo-serialization-fastjson2
+ org.apache.dubbo:dubbo-serialization-jdk
+ org.apache.dubbo:dubbo-kubernetes
+ org.apache.dubbo:dubbo-xds
+ io.netty:*
+
+
+
+
+ META-INF/dubbo/internal/com.alibaba.dubbo.common.extension.ExtensionFactory
+
+
+ META-INF/dubbo/internal/com.alibaba.dubbo.container.page.PageHandler
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.auth.spi.AccessKeyStorage
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.auth.spi.Authenticator
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.cache.CacheFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.compiler.Compiler
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.config.OrderedPropertiesProvider
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.config.configcenter.DynamicConfigurationFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.context.ApplicationExt
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.context.ModuleExt
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.convert.Converter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.convert.multiple.MultiValueConverter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.deploy.ApplicationDeployListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.deploy.ModuleDeployListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.extension.ExtensionFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.extension.ExtensionInjector
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.extension.ExtensionLoader
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.infra.InfraAdapter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.lang.ShutdownHookCallback
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.logger.LoggerAdapter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.serialize.MultipleSerialization
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.serialize.Serialization
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.status.StatusChecker
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.status.reporter.FrameworkStatusReporter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.store.DataStore
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.threadpool.ThreadPool
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.threadpool.manager.ExecutorRepository
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.url.component.param.DynamicParamSource
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.config.ConfigInitializer
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.config.ConfigPostProcessor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.config.ServiceListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.config.bootstrap.DubboBootstrapStartStopListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.config.spring.context.DubboSpringInitCustomizer
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.config.spring.extension.SpringExtensionInjector
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.MetadataParamsFilter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.ServiceNameMapping
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.annotation.processing.builder.TypeBuilder
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.annotation.processing.rest.AnnotatedMethodParameterProcessor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.annotation.processing.rest.ServiceRestMetadataResolver
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.definition.builder.TypeBuilder
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.report.MetadataReportFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.rest.AnnotatedMethodParameterProcessor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.rest.ServiceRestMetadataReader
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.monitor.MonitorFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.qos.api.BaseCommand
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.qos.probe.LivenessProbe
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.qos.probe.ReadinessProbe
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.qos.probe.StartupProbe
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.qos.permission.PermissionChecker
+
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.PenetrateAttachmentSelector
+
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.AddressListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.ProviderFirstParams
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.RegistryFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.RegistryServiceListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.client.RegistryClusterIdentifier
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.client.ServiceDiscoveryFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.client.ServiceInstanceCustomizer
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.client.metadata.MetadataServiceURLBuilder
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.ssl.CertProvider
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.client.migration.MigrationAddressComparator
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.client.migration.PreMigratingConditionChecker
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.integration.RegistryProtocolListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.xds.XdsCertificateSigner
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.filter.RestResponseInterceptor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.filter.RestRequestFilter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.filter.RestResponseFilter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.rest.NoAnnotatedParameterRequestTagProcessor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.message.HttpMessageCodec
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.annotation.consumer.HttpConnectionPreBuildIntercept
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.annotation.param.parse.consumer.BaseConsumerParamParser
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.http.factory.RestClientFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.ChannelHandler
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.Codec
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.Codec2
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.Dispatcher
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.Transporter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.dubbo.ByteAccessor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.api.pu.PortUnificationTransporter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.api.connection.ConnectionManager
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.api.WireProtocol
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.exchange.Exchanger
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.http.HttpBinder
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.telnet.TelnetHandler
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.zookeeper.ZookeeperTransporter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.ExporterListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.Filter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.HeaderFilter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.InvokerListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.PenetrateAttachmentSelector
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.Protocol
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.ProxyFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.ZoneDetector
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.Cluster
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.ConfiguratorFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.LoadBalance
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.Merger
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.ProviderURLMergeProcessor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.RouterFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.RuleConverter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.filter.ClusterFilter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.filter.InvocationInterceptorBuilder
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.governance.GovernanceRuleRepository
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.interceptor.ClusterInterceptor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.mesh.route.MeshEnvListenerFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.state.StateRouterFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.condition.matcher.pattern.ValuePattern
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.condition.matcher.ConditionMatcherFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.model.ApplicationInitListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.model.BuiltinServiceDetector
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.model.ScopeModelInitializer
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.injvm.ParamDeepCopyUtil
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.PathResolver
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.validation.Validation
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.registry.client.metadata.ServiceInstanceNotificationCustomizer
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.compressor.Compressor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.compressor.DeCompressor
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.argument.ArgumentConverter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.argument.ArgumentResolver
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.filter.RestExtension
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.filter.RestExtensionAdapter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.mapping.RequestMappingResolver
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.route.RequestHandlerMapping
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.http12.message.HttpMessageAdapterFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metrics.service.MetricsService
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metrics.service.MetricsServiceExporter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metrics.report.MetricsReporterFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.common.threadpool.event.ThreadPoolExhaustedListener
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.api.pu.PortUnificationTransporter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.mesh.util.TracingContextProvider
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metadata.rest.ServiceRestMetadataResolver
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.executor.IsolationExecutorSupportFactory
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.metrics.collector.MetricsCollector
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.spring.security.jackson.ObjectMapperCodecCustomer
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.annotation.param.parse.provider.BaseProviderParamParser
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.model.PackableMethodFactory
+
+
+
+
+ org.apache.dubbo:dubbo
+
+
+ com/**
+ org/**
+
+ META-INF/dubbo/**
+
+
+
+ io.netty:*
+
+ META-INF/**
+
+
+
+
+
+ io.netty
+ org.apache.dubbo.netty.shaded.io.netty
+
+
+
+
+
+
+
+
+
+
+
+ release
+
-
- org.apache.maven.plugins
- maven-shade-plugin
-
-
- package
-
- shade
-
-
- true
- true
- false
-
-
- org.apache.dubbo:dubbo-auth
- org.apache.dubbo:dubbo-cluster
- org.apache.dubbo:dubbo-common
- org.apache.dubbo:dubbo-compatible
- org.apache.dubbo:dubbo-config-api
- org.apache.dubbo:dubbo-config-spring
- org.apache.dubbo:dubbo-configcenter-apollo
- org.apache.dubbo:dubbo-configcenter-nacos
- org.apache.dubbo:dubbo-configcenter-zookeeper
- org.apache.dubbo:dubbo-filter-cache
- org.apache.dubbo:dubbo-filter-validation
- org.apache.dubbo:dubbo-metadata-api
- org.apache.dubbo:dubbo-metadata-definition-protobuf
- org.apache.dubbo:dubbo-metadata-report-nacos
- org.apache.dubbo:dubbo-metadata-report-redis
- org.apache.dubbo:dubbo-metadata-report-zookeeper
- org.apache.dubbo:dubbo-metrics-api
- org.apache.dubbo:dubbo-metrics-default
- org.apache.dubbo:dubbo-metrics-registry
- org.apache.dubbo:dubbo-metrics-metadata
- org.apache.dubbo:dubbo-metrics-config-center
- org.apache.dubbo:dubbo-metrics-prometheus
- org.apache.dubbo:dubbo-qos
- org.apache.dubbo:dubbo-qos-api
- org.apache.dubbo:dubbo-security
- org.apache.dubbo:dubbo-reactive
- org.apache.dubbo:dubbo-spring-security
- org.apache.dubbo:dubbo-registry-api
- org.apache.dubbo:dubbo-registry-multicast
- org.apache.dubbo:dubbo-registry-multiple
- org.apache.dubbo:dubbo-registry-nacos
- org.apache.dubbo:dubbo-registry-zookeeper
- org.apache.dubbo:dubbo-remoting-api
- org.apache.dubbo:dubbo-remoting-http
- org.apache.dubbo:dubbo-remoting-netty4
- org.apache.dubbo:dubbo-remoting-netty
- org.apache.dubbo:dubbo-remoting-zookeeper
- org.apache.dubbo:dubbo-remoting-zookeeper-curator5
- org.apache.dubbo:dubbo-rpc-api
- org.apache.dubbo:dubbo-rpc-dubbo
- org.apache.dubbo:dubbo-rpc-injvm
- org.apache.dubbo:dubbo-rpc-rest
- org.apache.dubbo:dubbo-rpc-triple
- org.apache.dubbo:dubbo-serialization-api
- org.apache.dubbo:dubbo-serialization-hessian2
- org.apache.dubbo:dubbo-serialization-fastjson2
- org.apache.dubbo:dubbo-serialization-jdk
- org.apache.dubbo:dubbo-kubernetes
- org.apache.dubbo:dubbo-xds
- io.netty:*
-
-
-
-
-
- META-INF/dubbo/internal/com.alibaba.dubbo.common.extension.ExtensionFactory
-
-
-
-
- META-INF/dubbo/internal/com.alibaba.dubbo.container.page.PageHandler
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.auth.spi.AccessKeyStorage
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.auth.spi.Authenticator
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.cache.CacheFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.compiler.Compiler
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.config.OrderedPropertiesProvider
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.config.configcenter.DynamicConfigurationFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.context.ApplicationExt
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.context.ModuleExt
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.convert.Converter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.convert.multiple.MultiValueConverter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.deploy.ApplicationDeployListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.deploy.ModuleDeployListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.extension.ExtensionFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.extension.ExtensionInjector
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.extension.ExtensionLoader
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.infra.InfraAdapter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.lang.ShutdownHookCallback
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.logger.LoggerAdapter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.serialize.MultipleSerialization
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.serialize.Serialization
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.status.StatusChecker
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.status.reporter.FrameworkStatusReporter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.store.DataStore
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.threadpool.ThreadPool
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.threadpool.manager.ExecutorRepository
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.url.component.param.DynamicParamSource
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.config.ConfigInitializer
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.config.ConfigPostProcessor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.config.ServiceListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.config.bootstrap.DubboBootstrapStartStopListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.config.spring.context.DubboSpringInitCustomizer
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.config.spring.extension.SpringExtensionInjector
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.MetadataParamsFilter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.ServiceNameMapping
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.annotation.processing.builder.TypeBuilder
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.annotation.processing.rest.AnnotatedMethodParameterProcessor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.annotation.processing.rest.ServiceRestMetadataResolver
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.definition.builder.TypeBuilder
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.report.MetadataReportFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.rest.AnnotatedMethodParameterProcessor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.rest.ServiceRestMetadataReader
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.monitor.MonitorFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.qos.api.BaseCommand
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.qos.probe.LivenessProbe
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.qos.probe.ReadinessProbe
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.qos.probe.StartupProbe
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.qos.permission.PermissionChecker
-
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.PenetrateAttachmentSelector
-
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.AddressListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.ProviderFirstParams
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.RegistryFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.RegistryServiceListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.client.RegistryClusterIdentifier
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.client.ServiceDiscoveryFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.client.ServiceInstanceCustomizer
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.client.metadata.MetadataServiceURLBuilder
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.ssl.CertProvider
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.client.migration.MigrationAddressComparator
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.client.migration.PreMigratingConditionChecker
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.integration.RegistryProtocolListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.xds.XdsCertificateSigner
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.filter.RestResponseInterceptor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.filter.RestRequestFilter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.filter.RestResponseFilter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.rest.NoAnnotatedParameterRequestTagProcessor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.message.HttpMessageCodec
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.annotation.consumer.HttpConnectionPreBuildIntercept
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.annotation.param.parse.consumer.BaseConsumerParamParser
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.http.factory.RestClientFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.ChannelHandler
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.Codec
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.Codec2
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.Dispatcher
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.Transporter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.dubbo.ByteAccessor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.api.pu.PortUnificationTransporter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.api.connection.ConnectionManager
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.api.WireProtocol
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.exchange.Exchanger
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.http.HttpBinder
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.telnet.TelnetHandler
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.zookeeper.ZookeeperTransporter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.ExporterListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.Filter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.HeaderFilter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.InvokerListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.PenetrateAttachmentSelector
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.Protocol
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.ProxyFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.ZoneDetector
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.Cluster
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.ConfiguratorFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.LoadBalance
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.Merger
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.ProviderURLMergeProcessor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.RouterFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.RuleConverter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.filter.ClusterFilter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.filter.FilterChainBuilder
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.filter.InvocationInterceptorBuilder
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.governance.GovernanceRuleRepository
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.interceptor.ClusterInterceptor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.mesh.route.MeshEnvListenerFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.state.StateRouterFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.condition.matcher.pattern.ValuePattern
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.condition.matcher.ConditionMatcherFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.model.ApplicationInitListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.model.BuiltinServiceDetector
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.model.ScopeModelInitializer
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.injvm.ParamDeepCopyUtil
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.PathResolver
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.validation.Validation
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.registry.client.metadata.ServiceInstanceNotificationCustomizer
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.compressor.Compressor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.compressor.DeCompressor
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metrics.service.MetricsService
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metrics.service.MetricsServiceExporter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metrics.report.MetricsReporterFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.common.threadpool.event.ThreadPoolExhaustedListener
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.remoting.api.pu.PortUnificationTransporter
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.cluster.router.mesh.util.TracingContextProvider
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metadata.rest.ServiceRestMetadataResolver
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.executor.IsolationExecutorSupportFactory
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.metrics.collector.MetricsCollector
-
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.spring.security.jackson.ObjectMapperCodecCustomer
-
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.rest.annotation.param.parse.provider.BaseProviderParamParser
-
-
-
-
-
- META-INF/dubbo/internal/org.apache.dubbo.rpc.model.PackableMethodFactory
-
-
-
-
-
- org.apache.dubbo:dubbo
-
-
- com/**
- org/**
-
- META-INF/dubbo/**
-
-
-
- io.netty:*
-
- META-INF/**
-
-
-
-
-
- io.netty
- org.apache.dubbo.netty.shaded.io.netty
-
-
-
-
-
-
+
+ maven-javadoc-plugin
+ ${maven_javadoc_version}
+
+
+ attach-javadoc
+
+ jar
+
+
+ none
+
+
+
+
+ true
+
+ org.apache.dubbo:dubbo-*
+
+ public
+ UTF-8
+ UTF-8
+ UTF-8
+
+ http://docs.oracle.com/javase/7/docs/api
+
+
+
-
-
-
-
- release
-
-
-
- maven-javadoc-plugin
- ${maven_javadoc_version}
-
-
- attach-javadoc
-
- jar
-
-
- none
-
-
-
-
- true
-
- org.apache.dubbo:dubbo-*
-
- public
- UTF-8
- UTF-8
- UTF-8
-
- http://docs.oracle.com/javase/7/docs/api
-
-
-
-
-
-
-
+
+
+
diff --git a/dubbo-distribution/dubbo-all/pom.xml b/dubbo-distribution/dubbo-all/pom.xml
index 17e1ae2cb5..ee749b1672 100644
--- a/dubbo-distribution/dubbo-all/pom.xml
+++ b/dubbo-distribution/dubbo-all/pom.xml
@@ -284,6 +284,28 @@
true
+
+ org.apache.dubbo
+ dubbo-rest-jaxrs
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-rest-servlet
+ ${project.version}
+ compile
+ true
+
+
+ org.apache.dubbo
+ dubbo-rest-spring
+ ${project.version}
+ compile
+ true
+
+
org.apache.dubbo
@@ -448,6 +470,14 @@
+
+ org.springframework
+ spring-core
+
+
+ org.springframework
+ spring-beans
+ org.springframeworkspring-context
@@ -544,6 +574,9 @@
org.apache.dubbo:dubbo-rpc-injvmorg.apache.dubbo:dubbo-rpc-restorg.apache.dubbo:dubbo-rpc-triple
+ org.apache.dubbo:dubbo-rest-jaxrs
+ org.apache.dubbo:dubbo-rest-servlet
+ org.apache.dubbo:dubbo-rest-springorg.apache.dubbo:dubbo-serialization-apiorg.apache.dubbo:dubbo-serialization-hessian2org.apache.dubbo:dubbo-serialization-fastjson2
@@ -913,6 +946,27 @@
META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.compressor.DeCompressor
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.argument.ArgumentConverter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.argument.ArgumentResolver
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.filter.RestExtension
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.filter.RestExtensionAdapter
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.rest.mapping.RequestMappingResolver
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.rpc.protocol.tri.route.RequestHandlerMapping
+
+
+ META-INF/dubbo/internal/org.apache.dubbo.remoting.http12.message.HttpMessageAdapterFactory
+ META-INF/dubbo/internal/org.apache.dubbo.metrics.service.MetricsService
@@ -980,7 +1034,7 @@
org.apache.dubbo:dubbo
-
+
com/**org/**
diff --git a/dubbo-distribution/dubbo-bom/pom.xml b/dubbo-distribution/dubbo-bom/pom.xml
index 0edc520744..4b0d3220c8 100644
--- a/dubbo-distribution/dubbo-bom/pom.xml
+++ b/dubbo-distribution/dubbo-bom/pom.xml
@@ -334,6 +334,21 @@
dubbo-plugin-proxy-bytebuddy${project.version}
+
+ org.apache.dubbo
+ dubbo-rest-jaxrs
+ ${project.version}
+
+
+ org.apache.dubbo
+ dubbo-rest-servlet
+ ${project.version}
+
+
+ org.apache.dubbo
+ dubbo-rest-spring
+ ${project.version}
+
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/pom.xml b/dubbo-plugin/dubbo-rest-jaxrs/pom.xml
new file mode 100644
index 0000000000..26ab19d02f
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/pom.xml
@@ -0,0 +1,102 @@
+
+
+
+ 4.0.0
+
+ org.apache.dubbo
+ dubbo-plugin
+ ${revision}
+ ../pom.xml
+
+
+ dubbo-rest-jaxrs
+
+
+
+ org.apache.dubbo
+ dubbo-rpc-triple
+ ${project.version}
+
+
+ javax.ws.rs
+ javax.ws.rs-api
+
+
+ org.jboss.resteasy
+ resteasy-jaxrs
+
+
+ *
+ *
+
+
+
+
+ org.apache.dubbo
+ dubbo-remoting-netty4
+ ${project.version}
+ test
+
+
+ javax.xml.bind
+ jaxb-api
+ test
+
+
+ org.glassfish.jaxb
+ jaxb-runtime
+ test
+
+
+ org.apache.dubbo
+ dubbo-rpc-rest
+ ${project.version}
+ test
+
+
+ javax.validation
+ validation-api
+
+
+ io.swagger
+ swagger-jaxrs
+
+
+ io.swagger
+ swagger-annotations
+
+
+ org.eclipse.jetty
+ jetty-servlet
+
+
+ org.apache.tomcat.embed
+ tomcat-embed-core
+
+
+ org.eclipse.jetty
+ jetty-server
+
+
+ org.jboss.resteasy
+ resteasy-client
+
+
+
+
+
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/AbstractJaxrsArgumentResolver.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/AbstractJaxrsArgumentResolver.java
new file mode 100644
index 0000000000..e15ea56579
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/AbstractJaxrsArgumentResolver.java
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.rpc.protocol.tri.rest.argument.AbstractAnnotationBaseArgumentResolver;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.AnnotationMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.NamedValueMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.ParameterMeta;
+
+import java.lang.annotation.Annotation;
+
+public abstract class AbstractJaxrsArgumentResolver extends AbstractAnnotationBaseArgumentResolver {
+
+ @Override
+ protected NamedValueMeta createNamedValueMeta(ParameterMeta param, AnnotationMeta ann) {
+ return new NamedValueMeta(ann.getValue(), Helper.isRequired(param), Helper.defaultValue(param));
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/Annotations.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/Annotations.java
new file mode 100644
index 0000000000..42ddf4ccbd
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/Annotations.java
@@ -0,0 +1,65 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.AnnotationEnum;
+
+import java.lang.annotation.Annotation;
+
+public enum Annotations implements AnnotationEnum {
+ Path,
+ HttpMethod,
+ Produces,
+ Consumes,
+ PathParam,
+ MatrixParam,
+ QueryParam,
+ HeaderParam,
+ CookieParam,
+ FormParam,
+ BeanParam,
+ Body("org.jboss.resteasy.annotations.Body"),
+ Form("org.jboss.resteasy.annotations.Form"),
+ Context("javax.ws.rs.core.Context"),
+ Suspended("javax.ws.rs.container.Suspended"),
+ DefaultValue,
+ Encoded,
+ Nonnull("javax.annotation.Nonnull");
+
+ private final String className;
+ private Class type;
+
+ Annotations(String className) {
+ this.className = className;
+ }
+
+ Annotations() {
+ className = "javax.ws.rs." + name();
+ }
+
+ public String className() {
+ return className;
+ }
+
+ @Override
+ public Class type() {
+ if (type == null) {
+ type = loadType();
+ }
+ return type;
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/BeanArgumentBinder.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/BeanArgumentBinder.java
new file mode 100644
index 0000000000..294875bd95
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/BeanArgumentBinder.java
@@ -0,0 +1,280 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.common.beans.factory.ScopeBeanFactory;
+import org.apache.dubbo.common.utils.CollectionUtils;
+import org.apache.dubbo.common.utils.Pair;
+import org.apache.dubbo.remoting.http12.HttpRequest;
+import org.apache.dubbo.remoting.http12.HttpResponse;
+import org.apache.dubbo.rpc.model.FrameworkModel;
+import org.apache.dubbo.rpc.protocol.tri.rest.Messages;
+import org.apache.dubbo.rpc.protocol.tri.rest.RestException;
+import org.apache.dubbo.rpc.protocol.tri.rest.argument.ArgumentResolver;
+import org.apache.dubbo.rpc.protocol.tri.rest.argument.CompositeArgumentResolver;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.AnnotationMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.ParameterMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.util.RestToolKit;
+
+import java.lang.reflect.AnnotatedElement;
+import java.lang.reflect.Constructor;
+import java.lang.reflect.Field;
+import java.lang.reflect.Method;
+import java.lang.reflect.Modifier;
+import java.lang.reflect.Parameter;
+import java.lang.reflect.Type;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
+
+final class BeanArgumentBinder {
+
+ private final ArgumentResolver argumentResolver;
+
+ private final Map, String>, BeanMeta> cache = CollectionUtils.newConcurrentHashMap();
+
+ BeanArgumentBinder(FrameworkModel frameworkModel) {
+ ScopeBeanFactory beanFactory = frameworkModel.getBeanFactory();
+ argumentResolver = beanFactory.getOrRegisterBean(CompositeArgumentResolver.class);
+ }
+
+ public Object bind(ParameterMeta parameter, HttpRequest request, HttpResponse response) {
+ try {
+ return resolveArgument(parameter, request, response);
+ } catch (Exception e) {
+ throw new RestException(Messages.ARGUMENT_BIND_ERROR, parameter.getName(), parameter.getType(), e);
+ }
+ }
+
+ private Object resolveArgument(ParameterMeta param, HttpRequest request, HttpResponse response) throws Exception {
+ AnnotationMeta> form = param.findAnnotation(Annotations.Form);
+ if (form != null || param.isHierarchyAnnotated(Annotations.BeanParam)) {
+ String prefix = form == null ? null : form.getString("prefix");
+ BeanMeta beanMeta = cache.computeIfAbsent(
+ Pair.of(param.getActualType(), prefix),
+ k -> new BeanMeta(param.getToolKit(), k.getValue(), k.getKey()));
+
+ ConstructorMeta constructor = beanMeta.constructor;
+ ParameterMeta[] parameters = constructor.parameters;
+ int len = parameters.length;
+ Object[] args = new Object[len];
+ for (int i = 0; i < len; i++) {
+ args[i] = resolveArgument(parameters[i], request, response);
+ }
+ Object bean = constructor.newInstance(args);
+
+ for (FieldMeta fieldMeta : beanMeta.fields) {
+ fieldMeta.set(bean, resolveArgument(fieldMeta, request, response));
+ }
+
+ for (SetMethodMeta methodMeta : beanMeta.methods) {
+ methodMeta.invoke(bean, resolveArgument(methodMeta, request, response));
+ }
+ return bean;
+ }
+
+ return argumentResolver.resolve(param, request, response);
+ }
+
+ private static class BeanMeta {
+
+ private final List fields = new ArrayList<>();
+ private final List methods = new ArrayList<>();
+ private final ConstructorMeta constructor;
+
+ BeanMeta(RestToolKit toolKit, String prefix, Class> type) {
+ constructor = resolveConstructor(toolKit, prefix, type);
+ resolveFieldAndMethod(toolKit, prefix, type);
+ }
+
+ private ConstructorMeta resolveConstructor(RestToolKit toolKit, String prefix, Class> type) {
+ Constructor>[] constructors = type.getConstructors();
+ Constructor> ct = null;
+ if (constructors.length == 1) {
+ ct = constructors[0];
+ } else {
+ try {
+ ct = type.getDeclaredConstructor();
+ } catch (NoSuchMethodException ignored) {
+ }
+ }
+ if (ct == null) {
+ throw new IllegalArgumentException("No available default constructor found in " + type);
+ }
+ return new ConstructorMeta(toolKit, prefix, ct);
+ }
+
+ private void resolveFieldAndMethod(RestToolKit toolKit, String prefix, Class> type) {
+ if (type == Object.class) {
+ return;
+ }
+ for (Field field : type.getDeclaredFields()) {
+ int modifiers = field.getModifiers();
+ if (Modifier.isStatic(modifiers) || Modifier.isFinal(modifiers)) {
+ continue;
+ }
+ if (field.getAnnotations().length == 0) {
+ continue;
+ }
+ if (!field.isAccessible()) {
+ field.setAccessible(true);
+ }
+ fields.add(new FieldMeta(toolKit, prefix, field));
+ }
+ for (Method method : type.getDeclaredMethods()) {
+ if (method.getParameterCount() != 1) {
+ continue;
+ }
+ int modifiers = method.getModifiers();
+ if ((modifiers & (Modifier.PUBLIC | Modifier.ABSTRACT | Modifier.STATIC)) == Modifier.PUBLIC) {
+ Parameter parameter = method.getParameters()[0];
+ String name = method.getName();
+ if (name.length() > 3 && name.startsWith("set")) {
+ name = Character.toLowerCase(name.charAt(3)) + name.substring(4);
+ methods.add(new SetMethodMeta(toolKit, method, parameter, prefix, name));
+ }
+ }
+ }
+ resolveFieldAndMethod(toolKit, prefix, type.getSuperclass());
+ }
+ }
+
+ private static final class ConstructorMeta {
+
+ private final Constructor> constructor;
+ private final ConstructorParameterMeta[] parameters;
+
+ ConstructorMeta(RestToolKit toolKit, String prefix, Constructor> constructor) {
+ this.constructor = constructor;
+ parameters = initParameters(toolKit, prefix, constructor);
+ }
+
+ private ConstructorParameterMeta[] initParameters(RestToolKit toolKit, String prefix, Constructor> ct) {
+ Parameter[] cps = ct.getParameters();
+ int len = cps.length;
+ ConstructorParameterMeta[] parameters = new ConstructorParameterMeta[len];
+ for (int i = 0; i < len; i++) {
+ parameters[i] = new ConstructorParameterMeta(toolKit, cps[i], prefix);
+ }
+ return parameters;
+ }
+
+ Object newInstance(Object[] args) throws Exception {
+ return constructor.newInstance(args);
+ }
+ }
+
+ public static final class ConstructorParameterMeta extends ParameterMeta {
+
+ private final Parameter parameter;
+
+ ConstructorParameterMeta(RestToolKit toolKit, Parameter parameter, String prefix) {
+ super(toolKit, prefix, parameter.isNamePresent() ? parameter.getName() : null);
+ this.parameter = parameter;
+ }
+
+ @Override
+ protected AnnotatedElement getAnnotatedElement() {
+ return parameter;
+ }
+
+ @Override
+ public Class> getType() {
+ return parameter.getType();
+ }
+
+ @Override
+ public Type getGenericType() {
+ return parameter.getParameterizedType();
+ }
+
+ @Override
+ public String getDescription() {
+ return "ConstructorParameter{" + parameter + '}';
+ }
+ }
+
+ private static final class FieldMeta extends ParameterMeta {
+
+ private final Field field;
+
+ FieldMeta(RestToolKit toolKit, String prefix, Field field) {
+ super(toolKit, prefix, field.getName());
+ this.field = field;
+ }
+
+ @Override
+ public Class> getType() {
+ return field.getType();
+ }
+
+ @Override
+ public Type getGenericType() {
+ return field.getGenericType();
+ }
+
+ @Override
+ protected AnnotatedElement getAnnotatedElement() {
+ return field;
+ }
+
+ public void set(Object bean, Object value) throws Exception {
+ field.set(bean, value);
+ }
+
+ @Override
+ public String getDescription() {
+ return "FieldParameter{" + field + '}';
+ }
+ }
+
+ private static final class SetMethodMeta extends ParameterMeta {
+
+ private final Method method;
+ private final Parameter parameter;
+
+ SetMethodMeta(RestToolKit toolKit, Method method, Parameter parameter, String prefix, String name) {
+ super(toolKit, prefix, name);
+ this.method = method;
+ this.parameter = parameter;
+ }
+
+ @Override
+ public Class> getType() {
+ return parameter.getType();
+ }
+
+ @Override
+ public Type getGenericType() {
+ return parameter.getParameterizedType();
+ }
+
+ @Override
+ protected AnnotatedElement getAnnotatedElement() {
+ return parameter;
+ }
+
+ public void invoke(Object bean, Object value) throws Exception {
+ method.invoke(bean, value);
+ }
+
+ @Override
+ public String getDescription() {
+ return "SetMethodParameter{" + method + '}';
+ }
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/BeanParamArgumentResolver.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/BeanParamArgumentResolver.java
new file mode 100644
index 0000000000..7c59ec6d59
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/BeanParamArgumentResolver.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.common.extension.Activate;
+import org.apache.dubbo.remoting.http12.HttpRequest;
+import org.apache.dubbo.remoting.http12.HttpResponse;
+import org.apache.dubbo.rpc.protocol.tri.rest.argument.AnnotationBaseArgumentResolver;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.AnnotationMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.ParameterMeta;
+
+import java.lang.annotation.Annotation;
+
+@Activate(onClass = "javax.ws.rs.BeanParam")
+public class BeanParamArgumentResolver implements AnnotationBaseArgumentResolver {
+
+ @Override
+ public Class accept() {
+ return Annotations.BeanParam.type();
+ }
+
+ @Override
+ public Object resolve(
+ ParameterMeta parameter,
+ AnnotationMeta annotation,
+ HttpRequest request,
+ HttpResponse response) {
+ return parameter.bind(request, response);
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/BodyArgumentResolver.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/BodyArgumentResolver.java
new file mode 100644
index 0000000000..5d46134103
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/BodyArgumentResolver.java
@@ -0,0 +1,56 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.common.extension.Activate;
+import org.apache.dubbo.common.io.StreamUtils;
+import org.apache.dubbo.remoting.http12.HttpRequest;
+import org.apache.dubbo.remoting.http12.HttpResponse;
+import org.apache.dubbo.rpc.protocol.tri.rest.RestException;
+import org.apache.dubbo.rpc.protocol.tri.rest.argument.AnnotationBaseArgumentResolver;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.AnnotationMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.ParameterMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.util.RequestUtils;
+
+import java.io.IOException;
+import java.lang.annotation.Annotation;
+
+@Activate(onClass = "org.jboss.resteasy.annotations.Body")
+public class BodyArgumentResolver implements AnnotationBaseArgumentResolver {
+
+ @Override
+ public Class accept() {
+ return Annotations.Body.type();
+ }
+
+ @Override
+ public Object resolve(
+ ParameterMeta parameter,
+ AnnotationMeta annotation,
+ HttpRequest request,
+ HttpResponse response) {
+ Class> type = parameter.getActualType();
+ if (type == byte[].class) {
+ try {
+ return StreamUtils.readBytes(request.inputStream());
+ } catch (IOException e) {
+ throw new RestException(e);
+ }
+ }
+ return RequestUtils.decodeBody(request, type);
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/CookieParamArgumentResolver.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/CookieParamArgumentResolver.java
new file mode 100644
index 0000000000..7f1b37b25a
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/CookieParamArgumentResolver.java
@@ -0,0 +1,74 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.common.extension.Activate;
+import org.apache.dubbo.common.utils.CollectionUtils;
+import org.apache.dubbo.remoting.http12.HttpCookie;
+import org.apache.dubbo.remoting.http12.HttpRequest;
+import org.apache.dubbo.remoting.http12.HttpResponse;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.NamedValueMeta;
+
+import java.lang.annotation.Annotation;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+
+@Activate(onClass = "javax.ws.rs.CookieParam")
+public class CookieParamArgumentResolver extends AbstractJaxrsArgumentResolver {
+
+ @Override
+ public Class accept() {
+ return Annotations.CookieParam.type();
+ }
+
+ @Override
+ protected Object resolveValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ return request.cookie(meta.name());
+ }
+
+ @Override
+ protected Object resolveCollectionValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ Collection cookies = request.cookies();
+ if (cookies.isEmpty()) {
+ return Collections.emptyList();
+ }
+ String name = meta.name();
+ List result = new ArrayList<>(cookies.size());
+ for (HttpCookie cookie : cookies) {
+ if (name.equals(cookie.name())) {
+ result.add(cookie);
+ }
+ }
+ return result;
+ }
+
+ @Override
+ protected Object resolveMapValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ Collection cookies = request.cookies();
+ if (cookies.isEmpty()) {
+ return Collections.emptyMap();
+ }
+ Map> mapValue = CollectionUtils.newLinkedHashMap(cookies.size());
+ for (HttpCookie cookie : cookies) {
+ mapValue.computeIfAbsent(cookie.name(), k -> new ArrayList<>()).add(cookie);
+ }
+ return mapValue;
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/FallbackArgumentResolver.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/FallbackArgumentResolver.java
new file mode 100644
index 0000000000..0ecc924df7
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/FallbackArgumentResolver.java
@@ -0,0 +1,89 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.common.extension.Activate;
+import org.apache.dubbo.common.io.StreamUtils;
+import org.apache.dubbo.remoting.http12.HttpRequest;
+import org.apache.dubbo.remoting.http12.HttpResponse;
+import org.apache.dubbo.rpc.protocol.tri.rest.RestConstants;
+import org.apache.dubbo.rpc.protocol.tri.rest.RestException;
+import org.apache.dubbo.rpc.protocol.tri.rest.argument.AbstractArgumentResolver;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.NamedValueMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.ParameterMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.util.RequestUtils;
+import org.apache.dubbo.rpc.protocol.tri.rest.util.TypeUtils;
+
+import java.io.IOException;
+
+@Activate(order = Integer.MAX_VALUE - 10000, onClass = "javax.ws.rs.Path")
+public class FallbackArgumentResolver extends AbstractArgumentResolver {
+
+ @Override
+ public boolean accept(ParameterMeta param) {
+ return param.getToolKit().getDialect() == RestConstants.DIALECT_JAXRS;
+ }
+
+ @Override
+ protected NamedValueMeta createNamedValueMeta(ParameterMeta param) {
+ return new NamedValueMeta(param.isAnnotated(Annotations.Nonnull), Helper.defaultValue(param));
+ }
+
+ @Override
+ protected Object resolveValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ Object value = RequestUtils.decodeBody(request, meta.type());
+ if (value != null) {
+ return value;
+ }
+ if (meta.parameterMeta().isSimple()) {
+ return request.parameter(meta.name());
+ }
+ return null;
+ }
+
+ @Override
+ protected Object resolveCollectionValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ Class> type = meta.type();
+ if (type == byte[].class) {
+ try {
+ return StreamUtils.readBytes(request.inputStream());
+ } catch (IOException e) {
+ throw new RestException(e);
+ }
+ }
+ Object value = RequestUtils.decodeBody(request, meta.type());
+ if (value != null) {
+ return value;
+ }
+ if (TypeUtils.isSimpleProperty(meta.nestedType(0))) {
+ return request.parameterValues(meta.name());
+ }
+ return null;
+ }
+
+ @Override
+ protected Object resolveMapValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ Object value = RequestUtils.decodeBody(request, meta.type());
+ if (value != null) {
+ return value;
+ }
+ if (TypeUtils.isSimpleProperty(meta.nestedType(1))) {
+ return RequestUtils.getParametersMap(request);
+ }
+ return null;
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/FormArgumentResolver.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/FormArgumentResolver.java
new file mode 100644
index 0000000000..4f3678be5f
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/FormArgumentResolver.java
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.common.extension.Activate;
+import org.apache.dubbo.remoting.http12.HttpRequest;
+import org.apache.dubbo.remoting.http12.HttpResponse;
+import org.apache.dubbo.rpc.protocol.tri.rest.argument.AnnotationBaseArgumentResolver;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.AnnotationMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.ParameterMeta;
+
+import java.lang.annotation.Annotation;
+
+@Activate(onClass = "org.jboss.resteasy.annotations.Form")
+public class FormArgumentResolver implements AnnotationBaseArgumentResolver {
+ @Override
+ public Class accept() {
+ return Annotations.Form.type();
+ }
+
+ @Override
+ public Object resolve(
+ ParameterMeta parameter,
+ AnnotationMeta annotation,
+ HttpRequest request,
+ HttpResponse response) {
+ return parameter.bind(request, response);
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/FormParamArgumentResolver.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/FormParamArgumentResolver.java
new file mode 100644
index 0000000000..7ac1b2fcda
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/FormParamArgumentResolver.java
@@ -0,0 +1,52 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.common.extension.Activate;
+import org.apache.dubbo.common.utils.CollectionUtils;
+import org.apache.dubbo.remoting.http12.HttpRequest;
+import org.apache.dubbo.remoting.http12.HttpResponse;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.NamedValueMeta;
+
+import java.lang.annotation.Annotation;
+
+/**
+ * TODO: support nested values: (e.g., 'telephoneNumbers[0].countryCode' 'address[INVOICE].street')
+ */
+@Activate(onClass = "javax.ws.rs.FormParam")
+public class FormParamArgumentResolver extends AbstractJaxrsArgumentResolver {
+
+ @Override
+ public Class accept() {
+ return Annotations.FormParam.type();
+ }
+
+ @Override
+ protected Object resolveValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ return CollectionUtils.first(request.formParameterValues(getFullName(meta)));
+ }
+
+ @Override
+ protected Object resolveCollectionValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ return request.formParameterValues(getFullName(meta));
+ }
+
+ private String getFullName(NamedValueMeta meta) {
+ String prefix = meta.parameterMeta().getPrefix();
+ return prefix == null ? meta.name() : prefix + '.' + meta.name();
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/HeaderParamArgumentResolver.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/HeaderParamArgumentResolver.java
new file mode 100644
index 0000000000..8989c0ab06
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/HeaderParamArgumentResolver.java
@@ -0,0 +1,48 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.common.extension.Activate;
+import org.apache.dubbo.remoting.http12.HttpRequest;
+import org.apache.dubbo.remoting.http12.HttpResponse;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.NamedValueMeta;
+
+import java.lang.annotation.Annotation;
+
+@Activate(onClass = "javax.ws.rs.HeaderParam")
+public class HeaderParamArgumentResolver extends AbstractJaxrsArgumentResolver {
+
+ @Override
+ public Class accept() {
+ return Annotations.HeaderParam.type();
+ }
+
+ @Override
+ protected Object resolveValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ return request.header(meta.name());
+ }
+
+ @Override
+ protected Object resolveCollectionValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ return request.headerValues(meta.name());
+ }
+
+ @Override
+ protected Object resolveMapValue(NamedValueMeta meta, HttpRequest request, HttpResponse response) {
+ return request.headers();
+ }
+}
diff --git a/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/Helper.java b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/Helper.java
new file mode 100644
index 0000000000..9abde6219a
--- /dev/null
+++ b/dubbo-plugin/dubbo-rest-jaxrs/src/main/java/org/apache/dubbo/rpc/protocol/tri/rest/support/jaxrs/Helper.java
@@ -0,0 +1,85 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.dubbo.rpc.protocol.tri.rest.support.jaxrs;
+
+import org.apache.dubbo.remoting.http12.HttpCookie;
+import org.apache.dubbo.remoting.http12.HttpResult;
+import org.apache.dubbo.remoting.http12.HttpUtils;
+import org.apache.dubbo.remoting.http12.message.DefaultHttpResult.Builder;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.AnnotationMeta;
+import org.apache.dubbo.rpc.protocol.tri.rest.mapping.meta.ParameterMeta;
+
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.NewCookie;
+import javax.ws.rs.core.Response;
+
+import java.util.List;
+import java.util.stream.Collectors;
+
+public final class Helper {
+
+ private Helper() {}
+
+ public static boolean isRequired(ParameterMeta parameter) {
+ return parameter.isAnnotated(Annotations.Nonnull);
+ }
+
+ public static String defaultValue(ParameterMeta annotation) {
+ AnnotationMeta> meta = annotation.getAnnotation(Annotations.DefaultValue);
+ return meta == null ? null : meta.getValue();
+ }
+
+ public static HttpResult