Source Profiling a native DLL

1037 byte By dinglemousea at 2007-10-2 21:27:48
I have native DLLs (C/C++) called via JNI I have the source code for the DLL and also for the Java that calls it, however this is *not* an application - in fact it is just libraries providing a CORBA implementation. I also have a java test program that invokes these java CORBA APIs.I would like ...

java.lang.OutOfMemoryError: Java heap space

643 byte By Hi_i_am_Amita at 2007-10-2 21:29:24
Hi,I am working on an web application. I get this OutOfMemoryError when i run a process which the input as a 1KB file.The process is actually launched with a heap size of 128MB, and multiple jvms are launched to run multiple processes.The heap size specified is actually more than enough for the ...

Only one instance of JVM? send parameters to this instance?

808 byte By Neubauera at 2007-10-2 21:30:22
Please help me. I don't know how to solve this problem. Is there anyone, who can help me?Scenario:- Open Java program without special parameter (like 'java test'). There can be multiple instances of this program (ok, this is normal), but:- Open Java programm with special parameter (like ...

JACOB HELP

1767 byte By Kurilenko_Denisa at 2007-10-2 21:31:35
Hi All.I have following COM Interfaceinterface Ihtmimgcom : IDispatch{[id(1), helpstring("method RenderHtml")] HRESULT RenderHtml([in] BSTR url, [in] int type, [in] long timeout, [in, out] BYTE** pBuf, [in, out] int* size);};It is rendering service for htmls that accept url of resource, type of ...

SoftReferences being cleared too aggressively?

873 byte By RGibsona at 2007-10-2 21:32:27
I have an RMI server application which I am running with java -Duser.timezone=GMT -Dcom.sun.management.jmxremote.port=5555-Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false-Xmx1800m -Xms1024m -ea -serverI have several caches, which are all implemented ...

System.load("C:\\tmp\\filename.dll") - Can't load library

2309 byte By emreayavuza at 2007-10-2 21:33:18
Has anybody tried calling a ".dll" file from a java script by defining it as a native method ? I'm having a problem while trying to load the .dll function that I have generated using MATLAB 6.5. I don't know whether it has something to do with the MATLAB version, but I am mentioning it just ...

Converting *jbyte to unsigned char[1514]

146 byte By bobthegoatgoda at 2007-10-2 21:33:39
I've tried many ways to get that to work but i can't seem to get it. could anyone help?Message was edited by: bobthegoatgod

JNI API

165 byte By OnCoreJavaa at 2007-10-2 21:35:00
Hi,Can anybody please, suggest me an API for JNI......and also will be helpful if u also send me a simple example of using JNI.Thanx in advance.

Java calling C/C++ and back (asynchronously)

713 byte By Nachoa at 2007-10-2 21:35:54
Hi everybody!, i have the following issue.I have an API in a dll wich allows you to register functions (in C) which will be called when some event occurs.I have to register a Java function so i hava a native method from wich i can access this dll and register another C function into the API, ...

Calling JNI library method from C++ code (How to get JNIEnv object)

1152 byte By a1prashanta at 2007-10-2 21:35:55
Hello All,I am writing a MFC application and dynamically loading the JNI library.LoadLibrary succeedsGetProcAddress succeedsBut inside JNI library when env-> functions are used it crashes.It is obvious because env is instantiated from JNIEnv, and JNIEnv is empty structure defined in jni.h ...

Catching System.loadLibrary exceptions

5402 byte By safira at 2007-10-2 21:37:45
I looked at the JNI book examples, and none does that. So i conclude that it is better to let that exception propagate up the stack. It makes sense because otherwise class behavior would be undefined. If you have evidence to the contrary, please speak ...

Build a DLL ( an error )

2211 byte By Taurenla at 2007-10-2 21:41:24
I want to use JNI to call an method in "demo.cpp". I write a "CallDemo.java" and build "CallDemo.h". Then I try to get a Dll. There is the error. F:\MyProject\MyRobot\test_JNI\calldemo\demo>CL -ID:\j2sdk1.4.2\include -ID:\j2sdk1.4.2\include\win32 -LD demo.cpp -FeDemo.dllMicrosoft (R) 32-bit ...

HotSpot Server VM crash (core dump) when my Java app calls a native library

