title: Angular HTTP Client multiple calls
body: <p>Which is the best way to manage subscribers on a Angular HTTP request in this case:</p>
  
  <p>I have button that performs a get request and then prints the result:</p>
  
  <h3>Template</h3>
  
  <pre><code>&lt;button type="button" class="btn btn-primary" (click)="helloWorld()"&gt;Mod1&lt;/button&gt;
  </code></pre>
  
  <h3>Component</h3>
  
  <pre><code>constructor(private heroService: HeroService) { }
  
  helloWorld() {
      this.heroService.getUser().subscribe(data =&gt; console.log(data));
  }
  </code></pre>
  
  <h3>Service</h3>
  
  <pre><code>constructor(private _http: HttpClient) { }
  
  getUser() {
      return this._http.get("https://randomuser.me/api/");
  }
  </code></pre>
  
  <p>The mainly problem here is, every time I press the button a new subscription is created, causing memory leaks and poor performance over time due to unused listeners.</p>
  
  <p>How may I implement a multiple get request without affect the application performance?</p>