After some patching activity on my server, now i am not able to run any of conf file below is the error I am new to it not able to resolve it:
you might need to reinstall the gem which depends on the missing jar or in case there is Jars.lock then resolve the jars with `lock_jars` com
mand
no such file to load -- org/apache/logging/log4j/log4j-core/2.6.2/log4j-core-2.6.2 (LoadError)
do_require at /kibana/logstash-6.1.1/vendor/bundle/jruby/2.3.0/gems/jar-dependencies-0.3.11/lib/jar_dependencies.rb:348
block in require_jar at /kibana/logstash-6.1.1/vendor/bundle/jruby/2.3.0/gems/jar-dependencies-0.3.11/lib/jar_dependencies.rb:255
require_jar_with_block at /kibana/logstash-6.1.1/vendor/bundle/jruby/2.3.0/gems/jar-dependencies-0.3.11/lib/jar_dependencies.rb:297
require_jar at /kibana/logstash-6.1.1/vendor/bundle/jruby/2.3.0/gems/jar-dependencies-0.3.11/lib/jar_dependencies.rb:254
require_jar at /kibana/logstash-6.1.1/lib/bootstrap/patches/jar_dependencies.rb:6
<main> at /kibana/logstash-6.1.1/logstash-core/lib/logstash-core_jars.rb:18
require at org/jruby/RubyKernel.java:955
<main> at /kibana/logstash-6.1.1/logstash-core/lib/logstash-core/logstash-core.rb:1
require at org/jruby/RubyKernel.java:955
<main> at /kibana/logstash-6.1.1/logstash-core/lib/logstash-core/logstash-core.rb:8
require at org/jruby/RubyKernel.java:955
<main> at /kibana/logstash-6.1.1/lib/bootstrap/environment.rb:66
Related
We are having a module which contains log4j.properties and other files in it. And there is a separate module which is dependent on the 1st module(Realign). So we had made the 1st module as a jar file and placed it in the WEB-INF/lib folder of the second module(Reasign). We are running the modules in Liberty server. But still we are getting the File Not found exception as below,
log4j:ERROR Could not read configuration file
[file:/metlife/runtime/installed/wlp/usr/servers/bobr/apps/expanded/bobr.ear/BOBReassignmentWeb.war/WEB-INF/lib/Realignment.jar!/r_resources/log4j.properties].
[9/12/18 8:28:51:591 EDT] 000002de SystemErr R java.io.FileNotFoundException:
file:/metlife/runtime/installed/wlp/usr/servers/bobr/apps/expanded/bobr.ear/BOBReassignmentWeb.war/WEB-INF/lib/Realignment.jar!/r_resources/log4j.properties (No such file or directory)
It looks like your PropertiesConfigurator class is taking a file path (as a String). If you used a URL instead, I think that would work - that way, you would get a JAR URL which includes the path to the JAR (or WAR, EAR, etc.) archive and the path inside the JAR. If you have control over the PropertiesConfigurator code, then I would recommend changing it so that it loads the file via URL.
If that is not an option, then you could extract the properties files and put them on the file system directly. For example, you could create a directory in your server directory (for an example, we'll call it log4jProps). Then you could create a shared library in your server config (server.xml) like this:
<library id="log4j.props">
<fileset dir="${server.config.dir}/log4jProps" includes="r_resources/*properties"/>
</library>
then update your application configuration to use this library as a common shared library:
<application id="myApp" name="myApp" location="myApp.war"...>
<classloader commonLibraryRef ="log4j.props" />
</application>
For good measure, you should probably remove the properties file from your application archives - that way they won't be loaded from there, and then throw off the PropertiesConfigurator like it is now.
Hope this helps,
Andy
In my project (myProject) I use an external jar (external.jar). Both of them make logging with log4j.jar . With the help of log4j.properties file (located in myProject) I can configure logging from myProject. How can I configurate log levels of logging from the the external.jar without changing that jar file ?
Simpy adding package from external.jar ( let say org.external) in property file
log4j.logger.org.external=ERROR does not make any difference.
Here I have found the salution.
I have some code which I am running in debug mode. As I understand it, this runs it through the standard node.js debugger.
I'm frequently getting the following:
...
break in timers.js:77
...
Sometimes I have breakpoints at other files, but they always give absolute file paths, but in this case its just the file name. I cannot find a file with that name which has the content listed on line 77, nor can I find an explanation of how the debugger works in regards to this.
How can I find this timers.js file?
Generally, when you see filenames with no path in the debugger, it means that the file is one of the core libraries that are compiled in to the node binary.
If you want to dig in to source, make sure you're looking at the git tag that matches the version of node you're running.
The builtin files are:
assert.js
buffer.js
child_process.js
cluster.js
console.js
constants.js
crypto.js
dgram.js
dns.js
domain.js
events.js
freelist.js
fs.js
http.js
https.js
module.js
net.js
os.js
path.js
punycode.js
querystring.js
readline.js
repl.js
smalloc.js
stream.js
string_decoder.js
sys.js
timers.js
tls.js
tty.js
url.js
util.js
vm.js
zlib.js
When we use
spark-submit
which directory contains third party libraries that will be loaded on each of the slaves? I would like to scp one or more libraries to each of the slaves instead of shipping the contents in the application uber-jar.
Note: I did try adding to
$SPARK_HOME/lib_managed/jars
But the spark-submit still results in a ClassNotFoundException for classes included in the added library.
Hope these points will help you.
$SPARK_HOME/lib/ [contains the jar files ]
$SPARK_HOME/bin/ [contains the launch scripts - Spark-Submit,Spark-Class,pySpark,compute-classpath.sh etc]
Spark-Submit ---will call ---> Spark-Class.
Spark-class internally calls compute-Classpath.sh before executing / launching the job.
compute-Classpath.sh will pick the jars availble in $SPARK_HOME/lib to CLASSPATH.
(execute ./compute-classpath.sh //returns jars in lib dir)
So try these options.
option-1 - Placing user-specific-jars in $SPARK_HOME/lib/ will works
option-2 - Tweak compute-classpath.sh so that it will be able to pic
your jars specified in a user specific jars dir
This is what I have currently:
sys.exit(git_hook(complexity=COMPLEXITY, strict=STRICT, ignore='W801,E128,E501,W402,F403'))
But it's complaining about django south migration files, so I want to exclude the migration files, my immediate guess was:
sys.exit(git_hook(complexity=COMPLEXITY, strict=STRICT, ignore='W801,E128,E501,W402,F403', exclude='migrations'))
but getting this error:
TypeError: git_hook() got an unexpected keyword argument 'exclude'
Go through the source code there is no such argument for me to use...
def git_hook(complexity=-1, strict=False, ignore=None, lazy=False):
Is there a way for me to exclude some files?
All I have to do is create the configuration file in ~/.config/flake8:
http://flake8.readthedocs.org/en/latest/config.html
or in project level create tox.ini.