• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1284
  • Last Modified:

Eclipse Hibernate Project: No buffer space available

Hello,

I am trying to run my project and am getting the following stack trace:


Could not connect to:  : 2407                  
java.net.SocketException: No buffer space available (maximum connections reached?): connect
      at java.net.PlainSocketImpl.socketConnect(Native Method)
      at java.net.PlainSocketImpl.doConnect(Unknown Source)
      at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
      at java.net.PlainSocketImpl.connect(Unknown Source)
      at java.net.SocksSocketImpl.connect(Unknown Source)
      at java.net.Socket.connect(Unknown Source)
      at java.net.Socket.connect(Unknown Source)
      at java.net.Socket.<init>(Unknown Source)
      at java.net.Socket.<init>(Unknown Source)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.connect(RemoteTestRunner.java:570)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:381)
      at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)


I read that the maximum number of connection has been reached.
I can I resolve this issue ?

Paolo
0
ptreves
Asked:
ptreves
  • 3
1 Solution
 
Sharon SethCommented:
Seems that either your test case is leaking connecions or that your actual code is doing it . Can you detail when you are seeing this exception?
0
 
ptrevesAuthor Commented:
When I run an JUnit test class from eclipse.
0
 
slightwv (䄆 Netminder) Commented:
Not a Hibernate/Java person but check that for every connection 'open', you call a 'close'.
0
 
Sharon SethCommented:
To what exactly is your test case trying to connect to?
0
 
Sharon SethCommented:
If you are trying to connect to a database using JDBC ,check your app server JDBC service for any connection leaks
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Improve Your Query Performance Tuning

In this FREE six-day email course, you'll learn from Janis Griffin, Database Performance Evangelist. She'll teach 12 steps that you can use to optimize your queries as much as possible and see measurable results in your work. Get started today!

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now