Tag: wsod

如何在Struts2中加载长时间运行的初始化数据时避免WSOD(空白屏幕)?

我需要做以下事情: 用户登录。 重定向到欢迎屏幕。 在加载大量记录时查看欢迎屏幕。 重定向到工作屏幕。 我正在寻找一种方法在Action类中做这样的事情: public class LinkAction extends ActionSupport implements SessionAware { @Autowired private ServiceDelegate myService; public String welcome() { new Runnable() { @Override public void run() { myService.getLoadsOfData(); //redirect to the next action } }.run(); // this is where the user // goes to look at the welcome screen return “welcome”; } […]