6250 byte By jnan-prasad_chukka@tcsa at 2007-10-2 21:43:36
Unexpected Signal : 11 occurred at PC=0xC56DDCD0Function=_shlInitLibrary=/opt/java1.4/jre/lib/PA_RISC2.0/server/libjvm.slCurrent Java thread:"main" prio=2 tid=00059ba8 nid=1 lwp_id=7172319 runnable [0x77ff2000..0x77ff1910]at oracle.jdbc.driver.T2CConnection.t2cCreateState(Native Method)at ...

How to integrate norton antivirus in java application

319 byte By Rookie_95a at 2007-10-2 21:44:02
hi allI would like to know that if their is any way of Configuring external applications with java.what my requirement is that i have to scan the files to be uploaded in java application(and i have to use norton antivirus) and before storing them i have to scan them using antivirus ...

Garbage Collector blocks applications

8813 byte By NiklasOa at 2007-10-2 21:49:12
We have a JSP/custom tags-based application running on a Sun Solaris machine with Tomcat 5.0.28.We've experienced severe problems lately where the GC takes up more and more time and finally blocks the application completely. No requests are coming through and one of the two CPU's is ...

Getting error Terminated, exit value: 128>

225 byte By kamalkga at 2007-10-2 21:49:37
Hi,I am trying to launch a java application and I am getting this errorTerminated, exit value: 128>Seems like a JVM crash issue, But not sure can anyone put some light.RegardsKamal

native function causes jvm crash

577 byte By estiedia at 2007-10-2 21:51:51
Hi,I have to use a commercial C API that communicates with a remote server using CORBA (they have a Java API as well, but that calls the same C API functions through JNI). If the server cannot respond correctly to the clients requests, it crashes the JVM.I've contacted support of this C API ...

Memory freed by GC not reflected in Task Manager of windows

466 byte By ashish.chopraa at 2007-10-2 21:54:51
HiWhen I run my Java application for a long time, I see that the garbage collector runs fine (verified this using -vebosegc), but I cannot see any reduction in the memory usage of my application(javaw.exe) in the task manager of windows. This goes on increasing slowly.Also I have checked my ...

Login and username?

313 byte By javitaa at 2007-10-2 21:57:06
Hello! I am using J2SE to show an application in my PC from another one. But some time Java show me a windows asking for login and username. I can not understand the login and password. This is not password of PC 1 or PC 2. Could someone tall me what is the login and username of java ...

Way to identify objects that got GC'd?

415 byte By BrianBarnetta at 2007-10-2 21:58:29
Hello,I'm wondering if there is a way to identify which objects are getting garbage collected? Our app intermittently slows way down, but we don't know exactly what was happening at the time. Our logs show a bunch of garbage collection going on. If we could know what objects are being ...

CMS runs too frequently in JDK1.4.2_11

6080 byte By singhalankit1a at 2007-10-2 22:03:19
Hi AllIn one of EJB Containers I am seeing that CMS is running too frequently.And because of that the CPU Usage is very high.And the thoughput has also decreased.But as soon as I stop using CMS , everything is backed to normal stage.I am attching the GC output. Does anyone has any Idea about ...

Redefining operators

458 byte By R.Singha at 2007-10-2 22:04:52
I want to redefine certain operators (instanceof and casting, specifically) using native code. I have this need for my custom Java-COM interoperability bridge. For the instanceof operator I want to do a runtime QueryInterface to determine if a java cast is to be allowed. Standard JNI does not ...

Global Variables

157 byte By smayea at 2007-10-2 22:10:08
Will the JVM garbage collection clean up global variables? Is a good practice to only use global variables when needed and mainly use local variables?

Help writing to file in "C" using JNI

1806 byte By sshyama at 2007-10-2 22:10:51
Hi,I am trying to write the encrypted data that I read from a file. It writes the decrypted data; however, it prints extra characters at the end of file after the data. I am not sure why this is happening. Below is the code that I use to write the decrypted data to a file. I am using "C" and ...

Machine getting shutdown

697 byte By rakesh_76a at 2007-10-2 22:18:11
Hi I am doing stress testing against my application. after sometime my machine is getting shutdown. I am using JProbe profile tool for finding out what exactly problem... i have given my application heap size --ms512m -m512m.(Total 1GB of memory on windows XP machine).when i run my stress test ...

