我正在使用 Elastic 7.9.2 版本并希望使用安全性。所以我跑了:
bin/elasticsearch-certutil cert -out config/elastic-certificates.p12 -pass ""
Run Code Online (Sandbox Code Playgroud)
然后添加
xpack.security.enabled: true
xpack.security.transport.ssl.enabled: true
xpack.security.transport.ssl.verification_mode: certificate
xpack.security.transport.ssl.keystore.path: elastic-certificates.p12
xpack.security.transport.ssl.truststore.path: elastic-certificates.p1
Run Code Online (Sandbox Code Playgroud)
在config/elasticsearch.yaml
现在当我运行 ES 时
bin/elasticsearch
Run Code Online (Sandbox Code Playgroud)
出现以下错误:
"error":{"root_cause":[{"type":"security_exception","reason":"missing authentication credentials
for REST request [/]","header":{"WWW-Authenticate":"Basic realm=\"security\" charset=\"UTF-
8\""}}],"type":"security_exception","reason":"missing authentication credentials for REST
request [/]","header":{"WWW-Authenticate":"Basic realm=\"security\" charset=\"UTF-
8\""}},"status":401}root@ip-localhost:/var/log/elasticsearch
Run Code Online (Sandbox Code Playgroud)
任何人都可以帮忙吗!
elasticsearch kibana amazon-elastic-beanstalk elastic-stack elasticsearch-x-pack
我的类路径中有以下罐子
我导入了以下课程。
import static org.junit.Assert.assertEquals;
import static org.powermock.api.mockito.PowerMockito.doReturn;
import static org.powermock.api.mockito.PowerMockito.spy;
import static org.powermock.api.mockito.PowerMockito.verifyPrivate;
import static org.powermock.api.mockito.PowerMockito.when;
import static org.powermock.api.mockito.PowerMockito.mock;
import org.powermock.modules.junit4.PowerMockRunner;
Run Code Online (Sandbox Code Playgroud)
然后我在执行测试类时收到以下错误
The type org.powermock.api.support.membermodification.MemberModifier cannot be resolved. It is indirectly referenced from required .class files
Run Code Online (Sandbox Code Playgroud)
PS:我没有使用像Spring Boot这样的任何框架请帮忙!