diff --git a/server/core/server.c b/server/core/server.c index 77accd29b..1faee1076 100644 --- a/server/core/server.c +++ b/server/core/server.c @@ -1264,6 +1264,7 @@ bool server_create(const char *name, const char *address, const char *port, if (server_find_by_unique_name(name) == NULL) { + // TODO: Get default values from the protocol module if (port == NULL) { port = "3306"; @@ -1272,6 +1273,12 @@ bool server_create(const char *name, const char *address, const char *port, { protocol = "MySQLBackend"; } + if (authenticator == NULL && (authenticator = get_default_authenticator(protocol)) == NULL) + { + MXS_ERROR("No authenticator defined for server '%s' and no default " + "authenticator for protocol '%s'.", name, protocol); + return false; + } /** First check if this service has been created before */ SERVER *server = find_destroyed_server(name, protocol, authenticator,