简体   繁体   English

应用服务器提供的罐子是什么?

[英]What are the jars provided by an application server?

I am switching my build chain from the one provided by Eclipse to Gradle. 我正在将构建链从Eclipse提供的链切换到Gradle。 When I develop a web application in Eclipse, I used to add a particular server runtime, so to have the jars provided by the application server already in the classpath. 当我在Eclipse中开发Web应用程序时,我曾经添加一个特定的服务器运行时,以使应用程序服务器提供的jar已存在于类路径中。

Now that I am swtiching to Gradle, how do I know what are the jars provided from the application server and which must consequently indicated as providedCompile instead of compile ? 现在,我要swtiching摇篮,我怎么知道什么是从应用服务器提供的罐子以及必须因此表示为providedCompile而不是编译

This might help you. 这可能对您有帮助。 in essence, you'll need the 'war' gradle plugin: https://gesellix.net/providedcompile-and-compile-dependencies-with-gradle/ 本质上,您将需要“战争” gradle插件: https ://gesellix.net/providedcompile-and-compile-dependencies-with-gradle/

It would depend on your app server: they all come with different JARs (obviously stuff like Servlet etc being provided by all) 这将取决于您的应用服务器:它们都带有不同的JAR(显然,所有人都提供Servlet等之类的东西)

You could remove the Server Runtime from your Eclipse classpath and see what breaks? 您可以从Eclipse类路径中删除服务器运行时,看看有什么坏处?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在Websphere中查找所有提供的jar - Find all provided jars in Websphere 罐子应该“提供”依赖吗? - Should jars have “provided” dependencies? restlet:在同一Web应用程序中使用Server和Client restlet Jars - restlet: Using Server and Client restlet Jars in same web application 查找tomcat6中特定应用程序的类加载器中的jar - Finding what jars are in the classloader for a specific application in tomcat6 在独立应用中使用弹簧所需的最小罐子是多少? - What are the minimum jars needed for spring to be used in a standalone application? 使用在另一个应用程序服务器中部署的应用程序服务器Java EE jars编译的类 - Class compiled using an application server Java EE jars deployed in another application server 范围“提供”不会在类路径中添加jar - scope “provided” does not add in jars in classpath 覆盖应用程序服务器行为,以便在打包的Web应用程序中加载jsp-api和servlet-api jar - Overriding application server behaviour for loading jsp-api and servlet-api jars in a packaged web application 应用程序在打印堆栈跟踪时提供未捕获的异常处理程序的作用是什么? - What is the role of an application provided uncaught exception handler in printing the stack trace? 更换tc服务器中的jar - Replacing jars in tc server
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM