1 /* 2 Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights 3 reserved. 4 5 This program is free software; you can redistribute it and/or modify 6 it under the terms of the GNU General Public License, version 2.0, 7 as published by the Free Software Foundation. 8 9 This program is also distributed with certain software (including 10 but not limited to OpenSSL) that is licensed under separate terms, 11 as designated in a particular file or component or in included license 12 documentation. The authors of MySQL hereby grant you an additional 13 permission to link the program and your derivative works with the 14 separately licensed software that they have included with MySQL. 15 16 This program is distributed in the hope that it will be useful, 17 but WITHOUT ANY WARRANTY; without even the implied warranty of 18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 19 GNU General Public License, version 2.0, for more details. 20 21 You should have received a copy of the GNU General Public License 22 along with this program; if not, write to the Free Software 23 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 24 02110-1301 USA 25 */ 26 #ifndef NDBMEMCACHE_NDBCONFIGURATION_H 27 #define NDBMEMCACHE_NDBCONFIGURATION_H 28 29 /* 30 Configuration is shared between the engine thread (which is C) and the 31 back-end NDB code (which is C++). 32 33 The functions here have C linkage, and serve as a wrapper around the C++ 34 Configuration methods. 35 */ 36 37 #include "atomics.h" 38 #include "KeyPrefix.h" 39 #include "ndbmemcache_global.h" 40 41 DECLARE_FUNCTIONS_WITH_C_LINKAGE 42 43 bool connect_to_primary_cluster(const char *connectstring, const char *role); 44 bool get_config(); 45 bool open_connections_to_all_clusters(); 46 bool prefetch_dictionary_objects(); 47 prefix_info_t get_prefix_info_for_key(int nkey, const char *key); 48 void disconnect_all(); 49 void set_initial_cas_ids(unsigned int *hi, atomic_int32_t *lo); 50 void print_debug_startup_info(); 51 void start_reconfig_listener(void *scheduler); 52 53 END_FUNCTIONS_WITH_C_LINKAGE 54 55 #endif 56