No rules found post PMD upgraded to PMD 6.48 - apex

SEVERE: Cannot load ruleset D:\Program Files\Jenkins\workspace\Devops\TestWarningNextGen/rule/apex/ruleset.xml: Cannot resolve rule/ruleset reference 'category/apex/codestyle.xml/ClassNamingConventions'. Make sure the resource is a valid file or URL and is on the CLASSPATH. Use --debug (or a fine log level) to see the current classpath.
Sep 21, 2022 1:34:32 PM net.sourceforge.pmd.util.log.internal.SimpleMessageReporter logImpl
FINE: net.sourceforge.pmd.RuleSetNotFoundException: Cannot resolve rule/ruleset reference 'category/apex/codestyle.xml/ClassNamingConventions'. Make sure the resource is a valid file or URL and is on the CLASSPATH. Use --debug (or a fine log level) to see the current classpath.
at net.sourceforge.pmd.RuleSetReferenceId.getInputStream(RuleSetReferenceId.java:440)
at net.sourceforge.pmd.RuleSetFactory.parseRuleSetNode(RuleSetFactory.java:361)
at net.sourceforge.pmd.RuleSetFactory.createRuleSet(RuleSetFactory.java:234)
at net.sourceforge.pmd.RuleSetFactory.createRule(RuleSetFactory.java:342)
at net.sourceforge.pmd.RuleSetFactory.parseRuleReferenceNode(RuleSetFactory.java:690)
at net.sourceforge.pmd.RuleSetFactory.parseRuleNode(RuleSetFactory.java:505)
at net.sourceforge.pmd.RuleSetFactory.parseRuleSetNode(RuleSetFactory.java:409)
at net.sourceforge.pmd.RuleSetFactory.createRuleSet(RuleSetFactory.java:234)
at net.sourceforge.pmd.RuleSetFactory.createRuleSet(RuleSetFactory.java:229)
at net.sourceforge.pmd.RuleSetLoader.loadFromResource(RuleSetLoader.java:253)
at net.sourceforge.pmd.RuleSetLoader.loadFromResource(RuleSetLoader.java:153)
at net.sourceforge.pmd.RuleSetLoader.loadRuleSetsWithoutException(RuleSetLoader.java:203)
at net.sourceforge.pmd.PmdAnalysis.create(PmdAnalysis.java:122)
at net.sourceforge.pmd.PMD.doPMD(PMD.java:246)
at net.sourceforge.pmd.PMD.runPmd(PMD.java:504)
at net.sourceforge.pmd.PMD.runPmd(PMD.java:471)
at net.sourceforge.pmd.PMD.main(PMD.java:417)
Sep 21, 2022 1:34:32 PM net.sourceforge.pmd.util.log.internal.SimpleMessageReporter logImpl
WARNING: No rules found. Maybe you misspelled a rule name? (D:\Program Files\Jenkins\workspace\Devops\TestWarningNextGen/rule/apex/ruleset.xml)
+ exit 0

Related

Using Render hosting app to deploy my project- Error Cannot find module

Follows Heroku becoming a paid app, I am trying other options.
Does anyone have experience uploading a MongoDB server-based project to "Render" Application Hosting?
This is the repo I want to deploy:
https://github.com/myyoss/FUNDLE_A_WORDLE_CLONE
On the app settings I use for the Build Command: "yarn" (and it seems to works cause I get "Build successful" message).
But for the Start Command I can't get the correct command/path.
I keep getting this error:
==> Build successful :
Oct 7 06:41:33 PM ==> Deploying…
Oct 7 06:42:01 PM ==> Starting service with ‘node dist/server.js’
Oct 7 06:42:06 PM internal/modules/cjs/loader.js:888
Oct 7 06:42:06 PM throw err;
Oct 7 06:42:06 PM ^
Oct 7 06:42:06 PM
Oct 7 06:42:06 PM Error: Cannot find module ‘…/routes/userRoutes’
Can someone please take a look at the repo LINK and tell me what I'm doing wrong?
On an other project I used "node dist/server.js" for the Start Command and it worked just fine.
I think your problem may be here, where you use "../routes/userRoutes". You want to use "./routes/userRoutes" since the location of that file is relative to the root directory, ./
This answer may be helpful re: routing errors, and Render's quickstart for Node/Express is also worth a look.

