fix malformed javadoc, and add an @see for close() to getAdminCore since caller needs to be aware of it

git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@690351 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Chris M. Hostetter 2008-08-29 18:04:45 +00:00
parent 95bdcc13a0
commit ece75c9762
2 changed files with 14 additions and 9 deletions

View File

@ -457,6 +457,7 @@ public class CoreContainer
/**
* Ensures there is a valid core to handle MultiCore admin taks and
* increase its refcount.
* @see SolrCore#close()
* @return the acquired admin core, null if no core is available
*/
public SolrCore getAdminCore() {

View File

@ -586,20 +586,24 @@ public final class SolrCore implements SolrInfoMBean {
}
/**
* Close all resources allocated by the core.
* 1. searcher
* 2. updateHandler
* 3. all CloseHooks will be notified
* 4. All MBeans will be unregistered from MBeanServer if JMX was enabled
* Close all resources allocated by the core...
* <ul>
* <li>searcher</li>
* <li>updateHandler</li>
* <li>all CloseHooks will be notified</li>
* <li>All MBeans will be unregistered from MBeanServer if JMX was enabled
* </li>
* </ul>
* <p>
* This should always be called when the core is obtained through:
* @see CoreContainer.getCore
* @see CoreContainer.getAdminCore
* This should always be called when the core is obtained through {@link CoreContainer#getCore} or {@link CoreContainer#getAdminCore}
* </p>
* <p>
* The actual close is performed if the core usage count is 1.
* (A core is created with a usage count of 1).
* If usage count is > 1, the usage count is decreased by 1.
* If usage count is &lt; 0, this is an error and a runtime exception is thrown.
* If usage count is &lt; 0, this is an error and a runtime exception
* is thrown.
* </p>
*/
public void close() {
int count = refCount.decrementAndGet();