45
45
#include <boost/filesystem.hpp>
47
#include "drizzled/abort_exception.h"
47
48
#include "drizzled/plugin.h"
48
49
#include "drizzled/gettext.h"
49
50
#include "drizzled/configmake.h"
343
/* Listen for new connections and start new session for each connection
344
accepted. The listen.getClient() method will return NULL when the server
345
should be shutdown. */
346
while ((client= plugin::Listen::getClient()) != NULL)
348
Session::shared_ptr session(new Session(client));
346
/* Listen for new connections and start new session for each connection
347
accepted. The listen.getClient() method will return NULL when the server
348
should be shutdown. */
349
while ((client= plugin::Listen::getClient()) != NULL)
351
Session::shared_ptr session(new Session(client));
359
/* If we error on creation we drop the connection and delete the
361
if (Session::schedule(session))
362
Session::unlink(session);
356
/* If we error on creation we drop the connection and delete the session. */
357
if (Session::schedule(session))
358
Session::unlink(session);
366
catch (abort_exception& ex)
368
cout << _("Drizzle has receieved an abort event.") << endl;
369
cout << _("In Function: ") << *::boost::get_error_info<boost::throw_function>(ex) << endl;
370
cout << _("In File: ") << *::boost::get_error_info<boost::throw_file>(ex) << endl;
371
cout << _("On Line: ") << *::boost::get_error_info<boost::throw_line>(ex) << endl;
374
catch (std::exception& ex)
376
cout << _("Drizzle has recieved an unknown error, shutting down") << endl;
377
cout << _("Error: ") << ex.what() << endl;
361
380
/* Send server shutdown event */