Can't remove duplicate

Hello all, I can’t remove duplicate,I’m using ferret
to index log file in order to monitor application activity,
what I want to do is index data based on the uniqueness of
[filename,line](actullay should be [host,filename,line],
the code is following:

if !$indexer

  field_infos = =>

:term_vector => :no)
field_infos.add_field(:content, :store => :yes, :index => :yes)

  $indexer = => index_dir,
                           :field_infos => field_infos,
                           :key => [:filename, :line],

  #$indexer ||=>index_dir, :key => ['filename',

‘line’], :max_buffered_docs=>100) #unique host,file_name,line
# #:default_boost => 20,
# :store => :yes,
# :index => :untokenized,
# :term_vector => :no)
but the problem is, I will index a new datum even if the [filename,line]
is same, even I change :key => [“filename”, “line”], it also doesn’t
what’s the problem? Thanks.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs