This actually does get brought up in the novel The Clone Wars: Wild Space- Yoda gives Obi-Wan a pointed warning that Anakin needs a mentor- not a friend- and it would be a mistake for Obi-Wan to build a friendship with him. Obi-Wan thinks to himself that in this case Yoda's wrong- after Anakin's loss of his mother, he needs a friend to support him. In the novel of Revenge of the Sith it's also brought up that they're close, but Anakin's closer than vice versa- any Jedi would be willing to sacrifice another to achieve peace- but not Anakin: "I trust him with my life," Obi-Wan said simply. "And that is precisely the problem." The other two Jedi Masters watched him silently while he tried to summon the proper words. "For Anakin," Obi-Wan said at length, "there is nothing more important than friendship. He is the most loyal man I have ever met- loyal beyond reason, in fact. Despite all I have tried to teach him about the sacrifices that are at the heart of being a Jedi, he- he will never, I think, truly understand." He looked over at Yoda. "Master Yoda, you and I have been close since I was a boy. An infant. Yet if ending this war one week sooner- one day sooner- were to require that I sacrifice your life, you know I would." "As you should," Yoda said. "As I would yours, young Obi-Wan. As any Jedi would any other, in the cause of peace." "Any Jedi," Obi-Wan said, "except Anakin." Yoda and Mace exchanged glances, both thoughtfully grim. Obi-Wan guessed they were remembering the times Anakin had violated orders- the times he had put at risk entire operations, the lives of thousands, the control of entire planetary systems- to save a friend. More than once, in fact, to save Obi-Wan. "I think," Obi-Wan said carefully, "that abstractions like peace don't mean much to him. He's loyal to people, not to principles. And he expects loyalty in return. He will stop at nothing to save me, for example, because he thinks I would do the same for him." Mace and Yoda gazed at him steadily, and Obi-Wan had to lower his head. "Because," he admitted reluctantly, "he knows I would do the same for him." "Understand exactly where your concern lies, I do not." Yoda's green eyes had gone softly sympathetic. "Named must your fear be, before banish it you can. Do you fear that perform his task, he cannot?" "Oh, no. That's not it at all. I am firmly convinced that Anakin can do anything. Except betray a friend. What we have done to him today..." "But that is what Jedi are," Mace Windu said. "That is what we have pledged ourselves to: selfless service-" Obi-Wan turned to stare once more toward the assault ship that would carry Yoda and the clone battalions to Kashyyyk, but he could see only Anakin's face. If he asked me to spy on you, do you think I would do it? "Yes," he said slowly. "That's why I don't think he will ever trust us again." He found his eyes turning unaccountably hot, and his vision swam with unshed tears. "And I'm not entirely sure he should."