Ext GWT 2.2.1 and GWT 2.1.1 - gxt

I am trying to use Ext GWT 2.0 to build an AJAX based web application. I ran into a snag while trying to use the GXT BeanModel classes.
In essence I am attempting to use the BeanModelMarker along the #BEAN annotation to define a BeanModel object.
At compilation time, I get the following error:
[ERROR] Class com.extjs.gxt.ui.client.data.BeanModelLookup not found.
[java] com.google.gwt.core.ext.typeinfo.NotFoundException: [JAVA BEAN CLASS NAME HERE]
[java] at com.google.gwt.core.ext.typeinfo.TypeOracle.getType(TypeOracle.java:534)
[java] at com.extjs.gxt.ui.rebind.core.BeanModelGenerator.getMarkerBean(BeanModelGenerator.java:188)
[java] at com.extjs.gxt.ui.rebind.core.BeanModelGenerator.generate(BeanModelGenerator.java:55)
[java] at com.google.gwt.dev.javac.StandardGeneratorContext.runGenerator(StandardGeneratorContext.java:427)
[java] at com.google.gwt.dev.cfg.RuleGenerateWith.realize(RuleGenerateWith.java:39)
[java] at com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.tryRebind(StandardRebindOracle.java:115)
[java] at com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.rebind(StandardRebindOracle.java:58)
[java] at com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.java:161)
[java] at com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.java:150)
[java] at com.google.gwt.dev.Precompile$DistillerRebindPermutationOracle.getAllPossibleRebindAnswers(Precompile.java:345)
[java] at com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.doFindAdditionalTypesUsingRebinds(WebModeCompilerFrontEnd.java:106)
[java] at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox$CompilerImpl.process(AbstractCompiler.java:254)
[java] at org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:444)
[java] at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox$CompilerImpl.compile(AbstractCompiler.java:175)
[java] at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox$CompilerImpl.compile(AbstractCompiler.java:288)
[java] at com.google.gwt.dev.jdt.AbstractCompiler$Sandbox$CompilerImpl.access$400(AbstractCompiler.java:145)
[java] at com.google.gwt.dev.jdt.AbstractCompiler.compile(AbstractCompiler.java:632)
[java] at com.google.gwt.dev.jdt.BasicWebModeCompiler.getCompilationUnitDeclarations(BasicWebModeCompiler.java:124)
[java] at com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.getCompilationUnitDeclarations(WebModeCompilerFrontEnd.java:54)
[java] at com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.precompile(JavaToJavaScriptCompiler.java:484)
[java] at com.google.gwt.dev.jjs.JavaScriptCompiler.precompile(JavaScriptCompiler.java:32)
[java] at com.google.gwt.dev.Precompile.precompile(Precompile.java:545)
[java] at com.google.gwt.dev.Precompile.precompile(Precompile.java:466)
[java] at com.google.gwt.dev.Compiler.run(Compiler.java:205)
[java] at com.google.gwt.dev.Compiler.run(Compiler.java:177)
[java] at com.google.gwt.dev.Compiler$1.run(Compiler.java:149)
[java] at com.google.gwt.dev.CompileTaskRunner.doRun(CompileTaskRunner.java:87)
[java] at com.google.gwt.dev.CompileTaskRunner.runWithAppropriateLogger(CompileTaskRunner.java:81)
[java] at com.google.gwt.dev.Compiler.main(Compiler.java:156)
[java] [ERROR] Errors in 'jar:[FILE PATH]/gxt.jar!/com/extjs/gxt/ui/client/data/BeanModelLookup.java'
[java] [ERROR] Line 34: Failed to resolve 'com.extjs.gxt.ui.client.data.BeanModelLookup' via deferred binding
[java] [ERROR] Cannot proceed due to previous errors

Need to add source path to gwt.xml

Related

javax.faces.FacesException: Class org.jboss.as.jsf.injection.JandexAnnotationProvider is not an instance of com.sun.faces.spi.AnnotationProvider

