I'm trying to understand the threading models available in the HotSpot JVM. I'm aware there's info in the link below: http://java.sun.com/docs/hotspot/threads/threads.htmlHowever I'm a bit confused because it states that it's for the SolarisTM OS. Can't the HotSpot JVM be used on ...
We are currently using JNI for transferring simpele/primitive types from Java to C++ successfully. 1) How JNI is enables to convert complex objects such as hashMap, Vectores from Java to C++ and vice versa.2) We want to send a Hashmap .We try to send the Hashmap as a "jobject". The question is ...
Hi, I'm running JBoss 4.0.5 on Redhat Linux 64 and java 1.5.0_12. The server has two dual core processor and ten gigabyte of ram. I start JBoss with : -Xms4096m -Xmx5120m -XX:PermSize=128m -XX:MaxPermSize=256m -XX:NewSize=2048m -Dsun.rmi.dgc.client.gcInterval=3600000 ...
599 byte By
AlanOLa at 2007-11-27 7:12:34
Hello,I have a process that is started with a max heap size of 256 megabytes....However after running for a few hours the process size on Linux is seen to start growing and keeps growing to well over a gig of RES memory usage (another gig of VIRT can also be seen)I have been looking at this for ...
How to find default heapsize on solaris allocated for jvm?moreover how to increase it?is it stored in any file or any parameter needs to be set?please explain in detail.......thanx in advance
In development environment, I built a servlet application via netbeans on Windows XP (32 bits). I am going to delopy the war file on a Sun box x 4100 with AMD Opteron/Solaris platform(AMD 64 bits). However, I was told that the java classes need to be recompiled on the opteron box since the java ...
Respected Members ,I Want to know from you that How Can i Call the above mentioned Function As early as possible Thanks in Advance Reply!!!!!jayesh.dulani@gmail.com
Hi I got jdk 1.4 and jdk 1.5 installed in my system.So now the point is, consider i am running some services compatible to jdk 1.4 and some compatible with jdk 1.5.Now tell me how the JVM handles this scenario....?Thank you
void Callback() {if(env == NULL || gObj == NULL) return;jclass cls = env->GetObjectClass(gObj);if(cls){jmethodID mid = env->GetMethodID(cls, "MyMethod", "()V");if(mid) env->CallVoidMethod(gObj, mid, NULL);else printf("mid is null\n");}}In the above code, env & gObj are global ...
In out project we have two DLLS which export the same JNI functions.We have a single base class which interfaces to them then two subclasses which implement specific functionality (ie. the DLLS are plugins that conform to a spec, the java classes are the specific classes to load the dlls).All ...
I have an AccessibleContext and type cast it to jobject:long accID;jobject obj = (jobject) accID ;Type casting seems to be successfull but I cannot get class of obj :cls = env->GetObjectClass(obj); //JNIEnv* envPlease help me to fix this one. I appreciate your response. ...
336 byte By
zsseana at 2007-11-27 7:50:22
I have the following code:function a{call JNI_CreateJavaVMdo some thingDestroyJavaVM}function b{Call function a;call function a again;}the problem is when I "call function a again". the create function returns -1. anyone has any idea ...
ok here is the deal, when i play runescape for like 10 min, after restarting my computer, runescape just logs off randomly and i have tried everything, restarting my computer and reinstalling java and internet explorer but runescape works the best after i restart my computer but once it crashes ...
15033 byte By
Giela at 2007-11-27 7:51:19
Here is the complete error file: ## An unexpected error has been detected by Java Runtime Environment:## EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x2309cfa0, pid=3108, tid=2896## Java VM: Java HotSpot(TM) Client VM (1.6.0_01-b06 mixed mode, sharing)# Problematic frame:# C 0x2309cfa0## If ...
Is using verbose:gc and other print GC options an overhead to running java.Questions have been asked that it might cause some performance issues because of the logging.
1.We used following mem_args with jvm 1.4 and weblogic 8.x. Recently we upgraded to wls 9.2 and jvm 5.x. Please suggest me whether following mem args still suitable with jvm 5 for better performance. If not, advise me required changes for better performance. USER_MEM_ARGS=" -Xmx512m -Xms512m ...
We are running a web based application & below are the details.App Server : Websphere Application Server 5.1 Fix pack 12.Linux , JDK 1.4.2_03, 2 CPU, 4 GB RAM.The min heap set is 256 M and Maximum is 1024m.When we start our application and we more users login, we see the Java process memory ...
512 byte By
Dummya at 2007-11-27 8:08:38
Hi,I have C code that must create a JVM through the JNI invocation interface and later make several Java method calls. Is there a way to debug Java code called from C functions. My C code is not standalone but is run from an external db plugin (I can only customize this code). I probably have ...
Hello. I'm having some problems with the JVM. Whenever I open up my browser ( doesn't matter with), it always ends up closing down, and leaving me with a hs_err_pid- document on my desktop. Can anyone help me by giving me ways to stop this?
iam setting the max heap size to 1GB in java 1.4, but sometimes during the run of my application i do get Out of memory error.If increasing the max heap size is the solution then how do i do that?I have set the initial heap size to 64MB while my machine RAM is 2GB.Please advice.Thanks in ...
Hi,we're using Linux 2.6.9-55.ELsmp on 2 x Xeon 2.4 Ghz machines.Now we switched from 1.5.0_11-b03 to build 1.6.0_01-b06, mixed mode and all applications are tremendously slower, about 7 times. Servers which were using 10-15 % CPU are now using about 85%. On windows everything is running as ...
I was working a problem with connection pooling and it was pointed out that to utilize pooling all my workstations would have to be using the same JVM.I am not clear how one determines how to use the JVM locally or remotely, or some other way?Would anyone have an simple explanation for this and ...
809 byte By
csb42a at 2007-11-27 8:19:14
Hi, I have some existing C++ classes objects that I would like to access through Java methods. However, if I use a java method to create an instance of a C++ object, and then I want to edit the state of that C++ object through java, how do I reference the correct C++ object.For example, if I ...
1176 byte By
cactuara at 2007-11-27 8:20:35
I am working on a 64-bit AIX5.2 machine. I created a hello world program using JNI. When I run it, System.loadLibrary() does not find my shared library. After looking into it for several hours, I realized it might be something to do with my 32 bit mode build. The reason I am building as 32 bit ...
Hello,The dll gets correctly loaded but when the cpp code tries to find the java class from where it is invoked, it throws an error for class not found. My cpp code is given below :JNIEnv *_env = 0;jclass _clazz = 0;char className[] = abcd/xyz/myClass";_clazz = ...
I have an application that needs to have low virtual memory usage, since several instances of different users are running on the same machine. I'd like to avoid -Xmx limit since the application sometimes needs more memory. I've tried using:-XX:ReservedCodeCacheSize=48m ...
Apparently, HotSpot starts some number of internal threads.In my environment (SUSE Linux 10.1, JDK 5, Intel Dual Core) , when I run a simple single-threaded test program(just your basic 'hello world'), I see 12 threads running. There are probably 2 GC threads, 1 main thread, what are the ...
Hi,Apparently, HotSpot starts some number of internal threads.In my environment (SUSE Linux 10.1, JDK 5, Intel Dual Core) , when I run a simple single-threaded test program(just your basic 'hello world'), I see about 15 threads running.There are probably 2 GC threads, 1 main thread, what are ...
548 byte By
Omkaraa at 2007-11-27 8:38:26
I am confused about JVM.My questions are :Is 1 JRE = 1 JVM ?Is every invocation of a java program start a separate jvm e.g. 2 instances of notepad show notepad.exe twice in task manager ?If I start 2 java programs from command line simultaneouslye.g. java cls1 and java cls2Does it mean there ...
Hi guys.I am in need for help.I have to wrap a c++ application to Java using JNI. from then i have to make the java into a servlet.The c++ application is an AXIS camera API written in C++.My knowledge is only on JAVA. Seriously i need help.anyone can help me. please. thanks in advance. ...
Hi,My application uses RMI for communicating between two java processes. I'm observing some kind of memory leak in one of the classes in RMI library.When observed through OptimizeIT, I see a large number of Object[] being created by the ClassDefiner.defineClass() & ...
1993 byte By
syg6a at 2007-11-27 8:51:55
Hello,I have a cache app running on Red Hat Linux. It's a 2-processor, 4G RAM machine with 2.3 G of RAM assigned to the JVM. I am using the Parallel Collector and have set NewRatio to 4 (it was set to 8 by default) to try to make Minor Collections less frequent, thus deleting more dead objects ...
I wonder, is there a way to bypass MSJVM. In other words, there is a web site that i have to use, and the they make the web site with MSJVM and cannot access with any tool except MS Windows+IE. I would like to access that web site in other platforms and browsers. The web site that i have ...
Hi,I'm running a java server app on a 4-core 64-bit Linux box with JDK 1.6.0u1The system has 8G of physical RAM and the java app is the dedicated app running on the server. I've allocated a max heap size of 8G to the java app.The app does a lot of caching and as expected, the old gen starts ...
Hi,i use jawin to run a dll which creates xml-files. In some cases i have to stop the creation of the xml-files. But there is no way to stop the invoked function of the dll. The sourcecode of the dll is not available . But i assume that the called function is a "normal" method without threads. ...
Hi, I've packaged and deployed my java application as a dll using the activex bridge. I can get calls from the COM host just fine, but I'm not being able to pass values across to the host. For example, the COM host specifies that a property called 'Long Version' be set. So I've created an ...
412 byte By
palthia at 2007-11-27 9:07:23
want to call a generic dll from JAVA. The dll is provided by thirdparty. I am able to load it using "System.load("dllName.dll");" but i am now confused how can i call the methods. Since it is not made by me using JNI so there is not method with "native" keyword. its methods are not having ...
If you use -XX:+UseParNewGC , Parallel YG collector will be used.But If I mention "-XX:-UseParNewGC" with -XX:+UseConcMarkSweepGC" in java 5, what type of collector would be use for YG? Please clarify.Message was edited by: tech_luver
Hi guys. Ive done a succesfully some JNI examples on the web.I have a c++ application together with the dll given. I do not know how to implement JNI onto the application. anyone can help me in this?btw the c++ is an AXIS camera API application.thanks in
1715 byte By
RGAnna at 2007-11-27 9:15:12
Hello!I have a very simple jni - method, which puts a string into the java String field:JNIEXPORT void JNICALL Java_de_getStr(JNIEnv *env, jobject obj){jclassclazz = (*env)->GetObjectClass(env, obj);char myStr[5] = "aaaa";jobject aString = (*env)->NewStringUTF(env, myStr);jfieldID jfid = ...
1281 byte By
cactuara at 2007-11-27 9:15:33
I have a native function that returns a Unicode string, which I use the NewString() jni method to return it. My native string is in UTF16 LE for Windows and BE for Unix (platform default encoding). Currently I am only using the ASCII characters that are represented in UTF16. When I get a string ...
Hello,I get the following error periodically which causes my Tomcat service to stop. There do not seem to be any exceptions listed in my log files, only the "An unrecoverable stack overflow has occurred." error listed in the jakarta_service_yyyymmdd.log file.I am running tomcat5.5.23 on a ...
HIThank you for reading my postby default i run an applicaton using foolowing command, now i want to have access to the objects from within the native applications.here is the code that i used to run the application using normal commands, how can some one tell me how i can run it using native ...
I just started on JNative and I have some questions on about it. I hope someone here can help me with some answers. Pardon me if I sound stupid, I just barely started less than 24 hours. Anyway I have a C structure here...//C code structstruct usb_bus { struct usb_bus *next, *prev; char ...
Hi there,I just recently bought a second GB of RAM for my Notebook, and now I meet the requirements for a server-class-machine (2GB ram/ 2 cpu/ Linux).Is there any way I can tell the jvm without always specifying that I would like to run the client-compiler always?I know I could just use the ...
I want to write a java program using the msn functionality in this program. I'd like to know whether there is any package exists that can include the msn application into a java user interface. Thank you.
1797 byte By
alan_SEa at 2007-11-27 9:25:20
Hi there.I'm trying to load a library by -Djava.library.path=path_to_lib but get error message saying java.lang.UnsatisfiedLinkError.I'm doing it this way because I'm trying to write a midlet.So the questions are: Is this possible in a midlet andif possible what am i doing wrong:My java code ...
976 byte By
Popupa at 2007-11-27 9:27:02
Hi all,I am trying to execute a C program from a Java Program. All things are working fine but when I am returning a char* pointer from C code to native C file I am unable to get this string(In opposite to that I can send a char* from native code to C code)In core C code I am doing:-struct ...
477 byte By
gripusaa at 2007-11-27 9:30:15
Hi guys, i am bit confused and i hope so somebody clerify this, i am working to access COM dll through JNI but as we know all the litrature and references always point out that the language should be used is C++ (altough i cant understand why it is so as dll is bit generic and should be ...
Hello,I have injected a DLL having JNI code into Java Application using CreateRemoteThread() function.Then i created a Thread using CreateThread() function in DLL_PROCESS_ATTACH.I wanted to attach this thread to JVM already running inside the Java Application. So i used JNI_GetCreatedJVMs to ...