CREATING POWERPOINT REPORTS USING JAWIN

556 byte By Sansa at 2007-10-2 22:20:22
Hey all,I have a certain requirement in creating a power point report through java using jawin. I want to create a report in the Power Point with all the values coming from some java object, say for example 揳n array list or any collection objects? It should also be able to display some ...

memory required by JVM

355 byte By itcareera at 2007-10-2 22:21:10
Hi,I need to run a Java application that would handle around 2-3 GB of data at a time.The system would have a 4 GB RAM.I would like to know whether there would be any problems in doing that?Would my JVM complain for non-availability of memory(i.e. OutOfMemory error)?What amount of memory should ...

SIGBUS with -Xincgx/-Xconcgc for JDK 1.5 on multi-CPU system

917 byte By DamonHDa at 2007-10-2 22:22:50
Hi,I've been having trouble with random crashes using 1.5.0_03 up to _07 on Solaris and Linux (x86), especially on multi-CPU hosts. This is for a Web server (Tomcat 4.1.x), where CMS has been wonderful in avoiding the sometimes-horrible (multi-minute) GC pauses that I otherwise saw inspite of ...

JVM memory footprint and overhead

1830 byte By -bsx-a at 2007-10-2 22:22:57
Hi,We are running several 64-Bit JVMs on Solaris 8. All VMs are configured with -Xms1536m -Xmx3072m -XX:MaxPermSize=512M.Recently we ran into memory issues on the machines and noticed that the VMs are 3.5GB to 7GB in size as reported by prstat.These sizes imply a per VM memory overhead of up to ...

Core dumps with 1.5.0_06-b05... any idea why?

18789 byte By filipKa at 2007-10-2 22:24:08
I am trying to run 1.5.0_06-b05 with Tomcat 5.5.9, and the application keeps producing core dumps from the JVM after some period of use. The hs_err file says the following:-## An unexpected error has been detected by HotSpot Virtual Machine:## SIGSEGV (0xb) at pc=0xfee32868, pid=17413, tid=10## ...

java.exe Memory Terms

255 byte By has_stara at 2007-10-2 22:25:21
can any one explain me the different terms use in relation to memory for java.exe such as PERMSIZE, HEAP, NONHEAP MEMORY etci aslo want to know terms such as EDEN SPACE, SURVIVOR SPACE, TENURED GEN, CODE CACHE, PERM GEN etc used in jconsole.

How to create java class from C header file

93 byte By Alenaala at 2007-10-2 22:26:45
Hi,does anyone know how to create/build java class from existing C header file?

How can java Disable Shutdown and Restart in Windows ?

304 byte By c2005sa at 2007-10-2 22:31:02
Hi everybody!!!!i'm going to develop a cybercafe manager using java...one of it's features is to disable windows shutdown and restart & getting the running processes on the client...i wanna know how to acheive this features ..... thank u for ...

How does a JVM schedules equal priority threads.

105 byte By alok.aa at 2007-10-2 22:32:05
How does a JVM schedules equal priority threads. Is the policy JVM implementation specific?

How-to get VMID for jvlstat tool

467 byte By alexander.rozhkova at 2007-10-2 22:34:46
Hello!I would like to use jvmstat tool for gathering runtime info of our application. The problem is that application is running on Windows and executed from native process via jvm.dll so jps doesn't see it.Is VMID used by jvmstat the same thing as the class ...

JVM getting killed sillently in Linux

1014 byte By deepakkm@gmail.coma at 2007-10-2 22:34:50
Hi I am having a strage problem of JVM getting killed while running my program in Linux. During this time I an not getting any dumps or any messages other than the messaeg <PID>Killed.This program reads a Random Access file and then write it into Oracle database. The database insertion is ...

Legacy C program -> new Java GUI and calling methods

1006 byte By vmehta211a at 2007-10-2 22:34:54
Hello,I am fairly new to these forums. I've been working for a company that has an exsisting program that is a propriotery video-client to a video-server. It is written in C and has DirectX components for the standalone C application and ActiveX components for the Internet Explorer version. I ...

Problem using standard libraries in C++ class