I using: Maven 3.3.1, Java SE 1.8, JavaServerFaces 2.2, JPA 2.0, Spring 4.1.6, Hibernate 4.3.2.Final and Wildfly.
I'm new to J2EE, please give me detailed instructions.
My stacktrace:
09:52:31,461 SEVERE [javax.enterprise.resource.webcontainer.jsf.config] (MSC service thread 1-4) Critical error during deployment: : com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! Class org.jboss.as.jsf.injection.JandexAnnotationProvider is not an instance of com.sun.faces.spi.AnnotationProvider
at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:357) [javax.faces-2.0.10.jar:2.0.10-SNAPSHOT]
at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:220) [javax.faces-2.0.10.jar:2.0.10-SNAPSHOT]
at io.undertow.servlet.core.ApplicationListeners.contextInitialized(ApplicationListeners.java:173) [undertow-servlet-1.1.0.Final.jar:1.1.0.Final]
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:193) [undertow-servlet-1.1.0.Final.jar:1.1.0.Final]
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.startContext(UndertowDeploymentService.java:87)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.start(UndertowDeploymentService.java:72)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_75]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_75]
at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_75]
Caused by: javax.faces.FacesException: Class org.jboss.as.jsf.injection.JandexAnnotationProvider is not an instance of com.sun.faces.spi.AnnotationProvider
at com.sun.faces.spi.AnnotationProviderFactory.createAnnotationProvider(AnnotationProviderFactory.java:78) [javax.faces-2.0.10.jar:2.0.10-SNAPSHOT]
at com.sun.faces.config.ConfigManager$AnnotationScanTask.<init>(ConfigManager.java:752) [javax.faces-2.0.10.jar:2.0.10-SNAPSHOT]
at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:330) [javax.faces-2.0.10.jar:2.0.10-SNAPSHOT]
... 10 more
09:52:31,472 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-4) MSC000001: Failed to start service jboss.undertow.deployment.default-server.default-host./Ear_Project: org.jboss.msc.service.StartException in service jboss.undertow.deployment.default-server.default-host./Ear_Project: Failed to start service
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1904) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_75]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_75]
at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_75]
Caused by: java.lang.RuntimeException: java.lang.RuntimeException: com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! Class org.jboss.as.jsf.injection.JandexAnnotationProvider is not an instance of com.sun.faces.spi.AnnotationProvider
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:222)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.startContext(UndertowDeploymentService.java:87)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.start(UndertowDeploymentService.java:72)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881) [jboss-msc-1.2.2.Final.jar:1.2.2.Final]
... 3 more
Caused by: java.lang.RuntimeException: com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! Class org.jboss.as.jsf.injection.JandexAnnotationProvider is not an instance of com.sun.faces.spi.AnnotationProvider
at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:287)
at io.undertow.servlet.core.ApplicationListeners.contextInitialized(ApplicationListeners.java:173)
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:193)
... 7 more
Caused by: com.sun.faces.config.ConfigurationException: CONFIGURATION FAILED! Class org.jboss.as.jsf.injection.JandexAnnotationProvider is not an instance of com.sun.faces.spi.AnnotationProvider
at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:357)
at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:220)
... 9 more
Caused by: javax.faces.FacesException: Class org.jboss.as.jsf.injection.JandexAnnotationProvider is not an instance of com.sun.faces.spi.AnnotationProvider
at com.sun.faces.spi.AnnotationProviderFactory.createAnnotationProvider(AnnotationProviderFactory.java:78)
at com.sun.faces.config.ConfigManager$AnnotationScanTask.<init>(ConfigManager.java:752)
at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:330)
... 10 more
JandexAnnotationProvider in fact extends from AnnotationProvider class and such error may be caused if both classes are loaded via different classloaders.
I think you have to exclude your jsf-api-???.jar and jsf-impl-???.jar from beeing deployed with your application. Use jsf libraries, provided by application server.
To achieve it with maven, just set <scope>provided</scope> to the jsf-api and jsf-impl dependencies in your pom.xml

