I believe there is also the possibility of getting a null pointer exception when the user is logged out, as conversationManager will be null. Also, what is MessageException? You can add multiple catch statements for each type of exception, or you can just do a general catch(Exception e), which might be bad form since it doesn't tell you the specific error, but most times we don't need to know and it is simpler and safer so I like to use it.