I am using webclient at a servlet. If I make concurrent calls to the servlet the processing speed of htmlUnit decreases a lot. In other posts I read that htlmunit does not support multithreading. Could my case related to that?
Yes, that's possible. But the most problems with multithreading are things like throwing a ConcurrentModificationException or that one thread disturbs another.
The latest snapshof fixes a problem with a lock, that was used by all instances of DomNode. Maybe this helps a bit.
Can you please try the latest snapshot.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Do you use a single WebClient instance shared among the requests? If yes, this is not supported (and will probably never be supported).
How many concurrent calls do you have when you notice performance degradation? Is it possible, that it is the normal load due to the number of requests * single task load?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am using distinct instances between the threads. In fact, each one is created at a different servlet instance. Calls to the servlet are concurrent. I notice performance degradation very sooner, when there are 10 instances running simultaneously.
I will try with the latest snapshot and I will tell you how it works.
Javier.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Yes, that's possible. But the most problems with multithreading are things like throwing a ConcurrentModificationException or that one thread disturbs another.
The latest snapshof fixes a problem with a lock, that was used by all instances of DomNode. Maybe this helps a bit.
Can you please try the latest snapshot.
Do you use a single WebClient instance shared among the requests? If yes, this is not supported (and will probably never be supported).
How many concurrent calls do you have when you notice performance degradation? Is it possible, that it is the normal load due to the number of requests * single task load?
View and moderate all "feature-requests Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Feature Requests"
Thanks for all of your responses.
I am using distinct instances between the threads. In fact, each one is created at a different servlet instance. Calls to the servlet are concurrent. I notice performance degradation very sooner, when there are 10 instances running simultaneously.
I will try with the latest snapshot and I will tell you how it works.
Javier.
View and moderate all "feature-requests Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Feature Requests"
I tried again with snapshot-9 and the problem still persists....