  Function-as-a-Service (FaaS) has recently emerged to reduce the deployment
cost of running cloud applications compared to Infrastructure-as-a-Service
(IaaS). FaaS follows a serverless 'pay-as-you-go' computing model; it comes at
a higher cost per unit of execution time but typically application functions
experience lower provisioning time (startup delay). IaaS requires the
provisioning of Virtual Machines, which typically suffer from longer cold-start
delays that cause higher queuing delays and higher request drop rates. We
present LIBRA, a balanced (hybrid) approach that leverages both VM-based and
serverless resources to efficiently manage cloud resources for the
applications. LIBRA closely monitors the application demand and provisions
appropriate VM and serverless resources such that the running cost is minimized
and Service-Level Agreements are met. Unlike state of the art, LIBRA not only
hides VM cold-start delays, and hence reduces response time, by leveraging
serverless, but also directs a low-rate bursty portion of the demand to
serverless where it would be less costly than spinning up new VMs. We evaluate
LIBRA on real traces in a simulated environment as well as on the AWS
commercial cloud. Our results show that LIBRA outperforms other
resource-provisioning policies, including a recent hybrid approach - LIBRA
achieves more than 85% reduction in SLA violations and up to 53% cost savings.
