在eclipse上使用Hibernate时出错(Error using Hibernate on eclipse)
我开始学习如何使用hibernate。 当出现此错误时,我正在创建我的新应用程序
mar 13, 2015 5:05:06 PM org.hibernate.annotations.common.reflection.java.JavaReflectionManager <clinit> INFO: HCANN000001: Hibernate Commons Annotations {4.0.5.Final} mar 13, 2015 5:05:06 PM org.hibernate.Version logVersion INFO: HHH000412: Hibernate Core {4.3.8.Final} mar 13, 2015 5:05:06 PM org.hibernate.cfg.Environment <clinit> INFO: HHH000206: hibernate.properties not found mar 13, 2015 5:05:06 PM org.hibernate.cfg.Environment buildBytecodeProvider INFO: HHH000021: Bytecode provider name : javassist mar 13, 2015 5:05:06 PM org.hibernate.cfg.Configuration configure INFO: HHH000043: Configuring from resource: ./hibernate.cfg.xml mar 13, 2015 5:05:06 PM org.hibernate.cfg.Configuration getConfigurationInputStream INFO: HHH000040: Configuration resource: ./hibernate.cfg.xml mar 13, 2015 5:05:06 PM org.hibernate.internal.util.xml.DTDEntityResolver resolveEntity WARN: HHH000223: Recognized obsolete hibernate namespace http://hibernate.sourceforge.net/. Use namespace http://www.hibernate.org/dtd/ instead. Refer to Hibernate 3.6 Migration Guide! mar 13, 2015 5:05:06 PM org.hibernate.cfg.Configuration addResource INFO: HHH000221: Reading mappings from resource: sample/Event.hbm.xml Ocurrió un error en la inicialización de la SessionFactory: org.hibernate.MappingNotFoundException: resource: sample/Event.hbm.xml not found Exception in thread "main" java.lang.NullPointerException at samples.ContactosDAO.guardaContacto(ContactosDAO.java:31) at samples.main.main(main.java:18)
我真的迷失在这里。 请有人帮帮我
I'm starting to learn how to use hibernate. I was creating my new application when this error showed up
mar 13, 2015 5:05:06 PM org.hibernate.annotations.common.reflection.java.JavaReflectionManager <clinit> INFO: HCANN000001: Hibernate Commons Annotations {4.0.5.Final} mar 13, 2015 5:05:06 PM org.hibernate.Version logVersion INFO: HHH000412: Hibernate Core {4.3.8.Final} mar 13, 2015 5:05:06 PM org.hibernate.cfg.Environment <clinit> INFO: HHH000206: hibernate.properties not found mar 13, 2015 5:05:06 PM org.hibernate.cfg.Environment buildBytecodeProvider INFO: HHH000021: Bytecode provider name : javassist mar 13, 2015 5:05:06 PM org.hibernate.cfg.Configuration configure INFO: HHH000043: Configuring from resource: ./hibernate.cfg.xml mar 13, 2015 5:05:06 PM org.hibernate.cfg.Configuration getConfigurationInputStream INFO: HHH000040: Configuration resource: ./hibernate.cfg.xml mar 13, 2015 5:05:06 PM org.hibernate.internal.util.xml.DTDEntityResolver resolveEntity WARN: HHH000223: Recognized obsolete hibernate namespace http://hibernate.sourceforge.net/. Use namespace http://www.hibernate.org/dtd/ instead. Refer to Hibernate 3.6 Migration Guide! mar 13, 2015 5:05:06 PM org.hibernate.cfg.Configuration addResource INFO: HHH000221: Reading mappings from resource: sample/Event.hbm.xml Ocurrió un error en la inicialización de la SessionFactory: org.hibernate.MappingNotFoundException: resource: sample/Event.hbm.xml not found Exception in thread "main" java.lang.NullPointerException at samples.ContactosDAO.guardaContacto(ContactosDAO.java:31) at samples.main.main(main.java:18)
I'm really lost in here. Can someone help me out please
原文:https://stackoverflow.com/questions/29042504
更新时间:2023-09-21 16:09
最满意答案
问题似乎与附加的调试器有关,每当我运行附带调试器的程序时我会得到奇怪和无法解释的延迟,当我运行程序独立作为一个excecutable我没有得到任何延迟。
The problem seem to have somthing to do with the attached debugger, whenever i run the program with the debugger attached i get strange and unexplained delays, when i run the program stand alone as an excecutable i get no delays what so ever.
相关问答
更多-
为了设置背景,我已经向App Store编写并提交了2个成功的应用程序,因此您知道我不是在假设。 回过头来,您可以将下载推送到后台线程,并以滑块的形式更新进度(为了用户的利益)。 但是,如果在这种情况下用户无论如何都无法做任何事情那么就没有意义了。 另外,我不认为Apple会拒绝你的应用程序。 他们检查的主要内容之一是,如果您使用任何私有API或更基本的应用程序崩溃。 所以请继续提交APP商店评论...... Just to set the background, I have written & subm ...
-
检查JSON。 它兼容多种语言(包括Python和Java),并且它是人类可读的。 http://www.json.org/ 如果你打算做Web开发,并计划使用Javascript,那么JSON可能是一个不错的选择,因为它最初是为Javascript设计的。 此外,与YAML相比,在Python中使用JSON与写入一样简单: import json (它是标准库的一部分)。 你可以看看下面的页面 ,比较XML,JSON和YAML。 看起来它们在编码延迟和内存使用方面存在差异,这可能会指导您的选择。 Chec ...
-
很可能您系统上的OpenSSL动态库与Qt构建的动态库不兼容。 您使用的Qt版本是什么? 由于您尚未指定操作系统,因此很难判断这是否是因为系统本身提供了OpenSSL的旧版本,但我建议使用任何可用的转储工具在OpenSSL库中查找符号(例如SSL_get0_next_proto_negotiated)如果他们不在那里 - 要么降级Qt,要么升级OpenSSL。 如上所述 - 从Qt 5.2及以上版本至少需要OpenSSL 1.0.0,旧版本可能会失败。 UPDATE 我怀疑你为SSL获得的错误确实是由于Op ...
-
网络通信的延迟很大(Huge delay in network communication)[2022-10-22]
问题似乎与附加的调试器有关,每当我运行附带调试器的程序时我会得到奇怪和无法解释的延迟,当我运行程序独立作为一个excecutable我没有得到任何延迟。 The problem seem to have somthing to do with the attached debugger, whenever i run the program with the debugger attached i get strange and unexplained delays, when i run the prog ... -
在http://tutorials.jenkov.com/java-nio/datagram-channel.html的帮助下,找到了如何使用DatagramChannel 。 以下是代码。 import java.nio.ByteBuffer; import java.nio.channels.DatagramChannel; import java.nio.charset.StandardCharsets; public class ReaderThread extends Thread { ...
-
您只需将SOAP客户端配置为使用Compute Engine实例的公共IP(当我希望您拥有SOAP端点时)。 请记住,不可能从appengine到计算引擎创建一种“私有网络”,因此需要从“Internet”访问计算引擎实例,并且您必须验证请求。 Simply you can configure your SOAP client to use the public IP of you Compute Engine instance(when I hope you have a SOAP endpoint). ...
-
是否可以在WP8.1上创建TCP专用网络通信?(Is it possible to create TCP Private Network communication on WP8.1?)[2022-02-14]
是。 您链接到的页面可在同一网络上的手机和桌面应用之间使用。 你提出的引用说WP只有一种功能可以覆盖所有网络访问,而不是将不同的网络访问类型分成不同的功能。 这并不意味着其他功能背后的功能不存在。 Yes. The page you link to will work between a phone and a desktop app on the same network. The quote you pull out says that WP has just one capability to cov ... -
有人能指点我一个非常可靠的网络通信库吗?(Can someone point me to a very reliable network communication library? [closed])[2022-06-28]
如果内置类型不能满足您的需求,您是否听说过Mockets ? 您可能需要联系那里的人以获取更多信息,但它基本上表现为TCP可靠性,但是通过UDP运行。 另外,您需要使用套接字的原因是什么? 如果你真的没有严格的要求,那么使用消息队列怎么样? 您将获得异步消息传递,应用程序生存期间的消息持久性,并且它在2.0中工作。 编辑:我看到这个其他职位关于从您自己的安装程序安装MSMQ。 If the built-in types don't work for your needs, have you heard of ... -
它可以但主要的警告: 首先,系统将取消注册您可能已建立的任何Bonjour名称。 其次,如果你被绑定到WWAN,即使你在监听它也会失败(即使在前台也是如此)。 第三,如果您的应用程序在后台没有执行任何其他操作(即,未注册以提供背景音乐,位置事件或电话),您仍必须在后台任务完成的时间限制内关闭或终止。 所以,虽然你可以在后台绑定和监听套接字,但几乎所有实际用途都不值得做,你应该重新考虑你的设计。 It can but with major caveats: First, the system will unr ...
-
2个Docker容器之间的网络通信如何工作?(How does network communication between 2 Docker Containers work?)[2022-08-11]
我今天早上才回答:-) 链接答案(它谈到php-fpm和nginx,但当然apache的概念是相同的): https : //stackoverflow.com/a/19997381/227887 简而言之,您希望使用容器链接,这是0.6.5中允许将端口从容器暴露给另一个容器的新功能。 另请参阅官方docker文档: http : //docs.docker.io/en/latest/examples/linking_into_redis/ I just answered that this morning ...