Tomcat localhost failed to start

I was creating new servlet for my project and suddenly i can't run anymore on the tomcat server.
I try to open other project that that is finish and good but will also give the same error. try to create new server and it return the same error
Here is the error from console log
Dec 02, 2018 5:33:50 PM org.apache.tomcat.util.digester.SetPropertiesRule begin WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context}Setting property 'source' to 'org.eclipse.jst.jee.server:Test' did not find a matching property.
https://pastebin.com/6NpYR5tq
You are using the same mapping for two servlet, which of course is not allowed.
The servlets EventController and FeeController are both mapped to the url /EventController
Either check your design and rename the servlets mapping correct or Google servlet filter chain for another approach.
Show us your web.xml (you can generate one in eclipse if its missing)

FreeRadius 3.0.8 installation error of rlm_perl

I have installed freeradius 3.0.8 and I want to integrate or connect it with perl and for that I enter perl in /usr/local/etc/raddb/mods-available/perl and /usr/local/etc/raddb/sites-available/default is also edited as per instructions on http://wiki.freeradius.org/modules/Rlm_perl.
After entering radiusd -Xxx, I got the following error:
-Wed Jun 3 18:43:10 2015 : Error: /usr/local/etc/raddb/sites-enabled/default[477]: Failed to find "Perl" as a module or policy.
-Wed Jun 3 18:43:10 2015 : Error: /usr/local/etc/raddb/sites-enabled/default[477]: Please verify that the configuration exists in /usr/local/etc/raddb/mods-enabled/Perl.
-Wed Jun 3 18:43:10 2015 : Error: /usr/local/etc/raddb/sites-enabled/default[447]: Errors parsing authenticate section.
However, I also created symbolic link and the error pasted above is after creating symbolic link.
Please help me in resolving this issue.
It should be 'perl' not 'Perl' (you have the capitalisation wrong).

No output from the FIWARE complex event processing (CEP) engine

I am sending REST POST request to the FIWARE CEP and expecting output even in a file. But nothing in the file.
REST POST (Producer) -> CEP -> File Consumer
http://194.28.122.118:8080/ProtonOnWebServer/rest/events
{"Name":"TrafficReport", "volume":"9000"}
Catalina.out
Apr 3, 2015 4:54:19 PM com.ibm.hrl.proton.webapp.providers.EventJSONMessageReader readFrom
INFO: started event message body reader
Apr 3, 2015 4:54:19 PM com.ibm.hrl.proton.webapp.providers.EventJSONMessageReader readFrom
INFO: name value: TrafficReport looking for: Name
Apr 3, 2015 4:54:19 PM com.ibm.hrl.proton.webapp.providers.EventJSONMessageReader readFrom
INFO: finished event message body reader
Apr 3, 2015 4:54:19 PM com.ibm.hrl.proton.webapp.resources.EventResource submitNewEvent
INFO: starting submitNewEvent
Apr 3, 2015 4:54:19 PM com.ibm.hrl.proton.router.EventRouter routeTimedObject
INFO: routeTimedObject: forwarding event TrafficReport; Name=TrafficReport; Certainty=0.0; Cost=0.0; EventSource=; OccurrenceTime=null; Annotation=; Duration=0.0; volume=100000; EventId=f4aee2d0-2d4b-4c0c-a24f-ae452896fa75; ExpirationTime=null; Chronon=null; DetectionTime=1428072859603; to consumer...
Apr 3, 2015 4:54:19 PM com.ibm.hrl.proton.webapp.resources.EventResource submitNewEvent
INFO: events sent to proton runtime...
The reason might be that the path you specified as the Consumer's output file does not exist or that tomcat has no permission to write to this path or to write to the file you specified.
Look at the log file (logs/catalina.out) and see if you see a warning like:
WARNING: initializeAdapters: failed to initialize adapter Output adapter for consumer: DoSAttackTRConsumer, reason: No such file or directorycode here
I would also recommend to use an absolute path and not relative path for the output file path, since in different operating systems, the Tomcat "current" directory might be different.
You don't need to create the file, but you do need to create the directory and make sure tomcat has permission to write to this directory (or if the file exists to write to this file)
So here are my recommendation:
Stop tomcat
Delete catalina.out 
Activate tomcat
In the CEP web UI, change the path of the Consumers to an absolute path, save the project, export it to the repository
Make sure the path you specified for the Consumers exists, and that tomcat has permission to write to the directory, and if the file exist, to this file.
Change the status of the CEP engine to Stop
Change the status of the CEP engine to Start
Send an input event
Make sure you don't see the warning listed above in the catalina.out