Liferay 6.2: SassToCssBuilder has got NullPointerException,

Now, I have problem when I build portlet to war file in eclipse.
Env:
- liferay-plugins-sdk-6.2.0
- liferay-portal-6.2-ce-ga2
Issue: use eclipse to build the portlet to war file successfully, but I have the error:
build-css:
[java] Loading jar:file:/home/tomcat-7.0.53/webapps/ROOT/WEB-INF/lib/portal-impl.jar!/system.properties
[java] Loading jar:file:/home/tomcat-7.0.53/webapps/ROOT/WEB-INF/lib/portal-impl.jar!/portal.properties
[java] java.lang.NullPointerException
[java] at com.liferay.portal.tools.SassToCssBuilder._parseSassDirectory(SassToCssBuilder.java:222)
[java] at com.liferay.portal.tools.SassToCssBuilder.(SassToCssBuilder.java:144)
[java] at com.liferay.portal.tools.SassToCssBuilder.main(SassToCssBuilder.java:94)
Please, give me any suggestion to fix this problem!
I am waiting for all you help!
Thanks and Kind Regards,
I have found the root cause is the Tomcat-server that I changed. So, I have to use the tomcat-server of Liferay to build the portlet to pass that error.
Regards,
Try to comment out the goal build-css as mentioned here enter link description here
we want to just forward that request to the CSSBuilderMojo and not require the invoking from jars in portal directory
<plugin>
<groupId>com.liferay.maven.plugins</groupId>
<artifactId>liferay-maven-plugin</artifactId>
<version>${liferay.maven.plugin.version}</version>
<executions>
<!--<execution>-->
<!--<phase>generate-sources</phase>-->
<!--<goals>-->
<!--<goal>build-css</goal>-->
<!--</goals>-->
<!--</execution>-->
</executions>
</plugin>

SSLHandshakeException using t3s weblogic

