0

尝试使用gradle appengine 插件升级到 Google Cloud Endpoints 2.0 时,我遇到了配置冲突endpoints。Gradle 报错:

Error:Cannot add a configuration with name 'endpoints' as a configuration with that name already exists.

切换到较新的appengine gradle 插件可以避免这个问题,除了它 (1) 不支持 Android Studio,(2) 并且具有糟糕的 JDO 支持(升级文档)。

有没有人可以将旧插件与 Google Cloud Endpoints 2.0 一起使用?

4

1 回答 1

2

出现问题是因为 V2endpoints-framework-gradle-plugingradle-appengine-plugin两者都包含名为endpoints. 删除 V2 插件不起作用,因为该gradle-appengine-plugin版本不支持 V2 Cloud Endpoints。

最后,我不得不按照Android upgrade doc中的建议迁移到新的 appengine gradle 插件。这需要从命令行构建和部署以及处理 JDO 的自定义任务,但除此之外工作正常。

于 2017-08-08T12:24:58.143 回答