2014-10-24 5 views
0

를 찾을 수 없음 설정/sunspot.yml에게 Heroku - RSolr는 :: 오류 :: HTTP를 (RSolr :: 오류 :: HTTP를 - 404

production: 
    solr: 
    hostname: http://index.websolr.com/solr/... 
    port: 8983 
    log_level: WARNING 
    path: /solr/production 
... 

그리고 내에게 Heroku의 구성 변수는

http://index.websolr.com/solr/... 

입니다 그 외 모든 것은 문서별로 구성되어있는 것처럼 보이지만 로그 및 앱 충돌시 404 개의 메시지가 계속 표시됩니다. 이전에이 문제가 발생하여 문제를 해결할 수 있었습니까?

답변

1

Sunspot은 기본적으로 Solr 번들로 제공되지만 Websolr 인덱스와 완전히 별개입니다. Websolr 인덱스는 heroku addons:open websolr을 실행하여 볼 수있는 대시 보드를 통해 관리됩니다. 모든 구성 설정이 여기에 적용됩니다. 명령 행에서 websolr을 시작/중지/재시작 할 수 없습니다. documentation

:

By default, Sunspot 1.3.0 supports the WEBSOLR_URL environment variable used by your Heroku application in production. This lets Sunspot perform actions on your index without further configuration, allowing users to get search up and running quickly without necessitating changes to their app’s codebase.

If you would like more fine-grained control over which Solr servers you are using in different environments, you may run script/generate sunspot from a command line in your application’s root directory to create a Sunspot configuration file at config/sunspot.yml .

그래서 당신은 단순히 sunspot.yml 파일을 제거 할 수 있어야하고 태양 흑점 단순히 WEBSOLR_URL의 값을 사용합니다. 또는 다음과 같이 사용할 수 있습니다.

production: 
    solr: 
    hostname: index.websolr.com 
    port: 80 
    log_level: WARNING 
    path: /solr/a1b2c3d4e5 (whatever your key is) 
0

시험해보기 :

  1. 정지 SOLR
  2. 프로젝트 폴더
  3. 변경 '경로 :/SOLR/생산'에서
  4. 제거 SOLR 폴더 '경로 :/SOLR/기본'에
  5. 컴퓨터를 재부팅
  6. 시작 SOLR

이상하지만 작동합니다.

관련 문제