You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openmeetings.apache.org by Maxim Solodovnik <so...@gmail.com> on 2012/06/03 19:44:22 UTC

Re: svn commit: r1345719 [1/3] - in /incubator/openmeetings/trunk/singlewebapp/WebContent: swf10/networkTesting/ swf10/networkTesting/tests/ testingToolsFiles/

-        var hostUrl = "http://" + host + ":" + port + "/" + loadFileName;
+        var hostUrl = "http://" + host + ":" + port +
"/openmeetings/testingToolsFiles/" + loadFileName;

is not very good, since openmeetings context can be renamed.



On Mon, Jun 4, 2012 at 12:41 AM, <gg...@apache.org> wrote:

> Author: ggrekhov
> Date: Sun Jun  3 17:41:25 2012
> New Revision: 1345719
>
> URL: http://svn.apache.org/viewvc?rev=1345719&view=rev
> Log:
> NetworkTesting: add download speed test
>
> Added:
>
>  incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx
>
>  incubator/openmeetings/trunk/singlewebapp/WebContent/testingToolsFiles/downloadTest
>
>  incubator/openmeetings/trunk/singlewebapp/WebContent/testingToolsFiles/jitterTest
> Modified:
>
>  incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx
>
>  incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx
>
>  incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx
>
> Modified:
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx
> URL:
> http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx?rev=1345719&r1=1345718&r2=1345719&view=diff
>
> ==============================================================================
> ---
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx
> (original)
> +++
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx
> Sun Jun  3 17:41:25 2012
> @@ -29,11 +29,13 @@
>     <PingTest name="pingTest" host="${parent.host}"
> port="${parent.httpPort}" />
>     <PortAvailabilityTest name="portTest" host="${parent.host}"
> port="${parent.rtmpPort}" />
>     <JitterTest name="jitterTest" host="${parent.host}"
> port="${parent.httpPort}" />
> +    <DownloadSpeedTest name="downloadTest" host="${parent.host}"
> port="${parent.httpPort}" />
>
>     <handler name="oninit">
>         canvas.pingTest.start();
>         canvas.jitterTest.start();
>         canvas.portTest.start();
> +        canvas.downloadTest.start();
>     </handler>
>
>  </canvas>
>
> Modified:
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx
> URL:
> http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx?rev=1345719&r1=1345718&r2=1345719&view=diff
>
> ==============================================================================
> ---
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx
> (original)
> +++
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx
> Sun Jun  3 17:41:25 2012
> @@ -48,7 +48,7 @@
>
>
>     <method name="start">
> -        var hostUrl = "http://" + host + ":" + port + "/" + loadFileName;
> +        var hostUrl = "http://" + host + ":" + port +
> "/openmeetings/testingToolsFiles/" + loadFileName;
>         request = new URLRequest(hostUrl);
>
>         loader = new URLLoader();
> @@ -111,11 +111,11 @@
>     </method>
>
>     <method name="report">
> -        var report;
> +        var report = testName + " report:";
>         if (successfulTestsCount > 0) {
> -            report = testName + " report:\n" + this.generateReport();
> +            report += "\n" + this.generateReport();
>         } else {
> -            report = "Ping test: connection error";
> +            report += " connection error";
>         }
>
>         if($debug) Debug.write(report);
>
> Added:
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx
> URL:
> http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx?rev=1345719&view=auto
>
> ==============================================================================
> ---
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx
> (added)
> +++
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx
> Sun Jun  3 17:41:25 2012
> @@ -0,0 +1,46 @@
> +<?xml version="1.0" encoding="UTF-8" ?>
> +<!--
> +  Licensed to the Apache Software Foundation (ASF) under one
> +  or more contributor license agreements.  See the NOTICE file
> +  distributed with this work for additional information
> +  regarding copyright ownership.  The ASF licenses this file
> +  to you under the Apache License, Version 2.0 (the
> +  "License"); you may not use this file except in compliance
> +  with the License.  You may obtain a copy of the License at
> +
> +      http://www.apache.org/licenses/LICENSE-2.0
> +
> +  Unless required by applicable law or agreed to in writing,
> +  software distributed under the License is distributed on an
> +  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
> +  KIND, either express or implied.  See the License for the
> +  specific language governing permissions and limitations
> +  under the License.
> +
> +-->
> +<library>
> +
> +<class name="DownloadSpeedTest" extends="BaseURLLoadTest">
> +
> +    <handler name="oninit">
> +        this.setAttribute("testsCount", 1);
> +        this.setAttribute("testName", "Download speed test");
> +        this.setAttribute("loadFileName", "downloadTest");
> +        this.setAttribute("verbose", false);
> +    </handler>
> +
> +    <method name="generateReport">
> +        var mBytes = loader.bytesTotal/(1024*1024);
> +        var timeSec = wholeTime/1000;
> +        var speed = mBytes/timeSec;
> +
> +        var report = "Bytes loaded: " + mBytes + " Mb\n";
> +        report += "Download time: " + timeSec + " s\n";
> +        report += "Download speed: " + speed + " Mb/s\n";
> +
> +        return report;
> +    </method>
> +
> +</class>
> +
> +</library>
>
> Modified:
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx
> URL:
> http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx?rev=1345719&r1=1345718&r2=1345719&view=diff
>
> ==============================================================================
> ---
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx
> (original)
> +++
> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx
> Sun Jun  3 17:41:25 2012
> @@ -21,6 +21,7 @@
>  <library>
>
>     <include href="BaseURLLoadTest.lzx" />
> +    <include href="DownloadSpeedTest.lzx" />
>     <include href="JitterTest.lzx" />
>     <include href="NetworkTest.lzx" />
>     <include href="PingTest.lzx" />
>
>
>


