summaryrefslogtreecommitdiff
path: root/server-tools/instance-manager/instance.h
diff options
context:
space:
mode:
authorunknown <petr@mysql.com>2005-01-25 13:54:56 +0300
committerunknown <petr@mysql.com>2005-01-25 13:54:56 +0300
commitfb3d6c39a0dc128f5310aac2906cc1e6c6b7db59 (patch)
treeada085796e1dc8387942522e6233d9a1b1a1d6d3 /server-tools/instance-manager/instance.h
parent28f86d8ff1d042a2224c64712e31c65b1d6b7476 (diff)
downloadmariadb-git-fb3d6c39a0dc128f5310aac2906cc1e6c6b7db59.tar.gz
IM mostly fixed according to Brian's directions. Will need to do some additional option handling and cleanups
server-tools/instance-manager/Makefile.am: New file added server-tools/instance-manager/client_func.c: typo fixed server-tools/instance-manager/commands.cc: there are no admin-user snd admin-password fields anymore, so no need to show their values server-tools/instance-manager/guardian.cc: Syncronization added -- now guardian wakes up whenever SIGCLD has been catched server-tools/instance-manager/guardian.h: Condition variable declared server-tools/instance-manager/instance.cc: Persistent connection to the instance removed. Now we use SIGTERM instead of com_shutdown for STOP. We also manage SIGCHLD ourselves now (therefore no double fork). server-tools/instance-manager/instance.h: Pointer to the instance_map added, MySQL connection structures removed server-tools/instance-manager/instance_map.cc: More syncronization added (to make proper STOP) server-tools/instance-manager/instance_map.h: added condition variable and mutex for connection threads to wait for SIGCHLD server-tools/instance-manager/instance_options.cc: defaults-handling methods have been added. server-tools/instance-manager/instance_options.h: New functions and constants declared server-tools/instance-manager/listener.cc: No changes here (bk bug?) server-tools/instance-manager/manager.cc: SIGCHLD handling added
Diffstat (limited to 'server-tools/instance-manager/instance.h')
-rw-r--r--server-tools/instance-manager/instance.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/server-tools/instance-manager/instance.h b/server-tools/instance-manager/instance.h
index 6733985116a..78b7768c121 100644
--- a/server-tools/instance-manager/instance.h
+++ b/server-tools/instance-manager/instance.h
@@ -25,14 +25,14 @@
#pragma interface
#endif
+class Instance_map;
+
class Instance
{
public:
- Instance(): is_connected(FALSE)
- {}
~Instance();
-
int init(const char *name);
+ int complete_initialization(Instance_map *instance_map_arg);
/* check if the instance is running and set up mysql connection if yes */
bool is_running();
@@ -44,7 +44,7 @@ public:
Instance_options options;
/* connection to the instance */
- MYSQL mysql;
+ pid_t pid;
private:
/*
@@ -53,8 +53,7 @@ private:
and we issue the start command once more.
*/
pthread_mutex_t LOCK_instance;
- /* Here we store the state of the following connection */
- bool is_connected;
+ Instance_map *instance_map;
};
#endif /* INCLUDES_MYSQL_INSTANCE_MANAGER_INSTANCE_H */