对于这个项目,我尝试在intellij中创建一个mongodb应用程序,并为数据库gui添加javafx。我使用的是Java15.0.1。
请找到以下程序的链接:
https://connectglosac-my.sharepoint.com/:f:/g/personal/s1905596\u glos\u ac\u uk/ehrd40zw4m9gjilgmcnjriobsm1t4rrnbgbm3y\u xrbka0a?e=g6xvnr
当我尝试运行gradle程序并收到以下错误代码时遇到问题:
应用程序启动时出现异常
方法java.base/jdk.internal.reflect.invocationtargetexception位于java.base/jdk.internal.reflect.nativemethodaccessorimpl.invoke0(本机方法)位于java.base/jdk.internal.reflect.nativemethodaccessorimpl.invoke(本机方法)。java:64)在java.base/jdk.internal.reflect.delegatingmethodaccessorimpl.invoke(delegatingmethodaccessorimpl。java:43)在java.base/java.lang.reflect.method.invoke(方法。java:564)在javafx.graphics/com.sun.javafx.application.launchempl.launchapplicationwithargs(launchempl。java:464)在javafx.graphics/com.sun.javafx.application.launchempl.launchapplication(launchempl。java:363)位于java.base/jdk.internal.reflect.nativemethodaccessorimpl.invoke0(本机方法)在java.base/jdk.internal.reflect.nativemethodaccessorimpl.invoke(nativemethodaccessorimpl。java:64)在java.base/jdk.internal.reflect.delegatingmethodaccessorimpl.invoke(delegatingmethodaccessorimpl。java:43)在java.base/java.lang.reflect.method.invoke(method。java:564)在java.base/sun.launcher.launchelper$fxhelper.main(launchelper。java:1071)原因:java.lang.runtimeexception:javafx.graphics/com.sun.javafx.application.launchempl.launchapplication1(launchempl)的应用程序启动方法中的异常。java:900)在javafx.graphics/com.sun.javafx.application.launchempl.lambda$launchapplication$2(launchempl。java:195)在java.base/java.lang.thread.run(thread。java:832)引起原因:com.mongodb.mongosecurityexception:验证mongocredential{mechanism=scram-sha-1,username='dbuser',source='admin',password=,mechanismproperties=}位于com.mongodb.internal.connection.saslauthenticator.wrapexception(saslauthenticator。java:235)在com.mongodb.internal.connection.saslauthenticator$1.run(saslauthenticator。java:80)在com.mongodb.internal.connection.saslauthenticator$1.run(saslauthenticator。java:51)在com.mongodb.internal.connection.saslauthenticator.doassObject(saslauthenticator。java:241)在com.mongodb.internal.connection.saslauthenticator.authenticate(saslauthenticator。java:51)在com.mongodb.internal.connection.defaultauthenticator.authenticate(defaultauthenticator。java:53)在com.mongodb.internal.connection.internalstreamconnectioninitializer.authenticate(internalstreamconnectioninitializer。java:168)在com.mongodb.internal.connection.internalstreamconnectioninitializer.initialize(internalstreamconnectioninitializer。java:63)在com.mongodb.internal.connection.internalstreamconnection.open(internalstreamconnection。java:144)在com.mongodb.internal.connection.usagetrackinginternalconnection.open(usagetrackinginternalconnection。java:51)在com.mongodb.internal.connection.defaultconnectionpool$pooledconnection.open(defaultconnectionpool。java:431)在com.mongodb.internal.connection.defaultconnectionpool.get(defaultconnectionpool。java:115)在com.mongodb.internal.connection.defaultconnectionpool.get(defaultconnectionpool。java:100)在com.mongodb.internal.connection.defaultserver.getconnection(defaultserver。java:92)在com.mongodb.internal.binding.clusterbinding$clusterbindingconnectionsource.getconnection(clusterbinding。java:119)在com.mongodb.client.internal.clientsessionbinding$sessionbindingconnectionsource.getconnection(clientsessionbinding)。java:135)在com.mongodb.internal.operation.findoOperation$1.call(findoOperation。java:653)在com.mongodb.internal.operation.findoOperation$1.call(findoOperation。java:650)在com.mongodb.internal.operation.operationhelper.withreadconnectionsource(operationhelper。java:582)在com.mongodb.internal.operation.findoOperation.execute(findoOperation。java:650)在com.mongodb.internal.operation.findoOperation.execute(findoOperation。java:78)在com.mongodb.client.internal.mongoclientdelegate$delegateoperationexecutor.execute(mongoclientdelegate。java:178)在com.mongodb.client.internal.mongoiterablempl.execute(mongoiterablempl。java:135)在com.mongodb.client.internal.mongoiterablempl.iterator(mongoiterablempl。java:92)在com.mongodb.client.internal.mongoiterablempl.foreach(mongoiterablempl。java:121)在com.mongodb.client.internal.mongoiterablempl.into(mongoiterablempl。java:130)在com.accelita.repository.mongorepository.getmodules(mongorepository。java:39)在com.accelita.universitydata.application.mainapp.start(mainapp。java:23)在javafx.graphics/com.sun.javafx.application.launchempl.lambda$launchapplication1$9(launchempl。java:846)在javafx.graphics/com.sun.javafx.application.platformimpl.lambda$runandwait$12(platformimpl。java:455)在javafx.graphics/com.sun.javafx.application.platformimpl.lambda$runlater$10(platformimpl。java:428)在java.base/java.security.accesscontroller.doprivileged(accesscontroller。java:391)在javafx.graphics/com.sun.javafx.application.platformimpl.lambda$runlater$11(platformimpl。java:427)在javafx.graphics/com.sun.glass.ui.invokelaterdispatcher$future.run(invokelaterdispatcher。java:96)在javafx.graphics/com.sun.glass.ui.win.winapplication.\u runloop(本机方法)位于javafx.graphics/com.sun.glass.ui.win.winapplication.lambda$runloop$3(winapplication)。java:174) ... 另外1个原因:com.mongodb.mongocommandexception:命令失败,错误为8000(atlaserror):“错误身份验证:身份验证失败。”在服务器cluster0-shard-00-02.wdbc6.mongodb上。net:27017. 完整响应为{“ok”:0,“errmsg”:“bad auth:authentication failed.”,“code”:8000,“codename”:“atlaserror”}位于com.mongodb.internal.connection.protocolhelper.getcommandfailureexception(protocolhelper)。java:175)在com.mongodb.internal.connection.internalstreamconnection.receivecommandmessageresponse(internalstreamconnection。java:359)在com.mongodb.internal.connection.internalstreamconnection.sendandreceive(内部流连接。java:280)在com.mongodb.internal.connection.commandhelper.sendandreceive(commandhelper。java:83)在com.mongodb.internal.connection.commandhelper.executecommand(commandhelper。java:33)在com.mongodb.internal.connection.saslauthenticator.sendsalslcontinue(saslauthenticator。java:195)访问com.mongodb.internal.connection.saslauthenticator.access$200(saslauthenticator。java:43)在com.mongodb.internal.connection.saslauthenticator$1.run(saslauthenticator。java:69) ... 35运行应用程序com.accelita.universitydata.application.mainapp时出现更多异常
失败:生成失败,出现异常。
暂无答案!
目前还没有任何答案,快来回答吧!