ServiceRegistry ser=new ServiceRegistryBuilder().applySettings(config.getProperties()).buildServiceRegistry();
ServiceRegistry serviceRegistry
= new StandardServiceRegistryBuilder().applySettings(config.getProperies()).build();
serviceRegistry 的包导入错误来吧。。你好像导入的不是 hibernate 的包