Thanks a lot!
Several doubts.
- in each client handler, how it is notified of a SIGTERM signal? I guess there should be only one instance of signal handler running and it is as what you coded in above. But how signal handler pass the signal to each running processes and threads in real-time...
I have a program that uses socket in this way: Client A has a socket connection to Server B. A sends some data to B. B processes data and return results to A.
However, sometimes, B might take too long to process data and in such a case, for efficiency consideration, A would expect B to simply...
I have a server using unix domain socket. It works in a standard way: listening for requests and accepting each of them by running a separater thread for it:
while(true){
int clientsocket;
clientsocket=accept(serversocket, NULL, NULL);
ClientHandler * ch = new...
I have a server written in sun/j2se. It uses unix domain socket in a standard way. It listens for connection requests in background all time. After accepting a request, it creates a object of taking care of some job, passes it to an object of Thread, and starts the Thread object:
while(true){...
Hi, Feherke, you mentioned no need to keep temp files. But after a new map filled with colors is created from a blank map on the server side, how to send it with a web page back to client browsers? I think I can put such a map or some picture object as a file somewhere on the server (even...
Usually, a CGI would create many temp files. For example, it may dynamically create many maps, which do not exist on disks. So, after a web browser session expires, some of these files will be no use any more. But some (e.g., a map for recent climate) may serve multiple requests at different...
I want to display a outline state map in web browser. Each state is going to be filled out with a color, which indicates some property of the state, such as temperature or population, etc. So, the map varies in color from time to time with changing property values.
I wanted to use javascript to...
Because each state may be in different color from one time to another. In other words, color is used as indicator of some property, for example, temperature. And I do not want to create this map on server side in order to avoid managing temp files.
I want to write a javascript to display a outline state map such that different states are filled with different color in a web browser such as IE and FireFox.
What I am thinking is as this:
1st, display blank outline state map as a map (.gif?). Blank outline state map is one that has contour...
Yes. In all cases that either message was reported, all arguments (scalar, array, hash and their refs) passed to thread "B::c" have been initialized. In "B::c", it also doesn't matter if those arguments appear as lef-side or right-side (the semaphore and queue definitely change their content and...
Suppose we have "A.pl" and "B.pm" as follows.
_A.pl_
...
my $dummy;
threads->create("B::c", ($dummy));
...
_B.pm_
...
sub c{...}
...
"Scalars leaked:" occurs for each ref or a hash (replace $dummy with %dummy in above script) that is passed as argument to "B::c".
"Attempt to free...
Thanks. Mike. That's what I'm thinking to isolate the problem code and find out what is wrong. But just working on other things and didn't find a time for this.
I will do this and post whatever I will find later ...
forgot to mention that I have 4 threads in total. 3 of them used those queues and semaphores. and there were 3 such message reports for them. no report for the remaining one, which just passed queues and semaphores as arguments.
so, more like some problem w/ my code ...
Thanks.
mine is "v5.8.8 built for i686-linux-thread-multi" on gentoo linux.
there is known bug similar to this? not very sure
I will have to check my code when I have time later ...
It seems to hang forever at writing data to a DataOutputStream associated with a socket connection to a client. "locked at ...".
So, what could cause such block? "Unix Domain Socket" was used. Each write was between 10KB ~ 1MB. Is this because of some buffer problem with socket or something...
A java server seemss to pause for a long time. How to find what it is doing and where it is? Thanks.
The following is exceprt of top -p output:
VIRT RES SHR S %CPU %MEM
638m 339m 11m S 102 9.0
And the following is extracted from stack trace by sending "kill -QUIT" to the program:
"Finalizer"...
I got the following message when one of my perl program exits (it runs multiple threads simultaneously, it has several variable of typess of Thread::Queue and Thread::Semaphore):
Attempt to free unreferenced scalar: SV 0x84f0c00, Perl interpreter: 0x8362c78 during global destruction.
What does...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.