Rabbi Yohanan said: "This righteous man [Choni] was troubled throughout the whole of his life concerning the meaning of the verse, 'A Song of Ascents: When the Lord brought back those that returned to Zion, we were like dreamers' (Psalms 126:1). [Choni asked] Is it possible for seventy years to be like a dream? How could anyone sleep for seventy years?"
One day Choni was journeying on the road and he saw a man planting a carob tree. He asked, "How long does it take [for this tree] to bear fruit?" The man replied: "Seventy years." Choni then further asked him: "Are you certain that you will live another seventy years?" The man replied: "I found [already grown] carob trees in the world; as my forefathers planted those for me so I too plant these for my children."
Choni sat down to have a meal and sleep overcame him. As he slept a rocky formation enclosed upon him which hid him from sight and he slept for seventy years. When he awoke, he saw a man gathering the fruit of the carob tree and Honi asked him, "Are you the man who planted the tree?" The man replied: "I am his grandson." Thereupon Choni exclaimed: "It is clear that I have slept for seventy years." He then caught sight of his ass which had given birth to several generations of mules, and he returned home. There he inquired, "Is the son of Choni the Circle-Drawer still alive?" The people answered him, "His son is no more, but his grandson is still living." Thereupon he said to them: "I am Choni the Circle-Drawer," but no one would believe him.
He then repaired to the Beit HaMidrash [study hall] and there he overheard the scholars say, "The law is as clear to us as in the days of Choni the Circle-Drawer," for whenever he came to the Beit HaMidrash he would settle for the scholars any difficulty that they had. Whereupon he called out, "I am he!" But the scholars would not believe him nor did they give him the honor due to him. This hurt him greatly and he prayed for mercy, and he died. Raba said: "Hence the saying, 'Either companionship or death.'"
Jerusalem Talmud version (Taanit 3:9)
Said R. Yudan Giria: "This is Choni the Circle Maker [of M. Ta. 3:9], the grandson of Choni the Circle Maker. Near the time of the destruction of the Temple, he went out to a mountain to his workers. Before he got there, it rained. He went into a cave. Once he sat down there, he fell asleep. He remained sound asleep for seventy years, until the Temple was destroyed and it was rebuilt a second time. At the end of the seventy years, he awoke from his sleep. He went out of the cave, and he saw a world completely changed. An area that had been planted with vineyards now produced olives, and an area planted with olives now produced grain. He asked the people of the district, "What do you hear in the world?" They said to him, "And don't you know what the news is?" He said to them, "No." They said to him, "Who are you?" He said to them, " Choni the Circle Maker." They said to him, "We heard that when he would go into the Temple courtyard, it would be illuminated." He went in and illuminated the place and recited the following verse of Scripture, "When the Lord restored the fortune of Zion, we were like those who dream" (Ps. 126:1).