小编zub*_*024的帖子

如何在NightmareJs中发出POST请求

我一直在PhantomJs和CasperJs中编写一些测试用例.最近我偶然发现了使用ElectronJs的NightmareJs.

我想知道我是否可以在NigthmareJs中自动执行POST请求(例如下面)(可能使用goto,但我没有看到传递params和更改方法的任何规范):

PhantomJs代码:

  page.open(url, 'post', params, function (status) {/*something*/});
Run Code Online (Sandbox Code Playgroud)

如果是这样,我可以循环几次以监控所花费的时间.

javascript post loops nightmare

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

Angular 2 Kendo UI 上的日期时间过滤器

我在使用Kendo UI for Angular 2实现日期时间过滤器时遇到了麻烦。有没有人能够解决这个问题?如果是这样,请让我知道,希望有关于如何实现相同的片段。

javascript kendo-ui kendo-grid angular

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

对ElasticSearch使用“ repository-s3”插件时出错

我正在尝试将Elasticsearch节点的快照存储库的配置设置为S3。

我已经为Elasticsearch 安装了“ repository-s3”插件。

PUT http://<username>:<password>@<elasticsearch-instance-ip>:9200/_snapshot/s3_repository?verify=false

    {
      "type": "s3",
      "settings": {
        "bucket": "bucket-name",
        "region": "eu-west-1",
        "access_key": "****",
        "secret_key": "****"
    }
}
Run Code Online (Sandbox Code Playgroud)

响应是:

{
    "error": {
        "root_cause": [
            {
                "type": "repository_exception",
                "reason": "[s3_repository] failed to create repository"
            }
        ],
        "type": "repository_exception",
        "reason": "[s3_repository] failed to create repository",
        "caused_by": {
            "type": "illegal_argument_exception",
            "reason": "Setting [access_key] is insecure, but property [allow_insecure_settings] is not set"
        }
    },
    "status": 500
}
Run Code Online (Sandbox Code Playgroud)

我曾尝试在elasticsearch.yml配置文件中应用allow_insecure_settings设置,但这不起作用。

仅供参考,我正在使用X-Pack插件

有什么建议么?

amazon-s3 elasticsearch elasticsearch-plugin

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