Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Cloud run as compared to VM

Hi Team,

I am thinking to create some rest APIs and some background jobs which is connecting to a Kafka to process some events.

Would like to understand the difference between VM vs cloud run (which is always running on).

In terms of costing, will it cost same or are there any difference between VM & cloud run having same CPU/Memory.

Is there anything I should consider like cloud run supports maximum 1 hr live thread executions? (Can background threads continue to run for more than 1 hr?)

 

Thanks & Regards

Amit

0 2 5,629
2 REPLIES 2

Greetings @amitkhosla,

You should take a look at this blog: Where should I run my stuff? Choosing a Google Cloud Compute Option.

One key difference between VM (Compute Engine) and Cloud run is your control:

  • Compute Engine - You configure the CPU, memory, disk, GPUs and decide what OS and software to run.
  • Cloud Run - Serverless platform. You provide the code or container, and it will host and auto scale based on your needs.

The above blog should provide you with more information about their differences.

When it comes to costing, It will depend on the billing model that you prefer.

  • Compute Engine - Billing is based on the resources that you provisioned from the start.
  • Cloud Run - Billing is based per request, meaning it only charges you based on the resources you use.

Let me know if it helped, thanks!

Thanks @Marramirez ! And apologies for delayed reply.

I am looking for having always on Cloud run. Will not it be similar to what any Compute Engine would have costed? Am I missing something?

And what are the limitations with Cloud Run which Compute Engine can help me with?

 

Thanks & Regards

Amit