title: java rest call get url net::ERR_FAILED
body: <p>I am writing a rest call as below</p>
  
  <pre><code>authenticationService(username: string, password: string) {
      debugger;
      let params = new HttpParams();
      params = params.append('username', username);
      params = params.append('password', password);
      return this.http.get(`http://localhost:8080/api/v1/basicauth?`,{params},
        ).pipe(map((res) =&gt; {
          this.username = username;
          this.password = password;
        }));
    }
  </code></pre>
  
  <p>And from spring boot end I am using @RequestParams like below</p>
  
  <pre><code>@GetMapping(path = "/basicauth")
      public AuthenticationBean helloWorldBean(@RequestParam(name = "username") String username,@RequestParam(name = "password") String password) {
          String status = authenticationService.isUserAuthenticated(username, password);
               return new AuthenticationBean("You are not authenticated");
      }
  </code></pre>
  
  <p>I am getting the error like </p>
  
  <p><a href="https://i.stack.imgur.com/UA7v9.png" rel="nofollow noreferrer">![this
  ]<a href="https://i.stack.imgur.com/UA7v9.png" rel="nofollow noreferrer">1</a></a></p>
  
  <p>PLease help me on this. Thanks:)</p>