public class ServiceComponent extends AbstractComponent
| 限定符和类型 | 字段和说明 |
|---|---|
static ComponentType |
SERVICE_COMPONENT_TYPE |
static String |
UNREGISTER_DELAY_MILLISECONDS |
componentName, componentStatus, e, implementation, sofaRuntimeContext| 构造器和说明 |
|---|
ServiceComponent(Implementation implementation,
Service service,
BindingAdapterFactory bindingAdapterFactory,
SofaRuntimeContext sofaRuntimeContext) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
activate()
activate component
|
void |
deactivate()
deactivate component
|
String |
dump()
get component information
|
Map<String,Property> |
getProperties()
get all properties
|
Service |
getService() |
ComponentType |
getType()
get component type
|
HealthResult |
isHealthy()
check component is health or not
|
boolean |
resolve()
resolve component
|
void |
unregister()
unregister component
|
exception, getContext, getImplementation, getName, getState, isActivated, isResolved, register, unresolvepublic static final ComponentType SERVICE_COMPONENT_TYPE
public ServiceComponent(Implementation implementation, Service service, BindingAdapterFactory bindingAdapterFactory, SofaRuntimeContext sofaRuntimeContext)
public ComponentType getType()
ComponentInfopublic Map<String,Property> getProperties()
ComponentInfopublic boolean resolve()
Componentresolve 在接口中 Componentresolve 在类中 AbstractComponentpublic void activate()
throws ServiceRuntimeException
Componentactivate 在接口中 Componentactivate 在类中 AbstractComponentServiceRuntimeExceptionpublic void deactivate()
throws ServiceRuntimeException
Componentdeactivate 在接口中 Componentdeactivate 在类中 AbstractComponentServiceRuntimeExceptionpublic void unregister()
throws ServiceRuntimeException
Componentunregister 在接口中 Componentunregister 在类中 AbstractComponentServiceRuntimeExceptionpublic String dump()
ComponentInfodump 在接口中 ComponentInfodump 在类中 AbstractComponentpublic Service getService()
public HealthResult isHealthy()
ComponentInfoisHealthy 在接口中 ComponentInfoisHealthy 在类中 AbstractComponentCopyright © 2018 Pivotal Software, Inc.. All rights reserved.