将OpenDolphin与Spring一起用作服务器端框架并将MongoDB用作数据库是否可行? 我想构建一个简单的团队应用程序来演示团队协作的功能。我对使用技术的建议很感兴趣。
答案 0 :(得分:0)
是的,这是可能的。
首先,尝试使用spring-boot和spring-boot-starter-web artefact。然后扩展DolphinServlet并在ServletRegistrationBean的帮助下注册该servlet。注册操作后,您可以像使用任何Java应用程序一样连接到MongoDB数据库。
@Bean
public ServletRegistrationBean servletRegistrationBean() {
ServletRegistrationBean registrationBean = new ServletRegistrationBean(serverServlet, "/s");
return registrationBean;
}
open dolphin Jumpstart项目是一个很好的起点: https://github.com/canoo/DolphinJumpStart