Skip to content

Commit

Permalink
Remove Vert.x from ShardingSphere-Proxy (#22982)
Browse files Browse the repository at this point in the history
* Remove Vert.x from ShardingSphere-Proxy

* Update related documents and configurations

* Inline DatabaseCommunicationEngine and BackendConnection

* Update server.yaml in E2E tests

* Inline Portal

* Remove type parameter from ConnectionPostProcessor

* Update RAL documents and tests

* Remove unused Netty dependencies

* Revise javadoc
  • Loading branch information
TeslaCN authored Dec 20, 2022
1 parent 45b4ddf commit 497b46f
Show file tree
Hide file tree
Showing 155 changed files with 1,005 additions and 5,590 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
import org.apache.shardingsphere.agent.plugin.tracing.jaeger.constant.JaegerConstants;
import org.apache.shardingsphere.agent.plugin.tracing.jaeger.span.JaegerErrorSpan;
import org.apache.shardingsphere.infra.executor.kernel.model.ExecutorDataMap;
import org.apache.shardingsphere.proxy.backend.communication.jdbc.connection.JDBCBackendConnection;
import org.apache.shardingsphere.proxy.backend.communication.BackendConnection;
import org.apache.shardingsphere.proxy.backend.session.ConnectionSession;
import org.apache.shardingsphere.proxy.frontend.command.CommandExecutorTask;

Expand Down Expand Up @@ -55,7 +55,7 @@ public void afterMethod(final TargetAdviceObject target, final Method method, fi
ExecutorDataMap.getValue().remove(JaegerConstants.ROOT_SPAN);
Field field = CommandExecutorTask.class.getDeclaredField("connectionSession");
field.setAccessible(true);
JDBCBackendConnection connection = (JDBCBackendConnection) ((ConnectionSession) field.get(target)).getBackendConnection();
BackendConnection connection = ((ConnectionSession) field.get(target)).getBackendConnection();
Scope scope = GlobalTracer.get().scopeManager().active();
scope.span().setTag(JaegerConstants.ShardingSphereTags.CONNECTION_COUNT.getKey(), connection.getConnectionSize());
scope.close();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
import org.apache.shardingsphere.agent.advice.MethodInvocationResult;
import org.apache.shardingsphere.agent.plugin.tracing.zipkin.constant.ZipkinConstants;
import org.apache.shardingsphere.infra.executor.kernel.model.ExecutorDataMap;
import org.apache.shardingsphere.proxy.backend.communication.jdbc.connection.JDBCBackendConnection;
import org.apache.shardingsphere.proxy.backend.communication.BackendConnection;
import org.apache.shardingsphere.proxy.backend.session.ConnectionSession;
import org.apache.shardingsphere.proxy.frontend.command.CommandExecutorTask;

Expand All @@ -52,7 +52,7 @@ public void beforeMethod(final TargetAdviceObject target, final Method method, f
public void afterMethod(final TargetAdviceObject target, final Method method, final Object[] args, final MethodInvocationResult invocationResult) {
Field field = CommandExecutorTask.class.getDeclaredField("connectionSession");
field.setAccessible(true);
JDBCBackendConnection connection = (JDBCBackendConnection) ((ConnectionSession) field.get(target)).getBackendConnection();
BackendConnection connection = ((ConnectionSession) field.get(target)).getBackendConnection();
Span span = (Span) ExecutorDataMap.getValue().remove(ZipkinConstants.ROOT_SPAN);
span.tag(ZipkinConstants.Tags.CONNECTION_COUNT, String.valueOf(connection.getConnectionSize()));
span.finish();
Expand Down
5 changes: 0 additions & 5 deletions distribution/proxy-native/src/main/release-docs/LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -270,15 +270,13 @@ The text of each license is the standard Apache 2.0 license.
memory 0.9.0, Apache 2.0
netty-buffer 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-codec 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-codec-dns 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-codec-http 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-codec-http2 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-codec-socks 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-common 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-handler 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-handler-proxy 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-resolver 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-resolver-dns 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-transport 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-transport-classes-epoll 4.1.85.Final: https://github.com/netty, Apache 2.0
netty-transport-native-epoll 4.1.85.Final-linux-aarch_64: https://github.com/netty, Apache 2.0
Expand All @@ -291,8 +289,6 @@ The text of each license is the standard Apache 2.0 license.
sketches-core 0.9.0, Apache 2.0
snakeyaml 1.33: https://bitbucket.org/snakeyaml/snakeyaml, Apache 2.0
uzaygezen-core 0.2: https://code.google.com/p/uzaygezen, Apache 2.0
vertx-mysql-client 4.3.3: https://github.com/eclipse-vertx/vertx-sql-client, Apache 2.0
vertx-sql-client 4.3.3: https://github.com/eclipse-vertx/vertx-sql-client, Apache 2.0
zookeeper 3.8.0: https://github.com/apache/zookeeper, Apache 2.0
zookeeper-jute 3.8.0: https://github.com/apache/zookeeper, Apache 2.0

Expand All @@ -308,7 +304,6 @@ The text of each license is also included at licenses/LICENSE-[project].txt.
transactions-api 5.0.9: https://www.atomikos.com, Apache 2.0
transactions-jdbc 5.0.9: https://www.atomikos.com, Apache 2.0
transactions-jta 5.0.9: https://www.atomikos.com, Apache 2.0
vertx-core 4.3.3: https://github.com/eclipse-vertx/vert.x, Apache 2.0

========================================================================
BSD licenses
Expand Down
45 changes: 0 additions & 45 deletions distribution/proxy-native/src/main/release-docs/NOTICE
Original file line number Diff line number Diff line change
Expand Up @@ -387,48 +387,3 @@ SoundCloud Ltd. (http://soundcloud.com/).

This product includes software developed as part of the
Ocelli project by Netflix Inc. (https://github.com/Netflix/ocelli/).

========================================================================

Vert.x NOTICE

========================================================================

This content is produced and maintained by the Eclipse Vert.x project.

* Project home: https://projects.eclipse.org/projects/rt.vertx

Eclipse Vert.x, and Vert.x are trademarks of the Eclipse Foundation. Eclipse,
and the Eclipse Logo are registered trademarks of the Eclipse Foundation.

## Declared Project Licenses

This program and the accompanying materials are made available under the
terms of the Eclipse Public License 2.0 which is available at
http://www.eclipse.org/legal/epl-2.0, or the Apache Software License
2.0 which is available at https://www.apache.org/licenses/LICENSE-2.0.

SPDX-License-Identifier: EPL-2.0 OR Apache-2.0

## Source Code

The project maintains the following source code repositories:

* https://github.com/eclipse-vertx/vert.x

## Copyright Holders

> See the header in each individual file and https://github.com/eclipse/vert.x/graphs/contributors.

## Third-party Content

> See the declared runtime dependencies in `pom.xml`.

## Cryptography

Content may contain encryption software. The country in which you are currently
may have restrictions on the import, possession, and use, and/or re-export to
another country, of encryption software. BEFORE using any encryption software,
please check the country's laws, regulations and policies concerning the import,
possession, or use, and re-export of encryption software, to see if this is
permitted.
Loading

0 comments on commit 497b46f

Please sign in to comment.