Changes between Version 2 and Version 3 of PrefsImpl


Ignore:
Timestamp:
Oct 18, 2007, 10:13:26 AM (17 years ago)
Author:
Didactylos
Comment:

Major updates

Legend:

Unmodified
Added
Removed
Modified
  • PrefsImpl

    v2 v3  
    55General preferences are represented by an XML element of the form:
    66{{{
     7#!xml
    78<global_preferences>
    8     <source_project>http://setiathome.berkeley.edu/</source_project>
    9     <source_scheduler>http://setiboinc.ssl.berkeley.edu/sah_cgi/cgi</source_scheduler>
    10     <mod_time>1140215730</mod_time>
     9    <source_project>%s</source_project>
     10    <source_scheduler>%s</source_scheduler>
     11    <mod_time>%d</mod_time>
     12    <run_on_batteries/>
    1113    <run_if_user_active/>
    12     <idle_time_to_run>3</idle_time_to_run>
    13     <cpu_scheduling_period_minutes>60</cpu_scheduling_period_minutes>
     14    <suspend_if_no_recent_input>%f</suspend_if_no_recent_input>
     15    <start_hour>%f</start_hour>
     16    <end_hour>%f</end_hour>
     17    <net_start_hour>%f</net_start_hour>
     18    <net_end_hour>%f</net_end_hour>
     19    <leave_apps_in_memory/>
     20    <confirm_before_connecting/>
    1421    <hangup_if_dialed/>
    15     <work_buf_min_days>0.1</work_buf_min_days>
    16     <max_cpus>2</max_cpus>
    17     <disk_interval>60</disk_interval>
    18     <disk_max_used_gb>100</disk_max_used_gb>
    19     <disk_max_used_pct>50</disk_max_used_pct>
    20     <disk_min_free_gb>0.1</disk_min_free_gb>
    21     <vm_max_used_pct>75</vm_max_used_pct>
    22     <max_bytes_sec_down>0</max_bytes_sec_down>
    23     <max_bytes_sec_up>0</max_bytes_sec_up>
    24     <venue name="home">
    25         <idle_time_to_run>3</idle_time_to_run>
    26         <cpu_scheduling_period_minutes>60</cpu_scheduling_period_minutes>
    27         <hangup_if_dialed/>
    28         <work_buf_min_days>0.1</work_buf_min_days>
    29         <max_cpus>2</max_cpus>
    30         <disk_interval>60</disk_interval>
    31         <disk_max_used_gb>100</disk_max_used_gb>
    32         <disk_max_used_pct>50</disk_max_used_pct>
    33         <disk_min_free_gb>0.001</disk_min_free_gb>
    34         <vm_max_used_pct>75</vm_max_used_pct>
    35         <max_bytes_sec_down>0</max_bytes_sec_down>
    36         <max_bytes_sec_up>0</max_bytes_sec_up>
     22    <dont_verify_images/>
     23    <work_buf_min_days>%f</work_buf_min_days>
     24    <work_buf_additional_days>%f</work_buf_additional_days>
     25    <max_cpus>%d</max_cpus>
     26    <cpu_scheduling_period_minutes>%f</cpu_scheduling_period_minutes>
     27    <disk_interval>%f</disk_interval>
     28    <disk_max_used_gb>%f</disk_max_used_gb>
     29    <disk_max_used_pct>%f</disk_max_used_pct>
     30    <disk_min_free_gb>%f</disk_min_free_gb>
     31    <vm_max_used_pct>%f</vm_max_used_pct>
     32    <ram_max_used_busy_pct>%f</ram_max_used_busy_pct>
     33    <ram_max_used_idle_pct>%f</ram_max_used_idle_pct>
     34    <idle_time_to_run>%f</idle_time_to_run>
     35    <max_bytes_sec_up>%f</max_bytes_sec_up>
     36    <max_bytes_sec_down>%f</max_bytes_sec_down>
     37    <cpu_usage_limit>%f</cpu_usage_limit>
     38    <day_prefs>                 
     39        <day_of_week>%d</day_of_week>
     40        <start_hour>%.02f</start_hour>
     41        <end_hour>%.02f</end_hour>
     42        <net_start_hour>%.02f</net_start_hour>
     43        <net_end_hour>%.02f</net_end_hour>
     44    </day_prefs>
     45    <venue name="%s">
     46        [...]
    3747    </venue>
    3848</global_preferences>
    3949}}}
    40 
    41 The first set of preferences are the default; each set of venue-specific preferences is enclosed in a <venue> element. The optional <source_project> and <source_scheduler> elements indicate the source of the preferences.  On the client, the global prefs are stored in global_prefs.xml (present only if they've been obtained from a server).
     50The first set of preferences are the default; each set of venue-specific preferences is enclosed in a <venue> element. The optional <source_project> and <source_scheduler> elements indicate the source of the preferences.  On the client, the global prefs are stored in global_prefs.xml (present only if they've been obtained from a server). <day_prefs> appears once for each day with customised times.
    4251
    4352A scheduler RPC request includes global_prefs.xml if it's present. If the request includes global prefs, the scheduler installs them in the DB if the DB copy is missing or older. If the DB copy is newer, it includes it in the reply. If the request has no prefs and they're present in the DB, they're included in the reply.
     
    4958Project preferences are represented by an XML element of the form:
    5059{{{
     60#!xml
    5161<project_preferences>
    52     <resource_share>50</resource_share>
     62    <resource_share>%d</resource_share>
    5363    <project_specific>
    54         <format_preset>Custom</format_preset>
    55         <text_style>Pillars</text_style>
    56         <graph_style>Rectangles</graph_style>
    57         <max_fps>30</max_fps>
    58         <max_cpu>50</max_cpu>
    59         <grow_time>10</grow_time>
    60         <hold_time>5</hold_time>
    61         <graph_alpha>0.7</graph_alpha>
    62         <roll_period>10</roll_period>
    63         <roll_range>20</roll_range>
    64         <pitch_period>30</pitch_period>
    65         <pitch_range>30</pitch_range>
    66         <starfield_size>2000</starfield_size>
    67         <starfield_speed>40</starfield_speed>
    68         <color_preset>Rainbow</color_preset>
    69         <start_hue>0</start_hue>
    70         <hue_change>1</hue_change>
    71         <app_file>
    72             <timestamp>1095011196</timestamp>
    73             <open_name>background</open_name>
    74             <url>http://setiweb.ssl.berkeley.edu/~davea/yosemite_08_04/800/P1010008.jpg</url>
    75         </app_file>
     64        [...]
    7665    </project_specific>
    77     <venue name="school">
    78         <resource_share>100</resource_share>
     66    <allow_beta_work>%d</allow_beta_work>
     67    <allow_non_preferred_projects>%d</allow_non_preferred_projects>
     68    <apps_selected>
     69        <app_id>%d</app_id>
     70    </apps_selected>
     71    <venue name="%s">
     72        <resource_share>%d</resource_share>
    7973        <project_specific>
    80             <format_preset>SETI@home classic</format_preset>
    81             <text_style>Pillars</text_style>
    82             <graph_style>Rectangles</graph_style>
    83             <max_fps>30</max_fps>
    84             <max_cpu>50</max_cpu>
    85             <grow_time>10</grow_time>
    86             <hold_time>5</hold_time>
    87             <graph_alpha>0.7</graph_alpha>
    88             <roll_period>10</roll_period>
    89             <roll_range>20</roll_range>
    90             <pitch_period>30</pitch_period>
    91             <pitch_range>30</pitch_range>
    92             <starfield_size>2000</starfield_size>
    93             <starfield_speed>40</starfield_speed>
    94             <color_preset>Rainbow</color_preset>
    95             <start_hue>0</start_hue>
    96             <hue_change>1</hue_change>
     74            [...]
    9775        </project_specific>
     76        <allow_beta_work>%d</allow_beta_work>
     77        <allow_non_preferred_projects>%d</allow_non_preferred_projects>
     78        <apps_selected>
     79            <app_id>%d</app_id>
     80        </apps_selected>
    9881    </venue>
    9982</project_preferences>