|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.hive.service.AbstractService
org.apache.hive.service.CompositeService
org.apache.lens.server.LensService
public abstract class LensService
The Class LensService.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.apache.hive.service.CompositeService |
|---|
org.apache.hive.service.CompositeService.CompositeServiceShutdownHook |
| Nested classes/interfaces inherited from interface org.apache.hive.service.Service |
|---|
org.apache.hive.service.Service.STATE |
| Field Summary | |
|---|---|
static org.apache.commons.logging.Log |
LOG
The Constant LOG. |
protected static ConcurrentHashMap<String,org.apache.lens.api.LensSessionHandle> |
sessionMap
The session map. |
protected boolean |
stopped
The stopped. |
| Constructor Summary | |
|---|---|
protected |
LensService(String name,
org.apache.hive.service.cli.CLIService cliService)
Instantiates a new lens service. |
| Method Summary | |
|---|---|
void |
acquire(org.apache.lens.api.LensSessionHandle sessionHandle)
Acquire. |
void |
acquire(String sessionHandle)
Acquire a lens session specified by the public UUID. |
void |
addResource(org.apache.lens.api.LensSessionHandle sessionHandle,
String type,
String path)
Adds the resource. |
void |
closeSession(org.apache.lens.api.LensSessionHandle sessionHandle)
Close session. |
void |
deleteResource(org.apache.lens.api.LensSessionHandle sessionHandle,
String type,
String path)
Delete resource. |
org.apache.hive.service.cli.CLIService |
getCliService()
|
static org.apache.hive.service.cli.SessionHandle |
getHiveSessionHandle(org.apache.lens.api.LensSessionHandle lensHandle)
Gets the hive session handle. |
org.apache.hadoop.conf.Configuration |
getLensConf(org.apache.lens.api.LensConf conf)
Gets the lens conf. |
org.apache.hadoop.conf.Configuration |
getLensConf(org.apache.lens.api.LensSessionHandle sessionHandle,
org.apache.lens.api.LensConf conf)
Gets the lens conf. |
String |
getServerDomain()
|
LensSessionImpl |
getSession(org.apache.lens.api.LensSessionHandle sessionHandle)
Gets the session. |
protected org.apache.lens.api.LensSessionHandle |
getSessionHandle(String sessionid)
Gets the session handle. |
org.apache.hive.service.cli.session.SessionManager |
getSessionManager()
|
org.apache.lens.api.LensSessionHandle |
openSession(String username,
String password,
Map<String,String> configuration)
Open session. |
void |
prepareStopping()
Prepare stopping. |
void |
readExternal(ObjectInput in)
|
void |
release(org.apache.lens.api.LensSessionHandle sessionHandle)
Release. |
void |
release(String sessionHandle)
Releases a lens session specified by the public UUID. |
void |
restoreSession(org.apache.lens.api.LensSessionHandle sessionHandle,
String userName,
String password)
Restore session from previous instance of lens server. |
void |
writeExternal(ObjectOutput out)
|
| Methods inherited from class org.apache.hive.service.CompositeService |
|---|
addService, getServices, init, removeService, start, stop |
| Methods inherited from class org.apache.hive.service.AbstractService |
|---|
getHiveConf, getName, getServiceState, getStartTime, register, unregister |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final org.apache.commons.logging.Log LOG
protected boolean stopped
protected static ConcurrentHashMap<String,org.apache.lens.api.LensSessionHandle> sessionMap
| Constructor Detail |
|---|
protected LensService(String name,
org.apache.hive.service.cli.CLIService cliService)
name - the namecliService - the cli service| Method Detail |
|---|
public org.apache.hive.service.cli.CLIService getCliService()
public String getServerDomain()
public org.apache.lens.api.LensSessionHandle openSession(String username,
String password,
Map<String,String> configuration)
throws org.apache.lens.api.LensException
username - the usernamepassword - the passwordconfiguration - the configuration
org.apache.lens.api.LensException - the lens exception
public void restoreSession(org.apache.lens.api.LensSessionHandle sessionHandle,
String userName,
String password)
throws org.apache.lens.api.LensException
sessionHandle - the session handleuserName - the user namepassword - the password
org.apache.lens.api.LensException - the lens exception
public void closeSession(org.apache.lens.api.LensSessionHandle sessionHandle)
throws org.apache.lens.api.LensException
sessionHandle - the session handle
org.apache.lens.api.LensException - the lens exceptionpublic org.apache.hive.service.cli.session.SessionManager getSessionManager()
public LensSessionImpl getSession(org.apache.lens.api.LensSessionHandle sessionHandle)
sessionHandle - the session handle
public void acquire(org.apache.lens.api.LensSessionHandle sessionHandle)
sessionHandle - the session handlepublic void acquire(String sessionHandle)
sessionHandle - public UUID of the sessionpublic void release(org.apache.lens.api.LensSessionHandle sessionHandle)
sessionHandle - the session handle
public void release(String sessionHandle)
throws org.apache.lens.api.LensException
sessionHandle - the session handle
org.apache.lens.api.LensException - if session cannot be releasedprotected org.apache.lens.api.LensSessionHandle getSessionHandle(String sessionid)
sessionid - the sessionid
public void addResource(org.apache.lens.api.LensSessionHandle sessionHandle,
String type,
String path)
throws org.apache.lens.api.LensException
sessionHandle - the session handletype - the typepath - the path
org.apache.lens.api.LensException - the lens exception
public void deleteResource(org.apache.lens.api.LensSessionHandle sessionHandle,
String type,
String path)
throws org.apache.lens.api.LensException
sessionHandle - the session handletype - the typepath - the path
org.apache.lens.api.LensException - the lens exceptionpublic static org.apache.hive.service.cli.SessionHandle getHiveSessionHandle(org.apache.lens.api.LensSessionHandle lensHandle)
lensHandle - the lens handle
public org.apache.hadoop.conf.Configuration getLensConf(org.apache.lens.api.LensSessionHandle sessionHandle,
org.apache.lens.api.LensConf conf)
throws org.apache.lens.api.LensException
sessionHandle - the session handleconf - the conf
org.apache.lens.api.LensException - the lens exception
public org.apache.hadoop.conf.Configuration getLensConf(org.apache.lens.api.LensConf conf)
throws org.apache.lens.api.LensException
conf - the conf
org.apache.lens.api.LensException - the lens exceptionpublic void prepareStopping()
public void readExternal(ObjectInput in)
throws IOException,
ClassNotFoundException
readExternal in interface ExternalizableIOException
ClassNotFoundException
public void writeExternal(ObjectOutput out)
throws IOException
writeExternal in interface ExternalizableIOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||