classpath

Best way to override MATLAB's default static javaclasspath

感情迁移 提交于 2019-12-20 18:45:08
问题 MATLAB is configured to search its static java class path before searching the user-modifiable dynamic path. Unfortunately, the static path contains quite a number of very old public libraries, so if you are trying to use a new version you may end up loading the wrong implementation and get errors. For instance, the static path contains an old copy of the google-collections.jar, which has long been supplanted by Google's guava library and which has some of the same class names (e.g. com

Error when start Solr cloud, due to location of 3rd party libraries

半腔热情 提交于 2019-12-20 15:12:36
问题 I tried to migrate to Solr 3.1 , my project uses Dataimport handler , when I started solr it asked me SolrCoreAwar not found I copied the following file to lib directory apache-solr-dataimporthandler-3.1-SNAPSHOT.jar but again an error appeared when stating solr I need to fix this problem , if you can help Thank You The next message is the exception I get When Starting Solr 3.1 java.lang.NoClassDefFoundError: Could not initialize class org.slf4j.LoggerFactory at org.apache.solr.handler

Error when start Solr cloud, due to location of 3rd party libraries

醉酒当歌 提交于 2019-12-20 15:11:27
问题 I tried to migrate to Solr 3.1 , my project uses Dataimport handler , when I started solr it asked me SolrCoreAwar not found I copied the following file to lib directory apache-solr-dataimporthandler-3.1-SNAPSHOT.jar but again an error appeared when stating solr I need to fix this problem , if you can help Thank You The next message is the exception I get When Starting Solr 3.1 java.lang.NoClassDefFoundError: Could not initialize class org.slf4j.LoggerFactory at org.apache.solr.handler

Finding all CLASSPATH resources matching a pattern

本小妞迷上赌 提交于 2019-12-20 12:59:54
问题 I want to read a bunch of text files, by loading them as resources using the context classloader. URL url = Thread.currentThread() .getContextClassLoader() .getResource("folder/foo.txt"); Is there some way to get a list of resources whose names match a given pattern? For eg: URL[] matchingUrls = someLibrary.getMatchingResources("folder/*.txt"); Libraries like Spring can scan the classpath to find classes with a given annotation, so I am wondering if there something similar to load a bunch of

Including JAR files in Eclipse (App Engine) project

风流意气都作罢 提交于 2019-12-20 11:37:31
问题 I have been searching for a solution for this issue for multiple hours today and many hours yesterday so I decided to address it here, although it seems a stupid issue. Situation: I have a Google AppEngine project setup in Eclipse Java EE. It's there for multiple weeks everything runs fine, I can deploy to App Engine and test in Eclipse without probs. Now I need to add JAR packages for f.e. JSON support and Google Visualization API. I tried JSON a week ago and because it failed, I just

Including JAR files in Eclipse (App Engine) project

倾然丶 夕夏残阳落幕 提交于 2019-12-20 11:37:01
问题 I have been searching for a solution for this issue for multiple hours today and many hours yesterday so I decided to address it here, although it seems a stupid issue. Situation: I have a Google AppEngine project setup in Eclipse Java EE. It's there for multiple weeks everything runs fine, I can deploy to App Engine and test in Eclipse without probs. Now I need to add JAR packages for f.e. JSON support and Google Visualization API. I tried JSON a week ago and because it failed, I just

Missing .classpath file in Eclipse project

白昼怎懂夜的黑 提交于 2019-12-20 10:33:17
问题 I have recently returned to a project after not using it for a couple of weeks. The project was not created in Eclipse it was imported, and there is no '.classpath' file in the project workspace. I am sure that previously I successfully added new .jar files by simply right clicking them and going to 'Add to build path', but thanks to an unrelated error I had to re-add the files to the build path, and now whenever I try to add a new .jar file I get the following error: Error while adding a

Is the Java classpath final after JVM startup?

有些话、适合烂在心里 提交于 2019-12-20 10:13:42
问题 I have read a lot about the Java class loading process lately. Often I came across texts that claimed that it is not possible to add classes to the classpath during runtime and load them without class loader hackery (URLClassLoaders etc.) As far as I know classes are loaded dynamically. That means their bytecode representation is only loaded and transformed to a java.lang.Class object when needed. So shouldn't it be possible to add a JAR or *.class file to the classpath after the JVM started

Overriding default hadoop jars in class path

梦想与她 提交于 2019-12-20 09:55:40
问题 I've seen many manifestations of ways to use the user class path as precedent to the hadoop one. Often times this is done if an m/r job needs a specific version of a library that hadoop coincidentally already uses an older version of (for example jackson's json parser or commons http , etc.) In any case : I've seen : mapreduce.task.classpath.user.precedence mapreduce.task.classpath.first mapreduce.job.user.classpath.first Which one of these parameters is the right one to set in my job

executing java -jar via classpath vs in the jar file dir

南笙酒味 提交于 2019-12-20 07:26:08
问题 After having used NetBeans to create a Java program call it Addition and then having successfully cleaned and built an Executable Jar File in a folder c:\Users\Ben\Doc\NetBeansProjects\Addition\dist WHY is it that when executing, from command prompt, c:\Users\Ben Java -Jar -cp "c:\Users\Ben\Doc\NetBeansProjects\Addition\dist" Addition.jar it does NOT work (i get 'unable to access jarfile Addition.jar) BUT if i use cd to change my current dir to c:\Users\Ben\Doc\NetBeansProjects\Addition\dist