public void setProperties(Properties properties) {
String dialectClass = properties.getProperty("dialect");
try {
dialect = (Dialect) Class.forName(dialectClass).newInstance();
} catch (Exception e) {
throw new MyBatisShardsException("Can not create dialect instance by dialect:"
+ dialectClass, e);
}
}