I have done t3s setting and configured it. Now when I try to make a call getting below exception. Please help guys.
Have tried the url mentioned steps Enterprise Software Development with Java: WebLogic Server SSL (https/t3s) and Java Web Start
As well as below code inclusion as per the Configuring Transport-Level Security
System.setProperty("weblogic.security.SSL.ignoreHostnameVerification","true");
System.setProperty("java.protocol.handler.pkgs", "weblogic.net");
System.setProperty("weblogic.security.TrustKeyStore","CustomTrust");
System.setProperty("weblogic.security.CustomTrustKeyStoreFileName","TRUST_STORE_LOCATION");
System.setProperty("weblogic.security.CustomTrustKeyStorePassPhrase","TRUST_STORE_PASSWORD");
System.setProperty("weblogic.security.CustomTrustKeyStoreType","JKS");
Exception :
[java] <Feb 25, 2014 1:14:22 AM EST> <Info> <Security> <BEA-090905> <Disabling the CryptoJ JCE Provider self-integrity check for better startup performance. To enable this check, specify -Dweblogic.security.allowCryptoJDefaultJCEVerification=true.>
[java] <Feb 25, 2014 1:14:22 AM EST> <Info> <Security> <BEA-090906> <Changing the default Random Number Generator in RSA CryptoJ from ECDRBG to FIPS186PRNG. To disable this change, specify -Dweblogic.security.allowCryptoJDefaultPRNG=true.>
[java] <Feb 25, 2014 1:14:22 AM EST> <Info> <Security> <BEA-090908> <Using the default WebLogic SSL Hostname Verifier implementation.>
[java]
[java] TYPE_PARAM = ERROR
[java] CODE_PARAM = null
[java] MESSAGE_PARAM = null
[java]
[java]
[java] at junit.extensions.jfunc.SALQATestCase.runBare(SALQATestCase.java:111)
[java] at junit.extensions.jfunc.SALQATestCase$1.protect(SALQATestCase.java:96)
[java] at junit.framework.TestResult.runProtected(TestResult.java:124)
[java] at junit.extensions.jfunc.SALQATestCase.run(SALQATestCase.java:99)
[java] at junit.framework.TestSuite.runTest(TestSuite.java:208)
[java] at junit.framework.TestSuite.run(TestSuite.java:203)
[java] at junit.extensions.jfunc.textui.SALQARunner.doRun(SALQARunner.java:69)
[java] at junit.extensions.jfunc.textui.SALQARunner.run(SALQARunner.java:314)
[java] Caused by: javax.naming.CommunicationException [Root exception is java.net.ConnectException: t3s://xxxxxxxxxx.com:7002: Destination xx.xx.xx.xx, 7002 unreachable; nested exception is:
[java] javax.net.ssl.SSLHandshakeException: General SSLEngine problem; No available router to destination]
[java] at weblogic.jndi.internal.ExceptionTranslator.toNamingException(ExceptionTranslator.java:40)
[java] at weblogic.jndi.WLInitialContextFactoryDelegate.toNamingException(WLInitialContextFactoryDelegate.java:808)
[java] at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialContextFactoryDelegate.java:363)
[java] at weblogic.jndi.Environment.getContext(Environment.java:319)
[java] at weblogic.jndi.Environment.getContext(Environment.java:288)
[java] at weblogic.jndi.WLInitialContextFactory.getInitialContext(WLInitialContextFactory.java:117)
[java] at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:667)
[java] at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288)
[java] at javax.naming.InitialContext.init(InitialContext.java:223)
[java] at javax.naming.InitialContext.<init>(InitialContext.java:197)
[java]
[java] Caused by: java.net.ConnectException: t3s://xxxxxxxxxx.com:7002: Destination xx.xx.xx.xx, 7002 unreachable; nested exception is:
[java] javax.net.ssl.SSLHandshakeException: General SSLEngine problem; No available router to destination
[java] at weblogic.rjvm.RJVMFinder.findOrCreateInternal(RJVMFinder.java:216)
[java] at weblogic.rjvm.RJVMFinder.findOrCreate(RJVMFinder.java:169)
[java] at weblogic.rjvm.ServerURL.findOrCreateRJVM(ServerURL.java:165)
[java] at weblogic.jndi.WLInitialContextFactoryDelegate$1.run(WLInitialContextFactoryDelegate.java:342)
[java] at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
[java] at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:146)
[java] at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialContextFactoryDelegate.java:337)
[java] ... 21 more
[java] Caused by: java.rmi.ConnectException: Destination xx.xx.xx.xx, 7002 unreachable; nested exception is:
[java] javax.net.ssl.SSLHandshakeException: General SSLEngine problem; No available router to destination
[java] at weblogic.rjvm.ConnectionManager.bootstrap(ConnectionManager.java:490)
[java] at weblogic.rjvm.ConnectionManager.bootstrap(ConnectionManager.java:328)
[java] at weblogic.rjvm.RJVMManager.findOrCreateRemoteInternal(RJVMManager.java:267)
[java] at weblogic.rjvm.RJVMManager.findOrCreate(RJVMManager.java:204)
[java] at weblogic.rjvm.RJVMFinder.findOrCreateRemoteServer(RJVMFinder.java:238)
[java] at weblogic.rjvm.RJVMFinder.findOrCreateInternal(RJVMFinder.java:200)
On netstat getting below list. I see 7002 on listen mode. Isn't it correct?
$ netstat -tulpn | grep :7002
(Not all processes could be identified, non-owned process info
will not be shown, you would have to be root to see it all.)
tcp 0 0 xxxxxxxxxxxxxxxxxxxxxx:7002 :::* LISTEN 25657/java
tcp 0 0 ::xxxx:127.0.0.1:7002 :::* LISTEN 25657/java
tcp 0 0 xxxx::xxxxxxxxxxxxxxxx:7002 :::* LISTEN 25657/java
tcp 0 0 ::xxxx:xx.xxx.xx.xx:7002 :::* LISTEN 25657/java
SSL errors are often misleading. An SSLHandshakeException is usually a certificate issue, (that the SSL connection cannot be validated as trusted).
Your server is likely signed with a self-signed certificate, which will usually need to be added to your cacerts keystore to allow SSL to trust it. i.e., You need to add the SSL Certificate from the Weblogic server to your JDK/JRE keystore. See the answer(s) to this question:
How to properly import a selfsigned certificate into Java keystore that is available to all Java applications by default
If you are on UNIX, the commands at the link above work as-is. If you are on windows, all of the UNIX utilities you need, (openssl, sed), are secretly included in the installation of GIT, or you can use cygwin. All I had to do was to use openssl to grab the certificate and then use keytool, (part of the JDK), to add it to my JDK's cacerts file. (%JAVA_HOME%\jre\lib\security\cacerts)
Note: If you import the certificate to your ~/.keystore, (on windows: %userprofile%.keystore), file it will still fail but you will likely get a different exception:
javax.net.ssl.SSLHandshakeException: General SSLEngine problem; No available router to destination
Once you are successfully connected, it will look like this:
Connecting to t3s://*********:7001 with userid ********...
<Jul 23, 2014 4:00:25 PM EDT> <Info> <Security> <BEA-090905> <Disabling the CryptoJ JCE Provider self-integrity check for better startup performance. To enable this check, specify -Dweblogic.security.allowCryptoJDefaultJCEVerification=true.>
<Jul 23, 2014 4:00:25 PM EDT> <Info> <Security> <BEA-090906> <Changing the default Random Number Generator in RSA CryptoJ from ECDRBG to FIPS186PRNG. To disable this change, specify -Dweblogic.security.allowCryptoJDefaultPRNG=true.>
<Jul 23, 2014 4:00:25 PM EDT> <Info> <Security> <BEA-090908> <Using the default WebLogic SSL Hostname Verifier implementation.>
Successfully connected to Admin Server "AdminServer" that belongs to domain "******".
Another related post on retrieving and adding an SSL key (through java): Java keytool easy way to add server cert from url/port
The error you are getting is not a SSLHandshake error, it says
" java.net.ConnectException: t3s://xxxxxxxxxx.com:7002: Destination xx.xx.xx.xx, 7002 unreachable "
1) Check the url you are providing.
2) Do a telnet on that DNS port
3) Make sure there's no firewall blocking the request.
4) If 7002 if the port of your admin server (I am assuming you have only 1 server in domain) then try accessing https://DNS:7002/console and see if that loads fine first.

