Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

475
Views
Difference between Cold or Hot http requests?

Could somebody explain me two things:

  • Difference between Cold or Hot http requests?
  • Are http requests in Angular 2 Cold or Hot?
about 4 years ago · Santiago Trujillo
2 answers
Answer question

0

In Angular, http requests made from the Http service are cold.

Cold, in this context, means that the http request is not made until someone subscribes to the observable returned from Http.get, Http.post etc. Also, each subscription to an http observable will cause a different http request to be fired. This is because, as a cold observable, the http observable is responsible for creating its producer (i.e. the Ajax request) on subscription, and each subscription will create a separate producer of values (i.e. separate Ajax requests).

Thoughtram has a detailed article on hot vs cold observables.

about 4 years ago · Santiago Trujillo Report

0

Its cold since any request only starts producing value first when you subscribe to it. Without running

http.get().subscribe((response) => ...)

No request will be send to the server. http.get() alone is just an object.

about 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!