BurstFS_Server/burstfs_cmd_handler.c
int burstfs_broadcast_exit(int sock_id) {
	int exit_cmd = XFER_COMM_EXIT, rc = ULFS_SUCCESS;
	int i;
	for (i = 0; i < glb_size; i++) {
		MPI_Send(&exit_cmd, sizeof(int), MPI_CHAR,\
				i,\
					CLI_DATA_TAG, MPI_COMM_WORLD);
	}

	int cmd = COMM_UNMOUNT;

	char *ptr_ack = sock_get_ack_buf(sock_id);
	int ret_sz = pack_ack_msg(ptr_ack, cmd, rc, NULL, 0);
	rc = sock_ack_cli(sock_id, ret_sz);
	return rc;
}
/**
* broad cast the exit command to all other
* delegators in the job
* @return success/error code
*/
broad cast the exit command to all other
delegators in the job
broad cast the exit command to all other delegators in the job
int burstfs_broadcast_exit(int sock_id) {
	int exit_cmd = XFER_COMM_EXIT, rc = ULFS_SUCCESS;
	int i;
	for (i = 0; i < glb_size; i++) {
		MPI_Send(&exit_cmd, sizeof(int), MPI_CHAR,\
				i,\
					CLI_DATA_TAG, MPI_COMM_WORLD);
	}
	int cmd = COMM_UNMOUNT;
	char *ptr_ack = sock_get_ack_buf(sock_id);
	int ret_sz = pack_ack_msg(ptr_ack, cmd, rc, NULL, 0);
	rc = sock_ack_cli(sock_id, ret_sz);
	return rc;
}
int burstfs_broadcast_exit ( int sock_id ) { int exit_cmd = XFER_COMM_EXIT , rc = ULFS_SUCCESS ; int i ; for ( i = 0 ; i < glb_size ; i ++ ) { MPI_Send ( & exit_cmd , sizeof ( int ) , MPI_CHAR , i , CLI_DATA_TAG , MPI_COMM_WORLD ) ; } int cmd = COMM_UNMOUNT ; char * ptr_ack = sock_get_ack_buf ( sock_id ) ; int ret_sz = pack_ack_msg ( ptr_ack , cmd , rc , NULL , 0 ) ; rc = sock_ack_cli ( sock_id , ret_sz ) ; return rc ; }
broad cast the exit command to all other
delegators in the job
broad cast the exit command to all other delegators in the job