Liferay Build failed

when i am trying to BUILD SERVICES for service.xml i am getting the following error.
[java] D:\liferay-mvc\liferay-plugins-sdk-6.1.1-ce-ga2-20120731132656558\liferay-plugins-sdk-6.1.1\build-common-plugin.xml:169: java.io.IOException: Cannot run program "D:\liferay-mvc\liferay-portal-tomcat-6.1.1-ce-ga2-20120731132656558\liferay-portal-6.1.1-ce-ga2\tomcat-7.0.27\jre1.6.0_20\win\bin\java.exe": CreateProcess error=87, The parameter is incorrect
[java] at org.apache.tools.ant.taskdefs.Java.fork(Java.java:798)
[java] at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:214)
[java] at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:135)
[java] at org.apache.tools.ant.taskdefs.Java.execute(Java.java:108)
[java] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
[java] at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[java] at java.lang.reflect.Method.invoke(Method.java:597)
[java] at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
[java] at org.apache.tools.ant.Task.perform(Task.java:348)
[java] at org.apache.tools.ant.Target.execute(Target.java:392)
[java] at org.apache.tools.ant.Target.performTasks(Target.java:413)
[java] at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
[java] at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
[java] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
[java] at org.eclipse.ant.internal.launching.remote.EclipseDefaultExecutor.executeTargets(EclipseDefaultExecutor.java:32)
[java] at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
[java] at org.eclipse.ant.internal.launching.remote.InternalAntRunner.run(InternalAntRunner.java:424)
[java] at org.eclipse.ant.internal.launching.remote.InternalAntRunner.main(InternalAntRunner.java:138)
[java] Caused by: java.io.IOException: Cannot run program "D:\liferay-mvc\liferay-portal-tomcat-6.1.1-ce-ga2-20120731132656558\liferay-portal-6.1.1-ce-ga2\tomcat-7.0.27\jre1.6.0_20\win\bin\java.exe": CreateProcess error=87, The parameter is incorrect
[java] at java.lang.ProcessBuilder.start(ProcessBuilder.java:460)
[java] at java.lang.Runtime.exec(Runtime.java:593)
[java] at org.apache.tools.ant.taskdefs.Execute$Java13CommandLauncher.exec(Execute.java:862)
[java] at org.apache.tools.ant.taskdefs.Execute.launch(Execute.java:481)
[java] at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:495)
[java] at org.apache.tools.ant.taskdefs.Java.fork(Java.java:791)
[java] ... 18 more
[java] Caused by: java.io.IOException: CreateProcess error=87, The parameter is incorrect
[java] at java.lang.ProcessImpl.create(Native Method)
[java] at java.lang.ProcessImpl.<init>(ProcessImpl.java:81)
[java] at java.lang.ProcessImpl.start(ProcessImpl.java:30)
[java] at java.lang.ProcessBuilder.start(ProcessBuilder.java:453)
[java] ... 23 more
[java] Java Result: -1
[echo] ${service.test.output}
[mkdir] Created dir: D:\liferay-mvc\liferay-plugins-sdk-6.1.1-ce-ga2-20120731132656558\liferay-plugins-sdk-6.1.1\portlets\library-portlet\docroot\WEB-INF\service-classes
compile-java:
[zip] Warning: skipping zip archive D:\liferay-mvc\liferay-plugins-sdk-6.1.1-ce-ga2-20120731132656558\liferay-plugins-sdk-6.1.1\portlets\library-portlet\docroot\WEB-INF\lib\library-portlet-service.jar because no files were included.
[delete] Deleting directory D:\liferay-mvc\liferay-plugins-sdk-6.1.1-ce-ga2-20120731132656558\liferay-plugins-sdk-6.1.1\portlets\library-portlet\docroot\WEB-INF\service-classes
BUILD SUCCESSFUL
Total time: 638 milliseconds
You're running into IDE-678. The ticket links to a forum post that describes a workaround. Alternatively - as it's a path length issue - it might work to just move your plugins-sdk to a directory with a shorter name - e.g. D:/liferay/sdk

