title: How to execute Angular 2 http call every timeInterval with Rxjs 'interval' operator?
body: <p>I have this simple method in my service : </p>
  
  <pre><code> notify(userID: string) {
      let _URL = this.baseUrl + '/notification/GetUnseen?userId=' + userID;
       this.datatService.set(_URL);
      return this.datatService.get()
          .flatMap((response) =&gt;
             response.json().slice())
             .distinct();
  }
  </code></pre>
  
  <p>It return a stream of object which contain informations about user's notification. i would like to execute this call every 5 second with interval operator without using setTimeout ?</p>
  
  <p>When i try this :</p>
  
  <pre><code> notify(userID: string) {
      let _URL = this.baseUrl + '/notification/GetUnseen?userId=' + userID;
       this.datatService.set(_URL);
      return this.datatService.get()
          **.interval(5000)**
          .flatMap((response) =&gt;
             response.json().slice())
             .distinct();
  }
  </code></pre>
  
  <p>I have an error.
  Any Suggestion ?</p>