P
pradeepag
Hi all,
I want to implement a proxy server in C.
That proxy server stands there for several concurrent client requests
& services them.
Using select(), it is working fine.
But I want to make my proxy work more efficiently.
So What is the next thing I can do?
whether there is any more thing should added with select()?
or should I move away from select() and go for multithreaded...?
or select() + multithreads ?
If multithreads should come there, please can some one give a simple
explanation for thread implementation...simple code( I want to use
POSIX thread library)
Actually, I wrote it using thread ah!...
//server code
int main(){
while(true){
//create a thread using pthread.h create_pthread()
//thread_join();
}
ThreadFunction(){
// coded What should client do
}
I couldn't see thread concept is working there. server works for one
client and then next one(in order), but not switching between threads
when one is reading a file, other thread should in work. but....:-(
Thanks a lot.
Pradeepag
I want to implement a proxy server in C.
That proxy server stands there for several concurrent client requests
& services them.
Using select(), it is working fine.
But I want to make my proxy work more efficiently.
So What is the next thing I can do?
whether there is any more thing should added with select()?
or should I move away from select() and go for multithreaded...?
or select() + multithreads ?
If multithreads should come there, please can some one give a simple
explanation for thread implementation...simple code( I want to use
POSIX thread library)
Actually, I wrote it using thread ah!...
//server code
int main(){
while(true){
//create a thread using pthread.h create_pthread()
//thread_join();
}
ThreadFunction(){
// coded What should client do
}
I couldn't see thread concept is working there. server works for one
client and then next one(in order), but not switching between threads
when one is reading a file, other thread should in work. but....:-(
Thanks a lot.
Pradeepag