Merge "Allow setting protocol for internal endpoints"