NebulaGraph Java Client  release-3.6
MetaManager Class Reference

MetaManager is a manager for meta info, such as spaces,tags and edges. More...

+ Inheritance diagram for MetaManager:
+ Collaboration diagram for MetaManager:

Public Member Functions

 MetaManager (List< HostAddress > address) throws TException, ClientServerIncompatibleException, UnknownHostException
 init the meta info cache
 
 MetaManager (List< HostAddress > address, int timeout, int connectionRetry, int executionRetry, boolean enableSSL, SSLParam sslParam) throws TException, ClientServerIncompatibleException, UnknownHostException
 init the meta info cache with more config
 
void close ()
 close meta client
 
int getSpaceId (String spaceName) throws IllegalArgumentException
 get space id More...
 
SpaceItem getSpace (String spaceName) throws IllegalArgumentException
 get space item More...
 
int getTagId (String spaceName, String tagName) throws IllegalArgumentException
 get tag id More...
 
TagItem getTag (String spaceName, String tagName) throws IllegalArgumentException
 get tag More...
 
int getEdgeType (String spaceName, String edgeName) throws IllegalArgumentException
 get edge type More...
 
EdgeItem getEdge (String spaceName, String edgeName) throws IllegalArgumentException
 get Edge More...
 
HostAddr getLeader (String spaceName, int part) throws IllegalArgumentException
 get part leader More...
 
List< Integer > getSpaceParts (String spaceName) throws IllegalArgumentException
 get all parts of one space More...
 
Map< Integer, List< HostAddr > > getPartsAlloc (String spaceName) throws IllegalArgumentException
 get all parts alloc of one space More...
 
void updateLeader (String spaceName, int part, HostAddr newLeader) throws IllegalArgumentException
 cache new leader for part More...
 
Set< HostAddr > listHosts ()
 get all storage addresses
 
int getConnectionRetry ()
 
int getTimeout ()
 
int getExecutionRetry ()
 

Detailed Description

MetaManager is a manager for meta info, such as spaces,tags and edges.

Definition at line 34 of file MetaManager.java.

Member Function Documentation

◆ getEdge()

EdgeItem getEdge ( String  spaceName,
String  edgeName 
) throws IllegalArgumentException

get Edge

Parameters
spaceNamenebula graph space name
edgeNamenebula edge name
Returns

Implements MetaCache.

Definition at line 239 of file MetaManager.java.

+ Here is the caller graph for this function:

◆ getEdgeType()

int getEdgeType ( String  spaceName,
String  edgeName 
) throws IllegalArgumentException

get edge type

Parameters
spaceNamenebula graph space name
edgeNamenebula edge name
Returns
long

Definition at line 227 of file MetaManager.java.

+ Here is the call graph for this function:

◆ getLeader()

HostAddr getLeader ( String  spaceName,
int  part 
) throws IllegalArgumentException

get part leader

Parameters
spaceNamenebula graph space name
partnebula part id
Returns
leader

Definition at line 265 of file MetaManager.java.

◆ getPartsAlloc()

Map<Integer, List<HostAddr> > getPartsAlloc ( String  spaceName) throws IllegalArgumentException

get all parts alloc of one space

Parameters
spaceNamenebula graph space name
Returns
Map

Implements MetaCache.

Definition at line 305 of file MetaManager.java.

+ Here is the caller graph for this function:

◆ getSpace()

SpaceItem getSpace ( String  spaceName) throws IllegalArgumentException

get space item

Parameters
spaceNamenebula graph space name
Returns
SpaceItem

Implements MetaCache.

Definition at line 166 of file MetaManager.java.

+ Here is the caller graph for this function:

◆ getSpaceId()

int getSpaceId ( String  spaceName) throws IllegalArgumentException

get space id

Parameters
spaceNamenebula space name
Returns

Definition at line 155 of file MetaManager.java.

+ Here is the call graph for this function:

◆ getSpaceParts()

List<Integer> getSpaceParts ( String  spaceName) throws IllegalArgumentException

get all parts of one space

Parameters
spaceNamenebula graph space name
Returns
Lsit

Definition at line 294 of file MetaManager.java.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getTag()

TagItem getTag ( String  spaceName,
String  tagName 
) throws IllegalArgumentException

get tag

Parameters
spaceNamenebula space name
tagNamenebula tag name
Returns

Implements MetaCache.

Definition at line 200 of file MetaManager.java.

+ Here is the caller graph for this function:

◆ getTagId()

int getTagId ( String  spaceName,
String  tagName 
) throws IllegalArgumentException

get tag id

Parameters
spaceNamenebula graph space name
tagNamenebula tag name
Returns
int

Definition at line 188 of file MetaManager.java.

+ Here is the call graph for this function:

◆ updateLeader()

void updateLeader ( String  spaceName,
int  part,
HostAddr  newLeader 
) throws IllegalArgumentException

cache new leader for part

Parameters
spaceNamenebula graph space
partnebula part
newLeadernebula part new leader

Definition at line 328 of file MetaManager.java.

+ Here is the caller graph for this function:

The documentation for this class was generated from the following file: