This forum is in READ-ONLY mode.
You can look around, but if you want to ask a new question, please use Stack Overflow.

Culture problems when using Lucene

Questions relating to sfLucenePlugin, sfSearch etc

Culture problems when using Lucene

by skywalker » Mon Sep 08, 2008 7:47 am

Hello folks,

We have a problem using lucene in a production environment. While developing the application we have had no problem using it.

But after freezing and deploying our application to the production server, we get the following error when trying to build the index:

Code: Select all
./symfony lucene-rebuild avrfreaks


  [sfLuceneException]
  Culture "en" is not enabled.


We do not use i18n.

Any suggestions about what's wrong?
May the source be with you
User avatar
skywalker
Faithful Member
 
Posts: 337
Joined: Fri Mar 07, 2008 4:31 pm
Location: Norway

Re: Culture problems when using Lucene

by wissl » Mon Sep 08, 2008 8:15 am

From the README of sfLucenePlugin:

If you require i18n support, you must define the cultures that you support under index. Use the following syntax:

index:
cultures: [fr_FR](en_US,)

(If you receive an exception saying "Culture XXX is not enabled" then define the culture even if you do not use i18n.)
wissl
Faithful Member
 
Posts: 461
Joined: Sun Mar 02, 2008 2:34 pm
Location: Germany

Re: Culture problems when using Lucene

by skywalker » Mon Sep 08, 2008 8:18 am

[Updated]
Since we don't want i18n we haven't enabled i18n. I tried to enable i18n and/or define a cultures:

Code: Select all
  index:
    cultures: [en]


Still it complains.

I have also tried to enable i18n in the apps config file setting.yml and defined the culture in the search.yml, but still we get the same error. When trying to use the application we get the Internal error 500 page. :(~ :-(~ :sad:

I also wonder why this works in the development environment (on a different virtual server) and not in production.
May the source be with you
User avatar
skywalker
Faithful Member
 
Posts: 337
Joined: Fri Mar 07, 2008 4:31 pm
Location: Norway

Re: Culture problems when using Lucene

by wissl » Mon Sep 08, 2008 9:14 am

I think the settings have to be made in the projects search.yml only. Have you tried that yet?
wissl
Faithful Member
 
Posts: 461
Joined: Sun Mar 02, 2008 2:34 pm
Location: Germany

Re: Culture problems when using Lucene

by skywalker » Mon Sep 08, 2008 9:22 am

I'm trying that now. And it seems like it will create new indexes. The problem is that it takes 2 hours to create new indexes (due to a huge database).

When new indexes are created I will check if the application work. I'll post an update here when the index generation has completed and I'm able to test the application again.

Update:
Seems like the problem has been solved, but due to other problems, which has occured, I cannot be 100% sure yet.

Anyway, thanks.
May the source be with you
User avatar
skywalker
Faithful Member
 
Posts: 337
Joined: Fri Mar 07, 2008 4:31 pm
Location: Norway

Re: Culture problems when using Lucene

by wm_maw » Sun Aug 01, 2010 1:39 pm

Code: Select all
symfony doctrine:build --all --no-confirmation --and-load --env=prod


I don't use the plugin -I made my own plugin- but the --env=prod does the trick for me.
Using SYMFONY 1.4.6
wm_maw
Junior Member
 
Posts: 8
Joined: Mon Jul 05, 2010 2:45 am
Location: Bucuresti