小编Val*_*Val的帖子

Filebeat> Logstash> ElasticSearch - Lumberjack错误

试图让Filebeat与logstash一起使用.目前我收到此错误:

2016/11/14 04:54:27.721478 output.go:109: DBG  output worker: publish 2047 events
2016/11/14 04:54:27.756650 sync.go:85: ERR Failed to publish events caused by: lumberjack protocol error
2016/11/14 04:54:27.756676 single.go:91: INFO Error publishing events (retrying): lumberjack protocol error
2016/11/14 04:54:28.782729 sync.go:85: ERR Failed to publish events caused by: lumberjack protocol error
2016/11/14 04:54:28.782756 single.go:91: INFO Error publishing events (retrying): lumberjack protocol error
2016/11/14 04:54:30.786983 sync.go:85: ERR Failed to publish events caused by: lumberjack protocol error
2016/11/14 04:54:30.787017 single.go:91: INFO Error publishing events (retrying): lumberjack …
Run Code Online (Sandbox Code Playgroud)

elasticsearch logstash filebeat

3
推荐指数
1
解决办法
4590
查看次数

MailChimp API java集成

我尝试将mailChimp API与java代码集成.我在Codenvy.com上参考MailChimp api教程 但是在功能上:

public String execute() throws Exception{

    ListsMethod listsMethod = new ListsMethod();
    listsMethod.apikey = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx-us7";
    ListsResult listsResult = mailChimpClient.execute(listsMethod);
    ListInformation data = listsResult.data.get(0);

    CampaignCreateMethod campaignCreateMethod = new CampaignCreateMethod();
    campaignCreateMethod.apikey = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx-us7";
    campaignCreateMethod.type = CampaignType.plaintext;
    campaignCreateMethod.options = new Options(data.id, "Test Campaign", "abc@xyz.com", "Codenvy", "Codenvy Users");
    campaignCreateMethod.content = new Content("This is a test campaign");
    String campaignId = mailChimpClient.execute(campaignCreateMethod);

    CampaignSendNowMethod campaignSendNowMethod = new CampaignSendNowMethod();
    campaignSendNowMethod.apikey = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx-us7";
    campaignSendNowMethod.cid = campaignId;
    mailChimpClient.execute(campaignSendNowMethod);

    setMessage("You have successfully created a campaign and …
Run Code Online (Sandbox Code Playgroud)

java email mailchimp

2
推荐指数
1
解决办法
4963
查看次数

elasticsearch 2.0父子孙子

我的操作:

父母:国家,子女:分支机构,孙子:雇员

PUT/company {"mappings":{"branch":{"_ parent":{"type":"country"}},"employee":{"_ parent":{"type":"branch"}}}}

我想添加一个孙子employee2,父亲是分支:

PUT/company/employee2/_mapping {"employee2":{"_ parent":{"type":"branch"}}}

我收到错误的消息:

{"error":{"root_cause":[{"type":"illegal_argument_exception","reason":"无法添加指向已存在类型的_parent字段"}],"type":"illegal_argument_exception" ,"reason":"无法添加指向已存在类型的_parent字段"},"status":400}

我不知道该怎么办.有什么建议吗?谢谢.

parent elasticsearch elasticsearch-2.0

2
推荐指数
1
解决办法
3629
查看次数

如何从弹性搜索索引中删除所有文档

我试图从我的索引中删除所有文档并在 CURL 上收到以下错误。找不到 uri [/logstash-2016.03.11/logevent/] 和方法 [DELETE] 的处理程序

这是我在 Windows 命令上的删除命令。

curl -XDELETE "http://localhost:9200/logstash-2016.03.11/logevent/"
Run Code Online (Sandbox Code Playgroud)

有人可以帮忙吗?

elasticsearch

2
推荐指数
1
解决办法
1万
查看次数

如何使用search_after从elasticsearch获取上一页?

我正在尝试使用 ElasticSearch 创建快速分页。我已阅读有关操作员的此文档页面search_after。我了解如何创建“向前”分页。但在这种情况下,我无法意识到如何移动到上一页。

pagination elasticsearch

2
推荐指数
2
解决办法
3424
查看次数

具有内部命中的弹性搜索部分字段

partial_fields执行nested过滤/查询时是否可以使用该参数?

例如,此查询将仅返回我要查找的字段hits:

{
  "query": {
      "filtered": {
          "query": {
              "ids": {
                  "type": "users",
                  "values": [
                      "111"
                  ]
              }
          },
          "filter": {
              "nested": {
                  "path": "entitlements",
                  "filter": {
                      "bool": {
                          "must": [
                              {
                                  "term": {
                                    "program": "program-a"
                                  }
                              }
                         ]
                      }
                  },
                  "inner_hits": {
                      "size": 999
                  }
              }
          }
      }
  },
  "partial_fields": {
      "partial": {
          "include": [
              "entitlements.accountNumber",
              "entitlements.name",
              "entitlments.numbers"
          ]
      }
  }
}
Run Code Online (Sandbox Code Playgroud)

但是该inner_hits部分没有返回任何字段.

   "inner_hits": {
           "entitlements": {
              "hits": {
                 "total": 1,
                 "max_score": …
Run Code Online (Sandbox Code Playgroud)

elasticsearch

1
推荐指数
1
解决办法
3851
查看次数

连接亚马逊的弹性搜索与mongo-connector

我正在尝试将mongo-connector与亚马逊新托管的Elasticsearch一起使用.

我相信它不是使用普通的Elasticsearch Shield等,而是使用亚马逊相当复杂的身份验证方案.

(相关GH问题:https://github.com/mongodb-labs/mongo-connector/issues/337)

mongodb amazon-web-services elasticsearch amazon-elasticsearch

1
推荐指数
1
解决办法
1054
查看次数

elasticsearch 中 field_value_factor 的多个输入

我正在尝试使用 field_value_factor 来衡量文档中的某些字段来制定弹性搜索查询。

{
  "query": {
    "match": {
      "local": true
    },
    "function_score": {
      "functions": [
        {
          "field_value_factor": {
            "field": "title",
            "factor": 1.2,
            "missing": 1
          }
        },
        {
          "gauss": {
            "location": {
              "origin": {
                "lat": 51.5,
                "lon": 0.12
              },
              "offset": "2 Miles",
              "scale": "3 Miles"
            }
          }
        },
        {
          "gauss": {
            "creation_time": {
              "decay": 0.8,
              "offset": "2d",
              "scale": "48d"
            }
          },
          "weight": 2
        }
      ]
    }
  }
}
Run Code Online (Sandbox Code Playgroud)

任何输入,如:

"field_value_factor": {
                             "field": [“title”,"description"],
                             "factor": [1.2,0.8],
                             "missing": [1,0]
                            }
Run Code Online (Sandbox Code Playgroud)

不适用于这两个字段,并且查询检索与第一个相同的文档。

是否可以在“field_value_vector”中输入多个术语?

elasticsearch elasticsearch-dsl

1
推荐指数
1
解决办法
1775
查看次数

如何在logstash过滤器中使用redis?

我正在将 ELK+Redis 从非常旧的版本升级到最新版本。

ES 1.6 to 7.4
LS 1.4 to 7.4
Redis 2.8 to 5.0
Run Code Online (Sandbox Code Playgroud)

我把所有东西都重新安装在一台新机器上。一切都很顺利,除了一件事:logstash-filter-redis 插件

这是我的logstash conf 文件

input
  {
    redis {
      host
      port => 6380
      data_type
      key
    }
  }
filter {
  grok {
    match => [ "message", "" ]
  }
  redis {
    host => ""
    port => 6379
    key => ""
    }
output {
  elasticsearch {
    host => ""
    index => ""
  }
Run Code Online (Sandbox Code Playgroud)

在这里,输入 { } 内的第一个 redis:6380 用于获取日志(用作logstash 输入源)

而第二个 redis:6379 在过滤器 { } 内被调用以获取与这些日志关联的数据。

我在https://www.elastic.co/guide/en/logstash/current/filter-plugins.html …

ruby plugins redis logstash elk

1
推荐指数
1
解决办法
2809
查看次数