150 likes | 224 Views
OGCE Building and Testing on NMI. Slides by: Rishi Verma. Configuring OGCE for NMI. Design of NMI tests: Used three NMI build scripts representing 28 platforms Each script downloads OGCE portal via svn Scripts use Maven to build portal for each platform
E N D
OGCE Building and Testing on NMI Slides by: Rishi Verma
Configuring OGCE for NMI • Design of NMI tests: • Used three NMI build scripts representing 28 platforms • Each script downloads OGCE portal via svn • Scripts use Maven to build portal for each platform • Following each build, scripts run Apache JMeter runtime checks against each platform's recently built portal
Configuring OGCE for NMI • Example NMI submit file script (Linux) project = OGCE component = Trunk Build component_version = 1.0.0 description = Automated test of OGCE build/runtime execution run_type = build inputs = ogcePortal.svn, buildOGCEPortal-nonmac.scp, OGCEJMeterTestFile.scp, OGCEJMeterResults.scp, jakarta-jmeter-2.scp, maven.scp remote_task = buildOGCEPortal-nonmac.sh remote_task_args = "" platforms = x86_64_fc_4, x86_64_fc_5, x86_64_rhap_5, x86_64_rhas_3, x86_64_rhas_4, x86_64_sles_8, x86_cent_4.2, x86_deb_3.1, x86_deb_4.0, x86_fc_2, x86_fc_3, x86_fc_4, x86_fc_5, x86_rh_7.2, x86_rh_8.0, x86_rh_9, x86_rhap_5, x86_rhas_3, x86_rhas_4, x86_slc_3, x86_sles_8, x86_sles_9, x86_slf_3, x86_suse_10.0, x86_suse_10.2, x86_ubuntu_5.10 prereqs = java-1.5.0_08 notify = riverma@indiana.edu remote_task_timeout = 120m
Configuring OGCE for NMI • Example NMI submit file script (OSX on x86) project = OGCE component = Trunk Build component_version = 1.0.0 description = Automated test of OGCE build/runtime execution run_type = build inputs = ogcePortal.svn, buildOGCEPortal-mac-x86.scp, tarResultsOGCEPortal-mac-x86.scp, OGCEJMeterTestFile.scp, jakarta-jmeter-2.scp remote_task = buildOGCEPortal-mac-x86.sh remote_task_args = "" platforms = x86_macos_10.4 prereqs = java-1.5.0_06 notify = riverma@indiana.edu remote_task_timeout = 120m
Configuring OGCE for NMI • Example NMI submit file script (OSX on ppc) project = OGCE component = Trunk Build component_version = 1.0.0 description = Automated test of OGCE build/runtime execution run_type = build inputs = ogcePortal.svn, buildOGCEPortal-mac-ppc.scp, tarResultsOGCEPortal-mac-ppc.scp, OGCEJMeterTestFile.scp, OGCEJMeterResults.scp, jakarta-jmeter-2.scp remote_task = buildOGCEPortal-mac-ppc.sh remote_task_args = "" platforms = ppc_macos_10.4 prereqs = java-1.5.0_05 notify = riverma@indiana.edu remote_task_timeout = 120m
Configuring OGCE for NMI Practical lessons: 1. Need to modify your build script for some platforms • JDK versions were different between Linux platforms, Macintosh x86, and Macintosh ppc platforms respectively • Made it necessary to use three different NMI scripts • Maven program had to be copied separately for Linux platforms because of NMI incompatibilities with OGCE’s bundled maven
Configuring OGCE for NMI Practical lessons continued.. 2. Environment variables need to be specifically assigned • $JAVA_HOME needed to be set and added to path • $HOME directory needed to be set to current NMI build directory because OGCE portal requires knowledge of $HOME 3. Keep trying to build even if project fails the first time • OGCE svn download would occasionally fail, so we had each script try 'rebuilding' the portal up to three times every night
Configuring OGCE for NMI Practical lessons continued.. 4. Have your script "sleep" if runtime programs aren't loading • Apache Tomcat server would often fail to start • Issuing a "sleep 20" command gave Tomcat enough time to load
Current state of OGCE NMI tests • Builds • Occur nightly • 26 Linux platforms, 2 Macintosh platforms • Notifications sent via email, NMI dashboard • Run-time assertion tests of portal • Tests run via console mode of Apache JMeter • Still being implemented into OGCE NMI nightly build scheme • We are still working on programmatic way to combine all platforms' test information into single document for simple viewing
Analysis of OGCE NMI build tests • Linux platforms • Average build time per platform = 52.19 minutes • Average total time w/ queue wait (all platforms) = 223.2 minutes • Macintosh OSX 10.4 (PPC) • Average build time = 10.3 minutes • Average total time (including queue) = 25.29 minutes • Macintosh OSX 10.4 (x86) • Average build time = 6.2 minutes • Average total time (including queue) = 96.5 minutes
Runtime testing: Apache JMeter • Apache JMeter • Webpage load-testing and performance analysis software • Assertion testing feature particularly useful for OGCE testing • Status on NMI testbed • JMeter not provided by NMI, so we have scripts copy and install JMeter during each nightly build • After each platform's nightly build finishes, Tomcat server is started and then JMeter tests are run • JMeter takes XML test-plan file, and outputs results of tests into another XML file
Runtime testing: Apache JMeter • What kind of runtime tests? • Testing of “logging into portal” • Testing of “obtaining MyProxy certificates” • Testing each "portlet" of OGCE portal • Automatic clicking of all web-links • Performing all theoretical user-actions • Submitting files, downloading, submitting jobs • Testing of “logging out of portal”
Runtime testing: Apache JMeter • How we set-up runtime tests on NMI • Copy Apache JMeter by using ".scp" file method = scp scp_file=/home/<username>/JMeter.tar.gz • Run JMeter within script • jmeter -n -t <JMeter Test File>.jmx -l <JMeter output file> • "-n" specifies non-gui mode • "-t" specifies name of a JMeter test plan file • "-l" specifies name of output file • Collect JMeter output file • Have script store JMeter output file in a "results.tar.gz" file (NMI standard technique)
Runtime testing: Apache JMeter • Current state of testing • XML-based results can be graphically interpreted via XSLT programming • Not yet fully implemented for all platforms
Runtime testing: Apache JMeter • Graphical interpretation of results (XML output)