0

我正在使用 ElasticSearch 为我的 Web 应用程序实现搜索引擎,我正在使用 Play 框架。当我尝试安装 ElasticSearch 模块时,它在命令提示符中写入它已成功安装,但它没有像 CRUD 等其他模块那样出现在项目资源管理器中,而且当我尝试使用@ElasticSearchable它时也会引发它不能的错误被解析成一个类型。

我确实尝试停止应用程序并将其重新导入 Eclipse,但没有任何改变。

这是我在命令提示符下得到的。我认为这可能是我将弹性搜索文件夹放在错误的位置,我已将其添加到模块文件夹中,这是正确的位置吗?

~        _            _
~  _ __ | | __ _ _  _| |
~ | '_ \| |/ _' | || |_|
~ |  __/|_|\____|\__ (_)
~ |_|            |__/
~
~ play! 1.2.4, http://www.playframework.org
~
~ Resolving dependencies using C:\Users\ahmed\Documents\play\play-1.2.4\se\conf\dependencies.yml,
~
~       play->elasticsearch {0.4} (from playContributedModules)
~
~ WARNING: Some dependencies could not be downloaded (use --verbose for details),
~
~       play->elasticsearch {0.4}: missing artifact
~
~ No dependencies to install
~
~ *****************************************************************************
~ WARNING: These dependencies are missing, your application may not work properly (use --verbose for details),
~
~       play->elasticsearch {0.4}: missing artifact
~ *****************************************************************************
~
~ Some dependencies are still missing.
~
4

1 回答 1

0

您没有详细描述您的安装过程,但是您是否按照ElasticSearch 模块页面上的说明进行操作?

在本地安装模块后(显然您已成功完成此操作),您需要将其添加到项目dependencies.yml文件中:

require:
    - play -> elasticsearch {version}

然后,在命令提示符下,为您的项目执行play dependenciesplay eclipsify命令。转到 Eclipse,刷新您的工作区,您应该已经准备就绪。

于 2012-04-17T05:20:48.783 回答