fd526976ba5971d4bae14235cf2f735751a5e548
angie
  Wed May 15 14:26:41 2019 -0700
Adding doReSaveSession to streamline loading and saving a session in one CGI request, for converting old session trash paths and customTrash tables to userdata and customData.  refs #22440

diff --git src/hg/hgSession/hgSession.h src/hg/hgSession/hgSession.h
index 3e6bd9a..883ddf4 100644
--- src/hg/hgSession/hgSession.h
+++ src/hg/hgSession/hgSession.h
@@ -40,30 +40,35 @@
 #define hgsDoLoadLocal hgSessionPrefix "doLoadLocal"
 
 #define hgsLoadUrlName hgSessionPrefix "loadUrlName"
 #define hgsDoLoadUrl hgSessionPrefix "doLoadUrl"
 
 #define hgsDoMainPage hgSessionPrefix "doMainPage"
 
 #define hgsDoSessionDetail hgSessionPrefix "doSessionDetail"
 #define hgsOldSessionName hgSessionPrefix "oldSessionName"
 #define hgsDoSessionChange hgSessionPrefix "doSessionChange"
 
 #define hgsCancel hgSessionPrefix "cancel"
 
 #define hgsDo hgSessionPrefix "do"
 
+// Non-UI reachable function to load a session and save it, for the purpose of moving files
+// and tables out of trash/customTrash into userdata/customData after sessionData* params are
+// added to hg.conf.
+#define hgsDoReSaveSession hgSessionPrefix "doReSaveSession"
+
 // Back-door CGI param to randomize the suffix (usually day of month) for sessionDataDbPrefix.
 // This is for bulk re-saving old sessions to move files and tables to safe storage;
 // we don't want all of the old sessions' tables to end up in the same day-of-month database.
 #define hgsSessionDataDbSuffix hgSessionPrefix "sessionDataDbSuffix"
 
 char *cgiDecodeClone(char *encStr);
 /* Allocate and return a CGI-decoded copy of encStr. */
 
 void startBackgroundWork(char *exec, char **pWorkUrl);
 /* deal with forking off child for background work
  * and setting up the trash file for communicating
  * from the child to the browser */
 
 void getBackgroundStatus(char *url);
 /* fetch status as the latest complete html block available.