Good point. In my recollection (it is a few years ago that I read
Die Verwandlung), it was the fact that someone (was it his father?) chucked al apple at him that got stuck in him that brought on this disease. But the animosity that produced the attack that was motivated out of fear for him (was it when he tried to listen to his sister playing the violin for the lodgers?), came way down the line and Gregor knew at that point that he wasn't wanted anymore, but he kept trying and thought it would get better.
But yes, what is suicide, after all? The issue I suppose becomes really poignant when you think about the similarities with the Jews as (learned) people who were discriminated against and what it came to in the end. Thankfully Kafka didn't have to see that anymore, although his sisters did. Ironically one of his sisters willingly volunteered a) to be deported (she was married to a non-Jew and wasn't supposed to go, but she did out of solidarity) and b) volunteered for the last children's transport from Theresienstadt (by far the best CC you could be in, it was supposed to be a model of what was in Poland, the Red Cross approved it

) to Auschwitz. I don't need to say where she went with the children when she arrived. The sheer naivety and meekness astonishes you somehow. How long some people exonerate and stand things just because they can't tear themselves away, because they fear what is outside.
But Kafka would not have liked me to parallel these two things.
Let's just say it's an interesting issue and that Samsa loved his family too much to go so that he eventually perished, not by anyone's fault...