-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathendpointURLs.py
27 lines (18 loc) · 927 Bytes
/
endpointURLs.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
import socket
hostname = socket.gethostname()
applications = AdminApp.list().splitlines()
for application in applications:
print application
modules = AdminApp.listModules(application).splitlines()
for module in modules:
start = module.find("#")
end = module.find("+")
moduleName = module[start+1:end]
print "\t" + moduleName
endPointManagers = AdminControl.queryNames("WebSphere:*,type=EndpointManager,ModuleName=" + moduleName).splitlines()
for endPointManager in endPointManagers:
serviceNames = AdminControl.invoke(endPointManager, "getServiceNames").splitlines()
for serviceName in serviceNames:
endpointNames = AdminControl.invoke(endPointManager, "getEndpointNames", [serviceName]).splitlines()
for endpointName in endpointNames:
print "\t\t" + AdminControl.invoke(endPointManager, "getEndpointPartialURL", [serviceName, endpointName])