|
List Info
Thread: Resend: CR-Client: Catching failures in ICT perftest site-selection
|
|
| Resend: CR-Client: Catching failures in
ICT perftest site-selection |

|
2006-11-15 21:14:51 |
The mailing list might not work correctly when I sent this;
I didn't
receive a copy myself. Resending...
--
Daniel Yek
At 10:41 AM 11/13/2006, Daniel Yek wrote:
>Modified by: dyek real.com
>Date: 11/13/2006
>Project: Helix Player
>Bug number: 5500
>
>Synopsis: Catching failures in ICT perftest
site-selection.
>
>Overview:
> This bug only manifests at very low bandwidth --
around 28.8k.
> It happened because failure in the new site-selection
feature
> wasn't being taken cared of -- ICT proceeded to the
second stage
> of downloading and then failed there.
>
> There is a small window where timeout happened after
failed
> site-selection and before the second stage failed and
the assert
> fired.
>
> The fix is to zero out timing entry properly and fail
the ICT if
> no perftest site is working.
>
> Also, disabled progress bar animation that wasn't
working now to speed
> up the UI response.
>
>
>Files Modified:
>player/app/gtk/ict_wget.c - Fixed ICT perftest
site-selection bug.
>player/app/gtk/ict.cpp - Removed an unused variable and
commented out a
>sleep.
>
>
>Platforms and Profiles Affected:
>Linux
>
>Platforms and Profiles Build Verified:
>Profile: helix_client_all_define
>Platform: Fedora Core 5
>
>Platforms and Profiles Functionality verified:
>Profile: helix_client_all_define
>Platform: Fedora Core 5
>
>Branch: HEAD
>
>Copyright assignment: I am a RealNetworks employee.
>
>
>
>Index: ict_wget.c
>========================================================
===========
>RCS file: /cvsroot/player/app/gtk/ict_wget.c,v
>retrieving revision 1.2
>diff -u -w -r1.2 ict_wget.c
>--- ict_wget.c 17 Oct 2006 02:46:50 -0000 1.2
>+++ ict_wget.c 10 Nov 2006 06:07:00 -0000
> -149,7 +149,7 
> , "--dns-timeout=3"
> , "--quiet"
> , "--output-document=/dev/null"
>- , "--output-file=/dev/null" // When
user hit Cancel, wget would
>have log to wget-log[.*]
>+ , "--output-file=/dev/null" // When
user hit Cancel, wget would
>have logged to wget-log[.*]
> , url // URL for wget.
> , NULL
> };
> -163,6 +163,10 
>
> g_timer = g_timer_new();
>
>+#ifdef DEBUG
>+ g_message("Downloading from %s", url);
>+#endif // DEBUG
>+
> // wget http://i
.realone.com/g/pics/perftest/500.gif
> successful = g_spawn_async(
> "/tmp", //
working_directory
> -337,6 +341,10 
> gint result_bandwidth = 0;
> int i;
>
>+#ifdef DEBUG
>+ g_message("Entering
ictw_gtk_handler_for_posix_signal (end
>downloading)!n");
>+#endif // DEBUG
>+
> switch(giocondition)
> {
> case G_IO_IN:
> -451,10 +459,15 
> if (ICTWS_SELECTING_SITE == g_state)
> {
> // One site failed; continue on to try
another.
>+ g_timing[g_files_index] = 0.0; // Don't
mistaken it as
>valid timing.
>+#ifdef DEBUG
>+ g_message("wget timedout!");
>+#endif
> }
> else if (ICTWS_INITIAL == g_state)
> {
> // Warmed up; continue to the actual
operations.
>+ g_timing[g_files_index] = 0.0; // Don't
mistaken it as
>valid timing.
> }
> else
> {
> -496,6 +509,8 
> case ICTWS_SELECTING_SITE:
> // time_elapsed is always saved in
g_timing[g_files_index] for
> all urls! Copy it to the right place.
> g_timing_select_site[g_urls_index] =
g_timing[g_files_index];
>+ g_timing[0] = 0.0; // Keep this as 0.0 for
the case where
>timeout occurs before a site is selected.
>+
> if (g_urls_index ==
>
sizeof(g_timing_select_site)/sizeof(*g_timing_select_site) -
1)
> {
> // We have all sites information to select
one now.
> -507,8 +522,8 
> {
> if (0.0 == g_timing[0]) // The
currently selected site
> isn't working.
> {
>- g_timing[0] =
g_timing_select_site[i];
>- g_urls_index = i;
>+ g_timing[0] =
g_timing_select_site[i]; //
>g_timing[0] is the selected timing.
>+ g_urls_index = i;
//
>g_urls_index corresponds to the selected URL.
> }
> if (g_timing_select_site[i] == 0.0)
continue;
>
> -518,6 +533,14 
> g_timing[0] =
g_timing_select_site[i];
> }
> }
>+ if (0.0 == g_timing[0])
>+ {
>+ g_warning("No working perftest
site found!");
>+ g_state = ICTWS_FAILED;
>+ g_callback_data.callback(-1,
g_callback_data.userdata);
>// Failed
>+ return
ictw_ipc_pipe_cleanup(posix_signal_gtk_io_channel);
>+ }
>+
> g_state = ICTWS_DOWNLOADING_1000;
> ++g_files_index; // 1000.gif
> g_message("Selected perftest site:
%s",
> urls_perftest[g_urls_index]);
>
>
>
>Index: ict.cpp
>========================================================
===========
>RCS file: /cvsroot/player/app/gtk/ict.cpp,v
>retrieving revision 1.3
>diff -u -w -r1.3 ict.cpp
>--- ict.cpp 31 Oct 2006 22:09:48 -0000 1.3
>+++ ict.cpp 13 Nov 2006 18:35:51 -0000
> -175,7 +175,6 
> GtkWindow *ict_window = NULL;
> GtkWidget *ict_window_widget = NULL;
> GtkButton *update_button;
>- GtkLabel *label;
>
> filename =
hxcommon_locate_file("ict.glade");
> xml = glade_xml_new(filename, NULL, NULL);
> -341,7 +340,7 
> while
(ict_timeout_step_progress_bar((gpointer)xml))
> {
> // 500,000 usec.
>- ict_sleep(0, 500000);
>+ //ict_sleep(0, 500000);
> }
> return;
> }
>
>
>
>--
>Daniel Yek
_______________________________________________
Player-dev mailing list
Player-dev helixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/play
er-dev
|
|
| Resend: CR-Client: Catching failures in
ICT perftest site-selection |

|
2006-11-15 21:14:51 |
The mailing list might not work correctly when I sent this;
I didn't
receive a copy myself. Resending...
--
Daniel Yek
At 10:41 AM 11/13/2006, Daniel Yek wrote:
>Modified by: dyek real.com
>Date: 11/13/2006
>Project: Helix Player
>Bug number: 5500
>
>Synopsis: Catching failures in ICT perftest
site-selection.
>
>Overview:
> This bug only manifests at very low bandwidth --
around 28.8k.
> It happened because failure in the new site-selection
feature
> wasn't being taken cared of -- ICT proceeded to the
second stage
> of downloading and then failed there.
>
> There is a small window where timeout happened after
failed
> site-selection and before the second stage failed and
the assert
> fired.
>
> The fix is to zero out timing entry properly and fail
the ICT if
> no perftest site is working.
>
> Also, disabled progress bar animation that wasn't
working now to speed
> up the UI response.
>
>
>Files Modified:
>player/app/gtk/ict_wget.c - Fixed ICT perftest
site-selection bug.
>player/app/gtk/ict.cpp - Removed an unused variable and
commented out a
>sleep.
>
>
>Platforms and Profiles Affected:
>Linux
>
>Platforms and Profiles Build Verified:
>Profile: helix_client_all_define
>Platform: Fedora Core 5
>
>Platforms and Profiles Functionality verified:
>Profile: helix_client_all_define
>Platform: Fedora Core 5
>
>Branch: HEAD
>
>Copyright assignment: I am a RealNetworks employee.
>
>
>
>Index: ict_wget.c
>========================================================
===========
>RCS file: /cvsroot/player/app/gtk/ict_wget.c,v
>retrieving revision 1.2
>diff -u -w -r1.2 ict_wget.c
>--- ict_wget.c 17 Oct 2006 02:46:50 -0000 1.2
>+++ ict_wget.c 10 Nov 2006 06:07:00 -0000
> -149,7 +149,7 
> , "--dns-timeout=3"
> , "--quiet"
> , "--output-document=/dev/null"
>- , "--output-file=/dev/null" // When
user hit Cancel, wget would
>have log to wget-log[.*]
>+ , "--output-file=/dev/null" // When
user hit Cancel, wget would
>have logged to wget-log[.*]
> , url // URL for wget.
> , NULL
> };
> -163,6 +163,10 
>
> g_timer = g_timer_new();
>
>+#ifdef DEBUG
>+ g_message("Downloading from %s", url);
>+#endif // DEBUG
>+
> // wget http://i
.realone.com/g/pics/perftest/500.gif
> successful = g_spawn_async(
> "/tmp", //
working_directory
> -337,6 +341,10 
> gint result_bandwidth = 0;
> int i;
>
>+#ifdef DEBUG
>+ g_message("Entering
ictw_gtk_handler_for_posix_signal (end
>downloading)!n");
>+#endif // DEBUG
>+
> switch(giocondition)
> {
> case G_IO_IN:
> -451,10 +459,15 
> if (ICTWS_SELECTING_SITE == g_state)
> {
> // One site failed; continue on to try
another.
>+ g_timing[g_files_index] = 0.0; // Don't
mistaken it as
>valid timing.
>+#ifdef DEBUG
>+ g_message("wget timedout!");
>+#endif
> }
> else if (ICTWS_INITIAL == g_state)
> {
> // Warmed up; continue to the actual
operations.
>+ g_timing[g_files_index] = 0.0; // Don't
mistaken it as
>valid timing.
> }
> else
> {
> -496,6 +509,8 
> case ICTWS_SELECTING_SITE:
> // time_elapsed is always saved in
g_timing[g_files_index] for
> all urls! Copy it to the right place.
> g_timing_select_site[g_urls_index] =
g_timing[g_files_index];
>+ g_timing[0] = 0.0; // Keep this as 0.0 for
the case where
>timeout occurs before a site is selected.
>+
> if (g_urls_index ==
>
sizeof(g_timing_select_site)/sizeof(*g_timing_select_site) -
1)
> {
> // We have all sites information to select
one now.
> -507,8 +522,8 
> {
> if (0.0 == g_timing[0]) // The
currently selected site
> isn't working.
> {
>- g_timing[0] =
g_timing_select_site[i];
>- g_urls_index = i;
>+ g_timing[0] =
g_timing_select_site[i]; //
>g_timing[0] is the selected timing.
>+ g_urls_index = i;
//
>g_urls_index corresponds to the selected URL.
> }
> if (g_timing_select_site[i] == 0.0)
continue;
>
> -518,6 +533,14 
> g_timing[0] =
g_timing_select_site[i];
> }
> }
>+ if (0.0 == g_timing[0])
>+ {
>+ g_warning("No working perftest
site found!");
>+ g_state = ICTWS_FAILED;
>+ g_callback_data.callback(-1,
g_callback_data.userdata);
>// Failed
>+ return
ictw_ipc_pipe_cleanup(posix_signal_gtk_io_channel);
>+ }
>+
> g_state = ICTWS_DOWNLOADING_1000;
> ++g_files_index; // 1000.gif
> g_message("Selected perftest site:
%s",
> urls_perftest[g_urls_index]);
>
>
>
>Index: ict.cpp
>========================================================
===========
>RCS file: /cvsroot/player/app/gtk/ict.cpp,v
>retrieving revision 1.3
>diff -u -w -r1.3 ict.cpp
>--- ict.cpp 31 Oct 2006 22:09:48 -0000 1.3
>+++ ict.cpp 13 Nov 2006 18:35:51 -0000
> -175,7 +175,6 
> GtkWindow *ict_window = NULL;
> GtkWidget *ict_window_widget = NULL;
> GtkButton *update_button;
>- GtkLabel *label;
>
> filename =
hxcommon_locate_file("ict.glade");
> xml = glade_xml_new(filename, NULL, NULL);
> -341,7 +340,7 
> while
(ict_timeout_step_progress_bar((gpointer)xml))
> {
> // 500,000 usec.
>- ict_sleep(0, 500000);
>+ //ict_sleep(0, 500000);
> }
> return;
> }
>
>
>
>--
>Daniel Yek
_______________________________________________
Player-dev mailing list
Player-dev helixcommunity.org
http://lists.helixcommunity.org/mailman/listinfo/play
er-dev
|
|
[1-2]
|
|