ant command works from within Eclipse but not from linux command line

I have a Java project done with Eclipse and I have an ANT command that works perfectly if run from within Eclipse's ANT tool but it doesn't work if I try to run the ANT command from the Linux command line.
Why can it be happening? I have several ANT commands working both in Eclipse and from the command line.
The command is this one:
<target name="run.jmsserver">
<java classname="JMSInternationalEventServer/JMSInternationalEventServer" classpath="${classpath}" fork="true">
</java>
</target>
And classpath is defined previously:
<property name="classpath" location="bin:EventReservationCore/bin:EventReservationCore/db:EventReservationCore/lib/*:EventReservationCore/lib/util_iso2.jar:EventReservationCore/lib/sqlitejdbc-v056.jar:AuthorizationRMI/lib/AuthorizationService.jar"/>
The error I am getting is:
[java] Exception in thread "main" java.lang.NoClassDefFoundError: javax/jms/JMSException
[java] Caused by: java.lang.ClassNotFoundException: javax.jms.JMSException
[java] at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
[java] at java.security.AccessController.doPrivileged(Native Method)
[java] at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
[java] at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
[java] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
[java] at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
[java] Could not find the main class: JMSInternationalEventServer.JMSInternationalEventServer. Program will exit.
[java] Java Result: 1
Thank you very much.
Thank you Jason Braucht for your help, the problem was that EventReservationCore/lib/* was not working, even if I had read that it should work on Linux.

Resources