Himanshu Jhamb

Ranch Hand
+ Follow
since Aug 01, 2001
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Himanshu Jhamb

Hi Steve,
Thanks for your reply.

Although your comments were extremely helpful in improving my understanding of Eclipse, the problem was somewhere else. After I had referenced my libraries - I guess Eclipse automatically references them in the classpath for that project. When I did the import of the file system, my file system contained a classpath that was overwriting the original classpath of the project thereby deleting the references created, earlier.

The problem got resolved when I explicitly asked Eclipse not to overwrite my existing classpath.

I thought I will just write the resolution in case this is helpful to anyone in the future.

Thanks!
- Himanshu
Hi.

I am having problems with Eclipse projects. I make a new Java project and in the 'Java Build Path --> Libraries' specify a jar file (Any jar file, for example - axis.jar). I click ok and then import certain code that references the package org.apache.axis. Eclipse marks these references as Compilation Errors. Per my understanding, I should not get compilation errors since the jar file (axis.jar) is present in my 'Libraries' (in effect being present on my Classpath). Is my understanding incorrect? Am I missing something here?

After struggling for a long time with this, I experimented some more and did a 'File --> Import --> archive file'. I imported the axis.jar this way - and it exploded the axis.jar file into individual packages into my project's workspace. This resolves my compilation problem. But, I still don't like the clutter of the individual packages in my project's workspace.

Any help would be appreciated.

Thanks!
- Himanshu
Hi

I have written a very simple web service on my local machine. Am using Tomcat w/Apache Axis to implement the same. I coded a very simple *.jws file in the Tomcat webapp directory. The file has two very simple public methods. With Tomcat & Axis, I was able to see the wsdl of the web service on my browser. That said, I started with the client. I generated the stub classes & interfaces (2 each) using the WSDL2Java tool and moved those generated classes in my workspace. Once done, I tried to run my client from the command line (Actually, I am using Eclipse IDE). The client is able to locate the service but throws a NullPointerException on the Call.Invoke method. ( I see this in the Stacktrace). I checked the Apache Axis docs for troubleshooting and found that it might be the Validation library (Crimson, by default) or the fact that the client and server are both on local server. I downloaded Xerces and referenced it in my project. I just do not understand why there is an issue with the client and the server being on the same local host. Does this mean that if the web service is on a remote machine, I wont run into this issue? Please help.

Thanks.

- Himanshu
PS> I am using the first example from the 'Real web services' book and having this issue.
17 years ago
Any suggestions, folks?
17 years ago
Hi,
Is there a way to set a Timeout for a JAX-RPC call. I am not using AXIS, so the axis api does me no good.

I am using the javax.xml.rpc.* classes and do the following steps for calling my web service:

1) Get a ServiceFactory Instance
2) Create the Service Instance using the factory & wsdl etc
3) Create a Call Obj from the service Instance using the operation name
4) Call invoke() on the call object

So, where can I specify my timeout if I want to timeout, after say, 30 seconds. This is a synchronous web service call.

Thanks!
17 years ago
Hi,
I am working on an XSL and am facing a problem thats been troubling me for a while. Being new to XSL, this might turn out to be a basic problem... any help would be nice.

Source Document looks like:

<TopLevelTag>
<Level1>
<Lv1Tag0/>
<Lv1Tag1/>
<Lv1Tag2/>
<Lv1Tag3/>
<Lv1Tag4/>
</Level1>
</TopLevelTag>

I want my XSL to work on tags Lv1Tag1, Lv1Tag2, Lv1Tag3 and transform the above to:

<TopLevelTag>
<Level1>
<Lv1Tag1/>
</Level1>
<Level1>
<Lv1Tag2/>
</Level1>
<Level1>
<Lv1Tag3/>
</Level1>
</TopLevelTag>

I tried thinking of using <xsl:for-each> but could not think up a solution. Tried exploring the internet for XPATH options available, but to no avail.

I dont know if it helps, but I tried to see if a regular expression can be used in the XPATH somehow. But, I guess thats more of a XSLT2.0 feature (I have to work on 1.0) & I cannot use that.
Hi,
I am at a crossroads in deciding the I/O package I have to use in my current project. We are using Sun JVM 1.4.2 and I wanted to know how stable NIO is at present. I know its been around for a while (> 1 year), but I wanted to know if someone has this in production handling huge amount of data... and how is its performance?

