In order to have your pet survive, you must manage its health. First things first: pets inherit part of your stats, so versatility, leech, armor, and others function the same as they would on your hunter.
To reduce damage taken, the only non-pet specific ability is
Depistaggio with the trait
Vantaggio del Cacciatore. If you don't need it for aggro, use it as a damage reduction.
All heals coming from the hunter are percentage-based.
Cura Famiglio heals 5% health per 2 seconds, and you want to use it as part of your rotation. If you can afford it, use it when you are focus starved or when you would use
Tiro del Cobra or
Tiro Multiplo, but not at max focus or during burst. If pet survival is tight, it takes priority over anything other than
Ordine di Morte.
Fuga Curativa is a lay on hands for the pet, giving it a second health bar. Make sure to use it before it dies or it will be wasted - pets usually take constant, spread out damage, so with practice using it at the last possible moment becomes easy.
Since most of the healing a pet takes is dependent on his health, its resistance is very dependent on stamina.
Finally, pets have a decent dodge chance - about 25% with
Riflessi Naturali.
If your pet dies, it is time to revive it. The objective here is to avoid getting a melee hit, especially since it can crit.
Your tool is
Rianima Famiglio. Two seconds cast, affected by haste. It completely heals your pet, so sometimes timing your pets death is a valid strategy. You will have to
Morte Apparente before the rez, or after.
After: if you can, take your distance. Against stunnable mobs, stunning them while you rez is a good option.
Disimpegno can help you get away. You can also rez while the boss is casting. If all else fails,
Aspetto della Tartaruga can buy you time.
Before: only works if the boss has other targets, such as
Hati. While he hits his other target you can revive the pet and send it back. Note that this will probably result in a dead
Hati, making you lose dps. Whatever the situation, having your pet die will usually cost dps.