What happens when you do a
This should tell you what class is actually it's expecting. You may already know this sort of thing, not trying to be insulting.
no problem steve, i positively appreciate any time someone can spend to help me understand this or any other issue! thanks.
i did a "logger.info(rcpts.getClass())", which showed a "MailAddress", and not an "EnvelopedAddress". that also explains the ClassCastException.
p.p.s: another weird new forum 'feature' is this automatic italicization you probably see in this post. have no idea how that happens either, and i never usually speak in italics!
This is kabir's code. I think the logic only takes place if say the server doesn't exist. Yahoo would generate the bounce message if it was justa non-existent account. Whats weird is it seems like the bounce code is working...
right --- don't know why, but may be because the ClassCastException is being caught somewhere else... i apologize for not completely tracing it through yet. will check into it. mike
I'll take a look a bit later today. Mike, do you have a use case that will cause this to happen?
thanks kab --- i was logged in as mikea@localhost, user mikea, password in jboss-service.xml, on my own local machine's jboss server. i sent an email to email@example.com. from jbmail logs, looks like yahoo didn't like 'mikea@localhost' and rejected that. a few seconds later, got a classcastexception in jbmail logs. this was all in latest HEAD code. mike
Fixed, the errors happening within SMTPSender are different when the server can't be reached, and when an account on a server is invalid. The invalid account exception (SendFailedException) returns a InternetAddress. Previously I created MailAddress from the failed ones, now I am creating EnvelopedAddress w/local=false.