2005-01-20 23:22:22 +00:00
// Berkeley Open Infrastructure for Network Computing
// http://boinc.berkeley.edu
// Copyright (C) 2005 University of California
2003-08-15 22:39:56 +00:00
//
2005-01-20 23:22:22 +00:00
// This is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation;
// either version 2.1 of the License, or (at your option) any later version.
2003-08-15 22:39:56 +00:00
//
2005-01-20 23:22:22 +00:00
// This software is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
// See the GNU Lesser General Public License for more details.
2002-12-03 18:57:40 +00:00
//
2005-01-20 23:22:22 +00:00
// To view the GNU Lesser General Public License visit
// http://www.gnu.org/copyleft/lesser.html
// or write to the Free Software Foundation, Inc.,
// 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
2002-12-03 18:57:40 +00:00
2003-09-02 21:16:55 +00:00
# ifndef _SCHED_CONFIG_
# define _SCHED_CONFIG_
2002-10-04 20:35:56 +00:00
2002-12-03 18:57:40 +00:00
// parsed version of server configuration file
2002-10-03 18:33:46 +00:00
//
2003-09-02 21:16:55 +00:00
class SCHED_CONFIG {
2002-10-03 18:33:46 +00:00
public :
2006-03-07 21:46:49 +00:00
char master_url [ 256 ] ;
2004-05-02 15:55:17 +00:00
char long_name [ 256 ] ;
2002-10-03 18:33:46 +00:00
char db_name [ 256 ] ;
2004-01-15 23:53:13 +00:00
char db_user [ 256 ] ;
2002-10-03 18:33:46 +00:00
char db_passwd [ 256 ] ;
2003-12-11 19:05:52 +00:00
char db_host [ 256 ] ;
2002-10-03 18:33:46 +00:00
int shmem_key ;
char key_dir [ 256 ] ;
2002-10-14 23:10:12 +00:00
char download_url [ 256 ] ;
2002-12-17 19:00:43 +00:00
char download_dir [ 256 ] ;
2004-08-06 11:42:41 +00:00
char download_dir_alt [ 256 ] ;
// old download dir, assumed to be flat
// (file deleter looks here if not in main dir)
2002-10-14 23:10:12 +00:00
char upload_url [ 256 ] ;
2002-10-03 18:33:46 +00:00
char upload_dir [ 256 ] ;
2005-05-24 04:32:36 +00:00
char sched_lockfile_dir [ 256 ] ;
2007-04-05 17:02:01 +00:00
int grace_period_hours ;
int delete_delay_hours ;
2003-10-16 19:03:49 +00:00
bool one_result_per_user_per_wu ;
2007-03-11 03:15:17 +00:00
bool one_result_per_host_per_wu ;
2004-06-24 21:00:13 +00:00
bool msg_to_host ;
2003-12-31 23:09:21 +00:00
int min_sendwork_interval ;
2004-02-03 21:48:49 +00:00
int max_wus_to_send ;
2004-04-14 23:32:17 +00:00
bool non_cpu_intensive ;
2006-06-20 17:36:28 +00:00
bool verify_files_on_app_start ;
2004-05-18 18:33:01 +00:00
bool homogeneous_redundancy ;
2004-09-10 21:02:11 +00:00
bool locality_scheduling ;
2007-04-16 22:22:15 +00:00
bool locality_scheduling_sorted_order ;
2004-06-07 03:34:07 +00:00
bool ignore_upload_certificates ;
2004-09-24 21:28:12 +00:00
bool dont_generate_upload_certificates ;
2005-02-14 04:39:07 +00:00
bool ignore_delay_bound ;
2004-05-27 18:13:00 +00:00
int daily_result_quota ; // max results per host per day
2004-08-05 11:35:09 +00:00
int uldl_dir_fanout ; // fanout of ul/dl dirs; 0 if none
2005-11-21 18:34:44 +00:00
int uldl_dir_levels ;
2005-01-09 06:38:42 +00:00
int locality_scheduling_wait_period ;
2005-01-12 00:50:32 +00:00
int locality_scheduling_send_timeout ;
2005-01-19 05:34:18 +00:00
int min_core_client_version ;
2005-02-09 04:38:19 +00:00
int min_core_client_version_announced ;
int min_core_client_upgrade_deadline ;
2005-02-02 18:13:00 +00:00
bool choose_download_url_by_timezone ;
2005-02-02 21:57:11 +00:00
bool cache_md5_info ;
2005-03-13 20:10:03 +00:00
bool nowork_skip ;
2005-07-28 09:29:12 +00:00
bool resend_lost_results ;
2007-04-05 17:02:01 +00:00
bool send_result_abort ;
2005-11-01 04:19:10 +00:00
bool use_benchmark_weights ;
double fp_benchmark_weight ;
2005-12-17 04:53:48 +00:00
double default_disk_max_used_gb ;
double default_disk_max_used_pct ;
double default_disk_min_free_gb ;
2006-05-22 09:54:31 +00:00
char symstore [ 256 ] ;
2006-05-25 18:51:57 +00:00
double next_rpc_delay ;
2006-06-07 04:10:04 +00:00
int sched_debug_level ;
int fuh_debug_level ;
2006-10-22 00:42:44 +00:00
int reliable_time ; // age of workunit before requiring reliable
2007-04-05 17:02:01 +00:00
int reliable_min_avg_credit ; // min average credit for a host to be declared reliable
int reliable_max_avg_turnaround ; // max average turnaround for a host to be declared reliable
int reliable_priority_on_over ; // additional results generated after at least one result is over will have their priority boosted by this amount
int reliable_priority_on_over_except_error ; // additional results generated after at least one result is over (unless their is an error) will have their priority boosted by this amount
int reliable_on_priority ; // results with a priority equal or greater than this value will be sent to reliable hosts
double reliable_reduced_delay_bound ; // Reduce the delay bounds for reliable hosts by this percent
2002-10-03 18:33:46 +00:00
2006-05-25 05:22:10 +00:00
int parse ( FILE * ) ;
2005-02-16 23:17:43 +00:00
int parse_file ( const char * dir = " . " ) ;
2007-04-18 20:49:58 +00:00
2007-04-19 22:11:25 +00:00
int upload_path ( const char * , char * ) ;
int download_path ( const char * , char * ) ;
2002-10-03 18:33:46 +00:00
} ;
2002-10-04 20:35:56 +00:00
2004-04-04 02:59:42 +00:00
// get the project's home directory
// (assumed to be the parent of the CWD)
//
void get_project_dir ( char * , int ) ;
2002-10-04 20:35:56 +00:00
# endif