• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

Communication Link Failure

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello people,
We are developing a job search engine.We use JDBC concepts for getting stored data for the purpose of searching particular job title.We use multithread programming. In this we get "communication Link failure" when we declare prepared statement globally.But while declaring that statement in local method there will not be any error.
we want to know the reason for communication link failure.This may come under threading problems.we welcome your suggestions and solutions.
you can make visit to www.jobpier.com to know the searching details.This may be useful for job seekers also
 
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm assuming this error is related to the database you are using. Can you give us more details please?
 
Ramesh Balakrishnan
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hai David,
I am using mySQL 1.4.0 version for database accesssing.In our program we continously executing the query for all the page contents in our database.During the process the "Communication Link Failure" occurs.This when we use single thread also...
 
Ranch Hand
Posts: 227
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Only use a PreparedStatement object from one thread at a time. Declare methods synchronized as needed - the resultset returned also needs to be part of the SAME synchronization. An application server with a good connection pooling and prepared statement caching would help you here. What are you using?
 
Ramesh Balakrishnan
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yah...That's fine.We made thread synchronization that a single should accesss the prepared statement and resultset.There is no exception...Thanks...
 
Whose rules are you playing by? This tiny ad doesn't respect those rules:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic