Hello,

I'm working on an irc bot that indexes in-channel image links, and so far 
so good---except I can't seem to get automatic timestamps working! I did my 
best to follow the docs at 
http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/mapping-timestamp-field.html
 
but I don't see any change in what my search docs look like, even after 
deleting the entire index and reconfiguring first.

Right now my mapping looks like this:

$ curl http://localhost:9200/archivist/_mapping?pretty
{
  "archivist" : {
    "mappings" : {
      "image" : {
        "_timestamp" : {
          "enabled" : true,
          "store" : true
        },
        "properties" : {
          "channel" : {
            "type" : "string"
          },
          "image" : {
            "type" : "string"
          },
          "message" : {
            "type" : "string"
          },
          "user" : {
            "type" : "string"
          }
        }
      }
    }
  }
}

and after indexing something (code doing this at 
https://github.com/jesusabdullah/archivist/blob/master/src/main/java/com/jesusabdullah/archivist/Indexer.java#L71-L82
 
first java project ever) my search results look like:

$ curl http://localhost:9200/archivist/image/_search?pretty
{
  "took" : 0,
  "timed_out" : false,
  "_shards" : {
    "total" : 5,
    "successful" : 5,
    "failed" : 0
  },
  "hits" : {
    "total" : 1,
    "max_score" : 1.0,
    "hits" : [ {
      "_index" : "archivist",
      "_type" : "image",
      "_id" : "jK8dY6oKTRifbUU4o406pw",
      "_score" : 1.0,
      
"_source":{"channel":"#nodebombrange","user":"jesusabdullah","message":"snoop! 
http://i.imgur.com/iktO9TK.gif","image":"http://i.imgur.com/iktO9TK.gif"}
    } ]
  }
}

Am I doing something wrong?

Thanks,

--Josh

-- 
You received this message because you are subscribed to the Google Groups 
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/b5f08fc5-3eb9-48a5-a141-454e30e248c4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to