Seeing as this is a UX form, it would really help knowing what the user needs are. That is, what is the nature of the nodes, and what will users try/need to do with them and why. Also, is there any additional data users may be able to filter nodes by, and is it a single level hierarchy or an unlimited one (Can A have an A child that has an A child and so on - like folders on a file system).
As a side note, one research suggests that 70 similar items is roughly the amount people will bother to visually inspect - more than that people are likely to use a search/filtering function.
Without these details it is hard to provide a comprehensive answer, but the approach for tree search goes like this:
- There's a typeahead search field.
- The query entered is matched against the leafs; unmatched items are hidden.
- After filtering, any node without children is also made invisible.
If users may search for nodes (not only leafs) that you keep the nodes that match the query.
Although not ux-related, I've recently implemented exactly such behaviour (albeit to trees that hardly ever has more than 250 items) using AngularJS and it was dead easy to do.
The last 'tip' would be to consider the physical effort involve in selecting/collapsing nodes - I can only assume that collapsing will be the more common action, so a click on a node (as well as on the collapse icon next to it) should collapse/expand the node, by that offering users large click area for such action; selecting a node can be done using a (much smaller) checkbox next to each node/leaf). If selection is more common, use node click for selection, and collapse icon for collapse.