Class BookieService
- java.lang.Object
- 
- org.apache.bookkeeper.common.component.AbstractComponent<ConfT>
- 
- org.apache.bookkeeper.common.component.AbstractLifecycleComponent<BookieConfiguration>
- 
- org.apache.bookkeeper.server.component.ServerLifecycleComponent
- 
- org.apache.bookkeeper.server.service.BookieService
 
 
 
 
- 
- All Implemented Interfaces:
- java.lang.AutoCloseable,- LifecycleComponent
 
 public class BookieService extends ServerLifecycleComponent AServerLifecycleComponentthat starts the core bookie server.
- 
- 
Field SummaryFields Modifier and Type Field Description static java.lang.StringNAME- 
Fields inherited from class org.apache.bookkeeper.common.component.AbstractLifecycleComponentlifecycle, statsLogger, uncaughtExceptionHandler
 - 
Fields inherited from class org.apache.bookkeeper.common.component.AbstractComponentcomponentName, conf
 
- 
 - 
Constructor SummaryConstructors Constructor Description BookieService(BookieConfiguration conf, Bookie bookie, StatsLogger statsLogger, org.apache.bookkeeper.common.allocator.ByteBufAllocatorWithOomHandler allocator, UncleanShutdownDetection uncleanShutdownDetection)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddoClose()protected voiddoStart()protected voiddoStop()BookieServergetServer()voidpublishInfo(ComponentInfoPublisher componentInfoPublisher)voidsetExceptionHandler(java.lang.Thread.UncaughtExceptionHandler handler)Set the default handler invoked when a lifecycle component abruptly terminates due an uncaught exception.- 
Methods inherited from class org.apache.bookkeeper.server.component.ServerLifecycleComponentloadServerComponents
 - 
Methods inherited from class org.apache.bookkeeper.common.component.AbstractLifecycleComponentaddLifecycleListener, close, getStatsLogger, lifecycleState, removeLifecycleListener, start, stop
 - 
Methods inherited from class org.apache.bookkeeper.common.component.AbstractComponentgetConf, getName
 - 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface org.apache.bookkeeper.common.component.LifecycleComponentgetName
 
- 
 
- 
- 
- 
Field Detail- 
NAMEpublic static final java.lang.String NAME - See Also:
- Constant Field Values
 
 
- 
 - 
Constructor Detail- 
BookieServicepublic BookieService(BookieConfiguration conf, Bookie bookie, StatsLogger statsLogger, org.apache.bookkeeper.common.allocator.ByteBufAllocatorWithOomHandler allocator, UncleanShutdownDetection uncleanShutdownDetection) throws java.lang.Exception - Throws:
- java.lang.Exception
 
 
- 
 - 
Method Detail- 
setExceptionHandlerpublic void setExceptionHandler(java.lang.Thread.UncaughtExceptionHandler handler) Description copied from interface:LifecycleComponentSet the default handler invoked when a lifecycle component abruptly terminates due an uncaught exception.- Specified by:
- setExceptionHandlerin interface- LifecycleComponent
- Overrides:
- setExceptionHandlerin class- AbstractLifecycleComponent<BookieConfiguration>
- Parameters:
- handler- handler invoked when an uncaught exception happens in the lifecycle component.
 
 - 
getServerpublic BookieServer getServer() 
 - 
doStartprotected void doStart() - Specified by:
- doStartin class- AbstractLifecycleComponent<BookieConfiguration>
 
 - 
doStopprotected void doStop() - Specified by:
- doStopin class- AbstractLifecycleComponent<BookieConfiguration>
 
 - 
doCloseprotected void doClose() throws java.io.IOException- Specified by:
- doClosein class- AbstractLifecycleComponent<BookieConfiguration>
- Throws:
- java.io.IOException
 
 - 
publishInfopublic void publishInfo(ComponentInfoPublisher componentInfoPublisher) 
 
- 
 
-