Re: [PATCH 2/2] Don't call reload on corosync-objctl actions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I have to temporary NACK this one, because it needs a cman counter part
for all subsystems.

What problem are we effectively trying to solve here in the first place?

We had to opt for the reload_db option because we needed full
notification for any change happening in the objdb, instead of
installing several trackers.

Fabio

On 11/19/2012 2:34 PM, Jan Friesse wrote:
> confdb reload is used only for reloading of file, not for triggering
> changes.
> 
> Signed-off-by: Jan Friesse <jfriesse@xxxxxxxxxx>
> ---
>  tools/corosync-objctl.c |   15 ---------------
>  1 files changed, 0 insertions(+), 15 deletions(-)
> 
> diff --git a/tools/corosync-objctl.c b/tools/corosync-objctl.c
> index 3e2bd4c..1168efe 100644
> --- a/tools/corosync-objctl.c
> +++ b/tools/corosync-objctl.c
> @@ -244,18 +244,6 @@ static void print_config_tree(confdb_handle_t handle, hdb_handle_t parent_object
>  	}
>  }
>  
> -static cs_error_t reload_db(confdb_handle_t handle)
> -{
> -	char error[1024];
> -	cs_error_t ret;
> -
> -	ret = confdb_reload(handle, 0, error, sizeof(error) - 1);
> -	if (ret != CONFDB_OK) {
> -		fprintf (stderr, "Error reloading DB %d\n", ret);
> -	}
> -	return ret;
> -}
> -
>  static int read_in_config_file (char * filename)
>  {
>  	confdb_handle_t handle;
> @@ -326,7 +314,6 @@ static int read_in_config_file (char * filename)
>  		/* write the attribute */
>  		write_key (handle, line);
>  	}
> -	reload_db(handle);
>  	confdb_finalize (handle);
>  	fclose (fh);
>  	return 0;
> @@ -931,8 +918,6 @@ int main (int argc, char *argv[]) {
>  	if (action == ACTION_TRACK) {
>  		listen_for_object_changes(handle);
>  		stop_tracking(handle);
> -	} else {
> -		reload_db(handle);
>  	}
>  
>  	result = confdb_finalize (handle);
> 

_______________________________________________
discuss mailing list
discuss@xxxxxxxxxxxx
http://lists.corosync.org/mailman/listinfo/discuss


[Index of Archives]     [Linux Clusters]     [Corosync Project]     [Linux USB Devel]     [Linux Audio Users]     [Photo]     [Yosemite News]    [Yosemite Photos]    [Linux Kernel]     [Linux SCSI]     [X.Org]

  Powered by Linux