Dear SS,
The speaker does not doubt that it will go well. He is prepared therefore to «eat his hat» if it does not go well.
The absurdity of the offer accords therefore with the absurdity of the possibility.
It is unusual to eat one's hat, I think. I have seen it in cartoons. ![Smile [:)]](/emoticons/emotion-1.gif)
Kind regards, ![Smile [:)]](/emoticons/emotion-1.gif)
Goldmund