jar doesn't work
Bug #1871478 reported by
Mauro Mancinetti
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Gearman Java |
New
|
Undecided
|
Unassigned |
Bug Description
Hi guys,
I write you cause I am trying to use the jar but I believe that there might be a problem with the latest version of gearman as when I try to run the examples, it doesn't work.
I am not familiar with gearman so I am just following your instructions and what happen is that the program gets stuck.
The point where it gets stuck is when the following instruction gets executed:
client.
Could you give me any help please as I'd like to use your library instead of some other non official handcrafted ones.
This one looks pretty good to me even if it looks like it's quite a while nobody works on it.
I hope to get an answer from you.
Thank you in advance.
Mauro
To post a comment you must log in.
Indeed this project hasn't been active in a while. I had some issue in the code running into an infinite loop while running with Java 11 while it works fine under Java 8. Maybe that is your case as well?
I have a made a fix that breaks the infinite loop and that seems to do the trick for Java 11:
--- src/main/ java/org/ gearman/ common/ GearmanJobServe rSession. java 2011-02-01 21:26:50 +0000 java/org/ gearman/ common/ GearmanJobServe rSession. java 2021-01-11 21:49:54 +0000
handleSessionEv ent(new GearmanSessionE vent(p, this)); //NOPMD
+++ src/main/
@@ -198,7 +198,7 @@
while (canRead()) {
p = connection.read();
if (p == null) {
- continue;
+ break;
}
}
More details at https:/ /phabricator. wikimedia. org/T271683# 6737850