OutOfMemory Exception while running a JAR file
Hi,
I am working with Java 1.5 and using Eclipse to build a GUI. My application has intensive image loading involved so I set -Xmx inside Eclipse when running the application in debug mode.
However, once a JAR file is exported, I do not know how to specify the heap size required to run the program. Is there a way to ...
1. embed the heap size info inside the JAR file?
2. specify a heap size when running the JAR file?
Thanks in advance.
Heap size is specified by the -Xmx option on the java command. See the java command documentation.
Similar Messages
-
Exception while creating a jar file for bean
Friendz,
I am getting this error whenever i tried to create a jar file.
I am using win 98 os and jdk1.4 please tell me what error it is
C:\bean\programs\spectrum>jar cfm a.jar manifest.mft spectrum.class
java.io.IOException: invalid header field
at java.util.jar.Attributes.read(Attributes.java:355)
at java.util.jar.Manifest.read(Manifest.java:162)
at java.util.jar.Manifest.<init>(Manifest.java:52)
at sun.tools.jar.Main.run(Main.java:124)
at sun.tools.jar.Main.main(Main.java:904)
Contents of manifest template file:
Name:spectrum.class
Java-Bean:TrueManifests are saved with the .mf file extension. Rename your manifest mainfest.mf.
-
Exception while adding External Jar files in NWDS
Dear Friends,
Actually i am adding an external Jar file in my EJB Module in NWDS.I am using this jar file for converting XML to flat file and i am calling this module from Receiver ommunication channel.For this process, i am importing dom4j.jar file in the EJB Module.
Now i have created an external Library project for the cause that i have used the external jar file, and i have made following code in the provider.xml file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE provider-descriptor SYSTEM "library.provider.dtd">
<provider-descriptor>
<display-name>
XML2EDI_Library
</display-name>
<component-name>
XML2EDI_Library
</component-name>
<major-version>6</major-version>
<minor-version>40</minor-version>
<micro-version>0</micro-version>
<provider-name>
dom4j.org
</provider-name>
<references>
<reference
provider-name="dom4j.org"
strength="weak"
type="library">org.dom4j.Document</reference>
<reference
provider-name="dom4j.org"
strength="weak"
type="library">org.dom4j.DocumentException</reference>
<reference
provider-name="dom4j.org"
strength="weak"
type="library">org.dom4j.Element</reference>
<reference
provider-name="dom4j.org"
strength="weak"
type="library">org.dom4j.io.SAXReader</reference>
</references>
<jars>
<jar-name>EDI_Module.jar</jar-name>
</jars>
</provider-descriptor>
I have included 4 references because i have imported following in my ejb module.
import org.dom4j.Document;
import org.dom4j.DocumentException;
import org.dom4j.Element;
import org.dom4j.io.SAXReader;
I am not sure of wht to include in reference target and provider name, I am getting the following exceptions in Message monitoring:
1. AO: Document Exception: org.dom4j.DocumentException: E:\usr\sap\BWS\DVEBMGS00\j2ee\cluster\server0\
2. Nested exception: E:\usr\sap\BWS\DVEBMGS00\j2ee\cluster\server0\
Help me in this issue..
Thanks in advance
N.Jayanth Kumarthanks for you help sidharth.
i have now jar files in the server and the application referring to the jar files. everything is deployed fine. however, when i start the application..i get the error -"package jcifs.smb does not exist". the jar i am using is jcifs-1.2.7.jar. in my web module when i expand the jar i see the package and the .class files inside. what am i missing?
Also, i din't define a SharingReference to usermanagement in portalapp.xml as i am working towards a pure j2ee enterprise application. the web module (DC) referes to the jar files. is there any step similar to defining the sharing reference for the web module DC?
please help. thanks - sowmiyar -
Exception while running a test file as JUNIT test case
Hi,
I am trying to build a code using Eclipse to generate an "ear" file that can be used for deployment. The ear file is generated successfully but the build is not successful as the following exception is thrown while debugging a junit test case:
javax.naming.CommunicationException: tdk.dk:389 [Root exception is java.net.SocketTimeoutException: connect timed out]
at com.sun.jndi.ldap.Connection.<init>(Connection.java:197)
at com.sun.jndi.ldap.LdapClient.<init>(LdapClient.java:118)
at com.sun.jndi.ldap.LdapClient.getInstance(LdapClient.java:1580)
at com.sun.jndi.ldap.LdapCtx.connect(LdapCtx.java:2616)
at com.sun.jndi.ldap.LdapCtx.<init>(LdapCtx.java:287)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(LdapCtxFactory.java:175)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(LdapCtxFactory.java:193)
at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(LdapCtxFactory.java:136)
at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(LdapCtxFactory.java:66)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Kindly suggest a solution.
P.S. : All test cases are running fine except for one test case, whose error details are given.No it is not. The Oracle JDeveloper and ADF forum is for development questions around development with Oracle JDeveloper and ADF.
If you use Eclipse through OEPE, you could post the question here
Enterprise Pack for Eclipse
If you don't use OEPE but Eclipse, then this forum may be a great source of help: http://stackoverflow.com/
Frank -
Error while running ldap40.jar file
Hi,
I have cloned an oracle 8i database(which is on windows 2000 sp4 server) to a new server(same configuration i.e windows 2000) to make the new server as a production database. I was not aware that the db server will connect to an LDAP server, so i have missed copyng some configuration files related to ldap. later, after making the new server as production server, development team informed me that some part of application is throwing some ora errors, the errors are
ora-04088, ora-06512, ora-29532,
Later i 've copied the configuration files related to ldap server into the db server, and i got some documentation regarding the db server(steps to follow for a new db server). in that we need to loadjava into database by using
*"call loadjava -username/passwd -resolve %script_path%/ldap40.jar"*
when i run the above command i got the ora-29552 error
ORA-29552: verification warning: at offset 66 of netscape.ldap.util.LDIF$Lin
eReader.readLine resolved FIELD<null> cannot Access netscape.ldap.util.LDIF.COMM
ENT
verifier is replacing bytecode at netscape.ldap.util.LDIF$LineReader.readLine:66
by a throw
at offset 66 of netscape.ldap.util.LDIF$LineReader.readLine resolved FIELD<null>
cannot Access netscape.ldap.util.LDIF.COMMENT
at offset 167 of netscape.ldap.util.LDIF$LineReader.readLine resolved FIELD<null
cannot Access netscape.ldap.util.LDIF.m_doneverifier is replacing bytecode at netscape.ldap.util.LDIF$LineReader.readLine:16
7 by a throw
at offset 167 of netscape.ldap.util.LDIF$LineReader.readLine resolved FIELD<null
cannot Access netscape.ldap.util.LDIF.m_doneat offset 167 of netscape.ldap.util.LDIF$LineReader.readLine resolved FIELD<null
cannot Access netscape.ldap.util.LDIF.m_doneplease help me out ,
Thanks in advance,
SaiPhotoshop Scripting Forum http://www.adobeforums.com/webx?13@@.3bbf2765
-
Exception is thrown only while executing the jar file
java.lang.NoClassDefFoundError: javax/mail/Address Exception is thrown only while executing the jar file. But the program compiles and executes good when executed for command prompt through the class files.
I used javamail API in my program. Classpath and every others are set to the right one's. Executed fine when used java Random.class. But the problem is only with the jar file.
Please help me out in this regard. Why the exception is thrown only in jar but not at class level.Assuming you're running your program using "java -jar", your jar file needs a Class-Path entry
in the manifest file that references mail.jar. -
Errror while Running the ant file(build.xml) when applying B2B-BPEL patch
Hello all,
I am trying to apply the B2B WSIL Browser patch and while running the ant file i got the following warning while backing out d3l.jar file
echo Backing out dl3l.jar to avoid conflicts with B2B...
move *Warning: Could not find file C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL\${env.ORACLE_HOME}\xqs\lib\d3l.jar to copy.*
and the following error when it was not able to find admin_client.jar file
*java Unable to access jarfile C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL\${env.ORACLE_HOME}\j2ee\home\admin_client.jar*
java Java Result: 1
echo Binding B2B WSIL Browser...
*java Unable to access jarfile C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL\${env.ORACLE_HOME}\j2ee\home\admin_client.jar*
and the BUILD FAILED
*so i created the necessary folders in the newly generated folder manually in ${env.ORACLE_HOME} i.e xqs\lib & j2ee\home and pasted the d3l.jar and admin_client.jar in these folders respectively,and again ran the ant file,this time the error is first problem is cleared i.e it is not showing the warning that it could not find* d3l.jar_+ file and it is also converting this file as d3l.jar.hide_+ *, but this time in the place of second error a new error is generated i.e* +
Problem_
C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL>ant
Buildfile: build.xml
apply-b2b-bpel-10.1.3:
echo Prompting for B2B repository connection parameters...
input Please enter B2B repository hostname [http://127.0.0.1:] [http://127.0.0.1]
172.17.4.14
input Please enter B2B repository port 1521: 1521
1521
input Please enter B2B repository sid ORCL: ORCL
orcl
input Please enter B2B password b2b: b2b
b2b
input Please enter oc4j instance name home: home
home
input Please enter oc4j admin password welcome1: welcome1
welcome1
input Please enter opmn request port 6003: 6003
6003
echo Copying b2b.jar and tip.properties to appropriate locations...
copy Copying 1 file to C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL\${env.ORACLE_HOME}\lib
copy Copying 1 file to C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL\${env.OB_HOME}\system\classes
echo Backing out dl3l.jar to avoid conflicts with B2B...
move Moving 1 file to C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL\${env.ORACLE_HOME}\xqs\lib
echo Deploying B2B WSIL Browser ...
echo OPMN Port is : 6003
echo Container is : home
echo Host is : ${env.HOSTNAME}
echo iasadminpassword is : welcome1
java java.lang.NoClassDefFoundError: oracle/oc4j/admin/deploy/cmdline/Oc4jAdminCmdline
java Exception in thread "main"
java Java Result: 1
echo Binding B2B WSIL Browser...
java java.lang.NoClassDefFoundError: oracle/oc4j/admin/deploy/cmdline/Oc4jAdminCmdline
java Exception in thread "main"
BUILD FAILED
C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL\build.xml:88: The following error occurred while executing this line:
C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL\build.xml:49: Java returned: 1
Total time: 31 seconds
C:\product\1013~1.1\ORACLE~1\bpel\samples\tmp\B2B-BPEL>
i have set the classpath for the jdk and jre files correctly and also checked it with a sample program and the file is compiling and running with correct output.then why is it showing up java.lang.NoClassDefFoundError exception.Did anyone face the same problem or have a solution for this problem if they have then plzzz help me
thnx
Sunny
Edited by: sunny kay on Jan 27, 2009 4:14 AMHello sri,
Thanks for your response as you have told i have set the ORACLE_HOME = C:\product\10.1.3.1\OracleAS_1
and added C:\product\10.1.3.1\OracleAS_1\bin to my sys path
and i have also set the JAVA_HOME=C:\product\10.1.3.1\OracleAS_1\jdk
and added C:\product\10.1.3.1\OracleAS_1\jdk\bin to my sys path
and ran the patch,now its coming up with a different problem after entering the B2B repository connection parameters...
and it is
Problem_
echo Deploying B2B WSIL Browser ...
echo OPMN Port is : 6003
echo Container is : home
echo Host is : ${env.HOSTNAME}
echo iasadminpassword is : welcome1
java
java
java Failed at "Could not get DeploymentManager".
java
java This is typically the result of an invalid deployer URI format being
supplied, the target server not being in a started state or incorrect authentic
ation details being supplied.
java
java More information is available by enabling logging -- please see the
Oracle Containers for J2EE Configuration and Administration Guide for details.
java
java
java Java Result: 1
echo Binding B2B WSIL Browser...
java
java
java Failed at "Could not get DeploymentManager".
java
java This is typically the result of an invalid deployer URI format being
supplied, the target server not being in a started state or incorrect authentic
ation details being supplied.
java
java More information is available by enabling logging -- please see the
Oracle Containers for J2EE Configuration and Administration Guide for details.
java
java
BUILD FAILED
The Application Server is in the started state and these are the details that i have entered when B2B Repository Connection Parameters is prompeted
echo Prompting for B2B repository connection parameters...
input Please enter B2B repository hostname [http://127.0.0.1]: [http://127.0.0.1]
172.17.4.14
input Please enter B2B repository port [1521|http://forums.oracle.com/forums/]: [1521|http://forums.oracle.com/forums/]
1521
input Please enter B2B repository sid ORCL: ORCL
orcl
input Please enter B2B password [b2b|http://forums.oracle.com/forums/]: [b2b|http://forums.oracle.com/forums/]
b2b
input Please enter oc4j instance name home: home
home
input Please enter oc4j admin password [welcome1|http://forums.oracle.com/forums/]: [welcome1|http://forums.oracle.com/forums/]
welcome1
input Please enter opmn request port [6003|http://forums.oracle.com/forums/]: [6003|http://forums.oracle.com/forums/]
6003
is anything wrong in this i have tried by giving the default host name instead of mine but result is still the same.what is the problem can you figure it out and provide me a solution.
thnx
Sunny -
Running a jar file from java code
Hi!
Im trying to run a jar file from my code.
I've tried Classloader, but that doesnt work because it doesnt find the images (also embedded in the 2nd jar file).
WHat I would like to do is actually RUN the 2nd jar file from the first jar file. There must be a way to do this right?
any ideas?ok, I found some wonderful code (see below) that will try to start the jar. But it doesn't. What it does is produce the following error when my application runs...
So it's not finding the images in the jar file that I am trying to run? Strange. I checked the URL that sending, but it seems ok....
I think I will check the url again to make sure......
any ideas?
Uncaught error fetching image:
java.lang.NullPointerException
at sun.awt.image.URLImageSource.getConnection(Unknown Source)
at sun.awt.image.URLImageSource.getDecoder(Unknown Source)
at sun.awt.image.InputStreamImageSource.doFetch(Unknown Source)
at sun.awt.image.ImageFetcher.fetchloop(Unknown Source)
at sun.awt.image.ImageFetcher.run(Unknown Source)
the code....
/* From http://java.sun.com/docs/books/tutorial/index.html */
import java.io.IOException;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.lang.reflect.Modifier;
import java.net.JarURLConnection;
import java.net.MalformedURLException;
import java.net.URL;
import java.net.URLClassLoader;
import java.util.jar.Attributes;
* Runs a jar application from any url. Usage is 'java JarRunner url [args..]'
* where url is the url of the jar file and args is optional arguments to be
* passed to the application's main method.
public class JarRunner {
public static void main(String[] args) {
URL url = null;
try {
url = new URL(args[0]);//"VideoTagger.jar");
} catch (MalformedURLException e) {
System.out.println("Invalid URL: ");
// Create the class loader for the application jar file
JarClassLoader cl = new JarClassLoader(url);
// Get the application's main class name
String name = null;
try {
name = cl.getMainClassName();
} catch (IOException e) {
System.err.println("I/O error while loading JAR file:");
e.printStackTrace();
System.exit(1);
if (name == null) {
fatal("Specified jar file does not contain a 'Main-Class'"
+ " manifest attribute");
// Get arguments for the application
String[] newArgs = new String[args.length - 1];
System.arraycopy(args, 1, newArgs, 0, newArgs.length);
// Invoke application's main class
try {
cl.invokeClass(name, newArgs);
} catch (ClassNotFoundException e) {
fatal("Class not found: " + name);
} catch (NoSuchMethodException e) {
fatal("Class does not define a 'main' method: " + name);
} catch (InvocationTargetException e) {
e.getTargetException().printStackTrace();
System.exit(1);
private static void fatal(String s) {
System.err.println(s);
System.exit(1);
* A class loader for loading jar files, both local and remote.
class JarClassLoader extends URLClassLoader {
private URL url;
* Creates a new JarClassLoader for the specified url.
* @param url
* the url of the jar file
public JarClassLoader(URL url) {
super(new URL[] { url });
this.url = url;
* Returns the name of the jar file main class, or null if no "Main-Class"
* manifest attributes was defined.
public String getMainClassName() throws IOException {
URL u = new URL("jar", "", url + "!/");
JarURLConnection uc = (JarURLConnection) u.openConnection();
Attributes attr = uc.getMainAttributes();
return attr != null ? attr.getValue(Attributes.Name.MAIN_CLASS) : null;
* Invokes the application in this jar file given the name of the main class
* and an array of arguments. The class must define a static method "main"
* which takes an array of String arguemtns and is of return type "void".
* @param name
* the name of the main class
* @param args
* the arguments for the application
* @exception ClassNotFoundException
* if the specified class could not be found
* @exception NoSuchMethodException
* if the specified class does not contain a "main" method
* @exception InvocationTargetException
* if the application raised an exception
public void invokeClass(String name, String[] args)
throws ClassNotFoundException, NoSuchMethodException,
InvocationTargetException {
Class c = loadClass(name);
Method m = c.getMethod("main", new Class[] { args.getClass() });
m.setAccessible(true);
int mods = m.getModifiers();
if (m.getReturnType() != void.class || !Modifier.isStatic(mods)
|| !Modifier.isPublic(mods)) {
throw new NoSuchMethodException("main");
try {
m.invoke(null, new Object[] { args });
} catch (IllegalAccessException e) {
// This should not happen, as we have disabled access checks
} -
ClassCastException exception while running EJB Client
Folks,
I am getting following exception while running the EJB Client.. I am
using WLS 5.1
Exception in thread "main" java.lang.ClassCastException
at
javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:319)
at FirstStatelessEJBClient.Client.lookupHome(Client.java:149)
at FirstStatelessEJBClient.Client.<init>(Client.java:44)
at FirstStatelessEJBClient.Client.main(Client.java:82)
Can anybody throw a light on this.
Thanks
AshishHi Eduardo,
Below is my classpath. The stubs are in first_statlessSession.jar file.
CLASSPATH=C:\weblogic\myserver\first_statelessSession.jar;
C:\jdk1.2.2\lib\tools.jar;C:\weblogic\license;C:\weblogic\classes;C:\weblogi
c\lib\weblogicaux.jar;
C:\weblogic\myserver\clientclasses;C:\weblogic\myserver\serverclasses
Also, I am just compiling and deploying the
C:\weblogic\examples\ejb\basic\statelessSession myself and testing it. I
am
using the build.cmd files to compile and deploy the above EJB. If I use the
jars provided by weblogic it works fine with same above classpath.
I don't know what to do next. I have invested the whole day to solve this
problem and couldn't.
Please let me know if I am doing anything wrong.
Appreciate your help.
Thanks,
Ashish
Eduardo Ceballos wrote:
Try putting the stubs into the client class path.
"Ashish N. Shah" wrote:
Folks,
I am getting following exception while running the EJB Client.. I am
using WLS 5.1
Exception in thread "main" java.lang.ClassCastException
at
javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:319)
at FirstStatelessEJBClient.Client.lookupHome(Client.java:149)
at FirstStatelessEJBClient.Client.<init>(Client.java:44)
at FirstStatelessEJBClient.Client.main(Client.java:82)
Can anybody throw a light on this.
Thanks
Ashish -
Getting following exception while running coherence tutorial using JDev
Hi,
I am getting following exception while running the Oracle Coherence tutorial in Jdeveloper, but unfortunately I'm not able to figure out what's wrong with my configuration.
Any help will be highly appreciated,
D:\OracleSOA\Middleware\jdk160_24\bin\javaw.exe -client -classpath C:\JDeveloper\mywork\KnowledgeSOA\.adf;C:\JDeveloper\mywork\KnowledgeSOA\JPA\classes;D:\OracleSOA\Middleware\modules\com.oracle.toplink_1.0.0.0_11-1-1-5-0.jar;D:\OracleSOA\Middleware\modules\org.eclipse.persistence_1.1.0.0_2-1.jar;D:\OracleSOA\Middleware\modules\com.bea.core.antlr.runtime_2.7.7.jar;D:\OracleSOA\Middleware\modules\javax.persistence_1.0.0.0_2-0-0.jar;D:\OracleSOA\Middleware\oracle_common\modules\oracle.xdk_11.1.0\xmlparserv2.jar;D:\OracleSOA\Middleware\oracle_common\modules\oracle.xdk_11.1.0\xml.jar;D:\OracleSOA\Middleware\modules\javax.jsf_1.1.0.0_1-2.jar;D:\OracleSOA\Middleware\modules\javax.ejb_3.0.1.jar;D:\OracleSOA\Middleware\modules\javax.enterprise.deploy_1.2.jar;D:\OracleSOA\Middleware\modules\javax.interceptor_1.0.jar;D:\OracleSOA\Middleware\modules\javax.jms_1.1.1.jar;D:\OracleSOA\Middleware\modules\javax.jsp_1.2.0.0_2-1.jar;D:\OracleSOA\Middleware\modules\javax.jws_2.0.jar;D:\OracleSOA\Middleware\modules\javax.activation_1.1.0.0_1-1.jar;D:\OracleSOA\Middleware\modules\javax.mail_1.1.0.0_1-4-1.jar;D:\OracleSOA\Middleware\modules\javax.xml.soap_1.3.1.0.jar;D:\OracleSOA\Middleware\modules\javax.xml.rpc_1.2.1.jar;D:\OracleSOA\Middleware\modules\javax.xml.ws_2.1.1.jar;D:\OracleSOA\Middleware\modules\javax.management.j2ee_1.0.jar;D:\OracleSOA\Middleware\modules\javax.resource_1.5.1.jar;D:\OracleSOA\Middleware\modules\javax.servlet_1.0.0.0_2-5.jar;D:\OracleSOA\Middleware\modules\javax.transaction_1.0.0.0_1-1.jar;D:\OracleSOA\Middleware\modules\javax.xml.stream_1.1.1.0.jar;D:\OracleSOA\Middleware\modules\javax.security.jacc_1.0.0.0_1-1.jar;D:\OracleSOA\Middleware\modules\javax.xml.registry_1.0.0.0_1-0.jar;D:\OracleSOA\Middleware\jdeveloper\ide\macros\..\..\..\oracle_common\modules\oracle.jdbc_11.1.1\ojdbc6dms.jar;D:\OracleSOA\Middleware\jdeveloper\ide\macros\..\..\..\oracle_common\modules\oracle.nlsrtl_11.1.0\orai18n.jar;D:\OracleSOA\Middleware\oracle_common\modules\oracle.odl_11.1.1\ojdl.jar;D:\OracleSOA\Middleware\oracle_common\modules\oracle.dms_11.1.1\dms.jar;D:\Coherence\toplink\jlib\eclipselink.jar;D:\Coherence\coherence-java-3.7.1.0b27797\coherence\lib\coherence.jar;D:\Oracle\Middleware\modules\javax.persistence_1.0.0.0_1-0-2.jar;D:\Coherence\coherence-java-3.7.1.0b27797\coherence\lib\coherence-jpa.jar;D:\Coherence\ojdbc5.jar;D:\Coherence\toplink\jlib\toplink.jar -Djavax.net.ssl.trustStore=D:\OracleSOA\Middleware\wlserver_10.3\server\lib\DemoTrust.jks -Dhttp.proxyHost=proxymlz.samba.com -Dhttp.proxyPort=80 -Dhttp.nonProxyHosts=scms.*|*.contoso.com|ldrps.*|col.wls.*|desu*|tdlintra.*|10.8.*|10.10.*|*.corp.samba.com|ckcexch1*|whoexch1*|lhoexch1*|ehoexch1*|cmzexch2*|choexch2*|cdcstg2.*|itr2.samba.com|itr.samba.com|*.session.rservices.com|cold.samba.com|sims.samba.com|intranet.samba.com|localhost|localhost.localdomain|127.0.0.1|::1|crgmz01bssu-006.corp.samba.com|crgmz01bssu-006 -Dhttps.proxyHost=proxymlz.samba.com -Dhttps.proxyPort=80 -Dhttps.nonProxyHosts=scms.*|*.contoso.com|ldrps.*|col.wls.*|desu*|tdlintra.*|10.8.*|10.10.*|*.corp.samba.com|ckcexch1*|whoexch1*|lhoexch1*|ehoexch1*|cmzexch2*|choexch2*|cdcstg2.*|itr2.samba.com|itr.samba.com|*.session.rservices.com|cold.samba.com|sims.samba.com|intranet.samba.com|localhost|localhost.localdomain|127.0.0.1|::1|crgmz01bssu-006.corp.samba.com|crgmz01bssu-006 -Dtangosol.coherence.cacheconfig=C:\JDeveloper\mywork\KnowledgeSOA\JPA\jpa-cache-config.xml -Dtangosol.coherence.distributed.localstorage=false -Dtangosol.coherence.log.level=3 com.samba.coherence.RunEmployee
2012-08-12 13:36:48.447/0.265 Oracle Coherence 3.7.1.0 <Info> (thread=main, member=n/a): Loaded operational configuration from "jar:file:/D:/Coherence/coherence-java-3.7.1.0b27797/coherence/lib/coherence.jar!/tangosol-coherence.xml"
2012-08-12 13:36:48.479/0.297 Oracle Coherence 3.7.1.0 <Info> (thread=main, member=n/a): Loaded operational overrides from "jar:file:/D:/Coherence/coherence-java-3.7.1.0b27797/coherence/lib/coherence.jar!/tangosol-coherence-override-dev.xml"
Oracle Coherence Version 3.7.1.0 Build 27797
Grid Edition: Development mode
Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.
2012-08-12 13:36:48.603/0.421 Oracle Coherence GE 3.7.1.0 <Info> (thread=main, member=n/a): Loaded cache configuration from "file:/C:/JDeveloper/mywork/KnowledgeSOA/JPA/jpa-cache-config.xml"; this document does not refer to any schema definition and has not been validated.
2012-08-12 13:36:49.290/1.108 Oracle Coherence GE 3.7.1.0 <Info> (thread=Cluster, member=n/a): This Member(Id=3, Timestamp=2012-08-12 13:36:49.118, Address=10.10.51.150:8090, MachineId=30889, Location=site:,machine:crgmz01bssu-006,process:4816, Role=SambaCoherenceRunEmployee, Edition=Grid Edition, Mode=Development, CpuCount=4, SocketCount=4) joined cluster "cluster:0xFCDB" with senior Member(Id=1, Timestamp=2012-08-12 13:31:01.774, Address=10.10.51.150:8088, MachineId=30889, Location=site:,machine:crgmz01bssu-006,process:4812, Role=CoherenceServer, Edition=Grid Edition, Mode=Development, CpuCount=4, SocketCount=4)
2012-08-12 13:36:49.305/1.123 Oracle Coherence GE 3.7.1.0 <Info> (thread=main, member=n/a): Started cluster Name=cluster:0xFCDB
Group{Address=224.3.7.0, Port=37000, TTL=4}
MasterMemberSet(
ThisMember=Member(Id=3, Timestamp=2012-08-12 13:36:49.118, Address=10.10.51.150:8090, MachineId=30889, Location=site:,machine:crgmz01bssu-006,process:4816, Role=SambaCoherenceRunEmployee)
OldestMember=Member(Id=1, Timestamp=2012-08-12 13:31:01.774, Address=10.10.51.150:8088, MachineId=30889, Location=site:,machine:crgmz01bssu-006,process:4812, Role=CoherenceServer)
ActualMemberSet=MemberSet(Size=2
Member(Id=1, Timestamp=2012-08-12 13:31:01.774, Address=10.10.51.150:8088, MachineId=30889, Location=site:,machine:crgmz01bssu-006,process:4812, Role=CoherenceServer)
Member(Id=3, Timestamp=2012-08-12 13:36:49.118, Address=10.10.51.150:8090, MachineId=30889, Location=site:,machine:crgmz01bssu-006,process:4816, Role=SambaCoherenceRunEmployee)
MemberId|ServiceVersion|ServiceJoined|MemberState
1|3.7.1|2012-08-12 13:31:01.774|JOINED,
3|3.7.1|2012-08-12 13:36:49.305|JOINED
RecycleMillis=1200000
RecycleSet=MemberSet(Size=0
TcpRing{Connections=[1]}
IpMonitor{AddressListSize=0}
Exception in thread "main" (Wrapped) java.io.InvalidClassException: org.eclipse.persistence.indirection.IndirectList; local class incompatible: stream classdesc serialVersionUID = 4038061360325736360, local class serialVersionUID = -494763524358427112
at com.tangosol.util.ExternalizableHelper.fromBinary(ExternalizableHelper.java:266)
at com.tangosol.coherence.component.util.daemon.queueProcessor.service.grid.partitionedService.PartitionedCache$ConverterFromBinary.convert(PartitionedCache.CDB:4)
at com.tangosol.util.ConverterCollections$ConverterMap.get(ConverterCollections.java:1655)
at com.tangosol.coherence.component.util.daemon.queueProcessor.service.grid.partitionedService.PartitionedCache$ViewMap.get(PartitionedCache.CDB:1)
at com.tangosol.coherence.component.util.SafeNamedCache.get(SafeNamedCache.CDB:1)
at com.samba.coherence.RunEmployee.main(RunEmployee.java:17)
Caused by: java.io.InvalidClassException: org.eclipse.persistence.indirection.IndirectList; local class incompatible: stream classdesc serialVersionUID = 4038061360325736360, local class serialVersionUID = -494763524358427112
at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:562)
at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1582)
at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1495)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1731)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1328)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1946)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1870)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1752)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1328)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1946)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1870)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1752)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1328)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1946)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1870)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1752)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1328)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:350)
at com.tangosol.util.ExternalizableHelper.readSerializable(ExternalizableHelper.java:2217)
at com.tangosol.util.ExternalizableHelper.readObjectInternal(ExternalizableHelper.java:2348)
at com.tangosol.util.ExternalizableHelper.deserializeInternal(ExternalizableHelper.java:2746)
at com.tangosol.util.ExternalizableHelper.fromBinary(ExternalizableHelper.java:262)
... 5 more
Process exited with exit code 1.
My Cache-Config file
<?xml version="1.0" encoding="windows-1252" ?>
<cache-config>
<caching-scheme-mapping>
<cache-mapping>
<!-- Set the name of the cache to be the entity name -->
<cache-name>Employees</cache-name>
<!-- Configure this cache to use the scheme defined below -->
<scheme-name>jpa-distributed</scheme-name>
</cache-mapping>
</caching-scheme-mapping>
<caching-schemes>
<distributed-scheme>
<scheme-name>jpa-distributed</scheme-name>
<service-name>JpaDistributedCache</service-name>
<backing-map-scheme>
<read-write-backing-map-scheme>
<!--
Define the cache scheme
-->
<internal-cache-scheme>
<local-scheme/>
</internal-cache-scheme>
<cachestore-scheme>
<class-scheme>
<class-name>com.tangosol.coherence.jpa.JpaCacheStore</class-name>
<init-params>
<!--
This param is the entity name
This param is the fully qualified entity class
This param should match the value of the
persistence unit name in persistence.xml
-->
<init-param>
<param-type>java.lang.String</param-type>
<param-value>{cache-name}</param-value>
</init-param>
<init-param>
<param-type>java.lang.String</param-type>
<param-value>com.samba.coherence.{cache-name}</param-value>
</init-param>
<init-param>
<param-type>java.lang.String</param-type>
<param-value>JPA</param-value>
</init-param>
</init-params>
</class-scheme>
</cachestore-scheme>
</read-write-backing-map-scheme>
</backing-map-scheme>
<autostart>true</autostart>
</distributed-scheme>
</caching-schemes>
</cache-config>
cache-server.cmd
@echo off
@rem This will start a cache server
setlocal
:config
@rem specify the Coherence installation directory
set coherence_home=D:\Coherence\coherence-java-3.7.1.0b27797\coherence
@rem specify the JVM heap size
set memory=512m
:start
if not exist "%coherence_home%\lib\coherence.jar" goto instructions
if "%java_home%"=="" (set java_exec=java) else (set java_exec=%java_home%\bin\java)
:launch
if "%1"=="-jmx" (
set jmxproperties=-Dcom.sun.management.jmxremote -Dtangosol.coherence.management=all -Dtangosol.coherence.management.remote=true
shift
set java_opts=-Xms%memory% -Xmx%memory% %jmxproperties% -Dtangosol.coherence.cacheconfig=C:\JDeveloper\mywork\KnowledgeSOA\JPA\jpa-cache-config.xml
%java_exec% -server -showversion %java_opts% -cp "%coherence_home%\lib\coherence.jar;C:\JDeveloper\mywork\KnowledgeSOA\JPA\classes;D:\Coherence\coherence-java-3.7.1.0b27797\coherence\lib\coherence-jpa.jar;D:\Coherence\ojdbc5.jar;D:\Coherence\toplink\jlib\eclipselink.jar;D:\Oracle\Middleware\modules\javax.persistence_1.0.0.0_1-0-2.jar" com.tangosol.net.DefaultCacheServer %1
goto exit
:instructions
echo Usage:
echo ^<coherence_home^>\bin\cache-server.cmd
goto exit
:exit
endlocal
@echo on
Many Thanks in Advance
ZiaHi Zia,
The error is...
Caused by: java.io.InvalidClassException: org.eclipse.persistence.indirection.IndirectList; local class incompatible: stream classdesc serialVersionUID = 4038061360325736360, local class serialVersionUID = -494763524358427112
...which means you have two different versions of org.eclipse.persistence.indirection.IndirectList, one on the server and one in the client (JDeveloper). As these classes have different serialVersionUID values then Java throws an exception when deserializing as they are probably not compatible.
I don't know much about the Eclipse stuff but from looking at your post I can only assume one version of the class is in D:\Coherence\toplink\jlib\eclipselink.jar on the Coherence server side and the other is in JDevloper in D:\OracleSOA\Middleware\modules\org.eclipse.persistence_1.1.0.0_2-1.jar as these are the only jar file containing "eclipse" that I can see on the classpaths.
JK -
NoClassFoundError exception while running the java program
Hi,
I am getting the following exception while running a java program CSTToGMTToSQL.java
Exception in thread "main" java.lang.NoClassDefFoundError: CSTToGMTToSQL
However, the class file is getting created for this program in the same directory where the program is residing.
Any idea on this ?
Regards
RameshI know that in the past there was an issue with running a particular version of the SDK on a particular version of windows. The resulant error was a ClassNotFoundException. I am not sure about the versions involved.
-
EJB5017: Exception while running preinvoke
Hi All
I have a strange problem in using an EJB. I have a pure java class in which a dao class which is an Stateless session bean. This bean is injected in another EJB and passed to this pure class but calling any method of this bean will fail. I tried to look it up inside that pure java class and the container is able to look it up but again any method invocation will fail!! Exception is very vague and I can't understand what happens. Please help me out of this since I am completely stuck!!!
[#|2009-11-23T08:57:13.937-0500|FINE|sun-appserver9.1|javax.enterprise.system.core.naming|_ThreadID=36;_ThreadName=httpSSLWorkerThread-8080-5;ClassName=com.sun.enterprise.naming.NamingManagerImpl;MethodName=lookup;_RequestID=1fe100d2-84a5-498b-857a-8ffd940746a5;|NamingManagerImpl : looking up name : java:comp/env/ITransactionFormDao|#]
[#|2009-11-23T08:57:13.938-0500|FINE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=36;_ThreadName=httpSSLWorkerThread-8080-5;ClassName=com.sun.ejb.containers.BaseContainer;MethodName=preInvoke;TransactionFormDaoImpl;_RequestID=1fe100d2-84a5-498b-857a-8ffd940746a5;|EJB5017: Exception while running preinvoke : ejbName = [TransactionFormDaoImpl]|#]
[#|2009-11-23T08:57:13.938-0500|FINE|sun-appserver9.1|javax.enterprise.system.container.ejb|_ThreadID=36;_ThreadName=httpSSLWorkerThread-8080-5;ClassName=com.sun.ejb.containers.BaseContainer;MethodName=preInvoke;_RequestID=1fe100d2-84a5-498b-857a-8ffd940746a5;|
javax.ejb.TransactionRolledbackLocalException: Client's transaction aborted
at com.sun.ejb.containers.BaseContainer.useClientTx(BaseContainer.java:3394)
at com.sun.ejb.containers.BaseContainer.preInvokeTx(BaseContainer.java:3274)
at com.sun.ejb.containers.BaseContainer.preInvoke(BaseContainer.java:1244)
at com.sun.ejb.containers.EJBLocalObjectInvocationHandler.invoke(EJBLocalObjectInvocationHandler.java:195)
at com.sun.ejb.containers.EJBLocalObjectInvocationHandlerDelegate.invoke(EJBLocalObjectInvocationHandlerDelegate.java:83)
at $Proxy651.getTransactionForms(Unknown Source)
at com.kishware.core.payment.packet.TransactionFormProvider.buildTransactionGraphIfRequired(TransactionFormProvider.java:85)
at com.kishware.core.payment.packet.TransactionFormProvider.getTransactionForm(TransactionFormProvider.java:48)
at com.kishware.core.payment.packet.PaymentVoucherAgentImpl.acquireTransactionForm(PaymentVoucherAgentImpl.java:163)
at com.kishware.core.payment.packet.PaymentVoucherAgentImpl.build(PaymentVoucherAgentImpl.java:133)
at com.kishware.core.payment.packet.PaymentVoucherAgentImpl.createPaymentPacketDto(PaymentVoucherAgentImpl.java:172)
at com.kishware.core.payment.service.AbstractDebitCreditAgent.createPaymentPacketDto(AbstractDebitCreditAgent.java:113)Muthu,
To find out whether the problem is with container setting or with your application, can you create a simple stateless session bean and check if it works fine. If it works fine send me ejb-jar.xml and sun-ejb-jar.xml for your application.
Deepak -
UsernamePasswordLoginModule exception while running PurgeCache.bat All
Hi All,
I am getting the below exception while running PurgeCache.bat All from OIM_HOME-->plugin_utility.
Note: I have Wlfullclient.jar,weblogic.jar,wljarbuilder.jar under WLS_HOME-->lib directory
Exception in thread "main" javax.security.auth.login.LoginException: unable to f
ind LoginModule class: weblogic.security.auth.login.UsernamePasswordLoginModule
at javax.security.auth.login.LoginContext.invoke(LoginContext.java:808)
at javax.security.auth.login.LoginContext.access$000(LoginContext.java:1
86)
at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:6
80)
at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
at Thor.API.Security.LoginHandler.weblogicLoginHandler.login(weblogicLog
inHandler.java:61)
at oracle.iam.platform.OIMClient.login(OIMClient.java:134)
at oracle.iam.platform.OIMClient.login(OIMClient.java:129)
at oracle.iam.platformservice.utils.PurgeCache.main(PurgeCache.java:67)
Thanks in AdvanceMake sure wlfullclient.jar is in wls_home/server/lib directory not wls_home/lib directory.
regards,
GP -
Getting error when running the jar file..
Hi All,
I am new to executing jar file..Actually i have one class which contains the following code.
import com.documentum.fc.client.DfClient;
import com.documentum.fc.client.IDfClient;
import com.documentum.fc.client.IDfSession;
import com.documentum.fc.client.IDfSessionManager;
import com.documentum.fc.common.DfLoginInfo;
import com.documentum.fc.common.IDfLoginInfo;
import com.documentum.fc.common.DfException;
import com.fidelity.ftg.ereviewg2.migration.util.MigrationResource;
* This class is used for creating docbase connection
* *@type* DocbaseConnection
* *@author* a405304
* *@see*
public *class *DocbaseConnection {
//public static ResourceBundle resource;
IDfSessionManager sMgr = *null*;
IDfSession session = *null*;
String docbaseName;
*private* *static* DocbaseConnection +docbaseCon+;
* Constructor for DocbaseConnection
* *@throws* DfException
* *@throws* Exception
*private* DocbaseConnection()*throws* DfException, Exception{
//ResourceBundle bundle = ResourceBundle.getBundle(Constants.RESOURCE_PATH,Locale.getDefault());
MigrationResource bundle = MigrationResource.+getBundle+();
String userId = bundle.getString("DOCBASE_USERID");
String password = bundle.getString("DOCBASE_PASSWORD");
docbaseName = bundle.getString("DOCBASE_NAME");
IDfClient client = DfClient.+getLocalClient+();
sMgr = client.newSessionManager();
IDfLoginInfo loginInfo = *new* DfLoginInfo();
loginInfo.setUser( userId );
loginInfo.setPassword( password );
loginInfo.setDomain("");
sMgr.setIdentity( docbaseName, loginInfo );
session= sMgr.getSession( docbaseName );
System.+out+.println("# Connected to Docbase: "+session);
}Now i create the jar file whose name is docbaseconnection.jar
Now when i am running this jar file by using the following command then i am getting the following error..
C:\JAR_FILES>java -jar docbaseconnection.jar
Exception in thread "main" java.lang.NoClassDefFoundError: com/documentum/fc/client/DfQuery
For running this docbaseconnection.jar file i need the following thing in classpath...
C:\Program Files\Documentum\dctm.jar;C:\Program Files\Documentum\Shared\dfc.jar;C:\Program Files\Documentum\Shared\log4j.jar
I already add this jar files in the classpath of environment variables..Then also i am getting the same error..
Kindly help me...........Well, let´s supose your manifest is defined as I did in my previous post. So, your directory base should be something like:
C:\dir
docbaseconnection.jar
dctm.jar
dfc.jar
anotherlibraries.jar
But, let´s supose you want something like
C:\dir
docbaseconnection.jar
lib (folder, which contains dctm.jar, dfc.jar, etc)
Then you should change the class-path of your manifest to
Class-Path: ./lib/dctm.jar ./lib/dfc.jar
That´s what I meant -
Hello,
I got a java jar file which contains folders with class file. When I double click on the jar file, it gave a error
Exception in thread "main" java.lang.NoClassDefFoundError
How can I run this jar file?
Thanks,
CRHello,
I got a java jar file which contains folders with
class file. When I double click on the jar file, it
gave a error
Exception in thread "main"
java.lang.NoClassDefFoundError
How can I run this jar file?
Thanks,
CR... and assuming that Jar contains a manifest file, what does it look like? I would guess that the Main-Class entry is incorrect, or that the Jar has external dependencies to other jars not listed properly in the Class-Path entry.
Maybe you are looking for
-
Document not auto cleared after performing FF67
Hi all, firstly i would like to acknowledge that i'm using version 4.7. after performing FF67, bank recon document generated in main bank & clearing bank GL accounts. But it is not auto clear in the clearing bank GL account. the treatment is as post
-
Downloading Solaris 10 6/06
I am using the Sun Download Manager (SDM) to download Solaris 10 6/06. I was able to download the 1st ISO and started on the second but the download keeps failing. Anyone else having problems or have a solution? This is what I have in the SDM log: In
-
ITunes albums Not Synching with Photoshop Elements 13
I just upgraded to Photoshop Elements 13. Since upgrading, the Photoshop albums that I select to synch from iTunes are no longer updated on my iPhone. I had the same problem when I upgraded to Photoshop Elements 12. For v12, the problem was resolv
-
Change periodic app to YTD app
Hello all, Due to reporting and analysis problems, we would like to change our people management application from Periodic to a YTD application. Changing the type of an application is the first time we do. What should be considered in this change? Th
-
From App World i downloaded couple of Games. When i opened them, suddenly a silly looking Game Application popped up forcing me to Get Started. Now when i say NO, it switched off my actual game of interest. When i try to Delete/ Un install this GAME