CERN org.glite.Gfal
2.0.1
|
main internal file of the lfc plugin module More...
#include <errno.h>
#include <stdio.h>
#include <string.h>
#include <time.h>
#include <sys/types.h>
#include <dlfcn.h>
#include <stdlib.h>
#include <pthread.h>
#include <serrno.h>
#include <uuid/uuid.h>
#include <common/gfal_prototypes.h>
#include <common/gfal_types.h>
#include <common/gfal_common_plugin.h>
#include <common/mds/gfal_common_mds.h>
#include <common/gfal_common_interface.h>
#include "lfc_ifce_ng.h"
#include <common/gfal_common_errverbose.h>
Defines | |
#define | _GNU_SOURCE |
#define | GFAL_LFN_MAX_LEN 2048 |
Functions | |
int | _Cthread_addcid (char *, int, char *, int, Cth_pid_t *, unsigned, void *(*)(void *), int) |
int | gfal_lfc_regex_compile (regex_t *rex, GError **err) |
void | gfal_lfc_init_thread (struct lfc_ops *ops) |
int | gfal_lfc_startSession (struct lfc_ops *ops, GError **err) |
void | gfal_auto_maintain_session (struct lfc_ops *ops, GError **err) |
void | lfc_set_session_timeout (int timeout) |
char * | gfal_get_lfchost_envar (GError **err) |
char * | gfal_convert_guid_to_lfn (plugin_handle handle, char *guid, GError **err) |
int | gfal_convert_guid_to_lfn_r (plugin_handle handle, const char *guid, char *buff_lfn, size_t sbuff_lfn, GError **err) |
char * | gfal_setup_lfchost (gfal_handle handle, GError **err) |
struct lfc_ops * | gfal_load_lfc (const char *name, GError **err) |
int | gfal_lfc_convert_statg (struct stat *output, struct lfc_filestatg *input, GError **err) |
int | gfal_lfc_convert_lstat (struct stat *output, struct lfc_filestat *input, GError **err) |
int | gfal_lfc_mkdir_rec (struct lfc_ops *ops, char *browser_path, const char *full_path, mode_t mode, GError **err) |
int | gfal_lfc_ifce_mkdirpG (struct lfc_ops *ops, const char *path, mode_t mode, gboolean pflag, GError **err) |
char ** | gfal_lfc_getSURL (struct lfc_ops *ops, const char *path, GError **err) |
int | gfal_lfc_getComment (struct lfc_ops *ops, const char *lfn, char *buff, size_t s_buff, GError **err) |
int | gfal_lfc_setComment (struct lfc_ops *ops, const char *lfn, const char *buff, size_t s_buff, GError **err) |
int | gfal_lfc_getChecksum (struct lfc_ops *ops, const char *lfn, lfc_checksum *checksum, GError **err) |
int | gfal_lfc_statg (struct lfc_ops *ops, const char *lfn, struct lfc_filestatg *statbuf, GError **err) |
ssize_t | g_strv_catbuff (char **strv, char *buff, size_t size) |
int | gfal_lfc_get_errno (struct lfc_ops *ops) |
char * | gfal_lfc_get_strerror (struct lfc_ops *ops) |
void | gfal_generate_guidG (char *buf, GError **err) |
generate an uiid string Generate a uuid string and cpy it in the buf, | |
int | gfal_lfc_set_host (const char *host, GError **err) |
main internal file of the lfc plugin module
char* gfal_convert_guid_to_lfn | ( | plugin_handle | handle, |
char * | guid, | ||
GError ** | err | ||
) |
convert a guid to a lfn link with a call to the lfclib
handle | handle of the lfc plugin |
string | of the guid |
err | : Error report system |
References gfal_lfc_init_thread().
Referenced by lfc_resolve_guid().
int gfal_convert_guid_to_lfn_r | ( | plugin_handle | handle, |
const char * | guid, | ||
char * | buff_lfn, | ||
size_t | sbuff_lfn, | ||
GError ** | err | ||
) |
convert a guid to a lfn link with a call to the lfclib in a reantrant( buffer mode )
handle | plugin handle |
guid | string of the guid |
buff_lfn | buffer for the lfn result |
sbuff_lfn | size of the buffer |
err | : Error report system |
References gfal_lfc_init_thread().
void gfal_generate_guidG | ( | char * | buf, |
GError ** | err | ||
) |
generate an uiid string Generate a uuid string and cpy it in the buf,
char** gfal_lfc_getSURL | ( | struct lfc_ops * | ops, |
const char * | path, | ||
GError ** | err | ||
) |
return a list of surls from a getreplica request
Referenced by lfc_getSURLG().
int gfal_lfc_ifce_mkdirpG | ( | struct lfc_ops * | ops, |
const char * | path, | ||
mode_t | mode, | ||
gboolean | pflag, | ||
GError ** | err | ||
) |
Implementation of mkdir -p call on the lfc
References gfal_lfc_mkdir_rec().
void gfal_lfc_init_thread | ( | struct lfc_ops * | ops | ) |
Routine for internal lfc hack, need to be call for the thread safety
Referenced by lfc_chmodG(), lfc_accessG(), lfc_renameG(), lfc_symlinkG(), lfc_statG(), lfc_getSURLG(), lfc_getxattrG(), gfal_plugin_init(), gfal_convert_guid_to_lfn(), and gfal_convert_guid_to_lfn_r().
int gfal_lfc_mkdir_rec | ( | struct lfc_ops * | ops, |
char * | browser_path, | ||
const char * | full_path, | ||
mode_t | mode, | ||
GError ** | err | ||
) |
Begin a recursive call on mkdir to create a full tree path
Referenced by gfal_lfc_ifce_mkdirpG().
struct lfc_ops* gfal_load_lfc | ( | const char * | name, |
GError ** | err | ||
) | [read] |
Resolve the lfc symbols, allow mocking load the shared library and link the symbol for the LFC usage
name | : name of the library |
err,: | error report |
Referenced by gfal_plugin_init().
char* gfal_setup_lfchost | ( | gfal_handle | handle, |
GError ** | err | ||
) |
setup the lfc_host correctly for the lfc calls
err | GError report system if |
Referenced by gfal_plugin_init().