检测到您已登录华为云国际站账号,为了您更好的体验,建议您访问国际站服务网站 https://www.huaweicloud.com/intl/zh-cn
不再显示此消息
huaweicloud.sdk.test; import com.huaweicloud.sdk.core.auth.ICredential; import com.huaweicloud.sdk.core.auth.BasicCredentials; import com.huaweicloud
15 16 17 18 19 20 21 22 23 24 25 26 27 from elasticsearch import Elasticsearch import ssl class ElasticFactory(object): def __init__(self
连接非安全集群,示例代码如下: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 package main import ( "github.com/elastic/go-elasticsearch/v7" "log" ) func main() {
-*- coding: UTF-8 -*- import json import time import h5py from elasticsearch import Elasticsearch from elasticsearch import helpers def get_client(hosts:
CloudSearchService.cer –out newname.pem 将安全证书从“.cer”格式转换为“.jks”格式。 keytool -import -alias newname -keystore ./truststore.jks -file ./CloudSearchService
在Saved Objects页面,单击“Import”,在弹窗中选择保存在本地的源集群的可视化对象文件“export.ndjson”,“Import options”选择“Automatically overwrite conflicts”,单击“Import”。 图3 导入可视化对象 确认导入完成后,单击Done,关闭弹窗。
install elasticsearch==7.6 代码示例 from elasticsearch import Elasticsearch from elasticsearch import helpers # 创建Elasticsearch客户端 def get_client(hosts:
保存为索引结构迁移脚本。 # -*- coding:UTF-8 -*- import sys import yaml import requests import re import json import os def printDividingLine(): pr
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 from opensearchpy import OpenSearch # 创建客户端 def get_client(hosts: list, user: str = None, password:
keytool -import -alias newname -keystore ./truststore.jks -file ./CloudSearchService.cer 在Windows系统中,执行如下命令转换证书。 keytool -import -alias newname
在Kibana页面,选择“Management > Stack Management > Saved objects”。 图4 选择Saved objects 单击“Import ”,选择上传5.a中创建的“monitoring-kibana.ndjson”文件。 图5 上传文件 上传完成选择“done”,索引监控图表即导入成功。