3a88c02326aadbb1df3436cd519f7b8a4df6ae5b chmalee Thu Jun 6 15:32:15 2024 -0700 Work in progress using the mysql table for hubSpace on client side diff --git src/hg/inc/userdata.h src/hg/inc/userdata.h index e0d7c89..b8a6e54 100644 --- src/hg/inc/userdata.h +++ src/hg/inc/userdata.h @@ -43,30 +43,33 @@ * on hgwdev, this is /data/apache/userdata/userStore/hash/userName/ * on the RR, this is /userdata/userStore/hash/userName/ */ char *prefixUserFile(char *userName, char *fname); /* Allocate a new string that contains the full per-user path to fname, NULL otherwise */ void removeFileForUser(char *fname, char *userName); /* Remove a file for this user if it exists */ struct userHubs *listHubsForUser(char *userName); /* Lists the directories for a particular user */ struct userFiles *listFilesForUserHub(char *userName, char *hubName); /* Get all the files for a particular hub for a particular user */ +struct hubSpace *listFilesForUser(char *userName); +/* Return the files the user has uploaded */ + long long getMaxUserQuota(char *userName); /* Return how much space is allocated for this user or the default */ long long checkUserQuota(char *userName); /* Return the amount of space a user is currently using */ char *storeUserFile(char *userName, char *fileName, void *data, size_t dataSize); /* Give a fileName and a data stream, write the data to: * userdata/userStore/hashedUserName/userName/fileName * where hashedUserName is based on the md5sum of the userName * to prevent proliferation of too many directories. * * After sucessfully saving the file, return a web accessible url * to the file. */