break;
}
std::cout << "release session";
- parent_service.release_session( boost::this_thread::get_id() );
+ parent_service.release_session( this );
}
void l7vs::tcp_session::down_thread_run(void){}
void l7vs::virtual_service::connection_inactive( const boost::asio::ip::tcp::endpoint& in ){
vs->connection_inactive( in );
}
-void l7vs::virtual_service::release_session( const boost::thread::id thread_id ){
- vs->release_session( thread_id );
+void l7vs::virtual_service::release_session( const tcp_session* session_ptr ){
+ vs->release_session( session_ptr );
}
unsigned long long l7vs::virtual_service::get_qos_upstream(){
void l7vs::virtualservice_tcp::connection_inactive( const boost::asio::ip::tcp::endpoint& in ){
}
-void l7vs::virtualservice_tcp::release_session( const boost::thread::id thread_id ){
+void l7vs::virtualservice_tcp::release_session( const tcp_session* session_ptr ){
}
void l7vs::virtualservice_udp::run(){}
void l7vs::virtualservice_udp::stop(){}
-void l7vs::virtualservice_udp::release_session( const boost::thread::id thread_id ){}
+void l7vs::virtualservice_udp::release_session( const tcp_session* session_ptr ){}
std::list<realserver>& get_rs_list(){
return rs_list;
}
- void release_session( const boost::thread::id in_id ){
+ void release_session( const tcp_session* session_ptr ){
std::cout << "release_session called." << std::endl;
- virtualservice_tcp::release_session( in_id );
+ virtualservice_tcp::release_session( session_ptr );
}
unsigned long long get_ref_count(){
return rs_list_ref_count.get();
vs->connection_inactive( ep );
}
- void release_session( const boost::thread::id id ){
+ void release_session( const l7vs::tcp_session* session_ptr ){
boost::mutex mtx;
boost::mutex::scoped_lock lk( mtx );
cond.wait( lk );
- vs->release_session( id );
-
+ vs->release_session( session_ptr );
}
};
vs->connection_inactive( ep );
}
- void release_session( const boost::thread::id id ){
+ void release_session( const l7vs::tcp_session* session_ptr ){
boost::mutex mtx;
boost::mutex::scoped_lock lk( mtx );
cond.wait( lk );
- vs->release_session( id );
-
+ vs->release_session( session_ptr );
}
};
}
void connection_inactive( const boost::asio::ip::tcp::endpoint& ep ){
}
- void release_session( const boost::thread::id in_id ){
+ void release_session( const tcp_session* session_ptr ){
}
//imprement for unit_test