1676 byte By shradhaa at 2007-10-2 22:35:34
Hi I am new to JNI. I am having problems using standard C++ library.My java code looks like public class JavaSide {public native void sayHello();static { System.loadLibrary("NativeSideImpl");}public static void main(String[] args) { JavaSide app = new JavaSide(); app.sayHello();} }and My ...

EXCEPTION_ACCESS_VIOLATION

15267 byte By beginner_needs_helpa at 2007-10-2 22:43:02
I have been trying to log into one bank website. At the start, it asked me to download some Java stuff (sorry but I couldn't recall), and it keeps on producing the crush. Finally when I re-enter the site just by typing in the website address, and the site automatically shuts down before even ...

how to use function in dll file

201 byte By suhaspna at 2007-10-2 22:45:19
hi i am new to jni. i want use the function declared in the dll function. i am also having the .h header file. can anybody please help me out with this?thank yousuhas

JVM ,JAva Runtime, JDK

169 byte By Madhurama at 2007-10-2 22:45:45
Hi EveryOneI want clear differcence between JVM ,JDK and Java Runtime And which includes whick one ?For running .class file what we require ?

Hot spot Exception

10041 byte By sreenu44a at 2007-10-2 22:50:49
Hi I got some Hot spot Exception in my project, can any buddy help me regarding this, here i am sending all log information.JDK version 1.5.0_04-b05 roblem Description ==================== Hot spot Exception found on OMGr sever on which is enrolled in AP and APSWACT and SSO operations have been ...

JDK1.5.0_06 -XX:SurvivorRatio setting is ignored?

1509 byte By sophiaxa at 2007-10-2 22:54:24
We upgraded the JVM from the previous 1.4.2_08 to the 1.5.0_06 and we are using the traditional copying collector. I found the -XX:SurvivorRatio setting is ignored by the new VM. The following is my settings and the output from jstat:JAVA_OPTIONS : -server -Xms1536m -Xmx1536m ...

Use JNI application has memory manager, feasible?

761 byte By PatrikOlssona at 2007-10-2 22:56:53
Hi, This is an attempt to circumvent javas poor memory management capabilities. Since java is unable to allocate memory dynamically (*) I'm thinking of writing a native library capable of allocating memory and then allowing java applications to stow away data in this area. The application ...

Why execution of jar is taking larger time?

591 byte By Nitin_Chaudharya at 2007-10-2 22:57:10
Hi,I have the signed applet code in JDK1.1, and for the same code base size of jar file is larger then cab file, this is because of insertion of Manifest files in the jar.Now I am executing the same code using both JRE(jar file) and MVM(cab file). But I am observing time difference between the ...

Questions about an object's init method

537 byte By Sunny_Daya at 2007-10-2 22:58:57
Hi folks,I am wondering if there is at least one init() method implicitly defined for each normal Java class (e.g., classes which are not Applets or Servlets), and what is the relation between a user-defined constructor and the init(...) method (e.g, which one of them is called first by the JVM ...

How to access each member variable from a C structure in Java using JNI?

895 byte By get123a at 2007-10-2 23:00:56
Hi All,I have a very very Urgent requirement.We a complete c code to develop a particular tool.Now we are trying to migrate/port to Java using JNI.Say for example I have a Structure in C as follows.struct Type1{ Char name; char * proc; int data; GUsage * Usage; //the usage that contains Array ...

excpetion while calling NewObjectArray 2 times

2712 byte By ap290a at 2007-10-2 23:06:04
I am calling a C++ method from another C++ code 2 times. First time, it works ok but second time, JVM throws an exception and terminates. Any idea ? It throws an exception while calling _env->NewObjectArray I have posted relavant portion of my method## An unexpected error has been detected ...

Calling a DLL

568 byte By inyoa at 2007-10-2 23:07:25
I want to screen scrape data from mainframes to my java application... Please tell me how to proceed with this... I have third party tool (Attachmate - Extra For windows) and it has some of its own DLLs that we used to scrape data when the application was earlier in VB... We are now migrating ...

sizeOf ()operator

131 byte By thomasa at 2007-10-2 23:07:30
hi friends i know that java doest not have sizeOf() operator as in c,c++.then how do i can get the size of int,float, etc...