Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The Task Of [Feature] Move Rest Protocol to SPI Extensions #13958 #306

Merged
merged 32 commits into from
Apr 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
a720eb4
add auddo-wasm/README_zh.md
wcy666103 Mar 24, 2024
1b7ca4d
Merge branch 'master' into master
songxiaosheng Mar 25, 2024
cec7dad
Merge branch 'apache:master' into master
wcy666103 Mar 26, 2024
e820429
add common README and cross-thread README_ch
wcy666103 Mar 26, 2024
f0b7b5b
Merge branch 'apache:master' into master
wcy666103 Mar 27, 2024
44fbd5b
add configcenter README
wcy666103 Mar 27, 2024
867f79f
add DocAutoGenCN
wcy666103 Mar 29, 2024
fa611d1
add License
wcy666103 Mar 29, 2024
addde91
update README
wcy666103 Mar 29, 2024
d7ba13b
Merge branch 'master' into master
songxiaosheng Mar 31, 2024
5d81888
add rpc-rest remoting-http
wcy666103 Apr 1, 2024
61ac43f
test ok
wcy666103 Apr 2, 2024
2995f48
add metadata-rest(including rest-api and rest-annotation-processing
wcy666103 Apr 3, 2024
886d0db
replace rpc-rest dependency
wcy666103 Apr 3, 2024
b81f367
Merge branch 'apache:master' into master
wcy666103 Apr 3, 2024
0d76ec1
Merge remote-tracking branch 'refs/remotes/origin/master'
wcy666103 Apr 3, 2024
0165810
add license
wcy666103 Apr 3, 2024
179de34
replace all of import xxx.*
wcy666103 Apr 3, 2024
d42e5c1
Merge branch 'master' into master
songxiaosheng Apr 7, 2024
eddd943
replace the rest import xxx.*
wcy666103 Apr 8, 2024
26191b6
Merge branch 'master' of https://github.com/wcy666103/dubbo-spi-exten…
wcy666103 Apr 8, 2024
c084bfe
remove useless import
wcy666103 Apr 8, 2024
e7ef95d
fix import
wcy666103 Apr 8, 2024
6e7be4f
fix cluster test module
wcy666103 Apr 8, 2024
2d1b1c7
Add logger
Apr 8, 2024
5efc16f
Revert junit
Apr 8, 2024
c6ada23
Revert junit
AlbumenJ Apr 8, 2024
d7902b1
Revert "Revert junit"
wcy666103 Apr 8, 2024
d7d39c9
Revert "Revert junit"
wcy666103 Apr 8, 2024
d2c4a9f
Revert "Add logger"
wcy666103 Apr 8, 2024
f2debe5
add MinaClientToServerTest disable
wcy666103 Apr 8, 2024
c0dae67
Merge branch 'master' into master
wcy666103 Apr 16, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
9 changes: 5 additions & 4 deletions dubbo-cluster-extensions/dubbo-cluster-router-mesh/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
<version>${revision}</version>
<relativePath>../pom.xml</relativePath>
</parent>

<modelVersion>4.0.0</modelVersion>
<artifactId>dubbo-cluster-router-mesh</artifactId>
<version>3.2.0</version>
Expand All @@ -31,14 +32,14 @@
<skip_maven_deploy>false</skip_maven_deploy>
</properties>
<dependencies>
<dependency>
<groupId>org.yaml</groupId>
<artifactId>snakeyaml</artifactId>
</dependency>
<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-common</artifactId>
</dependency>
<dependency>
<groupId>org.yaml</groupId>
<artifactId>snakeyaml</artifactId>
</dependency>
<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-rpc-api</artifactId>
Expand Down
157 changes: 157 additions & 0 deletions dubbo-metadata-report-extensions/dubbo-metadata-rest/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,157 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ 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.
-->

<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.dubbo.extensions</groupId>
<artifactId>dubbo-metadata-report-extensions</artifactId>
<version>${revision}</version>
<relativePath>../pom.xml</relativePath>
</parent>

<artifactId>dubbo-metadata-rest</artifactId>
<version>3.2.0</version>
<description>The rest-metadata module of Dubbo project</description>

<properties>
<skipIntegrationTests>true</skipIntegrationTests>
</properties>

<dependencies>

<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-rpc-api</artifactId>
<optional>true</optional>
</dependency>

<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-cluster</artifactId>
</dependency>

<!-- to use the utils and builders-->
<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-metadata-processor</artifactId>
<exclusions>
<exclusion>
<artifactId>dubbo-rpc-api</artifactId>
<groupId>org.apache.dubbo</groupId>
</exclusion>
<exclusion>
<artifactId>dubbo-common</artifactId>
<groupId>org.apache.dubbo</groupId>
</exclusion>
<exclusion>
<artifactId>dubbo-cluster</artifactId>
<groupId>org.apache.dubbo</groupId>
</exclusion>
</exclusions>
<optional>true</optional>
</dependency>

<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-common</artifactId>
<exclusions>
<exclusion>
<groupId>javax.annotation</groupId>
<artifactId>javax.annotation-api</artifactId>
</exclusion>

<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>

<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
<exclusion>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
</exclusion>

<exclusion>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
</exclusion>

<exclusion>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
</exclusion>
<exclusion>
<groupId>org.javassist</groupId>
<artifactId>javassist</artifactId>
</exclusion>
<exclusion>
<groupId>com.alibaba</groupId>
<artifactId>hessian-lite</artifactId>
</exclusion>
<exclusion>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
</exclusion>
</exclusions>
<optional>true</optional>
</dependency>

<!-- JAX-RS API -->
<dependency>
<groupId>javax.ws.rs</groupId>
<artifactId>javax.ws.rs-api</artifactId>
<scope>test</scope>
</dependency>

<!-- Spring Web MVC -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
<scope>test</scope>
</dependency>

<!-- Spring Web MVC -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-metrics-api</artifactId>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-metrics-default</artifactId>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.apache.dubbo</groupId>
<artifactId>dubbo-metrics-metadata</artifactId>
<scope>compile</scope>
</dependency>
</dependencies>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
/*
* 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.metadata.extension.rest.annotation.processing;


import org.apache.dubbo.metadata.extension.rest.api.RestMethodMetadata;

import javax.lang.model.element.AnnotationMirror;
import javax.lang.model.element.ExecutableElement;
import javax.lang.model.element.VariableElement;

import static org.apache.dubbo.metadata.annotation.processing.util.AnnotationUtils.getValue;
import static org.apache.dubbo.metadata.extension.rest.annotation.processing.AnnotatedMethodParameterProcessor.buildDefaultValue;

/**
* The abstract {@link AnnotatedMethodParameterProcessor} implementation
*
* @since 2.7.6
*/
public abstract class AbstractAnnotatedMethodParameterProcessor implements AnnotatedMethodParameterProcessor {

@Override
public final void process(
AnnotationMirror annotation,
VariableElement parameter,
int parameterIndex,
ExecutableElement method,
RestMethodMetadata restMethodMetadata) {
String annotationValue = getAnnotationValue(annotation, parameter, parameterIndex);
String defaultValue = getDefaultValue(annotation, parameter, parameterIndex);
process(annotationValue, defaultValue, annotation, parameter, parameterIndex, method, restMethodMetadata);
}

protected abstract void process(
String annotationValue,
String defaultValue,
AnnotationMirror annotation,
VariableElement parameter,
int parameterIndex,
ExecutableElement method,
RestMethodMetadata restMethodMetadata);

protected String getAnnotationValue(AnnotationMirror annotation, VariableElement parameter, int parameterIndex) {
return getValue(annotation);
}

protected String getDefaultValue(AnnotationMirror annotation, VariableElement parameter, int parameterIndex) {
return buildDefaultValue(parameterIndex);
}
}
Loading
Loading