有人做过elasticsearch6.4的数据库方式更新动态词库吗?就是IK分词改造的那个链接
https://blog.csdn.net/wuzhiwei ... ments
我这一直报数据库连接不上,不知道为什么
java.sql.SQLNonTransientConnectionException: Could not create connection to database server.
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:676) ~[?:?]
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:663) ~[?:?]
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:653) ~[?:?]
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:638) ~[?:?]
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:606) ~[?:?]
at com.mysql.cj.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:1837) ~[?:?]
Caused by: java.security.AccessControlException: access denied ("java.net.SocketPermission" "。。。。。。:3306" "connect,resolve")
at java.security.AccessControlContext.checkPermission(AccessControlContext.java:472) ~[?:1.8.0_181]
at java.security.AccessController.checkPermission(AccessController.java:884) ~[?:1.8.0_181]
at java.lang.SecurityManager.checkPermission(SecurityManager.java:549) ~[?:1.8.0_181]
at java.lang.SecurityManager.checkConnect(SecurityManager.java:1051) ~[?:1.8.0_181]
at java.net.Socket.connect(Socket.java:584) ~[?:1.8.0_181]
但是配置文件中的用户名和密码肯定是对的。。。
有大神知道为什么吗?或者有谁做过,可以给一个做好的用数据库热更新词库的IK分词器吗?搞了好几天了,就是找不到问题怎么解决
https://blog.csdn.net/wuzhiwei ... ments
我这一直报数据库连接不上,不知道为什么
java.sql.SQLNonTransientConnectionException: Could not create connection to database server.
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:676) ~[?:?]
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:663) ~[?:?]
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:653) ~[?:?]
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:638) ~[?:?]
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:606) ~[?:?]
at com.mysql.cj.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:1837) ~[?:?]
Caused by: java.security.AccessControlException: access denied ("java.net.SocketPermission" "。。。。。。:3306" "connect,resolve")
at java.security.AccessControlContext.checkPermission(AccessControlContext.java:472) ~[?:1.8.0_181]
at java.security.AccessController.checkPermission(AccessController.java:884) ~[?:1.8.0_181]
at java.lang.SecurityManager.checkPermission(SecurityManager.java:549) ~[?:1.8.0_181]
at java.lang.SecurityManager.checkConnect(SecurityManager.java:1051) ~[?:1.8.0_181]
at java.net.Socket.connect(Socket.java:584) ~[?:1.8.0_181]
但是配置文件中的用户名和密码肯定是对的。。。
有大神知道为什么吗?或者有谁做过,可以给一个做好的用数据库热更新词库的IK分词器吗?搞了好几天了,就是找不到问题怎么解决
2 个回复
rochy - rochy_he
赞同来自: hechangpeng
打开 $JAVA_HOME/jre/lib/security/java.policy
在中间添加下面的语句然后重试一下:
具体可参考:https://blog.csdn.net/soszou/a ... 77074
zz_hello
赞同来自: