Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: lichtjiang
  • Content: Threads
  • Order by date
  1. lichtjiang

    How to write a timer to monitor a server?

    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...
  2. lichtjiang

    How to terminate a socket server gracefully?

    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...
  3. lichtjiang

    Java socket server termination and memory release?

    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){...
  4. lichtjiang

    How to manage temp files created by CGIs?

    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...
  5. lichtjiang

    fill color in an outline state map?

    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...
  6. lichtjiang

    fill color in an outline state map?

    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...
  7. lichtjiang

    DataOutputStream locked?

    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...
  8. lichtjiang

    Program frozen?

    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"...
  9. lichtjiang

    what is "Attempt to free unreferenced scalar"?

    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...
  10. lichtjiang

    scalar leaked ?

    I have some perl scripts that run N threads. Upon exit of these threads, perl reported the following message: Scalar leaked: N what went wrong and how to tell which scalar variables have caused this error message? Thanks!
  11. lichtjiang

    "Wide character in syswrite" problem?

    I got the error "Wide character in syswrite at ...". syswrite writes data to a socket, which set to binmode. So, what does this error mean since any data written is treated as binary? Thanks.
  12. lichtjiang

    Lightweight Semantic Tags in HTML????

    Calling it "lightweight semantic html tag" may be misleading. But this is what I mean. In news article analysis applications, it is extremely important to just extract story content text since otherwise the template such as advertisement stuff may have negative impact (e.g. celebrity names...
  13. lichtjiang

    can we just request HEAD component in a HTML page from a http server?

    This may sounds stupid. But is there possibility that we just request the <HEAD> part of a html page from a server? Sometimes, this is good when we only need meta information of a html page. So, instead of downloading the whole page, we just ask for a small number of text.
  14. lichtjiang

    Inter-thread communication in PERL?

    How threads communicate in perl? For example, if there are 3 threads, A, B, C. C needs to know when A and B finish so that it terminates afterwards. How can C know such status info nicely? I guess there are two ways theoretically. One is gets status info from each other thread. And the other is...
  15. lichtjiang

    perl client writes 2-byte number through socket to server in java?

    I have a server listening on unix-domain-socket written in java; I also have 2 clients that write a 2-byte number to the server. One is written in Java. and the other is in Perl (code like $a=chr(0x80); print SOCKET, $a; $a=chr(0x00); print SOCKET, $a). On the server side, server reads 2 bytes...
  16. lichtjiang

    cannot write a number to disk file in its binary format?

    For example, say we want to write integer "100" in a binary file, "test.dat". The following code won't work. $anumber=100; $file="test.dat"; open(DAT, ">", $file); print DAT $anumber; This will write 3 bytes in "test.dat" as 31, 30, and 30. Though, if $anumber is read as "64" in hex from a...

Part and Inventory Search

Back
Top