-- 
WBR
Maxim aka solomax

Re: svn commit: r1345719 [1/3] - in /incubator/openmeetings/trunk/singlewebapp/WebContent: swf10/networkTesting/ swf10/networkTesting/tests/ testingToolsFiles/

Posted by German Grekhov <gg...@unipro.ru>.
Max, I know it. All "magic numbers" will be replaced when all test
prototypes are ready.

German.

> -        var hostUrl = "http://" + host + ":" + port + "/" + loadFileName;
> +        var hostUrl = "http://" + host + ":" + port +
> "/openmeetings/testingToolsFiles/" + loadFileName;
>
> is not very good, since openmeetings context can be renamed.
>
>
>
> On Mon, Jun 4, 2012 at 12:41 AM, <gg...@apache.org> wrote:
>
>> Author: ggrekhov
>> Date: Sun Jun  3 17:41:25 2012
>> New Revision: 1345719
>>
>> URL: http://svn.apache.org/viewvc?rev=1345719&view=rev
>> Log:
>> NetworkTesting: add download speed test
>>
>> Added:
>>
>>  incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx
>>
>>  incubator/openmeetings/trunk/singlewebapp/WebContent/testingToolsFiles/downloadTest
>>
>>  incubator/openmeetings/trunk/singlewebapp/WebContent/testingToolsFiles/jitterTest
>> Modified:
>>
>>  incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx
>>
>>  incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx
>>
>>  incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx
>>
>> Modified:
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx
>> URL:
>> http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx?rev=1345719&r1=1345718&r2=1345719&view=diff
>>
>> ==============================================================================
>> ---
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx
>> (original)
>> +++
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/networktesting.lzx
>> Sun Jun  3 17:41:25 2012
>> @@ -29,11 +29,13 @@
>>     <PingTest name="pingTest" host="${parent.host}"
>> port="${parent.httpPort}" />
>>     <PortAvailabilityTest name="portTest" host="${parent.host}"
>> port="${parent.rtmpPort}" />
>>     <JitterTest name="jitterTest" host="${parent.host}"
>> port="${parent.httpPort}" />
>> +    <DownloadSpeedTest name="downloadTest" host="${parent.host}"
>> port="${parent.httpPort}" />
>>
>>     <handler name="oninit">
>>         canvas.pingTest.start();
>>         canvas.jitterTest.start();
>>         canvas.portTest.start();
>> +        canvas.downloadTest.start();
>>     </handler>
>>
>>  </canvas>
>>
>> Modified:
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx
>> URL:
>> http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx?rev=1345719&r1=1345718&r2=1345719&view=diff
>>
>> ==============================================================================
>> ---
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx
>> (original)
>> +++
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/BaseURLLoadTest.lzx
>> Sun Jun  3 17:41:25 2012
>> @@ -48,7 +48,7 @@
>>
>>
>>     <method name="start">
>> -        var hostUrl = "http://" + host + ":" + port + "/" +
>> loadFileName;
>> +        var hostUrl = "http://" + host + ":" + port +
>> "/openmeetings/testingToolsFiles/" + loadFileName;
>>         request = new URLRequest(hostUrl);
>>
>>         loader = new URLLoader();
>> @@ -111,11 +111,11 @@
>>     </method>
>>
>>     <method name="report">
>> -        var report;
>> +        var report = testName + " report:";
>>         if (successfulTestsCount > 0) {
>> -            report = testName + " report:\n" + this.generateReport();
>> +            report += "\n" + this.generateReport();
>>         } else {
>> -            report = "Ping test: connection error";
>> +            report += " connection error";
>>         }
>>
>>         if($debug) Debug.write(report);
>>
>> Added:
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx
>> URL:
>> http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx?rev=1345719&view=auto
>>
>> ==============================================================================
>> ---
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx
>> (added)
>> +++
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/DownloadSpeedTest.lzx
>> Sun Jun  3 17:41:25 2012
>> @@ -0,0 +1,46 @@
>> +<?xml version="1.0" encoding="UTF-8" ?>
>> +<!--
>> +  Licensed to the Apache Software Foundation (ASF) under one
>> +  or more contributor license agreements.  See the NOTICE file
>> +  distributed with this work for additional information
>> +  regarding copyright ownership.  The ASF licenses this file
>> +  to you under the Apache License, Version 2.0 (the
>> +  "License"); you may not use this file except in compliance
>> +  with the License.  You may obtain a copy of the License at
>> +
>> +      http://www.apache.org/licenses/LICENSE-2.0
>> +
>> +  Unless required by applicable law or agreed to in writing,
>> +  software distributed under the License is distributed on an
>> +  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
>> +  KIND, either express or implied.  See the License for the
>> +  specific language governing permissions and limitations
>> +  under the License.
>> +
>> +-->
>> +<library>
>> +
>> +<class name="DownloadSpeedTest" extends="BaseURLLoadTest">
>> +
>> +    <handler name="oninit">
>> +        this.setAttribute("testsCount", 1);
>> +        this.setAttribute("testName", "Download speed test");
>> +        this.setAttribute("loadFileName", "downloadTest");
>> +        this.setAttribute("verbose", false);
>> +    </handler>
>> +
>> +    <method name="generateReport">
>> +        var mBytes = loader.bytesTotal/(1024*1024);
>> +        var timeSec = wholeTime/1000;
>> +        var speed = mBytes/timeSec;
>> +
>> +        var report = "Bytes loaded: " + mBytes + " Mb\n";
>> +        report += "Download time: " + timeSec + " s\n";
>> +        report += "Download speed: " + speed + " Mb/s\n";
>> +
>> +        return report;
>> +    </method>
>> +
>> +</class>
>> +
>> +</library>
>>
>> Modified:
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx
>> URL:
>> http://svn.apache.org/viewvc/incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx?rev=1345719&r1=1345718&r2=1345719&view=diff
>>
>> ==============================================================================
>> ---
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx
>> (original)
>> +++
>> incubator/openmeetings/trunk/singlewebapp/WebContent/swf10/networkTesting/tests/library.lzx
>> Sun Jun  3 17:41:25 2012
>> @@ -21,6 +21,7 @@
>>  <library>
>>
>>     <include href="BaseURLLoadTest.lzx" />
>> +    <include href="DownloadSpeedTest.lzx" />
>>     <include href="JitterTest.lzx" />
>>     <include href="NetworkTest.lzx" />
>>     <include href="PingTest.lzx" />
>>
>>
>>
>
>
> --
> WBR
> Maxim aka solomax
>