Sessions not working in Sinatra app when packaged with warbler

I've created a simple sinatra app, but can't get sessions to work when running it as an executable war.
I've verified that it works when run via "jruby -S rackup", but when run with "java -jar myapp.war", I find that the session is reset on each request:
INFO: Winstone Servlet Engine v0.9.10 running: controlPort=disabled
session: {"session_id"=>"75936d3d21367f5c1896e749ba401d7715e41a5fd01317484faa44d80c8afaea", "csrf"=>"60367cb6c5ead39b2669668ed28db3a1", "tracking"=>{"
HTTP_USER_AGENT"=>"9f3d63482f1fb48a317c5c9e2de6196f9cd239cc", "HTTP_ACCEPT_LANGUAGE"=>"66eae971492938c2dcc2fb1ddc8d7ec3196037da"}}
Jul 20, 2014 8:00:20 PM winstone.Logger logInternal
INFO: 0:0:0:0:0:0:0:1 - [20/Jul/2014 20:00:20] "GET / " 200 765 0.1670
session: {"session_id"=>"19d266ffb8ccb29108464961e68fa9e29f1c3b45e0097806b4cbc8db156d71d7", "csrf"=>"5ac12991c2ec8d4acf22180d79c494c2", "tracking"=>{"
HTTP_USER_AGENT"=>"9f3d63482f1fb48a317c5c9e2de6196f9cd239cc", "HTTP_ACCEPT_LANGUAGE"=>"66eae971492938c2dcc2fb1ddc8d7ec3196037da"}, "name"=>"john"}
Jul 20, 2014 8:00:31 PM winstone.Logger logInternal
INFO: 0:0:0:0:0:0:0:1 - [20/Jul/2014 20:00:31] "GET /login/john " 200 9 0.0240
session: {"session_id"=>"60f161941822b4f0fae9085db58fe9ea30e86d56dc16fff2ea5859bb4008c58f", "csrf"=>"7dd3977bef9fca9c7ed9b77fdc774657", "tracking"=>{"
HTTP_USER_AGENT"=>"9f3d63482f1fb48a317c5c9e2de6196f9cd239cc", "HTTP_ACCEPT_LANGUAGE"=>"66eae971492938c2dcc2fb1ddc8d7ec3196037da"}}
Jul 20, 2014 8:00:40 PM winstone.Logger logInternal
Other than setting sessions to be enabled, is there any special setup that is needed to have sessions work when the app is packaged with warbler and run as an executable war?
nothing special should be needed - I tried your sample and it worked fine.
it's probably a bug with the jruby-rack version you're using ... please try >= 1.1.15
also I would recommend to try out the jetty webserver (you'll find an option at config/warbler.rb) ... I'll try to make sure jetty is the default for a future Warbler version.