You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by at...@apache.org on 2020/10/19 09:44:10 UTC
[lucene-solr] branch branch_8x updated: Update Javadocs for Circuit
Breakers
This is an automated email from the ASF dual-hosted git repository.
atri pushed a commit to branch branch_8x
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git
The following commit(s) were added to refs/heads/branch_8x by this push:
new 9e812de Update Javadocs for Circuit Breakers
9e812de is described below
commit 9e812deee6a551b8ccd450385e675ca777a5c773
Author: Atri Sharma <at...@gmail.com>
AuthorDate: Mon Oct 19 15:11:07 2020 +0530
Update Javadocs for Circuit Breakers
---
.../solr/util/circuitbreaker/CircuitBreaker.java | 9 +++++++--
.../solr/util/circuitbreaker/package-info.java | 20 ++++++++++++++++++++
2 files changed, 27 insertions(+), 2 deletions(-)
diff --git a/solr/core/src/java/org/apache/solr/util/circuitbreaker/CircuitBreaker.java b/solr/core/src/java/org/apache/solr/util/circuitbreaker/CircuitBreaker.java
index 90fda7a..7c790d6 100644
--- a/solr/core/src/java/org/apache/solr/util/circuitbreaker/CircuitBreaker.java
+++ b/solr/core/src/java/org/apache/solr/util/circuitbreaker/CircuitBreaker.java
@@ -39,8 +39,10 @@ public abstract class CircuitBreaker {
this.config = config;
}
- // Global config for all circuit breakers. For specific circuit breaker configs, define
- // your own config.
+ /**
+ * Global config for all circuit breakers. For specific circuit breaker configs, define
+ * your own config.
+ */
protected boolean isEnabled() {
return config.isEnabled();
}
@@ -60,6 +62,9 @@ public abstract class CircuitBreaker {
*/
public abstract String getErrorMessage();
+ /**
+ * Represents the configuration for a circuit breaker
+ */
public static class CircuitBreakerConfig {
private final boolean enabled;
private final boolean memCBEnabled;
diff --git a/solr/core/src/java/org/apache/solr/util/circuitbreaker/package-info.java b/solr/core/src/java/org/apache/solr/util/circuitbreaker/package-info.java
new file mode 100644
index 0000000..228e162
--- /dev/null
+++ b/solr/core/src/java/org/apache/solr/util/circuitbreaker/package-info.java
@@ -0,0 +1,20 @@
+/*
+ * 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.
+ */
+/**
+ * Classes related to circuit breaker infrastructure
+ */
+package org.apache.solr.util.circuitbreaker;
\ No newline at end of file