-XX:NativeMemoryTracking=detail
jps
ps -p <PID> -o pcpu,rss,size,vsize
| /** | |
| @class BroadcastChannel | |
| A simple BroadcastChannel polyfill that works with all major browsers. | |
| Please refer to the official MDN documentation of the Broadcast Channel API. | |
| @see <a href="https://developer.mozilla.org/en-US/docs/Web/API/Broadcast_Channel_API">Broadcast Channel API on MDN</a> | |
| @author Alessandro Piana | |
| @version 0.0.6 | |
| */ | |
| /* |
| #include <time.h> | |
| #include <stdio.h> | |
| #include <errno.h> | |
| #include <stdlib.h> | |
| #include <stdint.h> | |
| #include <sys/random.h> | |
| #define UUID_T_LENGTH (16) | |
| #define UNIX_TS_LENGTH (6) |
| #!/bin/bash | |
| # Get temp dir | |
| tmpdir=$(mktemp -d) | |
| # Generate test | |
| cat > ${tmpdir}/ListenToSignal.java <<EOF | |
| import sun.misc.Signal; | |
| import sun.misc.SignalHandler; | |
| public class ListenToSignal { |
| #!/bin/bash | |
| # for use with cron, eg: | |
| # 0 3 * * * postgres /var/db/db_backup.sh foo_db | |
| if [[ -z "$1" ]]; then | |
| echo "Usage: $0 <db_name> [pg_dump args]" | |
| exit 1 | |
| fi |
| #!/bin/bash | |
| # | |
| # PostgreSQL Backup Script Ver 1.0 | |
| # http://autopgsqlbackup.frozenpc.net | |
| # Copyright (c) 2005 Aaron Axelsen <[email protected]> | |
| # | |
| # This script is based of the AutoMySQLBackup Script Ver 2.2 | |
| # It can be found at http://sourceforge.net/projects/automysqlbackup/ | |
| # | |
| # The PostgreSQL changes are based on a patch agaisnt AutoMySQLBackup 1.9 |
| (defn tree-seq-depth | |
| "Returns a lazy sequence of vectors of the nodes in a tree and their | |
| depth as [node depth], via a depth-first walk. branch? must be a fn | |
| of one arg that returns true if passed a node that can have | |
| children (but may not). children must be a fn of one arg that | |
| returns a sequence of the children. Will only be called on nodes for | |
| which branch? returns true. Root is the root node of the tree." | |
| [branch? children root] | |
| (let [walk (fn walk [depth node] | |
| (lazy-seq |
All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.
elem.offsetLeft, elem.offsetTop, elem.offsetWidth, elem.offsetHeight, elem.offsetParentelem.clientLeft, elem.clientTop, elem.clientWidth, elem.clientHeightelem.getClientRects(), elem.getBoundingClientRect()| (require '[clojure.core.async.impl.protocols :as impl] | |
| '[clojure.core.async.impl.dispatch :as dispatch]) | |
| ;;=> nil | |
| (extend-type java.util.concurrent.CompletionStage | |
| impl/ReadPort | |
| (take! [this handler] | |
| (.whenCompleteAsync this | |
| (reify |
| (defn array-type | |
| "Return a string representing the type of an array with dims | |
| dimentions and an element of type klass. | |
| For primitives, use a klass like Integer/TYPE | |
| Useful for type hints of the form: ^#=(array-type String) my-str-array" | |
| ([klass] (array-type klass 1)) | |
| ([klass dims] | |
| (.getName (class | |
| (apply make-array | |
| (if (symbol? klass) (eval klass) klass) |