|
SilverStream Application Server 3.5 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.sssw.rts.adminclient.AgAdmin
This class serves as an entry point for the Administration API since it provides factory methods for some important API objects, most notably the Server object. This is a client-side only entry point.
Constructor Summary | |
AgAdmin()
|
Method Summary | |
static AgiAdmExpressionMgr |
getExpressionMgrObject()
Instantiates an Expression Manager object. |
static AgiAdmPublishMgr |
getPublishMgrObject()
Instantiates a Publish Manager object. |
static AgiAdmServer |
getServer(AgrServerSession session)
Instantiates a server object. |
static AgiAdmServer |
getServer(String server)
Get an Admin API server from a string specification. |
static AgiAdmServer |
getServer(String serverName,
int port)
Instantiates a server object. |
static AgiAdmServer |
getServer(String protocol,
String serverName,
int port)
Instantiates a server object |
static AgiAdmStatContainer |
getStatCluster(AgiAdmCluster cluster)
Instantiates a "cluster" type of a statistic container element. |
static AgiAdmStatContainer |
getStatCluster(String protocol,
String host,
int port)
Instantiates a "cluster" type of a statistic container element. |
static AgiAdmStatElement |
getStatElement(String path)
Given a path, instantiate the appropriate statistic element. |
static AgiAdmStatContainer |
getStatServer(AgiAdmServer server)
Instantiates a "server" type of a statistic container element. |
static AgiAdmStatContainer |
getStatServer(String protocol,
String serverName,
int port)
Instantiates a "server" type of a statistic container element. |
static AgiAdmStatSet |
getStatSet(String spec)
Instantiate a statistics set object. |
static AgiAdmStatSet |
getStatSetFromFile(File file)
Instantiate a statistics set object. |
static AgiAdmStatSet |
getStatSetFromStream(InputStream in)
Instantiate a statistics set object. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public AgAdmin()
Method Detail |
public static AgiAdmServer getServer(String serverName, int port) throws AgoUnrecoverableSystemException
serverName
- the name of the serverport
- the port to use; the value of -1 means "use the default port".In the current implementation, this method uses "http" as the protocol.
This method is specific to client-side. On the server side, use the following to get to servers.
From a page:
AgiHttpServletRequest req = getCurrentRequest(); AgoHttpRequestEvent evt = (AgoHttpRequestEvent) req; AgiServer server = evt.getServer();
From a business object:
AgiServer server = evt.getServer();
AgiAdmServer server1 = AgAdmin.getServer("myserver", 90);
AgiAdmServer server2 = AgAdmin.getServer("myserver", -1);
AgiAdmServer
public static AgiAdmServer getServer(String protocol, String serverName, int port) throws AgoUnrecoverableSystemException
protocol
- the name of the protocol to use, e.g. "http" or "https".serverName
- the name of the serverport
- the port to use; the value of -1 means "use the default port".This method is specific to client-side. On the server side, use the following to get to servers.
From a page:
AgiHttpServletRequest req = getCurrentRequest(); AgoHttpRequestEvent evt = (AgoHttpRequestEvent) req; AgiServer server = evt.getServer();
From a business object:
AgiServer server = evt.getServer();
AgiAdmServer server = AgAdmin.getServer("https", "myserver", 88);
AgiAdmServer
public static AgiAdmServer getServer(String server) throws AgoUnrecoverableSystemException
server
- string specification of a server, e.g. "myserver:88"This method is specific to client-side. On the server side, use the following to get to servers.
From a page:
AgiHttpServletRequest req = getCurrentRequest(); AgoHttpRequestEvent evt = (AgoHttpRequestEvent) req; AgiServer server = evt.getServer();
From a business object:
AgiServer server = evt.getServer();
AgiAdmServer server = AgAdmin.getServer("https://myserver:8080"); AgiAdmServer server2 = AgAdmin.getServer("abc:90");
AgiAdmServer
public static AgiAdmServer getServer(AgrServerSession session) throws AgoUnrecoverableSystemException
session
- an established server session to the desired server,
as obtained by AgRuntime.connect().This method is specific to client-side.
This method is primarily intended for use in non-SilverStream applications, which use AgRuntime initialization
AgRuntime.init(null, null, userLogin); AgrServerSession session = AgRuntime.connect("https", "myserver", 88); AgiAdmServer server = AgAdmin.getServer(session);
AgiAdmServer
,
AgRuntime
,
AgrServerSession
public static AgiAdmPublishMgr getPublishMgrObject()
AgiAdmPublishMgr pubmgr = AgAdmin.getPublishMgrObject();
AgiAdmPublishMgr
public static AgiAdmExpressionMgr getExpressionMgrObject()
AgiAdmExpressionMgr exprmgr = AgAdmin.getExpressionMgrObject();
AgiAdmExpressionMgr
public static AgiAdmStatContainer getStatCluster(String protocol, String host, int port) throws AgoUnrecoverableSystemException, AgoSecurityException, MalformedURLException
protocol
- protocol to use, e.g. "https"host
- host nameport
- port, -1 means "use default port"AgiAdmStatContainer
public static AgiAdmStatContainer getStatCluster(AgiAdmCluster cluster) throws AgoUnrecoverableSystemException, AgoSecurityException, MalformedURLException
cluster
- Admin Cluster objectAgiAdmStatContainer
public static AgiAdmStatContainer getStatServer(String protocol, String serverName, int port) throws AgoUnrecoverableSystemException, AgoSecurityException, MalformedURLException
protocol
- protocol to use, e.g. "https"serverName
- host nameport
- server port, -1 means "use default port"AgiAdmStatContainer
public static AgiAdmStatContainer getStatServer(AgiAdmServer server) throws AgoUnrecoverableSystemException, AgoSecurityException, MalformedURLException
server
- an Admin API server admin objectAgiAdmStatContainer
public static AgiAdmStatElement getStatElement(String path) throws AgoUnrecoverableSystemException
path
- path to the elementAgiAdmStatElement
public static AgiAdmStatSet getStatSet(String spec) throws AgoUnrecoverableSystemException, AgoSecurityException
spec
- specifies either a cluster or a server for which this stat set is intended (see below)A cluster spec may be of the form '/protocol://hostname:port'.
A server spec may be of the form 'cluster spec/protocol://hostname:port';
The spec ties a particular set to a particular cluster or server; that means that every statistic added to the set must have its owner path point to an element within the cluster/server or the cluster/server itself.
AgiAdmStatSet set1 = AgAdmin.getStatSet("/http://abc:8080"); AgiAdmStatSet set2 = AgAdmin.getStatSet("/def:8080"); AgiAdmStatSet set3 = AgAdmin.getStatSet("/ghi"); AgiAdmStatSet set4 = AgAdmin.getStatSet("/http://abc:8080/http://myserver:80"); AgiAdmStatSet set5 = AgAdmin.getStatSet("/def:8080/klm:90");
public static AgiAdmStatSet getStatSetFromStream(InputStream in) throws AgoUnrecoverableSystemException, AgoSecurityException, IOException
in
- the input stream to read the statistics set fromYou cannnot specify elements whose paths point to different clusters/servers within the same set.
public static AgiAdmStatSet getStatSetFromFile(File file) throws AgoUnrecoverableSystemException, AgoSecurityException, FileNotFoundException, IOException
file
- the file to read the statistics set fromYou cannot specify elements whose paths point to different clusters/servers within the same set.
|
SilverStream Application Server 3.5 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |