0

when i am trying to run the following python code which uses solrpy,

enter code here

import solr

s = solr.SolrConnection('http://example.org:8080/solr')
s.add(id=1, title='Lucene in Action', author=['hello','lucky'])
s.commit()
response = s.query('title:lucene')
for hit in response.results:
    print hit['title']

i am getting the following error:

error: [Errno 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

Raksh
  • 1
  • 1

1 Answers1

0

You should point to a valid Solr (are you sure there is a Solr running at example.org?)

Andrea
  • 2,714
  • 3
  • 27
  • 38