20:15:43 [INFO] macintosh264 issued server command: /sell hand
20:15:43 [INFO] [XYZShop] MacCommand sell executed
20:15:43 [SEVERE] null
org.bukkit.command.CommandException: Unhandled exception executing command 'sell' in plugin XYZShop v0.1.3
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:46)
at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:186)
at org.bukkit.craftbukkit.v1_4_6.CraftServer.dispatchCommand(CraftServer.java:510)
at net.minecraft.server.v1_4_6.PlayerConnection.handleCommand(PlayerConnection.java:979)
at net.minecraft.server.v1_4_6.PlayerConnection.chat(PlayerConnection.java:897)
at net.minecraft.server.v1_4_6.PlayerConnection.a(PlayerConnection.java:852)
at net.minecraft.server.v1_4_6.Packet3Chat.handle(Packet3Chat.java:44)
at net.minecraft.server.v1_4_6.NetworkManager.b(NetworkManager.java:290)
at net.minecraft.server.v1_4_6.PlayerConnection.d(PlayerConnection.java:112)
at net.minecraft.server.v1_4_6.ServerConnection.b(SourceFile:39)
at net.minecraft.server.v1_4_6.DedicatedServerConnection.b(SourceFile:30)
at net.minecraft.server.v1_4_6.MinecraftServer.r(MinecraftServer.java:598)
at net.minecraft.server.v1_4_6.DedicatedServer.r(DedicatedServer.java:224)
at net.minecraft.server.v1_4_6.MinecraftServer.q(MinecraftServer.java:494)
at net.minecraft.server.v1_4_6.MinecraftServer.run(MinecraftServer.java:427)
at net.minecraft.server.v1_4_6.ThreadServerApplication.run(SourceFile:849)
Caused by: java.lang.NoSuchMethodError: dev.xyzcraft.net.database.DatabaseHandler.getItem(IS)Ldev/xyzcraft/net/xyzshop/dataObject/MSItem;
at dev.xyzcraft.net.xyzshop.commands.SellCommand.onCommand(SellCommand.java:63)
at dev.xyzcraft.net.xyzshop.util.MacCommand.onCommand(MacCommand.java:44)
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44)
... 15 more
I get that exception
here's the code:
https://github.com/macintosh264/XYZShop
Lastly, I'm using a Mod API for a popular video game, Minecraft, entitled Bukkit. Here's the JavaDoc, and library
http://dl.bukkit.org/downloads/bukkit/
http://jd.bukkit.org
"I also have this problem with another project that uses MySQL, and the stack trace occurs WHENEVER the mysql class is used. "
Macintosh264
It seems like whatever your trying to execute (i.e.the method that holds the command) isn't reading it properly. Try re-packaging your project, it's happened to me many times and that is usually an easy fix.
Related
I am running Java8 unit tests using the command mvn test -DskipITs=true on the multi-module maven project.
I am using this maven configuration
export MAVEN_OPTS="-Xmx4096M -Xss768M -XX:MetaspaceSize=640M -XX:MaxMetaspaceSize=2048M -XX:+CMSClassUnloadingEnabled"
prometheus:simpleclient:0.16.0
spring-boot:1.2.1.RELEASE
Since there are a lot of UTs, after an hour it starts throwing the below exception in between of UTs and after sometime, it keeps on throwing the exception and gets stuck:
java.lang.IllegalArgumentException: Failed to register Collector of type MicrometerCollector: jvm_gc_pause_seconds_count is already in use by another Collector of type MicrometerCollector
at io.prometheus.client.CollectorRegistry.register(CollectorRegistry.java:57)
at io.prometheus.client.Collector.register(Collector.java:307)
at io.micrometer.prometheus.PrometheusMeterRegistry.lambda$applyToCollector$17(PrometheusMeterRegistry.java:561)
at java.util.concurrent.ConcurrentHashMap.compute(ConcurrentHashMap.java:1853)
at io.micrometer.prometheus.PrometheusMeterRegistry.applyToCollector(PrometheusMeterRegistry.java:556)
at io.micrometer.prometheus.PrometheusMeterRegistry.newTimer(PrometheusMeterRegistry.java:322)
at io.micrometer.core.instrument.MeterRegistry.lambda$timer$2(MeterRegistry.java:318)
at io.micrometer.core.instrument.MeterRegistry.getOrCreateMeter(MeterRegistry.java:618)
at io.micrometer.core.instrument.MeterRegistry.registerMeterIfNecessary(MeterRegistry.java:570)
at io.micrometer.core.instrument.MeterRegistry.timer(MeterRegistry.java:316)
at io.micrometer.core.instrument.Timer$Builder.register(Timer.java:399)
at io.micrometer.core.instrument.composite.CompositeTimer.registerNewMeter(CompositeTimer.java:151)
at io.micrometer.core.instrument.composite.CompositeTimer.registerNewMeter(CompositeTimer.java:31)
at io.micrometer.core.instrument.composite.AbstractCompositeMeter.add(AbstractCompositeMeter.java:68)
at java.lang.Iterable.forEach(Iterable.java:75)
at java.util.Collections$SetFromMap.forEach(Collections.java:5530)
at io.micrometer.core.instrument.composite.CompositeMeterRegistry.lambda$new$0(CompositeMeterRegistry.java:67)
at io.micrometer.core.instrument.composite.CompositeMeterRegistry.lock(CompositeMeterRegistry.java:189)
at io.micrometer.core.instrument.composite.CompositeMeterRegistry.lambda$new$1(CompositeMeterRegistry.java:67)
at io.micrometer.core.instrument.MeterRegistry.getOrCreateMeter(MeterRegistry.java:627)
at io.micrometer.core.instrument.MeterRegistry.registerMeterIfNecessary(MeterRegistry.java:570)
at io.micrometer.core.instrument.MeterRegistry.timer(MeterRegistry.java:316)
at io.micrometer.core.instrument.Timer$Builder.register(Timer.java:399)
at io.micrometer.core.instrument.binder.jvm.JvmGcMetrics$GcMetricsNotificationListener.handleNotification(JvmGcMetrics.java:184)
at sun.management.NotificationEmitterSupport.sendNotification(NotificationEmitterSupport.java:156)
at sun.management.GarbageCollectorImpl.createGCNotification(GarbageCollectorImpl.java:143)
I am using db2 version 10.5 and inserting the values into the DB2JSON, created a simple standalone java program to retrieve all the values from the table(Collection) when I run the query I am getting the following error
Exception in thread "main" java.lang.RuntimeException: com.ibm.db2.jcc.am.SqlException: [jcc][t4][1065][12306][3.69.66] Caught java.io.CharConversionException. See attached Throwable for details. ERRORCODE=-4220, SQLSTATE=null
at com.ibm.nosql.json.api.DBObjectRowHandler.handle(DBObjectRowHandler.java:38)
at com.ibm.nosql.json.api.DBObjectRowHandler.handle(DBObjectRowHandler.java:14)
at com.ibm.nosql.json.api.BaseResultIterator.next(BaseResultIterator.java:119)
at com.ibm.nosql.json.api.DBCursor.fetchResultsEagerly(DBCursor.java:801)
at com.ibm.nosql.json.api.DBCursor.find(DBCursor.java:895)
at com.ibm.nosql.json.api.DBCursor.hasNext(DBCursor.java:278)
at com.ws.Demo.TestingDemo.main(TestingDemo.java:47)
Caused by: com.ibm.db2.jcc.am.SqlException: [jcc][t4][1065][12306][3.69.66] Caught java.io.CharConversionException. See attached Throwable for details. ERRORCODE=-4220, SQLSTATE=null
at com.ibm.db2.jcc.am.gd.a(gd.java:733)
at com.ibm.db2.jcc.am.gd.a(gd.java:66)
at com.ibm.db2.jcc.am.gd.a(gd.java:120)
at com.ibm.db2.jcc.am.kc.a(kc.java:2868)
at com.ibm.db2.jcc.am.kc.p(kc.java:525)
at com.ibm.db2.jcc.am.kc.Z(kc.java:2747)
at com.ibm.db2.jcc.am.ResultSet.getObjectX(ResultSet.java:1438)
at com.ibm.db2.jcc.am.ResultSet.getObject(ResultSet.java:1413)
at com.ibm.nosql.json.api.DBResultSet.getObject(DBResultSet.java:255)
at com.ibm.nosql.json.api.DBData.getObjectX(DBData.java:66)
at com.ibm.nosql.json.api.DBObjectRowHandler.getObjectID(DBObjectRowHandler.java:58)
at com.ibm.nosql.json.api.DBObjectRowHandler.handle(DBObjectRowHandler.java:28)
... 6 more
Caused by: java.nio.charset.MalformedInputException: Input length = 290
at com.ibm.db2.jcc.am.r.a(r.java:19)
at com.ibm.db2.jcc.am.kc.a(kc.java:2864)
... 14 more
Caused by: sun.io.MalformedInputException
at sun.io.ByteToCharUTF8.convert(ByteToCharUTF8.java:292)
at com.ibm.db2.jcc.am.r.a(r.java:16)
... 15 more
I also went throught few posts where it suggest to use db2.jcc.charsetDecoderEncoder=3 but I have no idea where to use it, and also I few other posts it is suggested touse the lastest version db2jcc.jar, I am using the jars that is present inside the db2 10.5 under sqllib folder. Anyone let me know how to fix this
Add the following environment variable(Java VM arguments) in your tomcat settings
-Ddb2.jcc.charsetDecoderEncoder=3
This worked.
You can set the charset decoder encoder using system property inside your Java code.
For example:
System.setProperty("db2.jcc.charsetDecoderEncoder", "3");
I found when all values are the same, the lm function throws errors. But it worked on GNU R. I am using the latest renjin-script-engine-0.8.1593.jar.
Any exception is thrown:
Caused by: org.renjin.eval.EvalException: contrasts can be applied only to factors with 2 or more levels
at org.renjin.primitives.Conditions.stop(Conditions.java:193)
at org.renjin.primitives.R$primitive$stop.doApply(R$primitive$stop.java:72)"
when I called RenjinScriptEngine.eval(..) with this script:
fit<-lm("formula"=vals~index,"data"=data)
The data of input is
"2015-36",9
"2015-37",9
"2015-41",9.
Renjin's goal is to be compatible with the latest version of GNU R. If you find a difference or encounter error like that above, please file a bug report at https://github.com/bedatadriven/renjin/issues. We're happy to have the test cases!
I just downloaded and setup the Apache James 3 latest beta release on Windows and so far i haven't been able to send a simple message. It looks like there is an issue with the build. The error is -
ERROR 22:45:01,666 | james.mailspooler | Exception processing mail while spooling Unable to process mail Mail1442234701295-757cd62b-eeed-4671-828c-2a7c715acfaa (org.apache.camel.CamelExecutionException: Exception occurred during execution on the exchange: Exchange[Message: org.apache.james.core.MailImpl#4262d5d7])
javax.mail.MessagingException: Unable to process mail Mail1442234701295-757cd62b-eeed-4671-828c-2a7c715acfaa (org.apache.camel.CamelExecutionException: Exception occurred during execution on the exchange: Exchange[Message: org.apache.james.core.MailImpl#4262d5d7])
.
.
Caused by: javax.mail.MessagingException: Unable to process mail Mail1442234701295-757cd62b-eeed-4671-828c-2a7c715acfaa (org.apache.camel.CamelExecutionException: Exception occurred during execution on the exchange: Exchange[Message: org.apache.james.core.MailImpl#4262d5d7])
.
.
Caused by: org.apache.camel.CamelExecutionException: Exception occurred during execution on the exchange: Exchange[Message: org.apache.james.core.MailImpl#4262d5d7]
.
.
Caused by: java.lang.NoSuchMethodError: org.apache.james.mime4j.stream.MimeConfig: method <init>()V not found
The relevant class in the JAR shows the supposedly missing constructor so i am at a complete loss. Can anyone guide me in the right direction please?
Thanks in advance!
Edit: Decompiled code snippet from the MimeConfig class shows the constructor
public final class MimeConfig {
/* member class not found */
class Builder {}
.
.
MimeConfig(boolean strictParsing, int maxLineLen, int maxHeaderCount, int maxHeaderLen, long maxContentLen, boolean countLineNumbers,
String headlessParsing, boolean malformedHeaderStartsBody) {
/* 53*/ this.strictParsing = strictParsing;
/* 54*/ this.countLineNumbers = countLineNumbers;
/* 55*/ this.malformedHeaderStartsBody = malformedHeaderStartsBody;
/* 56*/ this.maxLineLen = maxLineLen;
/* 57*/ this.maxHeaderCount = maxHeaderCount;
/* 58*/ this.maxHeaderLen = maxHeaderLen;
/* 59*/ this.maxContentLen = maxContentLen;
/* 60*/ this.headlessParsing = headlessParsing;
}
I got the same error and was searching for an answer. The error is because MimeConfig doesn't have a default constructor. I could get the mail successfully delivered locally by doing to following.
Dowloaded apache-mime4j-core-0.8.0-20150617.024907-738-sources
Created a default public constructor for MimeConfig
Initialized all the variables with values shown in the static class Builder constructor
Added setters for all the variables (Because I was getting NoSuchMethodError for setMaxLineLen)
Created a jar called apache-mime4j-0.8.0-fix.jar and pushed into the lib folder
I use run.sh, so replaced the mime4j core jar name with the above one.
I am sure there is some mismatch between spooler and mime4j. I think the calling code should use the Builder instead of directly trying to instantiate the MimeConfig.
Try these and let me know if it works. It worked for me. I am not sure if this is a permanent fix, but I can go ahead with exploring the V3 features till we get a permanent solution.
The solution is to use the : apache-mime4j-core-0.7.2.jar and apache-mime4j-dom-0.7.2.jar
download the two jars and put them in : james-server-app-3.0.0-beta5-SNAPSHOT\lib.
You can download james-server-app-3.0.0-beta5 from : https://repository.apache.org/content/repositories/snapshots/org/apache/james/james-server-app/3.0.0-beta5-SNAPSHOT/.
I have been using Apache CXF 2.7.0 for quite a while now, but recently I had to restructure my project in Eclipse. After I did that, for some reason, I cannot add a "WSAddressingFeature" Feature to the endpoint.
What am I missing??
endpoint.getFeatures().add(new org.apache.cxf.ws.addressing.WSAddressingFeature());
Eclipse is reporting that:
"The method add(Feature) in the type List<Feature> is not applicable for the arguments (WSAddressingFeature)"
This is my full implementation:
String url = "http://localhost:" + m_Port + "/infoburst/handler";
Object implementor = new HandlerImpl();
org.apache.cxf.jaxws.EndpointImpl endpoint = new org.apache.cxf.jaxws.EndpointImpl(implementor);
endpoint.getFeatures().add(new org.apache.cxf.ws.addressing.WSAddressingFeature());
endpoint.publish(url);
org.apache.cxf.endpoint.Server server = endpoint.getServer();
org.apache.cxf.jaxws.JaxWsServerFactoryBean serverFB = endpoint.getServerFactory();
If I remove the line of code that adds the feature, the following error occurs:
Exception in thread "main" java.lang.NoSuchMethodError: org.apache.cxf.common.util.ReflectionUtil.getDeclaredMethod(Ljava/lang/Class;Ljava/lang/String;[Ljava/lang/Class;)Ljava/lang/reflect/Method;
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.bindOperation(JaxWsServiceFactoryBean.java:276)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.createOperation(ReflectionServiceFactoryBean.java:1045)
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.createOperation(JaxWsServiceFactoryBean.java:642)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.createInterface(ReflectionServiceFactoryBean.java:990)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFromClass(ReflectionServiceFactoryBean.java:481)
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.buildServiceFromClass(JaxWsServiceFactoryBean.java:704)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServiceModel(ReflectionServiceFactoryBean.java:550)
at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(ReflectionServiceFactoryBean.java:265)
at org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServiceFactoryBean.java:215)
at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:102)
at org.apache.cxf.frontend.ServerFactoryBean.create(ServerFactoryBean.java:159)
at org.apache.cxf.jaxws.JaxWsServerFactoryBean.create(JaxWsServerFactoryBean.java:211)
at org.apache.cxf.jaxws.EndpointImpl.getServer(EndpointImpl.java:456)
at org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:334)
at org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:251)
at org.apache.cxf.jaxws.spi.ProviderImpl.createAndPublishEndpoint(ProviderImpl.java:155)
at javax.xml.ws.Endpoint.publish(Unknown Source)
at com.infosol.infoburst.XI4Service.HandlerService.publish(HandlerService.java:106)
at com.infosol.infoburst.XI4Service.HandlerService.main(HandlerService.java:42)
This is why I really don't enjoy working in the Java environment...
To fix the ""The method add(Feature) in the type List is not applicable for the arguments (WSAddressingFeature)" error:
Go into "Configure Build Path"
Go to "Order and Export"
Move the "cfx-2.7.0.jar" file to a higher priority, this may take a little trial and error.
Once the CFX file is moved up in priority, the error will go away.