Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[普通模式]点击[拉取方法]时报错 #6

Open
ZhangKe4042602 opened this issue May 7, 2019 · 3 comments
Open

[普通模式]点击[拉取方法]时报错 #6

ZhangKe4042602 opened this issue May 7, 2019 · 3 comments

Comments

@ZhangKe4042602
Copy link

错误信息:occur an error when get methods : can't found the interface from classpath, please add the dependency first.
过程描述:
版本1.1.0
1,把deploy下面的pom.xml文件拷贝到/app/doe路径下。
2,将打包的api-1.0-RELEASE.jar dubbo-doe.jar 拷贝到/app/doe/lib下
3,在【新增依赖】中添加了依赖,但是解析完成后在/app/doe/lib下面没有见到下载到的jar

@ZhangKe4042602
Copy link
Author

我的使用MAC OS 电脑调试的,发现在判断时只判断了Linux和Windows。我修改后继续调试。在执行maven 命令begin to exec the command /bin/bash -c mvn dependency:copy-dependencies -DoutputDirectory=/app/doe/lib/ -DincludeScope=compile -f /app/doe/pom.xml;
错误信息是:

[WARNING]
[WARNING] Some problems were encountered while building the effective settings
[WARNING]
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.056 s
[INFO] Finished at: 2019-05-08T09:59:47+08:00
[INFO] ------------------------------------------------------------------------
[ERROR] No goals have been specified for this build. You must specify a valid lifecycle phase or a goal in the format : or :[:]:. Available lifecycle phases are: validate, initialize, generate-sources, process-sources, generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources, generate-test-resources, process-test-resources, test-compile, process-test-classes, test, prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify, install, deploy, pre-clean, clean, post-clean, pre-site, site, post-site, site-deploy. -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/NoGoalSpecifiedException

感觉是/app/doe/pom.xml文件中的 copy-dependencies的问题

compile


maven-dependency-plugin


process-sources

                        <goals>
                            <goal>copy-dependencies</goal>
                        </goals>

                        <configuration>
                            <outputDirectory>/app/doe/lib</outputDirectory>
                        </configuration>
                    </execution>
                </executions>
        </plugin>
    </plugins>
</build>

@VIPJoey
Copy link
Owner

VIPJoey commented May 8, 2019

错误信息:occur an error when get methods : can't found the interface from classpath, please add the dependency first.
过程描述:
版本1.1.0
1,把deploy下面的pom.xml文件拷贝到/app/doe路径下。
2,将打包的api-1.0-RELEASE.jar dubbo-doe.jar 拷贝到/app/doe/lib下
3,在【新增依赖】中添加了依赖,但是解析完成后在/app/doe/lib下面没有见到下载到的jar

这里的确没有判断MAC OS的,等我有空了,加一下手工上传jar的功能吧~
你也可以自己拷贝需要的 jar到 /app/doe/lib 目录

@ZhangKe4042602
Copy link
Author

我今天找了下报错的原因,是在执行Linux maven命令时只能在/app/doe下,也就是pom.xml下执行才可以。我已经把/app/doe添加到环境变量中了还是报错。在/app/doe下执行就可以。明天再找下原因吧。感觉这个工具还是挺方便的,十分感谢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants