gpt4 book ai didi

java - Vaadin QuickTickets 仪表板部署错误

转载 作者:行者123 更新时间:2023-11-28 23:39:35 25 4
gpt4 key购买 nike

我尝试编译并运行 vaadin 演示应用程序,但出现以下错误。我错过了什么吗?

我从 github 下载代码 https://github.com/vaadin/dashboard-demo尝试过

mvn install

then deployed to Tomcatserver 7.0.47 but i keep getting the following error.

HTTP Status 500 - com.vaadin.server.ServiceException: java.lang.ArrayIndexOutOfBoundsException: -1

type Exception report

message com.vaadin.server.ServiceException: java.lang.ArrayIndexOutOfBoundsException: -1

description The server encountered an internal error that prevented it from fulfilling this request.

exception

javax.servlet.ServletException: com.vaadin.server.ServiceException: java.lang.ArrayIndexOutOfBoundsException: -1 com.vaadin.server.VaadinServlet.service(VaadinServlet.java:240) javax.servlet.http.HttpServlet.service(HttpServlet.java:728) org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51) root cause

com.vaadin.server.ServiceException: java.lang.ArrayIndexOutOfBoundsException: -1 com.vaadin.server.VaadinService.handleExceptionDuringRequest(VaadinService.java:1440) com.vaadin.server.VaadinService.handleRequest(VaadinService.java:1394) com.vaadin.server.VaadinServlet.service(VaadinServlet.java:238) javax.servlet.http.HttpServlet.service(HttpServlet.java:728) org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51) root cause

java.lang.ArrayIndexOutOfBoundsException: -1 java.util.ArrayList.elementData(ArrayList.java:400) java.util.ArrayList.get(ArrayList.java:413) com.vaadin.demo.dashboard.data.DataProvider.createTransaction(DataProvider.java:406) com.vaadin.demo.dashboard.data.DataProvider.generateTransactionsData(DataProvider.java:345) com.vaadin.demo.dashboard.data.DataProvider.(DataProvider.java:53) com.vaadin.demo.dashboard.DashboardUI.(DashboardUI.java:62) sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) java.lang.reflect.Constructor.newInstance(Constructor.java:526) java.lang.Class.newInstance(Class.java:374) com.vaadin.server.UIProvider.createInstance(UIProvider.java:36) com.vaadin.server.communication.UIInitHandler.getBrowserDetailsUI(UIInitHandler.java:200) com.vaadin.server.communication.UIInitHandler.synchronizedHandleRequest(UIInitHandler.java:73) com.vaadin.server.SynchronizedRequestHandler.handleRequest(SynchronizedRequestHandler.java:37) com.vaadin.server.VaadinService.handleRequest(VaadinService.java:1382) com.vaadin.server.VaadinServlet.service(VaadinServlet.java:238) javax.servlet.http.HttpServlet.service(HttpServlet.java:728) org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51) note The full stack trace of the root cause is available in the Apache Tomcat/7.0.47 logs.

Apache Tomcat/7.0.47

和另一个错误

    HTTP Status 500 - com.vaadin.server.ServiceException: java.lang.ArrayIndexOutOfBoundsException: -1

type Exception report

message com.vaadin.server.ServiceException: java.lang.ArrayIndexOutOfBoundsException: -1

description The server encountered an internal error that prevented it from fulfilling this request.

exception

javax.servlet.ServletException: com.vaadin.server.ServiceException: java.lang.ArrayIndexOutOfBoundsException: -1
com.vaadin.server.VaadinServlet.service(VaadinServlet.java:240)
javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
root cause

com.vaadin.server.ServiceException: java.lang.ArrayIndexOutOfBoundsException: -1
com.vaadin.server.VaadinService.handleExceptionDuringRequest(VaadinService.java:1440)
com.vaadin.server.VaadinService.handleRequest(VaadinService.java:1394)
com.vaadin.server.VaadinServlet.service(VaadinServlet.java:238)
javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
root cause

java.lang.ArrayIndexOutOfBoundsException: -1
java.util.ArrayList.elementData(ArrayList.java:400)
java.util.ArrayList.get(ArrayList.java:413)
com.vaadin.demo.dashboard.data.DataProvider.createTransaction(DataProvider.java:406)
com.vaadin.demo.dashboard.data.DataProvider.generateTransactionsData(DataProvider.java:345)
com.vaadin.demo.dashboard.data.DataProvider.<init>(DataProvider.java:53)
com.vaadin.demo.dashboard.DashboardUI.<init>(DashboardUI.java:62)
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
java.lang.reflect.Constructor.newInstance(Constructor.java:526)
java.lang.Class.newInstance(Class.java:374)
com.vaadin.server.UIProvider.createInstance(UIProvider.java:36)
com.vaadin.server.communication.UIInitHandler.getBrowserDetailsUI(UIInitHandler.java:200)
com.vaadin.server.communication.UIInitHandler.synchronizedHandleRequest(UIInitHandler.java:73)
com.vaadin.server.SynchronizedRequestHandler.handleRequest(SynchronizedRequestHandler.java:37)
com.vaadin.server.VaadinService.handleRequest(VaadinService.java:1382)
com.vaadin.server.VaadinServlet.service(VaadinServlet.java:238)
javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:51)
note The full stack trace of the root cause is available in the Apache Tomcat/7.0.47 logs.

Apache Tomcat/7.0.47

我也用eclipse试过它也返回同样的错误。

最佳答案

当您尝试运行此演示时,这是常见的异常。您必须修复 DataProvider.class 中的 apiKey。在仪表板示例中使用 http://developer.rottentomatoes.com用于获取电影列表的 API。最简单的方法 - 在该站点创建帐户。它简单且免费。

关于java - Vaadin QuickTickets 仪表板部署错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21316421/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com