This is the reference point. All the other options are based off this.
|-- app
| |-- controllers
| | |-- admin
__author__ = 'Amal G Jose' | |
from datetime import datetime | |
from dateutil import relativedelta | |
##Aug 7 1989 8:10 pm | |
date_1 = datetime(1989, 8, 7, 20, 10) | |
##Dec 5 1990 5:20 am | |
date_2 = datetime(1990, 12, 5, 5, 20) |
'use strict' | |
// see: https://github.com/nodejs/node/pull/6157 | |
var startTime = process.hrtime() | |
var startUsage = process.cpuUsage() | |
// spin the CPU for 500 milliseconds | |
var now = Date.now() | |
while (Date.now() - now < 500) |
# Browser caching of static assets. | |
location ~* \.(jpg|jpeg|png|gif|ico|css|js|pdf)$ { | |
expires 7d; | |
add_header Cache-Control "public, no-transform"; | |
} | |
# Media: images, icons, video, audio send expires headers | |
location ~* \.(?:jpg|jpeg|gif|png|ico|cur|gz|svg|svgz|mp4|ogg|ogv|webm)$ { | |
expires 1M; | |
access_log off; |
A lot of people land when trying to find out how to calculate CPU usage metric correctly in prometheus, myself included! So I'll post what I eventually ended up using as I think it's still a little difficult trying to tie together all the snippets of info here and elsewhere.
This is specific to k8s and containers that have CPU limits set.
To show CPU usage as a percentage of the limit given to the container, this is the Prometheus query we used to create nice graphs in Grafana:
sum(rate(container_cpu_usage_seconds_total{name!~".*prometheus.*", image!="", container_name!="POD"}[5m])) by (pod_name, container_name) /
sudo pacman -Syu zsh
You do not need to install manjaro-zsh-config
and all the other related packages like zsh-syntax-highlighting
, zsh-history-substring-search
, zsh-autosuggestions
, etc., as we will use Oh My Zsh.
const lodashPick = (object, keys) => { | |
return keys.reduce((obj, key) => { | |
if (object && object.hasOwnProperty(key)) { | |
obj[key] = object[key]; | |
} | |
return obj; | |
}, {}); | |
}; | |
const setupProps = async (props) => { |
# ESSE CODIGO FICA DENTRO DO SERVER | |
import threading | |
from django.conf import settings | |
# limita o numero de threads rodando em paralelo. | |
semaphore = threading.BoundedSemaphore( | |
value=settings.ASYNC_RESPONSE_MAXIMUM_CONCURRENCY_THREADS | |
) |
Requisitos:
Desenvolver uma API Node com autenticação JWT ou outro tipo de autenticação caso ache melhor.
Prestador de serviço poderá se cadastrar no sistema com os seguintes atributos. Nome Completo, E-mail, Senha, Role: "Prestador" (tipo de usuário como prestador de serviço).
O prestador de serviço poderá cadastrar seus serviços no sistema com os seguintes atributos: