Package edu.internet2.ndt
Class Tcpbw100
- All Implemented Interfaces:
ActionListener
Main Applet class that creates UI, defines tests and interprets results from
the tests.
-
Nested Class Summary
Modifier and TypeClassDescription(package private) class
Class to start tests in a thread. -
Field Summary
Modifier and TypeFieldDescription(package private) boolean
(package private) boolean
(package private) boolean
(package private) boolean
(package private) JButton
(package private) JButton
(package private) JButton
(package private) JButton
(package private) JButton
(package private) JButton
(package private) JButton
(package private) JButton
(package private) JButton
(package private) int
(package private) JCheckBox
(package private) JCheckBox
(package private) JComboBox
(package private) double
(package private) double
(package private) double
(package private) double
(package private) double
(package private) double
(package private) NewFrame
(package private) NewFrame
(package private) NewFrame
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) long
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) int
(package private) ResultsTextPane
(package private) int
(package private) String[]
(package private) String
(package private) String
(package private) String
(package private) JSpinner
(package private) String
(package private) String
protected URL
(package private) JTextArea
(package private) JTextArea
(package private) byte[]
(package private) byte
(package private) double
(package private) double
(package private) int
(package private) int
(package private) double
(package private) double
(package private) double
(package private) int
(package private) InetAddress
(package private) double
(package private) int
(package private) int
(package private) int
(package private) double
(package private) double
(package private) double
(package private) double
(package private) double
(package private) double
(package private) String
(package private) double
(package private) double
(package private) double
(package private) double
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
actionPerformed
(ActionEvent paramEventObj) Action handler method called when an associated action is performedvoid
Create the "More details" window.void
Create the "Options" window.void
Create the "Statistics" window.void
dottcp
(StatusPanel sPanel) Method to run tests and interpret the results sent by the serverget_host()
get_loss()
get_Ping()
int
Get Client->Server fire-wall test results.Function that returns a variable corresponding to the parameter passed to it as a request.getParameter
(String paramStrName) Utility method to get parameter value.int
Get Server->Client fire-wall test results.I2P Translated status, not HTML escaped.Set UserAgent String containing browser details.void
init()
Initialize the base NDT window Applet init() methodboolean
I2Pvoid
killIt()
bigly -- must have been started with main() or runIt()static void
public static void main for invoking as an Applicationstatic Tcpbw100
mainSupport
(String[] args) biglyvoid
middleboxResults
(String sMidBoxTestResParam) This routine decodes the middlebox test results.void
run_test()
"Remote Control" function - invoke NDT' runtest() method from the APIvoid
runIt()
biglyvoid
runtest()
Run the Thread that calls the "dottcp" method to run tests.void
save_dbl_values
(String sSysvarParam, double dSysvalParam) Method to save double values of various "keys" from the the test results string into corresponding double datatypes.void
save_int_values
(String sSysvarParam, int iSysvalParam) Method to save integer values of various "keys" from the the test results string into corresponding integer datatypes.void
save_long_values
(String sSysvarParam, long lSysvalParam) Method to save long values of various "keys" from the the test results string into corresponding long datatypes.void
setC2sSFWTestResults
(int iParamC2SRes) Set Client->Server fire-wall test results.void
setS2cSFWTestResults
(int iParamS2CRes) Set server->Client fire-wall test results.void
setUserAgent
(String paramStrUserAgent) Set UserAgent String.void
Pop up a window to display some information about TCP packet queuing.void
showStatus
(String msg) Display current status in Applet window.boolean
Client to server throughput test.boolean
The META test allows the Client to send an additional information to the Server that basically gets included along with the overall set of test results.boolean
MiddleBox testing is a throughput test from the Server to the Client to check for duplex mismatch conditions.boolean
S2C throughput test to measure network bandwidth from server to client.boolean
Fire-wall tests aiming to find out if one exists between Client and server.void
testResults
(String sTestResParam) Method that interprets test results.Methods inherited from class com.vuze.plugins.mlab.tools.ndt.swingemu.JApplet
getAppletContext, getCodeBase, start
Methods inherited from class com.vuze.plugins.mlab.tools.ndt.swingemu.JFrame
destroy, dispose, getContentPane, toBack
Methods inherited from class com.vuze.plugins.mlab.tools.ndt.swingemu.Component
add, add, add, addMouseListener, addWindowListener, getToolkit, pack, repaint, setBorder, setCursor, setEditable, setEnabled, setForeground, setLayout, setLayout, setPreferredSize, setResizable, setSize, setTitle, setVisible
-
Field Details
-
_txtDiagnosis
JTextArea _txtDiagnosis -
_txtStatistics
JTextArea _txtStatistics -
_resultsTxtPane
ResultsTextPane _resultsTxtPane -
_sErrMsg
String _sErrMsg -
_buttonStartTest
JButton _buttonStartTest -
_buttonDetailsDismiss
JButton _buttonDetailsDismiss -
_buttonStatsDismiss
JButton _buttonStatsDismiss -
_buttonDetailsCopy
JButton _buttonDetailsCopy -
_buttonStatsCopy
JButton _buttonStatsCopy -
_buttonDetails
JButton _buttonDetails -
_buttonStatistics
JButton _buttonStatistics -
_buttonMailTo
JButton _buttonMailTo -
_buttonOptions
JButton _buttonOptions -
_chkboxDefaultTest
JCheckBox _chkboxDefaultTest -
_chkboxPreferIPv6
JCheckBox _chkboxPreferIPv6 -
_spinnerTestCount
JSpinner _spinnerTestCount -
_saDelays
String[] _saDelays -
_cmboboxDelay
JComboBox _cmboboxDelay -
_bRandomize
boolean _bRandomize -
_bFailed
boolean _bFailed -
_bCanCopy
boolean _bCanCopy -
_frameWeb100Vars
NewFrame _frameWeb100Vars -
_frameDetailedStats
NewFrame _frameDetailedStats -
_frameOptions
NewFrame _frameOptions -
_dTime
double _dTime -
_s2cspdUpdateTime
int _s2cspdUpdateTime -
_c2sspdUpdateTime
int _c2sspdUpdateTime -
_iECNEnabled
int _iECNEnabled -
_iNagleEnabled
int _iNagleEnabled -
MSSSent
int MSSSent -
MSSRcvd
int MSSRcvd -
_iSACKEnabled
int _iSACKEnabled -
_iTimestampsEnabled
int _iTimestampsEnabled -
_iWinScaleRcvd
int _iWinScaleRcvd -
_iWinScaleSent
int _iWinScaleSent -
_iFastRetran
int _iFastRetran -
_iAckPktsOut
int _iAckPktsOut -
_iSmoothedRTT
int _iSmoothedRTT -
_iCurrentCwnd
int _iCurrentCwnd -
_iMaxCwnd
int _iMaxCwnd -
_iSndLimTimeRwin
int _iSndLimTimeRwin -
_iSndLimTimeCwnd
int _iSndLimTimeCwnd -
_iSndLimTimeSender
int _iSndLimTimeSender -
_iSndLimTransRwin
int _iSndLimTransRwin -
_iSndLimTransCwnd
int _iSndLimTransCwnd -
_iSndLimTransSender
int _iSndLimTransSender -
_iMaxSsthresh
int _iMaxSsthresh -
_iSumRTT
int _iSumRTT -
_iCountRTT
int _iCountRTT -
_iCurrentMSS
int _iCurrentMSS -
_iTimeouts
int _iTimeouts -
_iPktsRetrans
int _iPktsRetrans -
_iSACKsRcvd
int _iSACKsRcvd -
_iDupAcksIn
int _iDupAcksIn -
_iMaxRwinRcvd
int _iMaxRwinRcvd -
_iMaxRwinSent
int _iMaxRwinSent -
_iDataPktsOut
int _iDataPktsOut -
_iRcvbuf
int _iRcvbuf -
_iSndbuf
int _iSndbuf -
_iAckPktsIn
int _iAckPktsIn -
_iDataBytesOut
long _iDataBytesOut -
_iPktsOut
int _iPktsOut -
_iCongestionSignals
int _iCongestionSignals -
_iRcvWinScale
int _iRcvWinScale -
_iPkts
int _iPkts -
_iLength
int _iLength -
_iCurrentRTO
int _iCurrentRTO -
_iC2sData
int _iC2sData -
_iC2sAck
int _iC2sAck -
_iS2cData
int _iS2cData -
_iS2cAck
int _iS2cAck -
_sServerType
String _sServerType -
_targetURL
-
_sEmailText
String _sEmailText -
_dS2cspd
double _dS2cspd -
_dC2sspd
double _dC2sspd -
_dSc2sspd
double _dSc2sspd -
_dSs2cspd
double _dSs2cspd -
_iSsndqueue
int _iSsndqueue -
_dSbytes
double _dSbytes -
_yabuff2Write
byte[] _yabuff2Write -
half_duplex
int half_duplex -
congestion
int congestion -
bad_cable
int bad_cable -
mismatch
int mismatch -
mylink
double mylink -
loss
double loss -
estimate
double estimate -
avgrtt
double avgrtt -
spd
double spd -
waitsec
double waitsec -
timesec
double timesec -
rttsec
double rttsec -
order
double order -
rwintime
double rwintime -
sendtime
double sendtime -
cwndtime
double cwndtime -
rwin
double rwin -
swin
double swin -
cwin
double cwin -
aspd
double aspd -
_bIsApplication
boolean _bIsApplication -
sHostName
String sHostName -
hostAddress
InetAddress hostAddress -
_sTestResults
String _sTestResults -
_sMidBoxTestResult
String _sMidBoxTestResult -
_yTests
byte _yTests -
_iC2sSFWResult
int _iC2sSFWResult -
_iS2cSFWResult
int _iS2cSFWResult
-
-
Constructor Details
-
Tcpbw100
public Tcpbw100(boolean useSSL)
-
-
Method Details
-
main
public static void main for invoking as an Application- Parameters:
args
- String array of command line arguments- Throws:
IllegalArgumentException
- on bad hostname
-
mainSupport
bigly- Throws:
IllegalArgumentException
- on bad hostname
-
get_c2sspd
-
get_s2cspd
-
get_CurRwinRcvd
-
get_MaxRwinRcvd
-
get_Ping
-
get_MaxRTT
-
get_loss
-
get_avgrtt
-
get_CurRTO
-
get_SACKsRcvd
-
get_osVer
-
get_pluginVer
-
get_host
-
get_osName
-
get_osArch
-
get_mismatch
-
get_Bad_cable
-
get_congestion
-
get_cwndtime
-
get_AccessTech
-
get_rcvrLimiting
-
get_optimalRcvrBuffer
-
get_clientIP
-
get_natStatus
-
get_DupAcksOut
-
get_DupAcksIn
-
get_TimeStamp
-
get_PcBuffSpdLimit
-
get_jitter
-
get_WaitSec
-
get_errmsg
-
get_diagnosis
-
get_statistics
-
get_status
-
get_instSpeed
-
getUserAgent
Set UserAgent String containing browser details.- Returns:
- String UserAgent details set locally
- See Also:
-
setUserAgent
Set UserAgent String.- Parameters:
paramStrUserAgent
- UserAgent String to be set locally- See Also:
-
getC2sSFWTestResults
public int getC2sSFWTestResults()Get Client->Server fire-wall test results.- Returns:
- integer indicating C->S test results
-
setC2sSFWTestResults
public void setC2sSFWTestResults(int iParamC2SRes) Set Client->Server fire-wall test results.- Parameters:
iParamC2SRes
- integer indicating C->S test results
-
getS2cSFWTestResults
public int getS2cSFWTestResults()Get Server->Client fire-wall test results.- Returns:
- integer indicating C->S test results
-
setS2cSFWTestResults
public void setS2cSFWTestResults(int iParamS2CRes) Set server->Client fire-wall test results.- Parameters:
iParamS2CRes
- integer indicating C->S test results
-
isTestInProgress
public boolean isTestInProgress()I2P -
run_test
public void run_test()"Remote Control" function - invoke NDT' runtest() method from the API -
init
public void init()Initialize the base NDT window Applet init() method -
createDiagnoseWindow
public void createDiagnoseWindow()Create the "More details" window. -
createStatsWindow
public void createStatsWindow()Create the "Statistics" window. -
createOptionsWindow
public void createOptionsWindow()Create the "Options" window. The options displayed to the user are:- Would you like to Perform default tests?
- Would you prefer IPV6?
- Select number of times the test-suite is to be run
-
runtest
public void runtest()Run the Thread that calls the "dottcp" method to run tests. This method is called by the Applet's init method if user selected an "autorun" option, is run individually if user presses the "start button", or, is internally invoked by the API call. -
actionPerformed
Action handler method called when an associated action is performed- Parameters:
paramEventObj
- Event object that prompted the call
-
showStatus
Display current status in Applet window.- Overrides:
showStatus
in classJApplet
- Parameters:
msg
- String value of status
-
getStatus
I2P Translated status, not HTML escaped. -
test_mid
MiddleBox testing is a throughput test from the Server to the Client to check for duplex mismatch conditions. It determines if routers or switches in the path may be making changes to some TCP parameters.- Parameters:
paramProtoObj
- Protocol Object used to exchange messages- Returns:
- boolean value indicating test failure status true if test was not completed false if test was completed
- Throws:
IOException
- when sending/receiving messages from server fails- See Also:
-
test_sfw
Fire-wall tests aiming to find out if one exists between Client and server. Tests are performed in both directions.- Parameters:
protocolObj
- Protocol Object used for message exchange- Returns:
- boolean, true if test was not completed, false if test was completed.
- Throws:
IOException
- when sending/receiving messages from server fails. See the @see methods for more information on causes for Exception.- See Also:
-
test_c2s
Client to server throughput test. This test performs 10 seconds memory-to-memory data transfer to test achievable network bandwidth.- Parameters:
paramProtoObj
- Protocol Object used to exchange messages- Returns:
- boolean, true if test was not completed, false if test was completed.
- Throws:
IOException
- when sending/receiving messages from server fails- See Also:
-
test_s2c
S2C throughput test to measure network bandwidth from server to client.- Parameters:
paramProtoObj
- Protocol Object used to exchange messagesparamSocketObj
- Socket Object to write/read NDTProtocol control messages- Returns:
- boolean, true if test was not completed, false if test was completed.
- Throws:
IOException
- when sending/receiving messages from server fails- See Also:
-
test_meta
The META test allows the Client to send an additional information to the Server that basically gets included along with the overall set of test results.- Parameters:
paramProtoObj
- Protocol Object used to exchange protocol messages- Returns:
- boolean, true if test was completed, false if test is incomplete.
- Throws:
IOException
- when sending/receiving messages from server fails- See Also:
-
dottcp
Method to run tests and interpret the results sent by the server- Parameters:
sPanel
- StatusPanel object to describe status of tests- Throws:
IOException
- when sending/receiving messages from server fails- See Also:
-
testResults
Method that interprets test results. This routine extracts the key-value pairs of results of various categories and assigns these to the correct variables. These values are then interpreted to make decisions about various measurement items and written to the main results, statistics, web100 or mail-to panels.- Parameters:
sTestResParam
- String containing all results
-
middleboxResults
This routine decodes the middlebox test results. The data is returned from the server is a specific order. This routine pulls the string apart and puts the values into the proper variable. It then compares the values to known values and writes out the specific results. server data is ordered as: Server IP; Client IP; CurrentMSS; WinScaleSent; WinScaleRcvd; SumRTT; CountRTT; MaxRwinRcvd; Client then adds Server IP; Client IP.- Parameters:
sMidBoxTestResParam
- String Middlebox results
-
showBufferedBytesInfo
public void showBufferedBytesInfo()Pop up a window to display some information about TCP packet queuing. -
save_dbl_values
Method to save double values of various "keys" from the the test results string into corresponding double datatypes.- Parameters:
sSysvarParam
- key name stringdSysvalParam
- Value for this key name
-
save_long_values
Method to save long values of various "keys" from the the test results string into corresponding long datatypes.- Parameters:
sSysvarParam
- key name stringlSysvalParam
- Value for this key name
-
save_int_values
Method to save integer values of various "keys" from the the test results string into corresponding integer datatypes.- Parameters:
sSysvarParam
- String key nameiSysvalParam
- Value for this key name
-
getParameter
Utility method to get parameter value.- Overrides:
getParameter
in classJApplet
- Parameters:
paramStrName
- Key String whose value has to be found- Returns:
- String Value of key requested for
-
getNDTvar
Function that returns a variable corresponding to the parameter passed to it as a request.- Parameters:
varName
- {String} The parameter which the caller is seeking.- Returns:
- {String} The value of the desired parameter.
-
killIt
public void killIt()bigly -- must have been started with main() or runIt() -
runIt
public void runIt()bigly
-