You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by yu...@apache.org on 2023/02/03 05:23:59 UTC
[rocketmq] branch develop updated: Remove the useless exception class: MQRedirectException #5963
This is an automated email from the ASF dual-hosted git repository.
yukon pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/rocketmq.git
The following commit(s) were added to refs/heads/develop by this push:
new 4e6740949 Remove the useless exception class: MQRedirectException #5963
4e6740949 is described below
commit 4e6740949d1fc52c40f6bde512d1cd59734e342c
Author: loboxu <lo...@tencent.com>
AuthorDate: Thu Feb 2 14:37:16 2023 +0800
Remove the useless exception class: MQRedirectException #5963
---
.../client/exception/MQRedirectException.java | 38 ----------------------
1 file changed, 38 deletions(-)
diff --git a/client/src/main/java/org/apache/rocketmq/client/exception/MQRedirectException.java b/client/src/main/java/org/apache/rocketmq/client/exception/MQRedirectException.java
deleted file mode 100644
index 6ed395ead..000000000
--- a/client/src/main/java/org/apache/rocketmq/client/exception/MQRedirectException.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * 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.rocketmq.client.exception;
-
-public class MQRedirectException extends MQBrokerException {
- private static final StackTraceElement[] UNASSIGNED_STACK = new StackTraceElement[0];
-
- private final byte[] body;
-
- public MQRedirectException(byte[] responseBody) {
- this.body = responseBody;
- }
-
- // This exception class is used as a flow control item, so stack trace is useless and performance killer.
- @Override
- public synchronized Throwable fillInStackTrace() {
- this.setStackTrace(UNASSIGNED_STACK);
- return this;
- }
-
- public byte[] getBody() {
- return body;
- }
-}