Also, if someone can quickly point out the PITFALLS of using NIO (the most common mistakes that folks do while using NIO) and certain "MUST HAVE" features that that one must utilize to harness the power of NIO, that would be great.

I do have an option of using the threaded listener model (JVM 1.3.x), but ideally, I would like to save my system the unnecessary threading, if possible.

thanks!
17 years ago
Hi,
Thanks for your response.

I understand that the user has to checkout the entire project at the beginning. The question really is:

I want to use Eclipse on my local machine to integrate w/a Linux backend. The code is in CVS on the Linux box. How can I checkout the code files, make my changes, and check them back in to CVS? Are you saying that a developer cannot commit his changes back to CVS with eclipse? If thats the case, then how does source controlling work w/Eclipse?

Thanks!
Hi All.
I recently downloaded eclipse 3.0.1 to my windows 2000 machine and am trying to access an already existing CVS Repository on a red hat linux installation.

I was able to get to the repository using ssh2 and once checked out all the files. When I tried to open a .java file, it came up as 'Read-Only'. The problem is I just cannot seem to get around making it editable. My goal is to get the remote CVS working w/the local Eclipse installation.

I know there is a feature in the Preferences menu to get to the CVS Perspective options. I tried enabling the "Configure projects to use Watch/Edit on checkout" and then checked out the top level directory again, reopened the same file but it was still Read-Only and it would not let me edit it.

I have the following questions:
1) How do I make a file Writeable in this situation?
2) Can I check out individual files also OR does Eclipse allow only directory based checkouts (maybe this is a CVS limitation, not an Eclipse one - I am not sure)

Thanks in Advance!
Hi,
I have an application deployed on WLS6.1/WLI2.1 & was looking for some help regarding how to get the number of messages in a particular JMS Queue without going to the weblogic console.
Main concern is the speed with which I can access this info. The Weblogic console is extremely slow in response times. I also tried developing a home-grown solution (made a tool using MBeans) but that was also very slow - which kind of makes sense 'coz the weblogic console also uses MBeans to get the Queue Depth.
Is there any third party tool (preferably free... which I can use to get the count of the # of messages in a particlar Queue ? Again, the speed is imp. to me... Any suggestions/ideas ?
thx
Where can I find the API for this package/class?
I tried searching the sun site as well as the internet, in general - could not find anything....
Can anyone help, pls?
We haven't really pointed out the exact place using a profiler in the dev env... but we found from a production monitoring tool that this collection is the culprit.
So, we did use a tool - now we need to find a way to fix this hole... or at least clean up after it.
18 years ago
Hi,
We have a app in production where we are seeing a bunch of these errors & we believe its being caused by an internal Collection of objects that we maintain (for each request) throughout the life of the request
We strongly suspect that at times this collection is not getting cleaned up properly & thus causing memory leaks. The correct solution would to see that the collection is null'd for the requests at all exit points. I am afraid we dont have the time to identify all these as quickly as we need the solution.
Are there any suggestions that folks over here can make on how to track the culprit requests still hanging in memory... Of course, we don't want to eradicate the ones that are still in process... only the ones that are done processing.
thx
18 years ago
I'm not sure I understand, but A ClassLoader will only load a Class once. After it has been loaded it is cached in that ClassLoader forever.
I highlighted that part, since you can re-load Classes if they change by throwing away the ClassLoader that loaded them and starting a new one.
--------------------------------------------------------------------------
Yes, I do undestand that. I do have a new Class Loader which I invoke from a client by sending a JMS message. While calling the new Class Loader, I pass it the class that I want reloaded. I see the new class loader being instantiated, the overridden findClass() of the new Class Loader being called, the findClass() finds my new class & returns a Class obj. after a call to defineClass(). All this is happening. But, when I run my test case, I still get the same results as if the old version of the Class file I was trying to load is present in the JVM, not the new one.
I hope I have been clear this time.
thx.
18 years ago
Hi,
Okay! I got over that hump... and got stuck on another.
What was happening was ... the JVM classloader was probably finding the said class already loaded and hence was not calling my findClass(). So, I changed it to point to another file ... e.g. instead of xxx.class, I gave it xxx.ini
Once that was done, I again (inside the code) pointed it back to xxx.class & that invoked my findClass(). The findClass() proceeded as expected & found the class that I wanted loaded. But, for some reason, it still did not invoke the *new* class file... but I still see the result as if the *old* xxx.class is being invoked.
Any ideas why the new one is not being loaded inside the JVM???
18 years ago