I don’t have the time to research this right now, but it seems to me that the set of features known as “the Kafkaesque” owe at least as much to the experience of being a tuberculosis patient in the 1920s as they do to to Jewishness, Austro-Hungarian bureaucracy, minority language status, the Oedipus complex or other factors that have been put forward.
It’s all there. The dream quality of not being able to distinguish the most trivial things, or fantasies, from mortal danger:
 March 16. The attacks, my fear, rats that tear at me and whom my eyes multiply.
March 24. How it lies in wait for me! On the way to the doctor, for example, so often there.
May 26. The severe ‘attacks’ during the evening walk (resulting from four tiny vexations during the day: the dog in the summer resort; Mars’ book; enlistment as a soldier; lending the money through Z.); momentary confusion, helplessness, hopelessness, unfathomable abyss, nothing but abyss; only when I turned in at the front door did a thought come to my assistance… [The Diaries of Franz Kafka 1914-1923, ed. Max Brod, tr. Martin Greenberg (New York: Shocken Books, 1949), 225, 230]
The paranoiac feeling:
 June 12…. More and more fearful as I write. It is understandable. Every word, twisted in the hands of the spirits– this twist of the hand is their characteristic gesture–becomes a spear turned against the speaker. Most especially a remark like this. And so ad infinitum. The only consolation would be: it happens whether you like or no. And what you like is of infinitesimally little help. More than consolation is: You too have weapons. [Diaries, 232-233]
But Franz K. didn’t have all the weapons he needed: that was the last entry in the diary. (He lived for almost another year past writing those words.)
Most of all, a description of tuberculosis that makes it sound like what much later would be classified as an auto-immune disease:
 March 7. Yesterday the worst night I have had, as if everything were at an end.
March 9. But that was only weariness; today a fresh attack, wringing the sweat from my brow. How would it be if one were to choke to death on oneself? If the pressure of introspection were to diminish, or close off entirely, the opening through which one flows forth into the world. I am not far from it at times. A river flowing upstream. For a long time now, that is what for the most part has been going on. [Diaries, 223]
What’s so special about the 1920s? Since Koch’s discovery of the TB bacillus in 1882 and development of the sputum test in 1890, it had been possible to know with certainty that you were doomed, yet be unable to do anything conclusive about it (that would become possible only with antibiotics). Does this sound like the judgment or what? Yes, Susan Sontag, I am aware of the danger of romanticizing illness. But don’t you see the analytic mind of Kafka at work, trying to understand the process of his own obliteration? That’s the castle, that’s the trial, that’s Amerika (or: The One Who Disappeared).