一、避免使用类成员变量。
二、加锁
三、使用ThreadLocal成员变量
四、使用prototype bean