Is there a surgery for type 2 diabetes to temporarily stop the need of insulin?

I know there is a procedure available for type 1 diabetes that works for 2-3 years (animal transplant that eventually gets rejected by the human immune system) but does it work with type 2 diabetes?