Hierarchical data metrics that allows fast read operations on tree like structures.
Based on Left and Right fields that are set during tree traversal. When entered into node value is set to it's Left, when exiting node value is set to it's Right.
package main | |
import ( | |
"flag" | |
"fmt" | |
"log" | |
"os" | |
"os/signal" | |
"syscall" | |
) |
class RedisSessionStore(SessionStore): | |
def __init__(self, expire = 1800, key_prefix=''): | |
SessionStore.__init__(self) | |
self.redis = redis.Redis(tools.config.get('redis_host', 'localhost'), | |
int(tools.config.get('redis_port', 6379)), | |
int(tools.config.get('redis_dbindex', 1)), | |
password=tools.config.get('redis_pass', None)) | |
self.path = session_path() | |
self.expire = expire | |
self.key_prefix = key_prefix |
### Create rsyslog entry to catch log data [based on 'pgpool' name] in '/etc/rsyslog.d/pgpool2.conf' | |
if ( $programname == "pgpool" ) then { | |
action(type="omfile" fileOwner="postgres" fileGroup="postgres" fileCreateMode="0644" file="/var/log/pgpool2/pgpool2.log") stop | |
} | |
### Create logrotate configuration in '/etc/logrotate.d/pgpool2.conf' | |
/var/log/pgpool2/pgpool2.log { | |
daily | |
rotate 30 | |
compress |
# Replace REMOTE_NAME with your remote name (e.g. origin) | |
git branch -r | grep REMOTE_NAME/ | grep -v 'master$' | grep -v HEAD| cut -d/ -f2 | while read line; do git push REMOTE_NAME :$line; done; |
# Prevent Trackers and Malwares | |
https://raw.githubusercontent.com/DRSDavidSoft/additional-hosts/master/domains/blacklist/adservers-and-trackers.txt | |
https://gitlab.com/quidsup/notrack-blocklists/raw/master/notrack-malware.txt | |
https://gitlab.com/quidsup/notrack-blocklists/raw/master/notrack-blocklist.txt | |
https://raw.githubusercontent.com/notracking/hosts-blocklists/master/hostnames.txt | |
https://s3.amazonaws.com/lists.disconnect.me/simple_tracking.txt | |
https://gitlab.com/my-privacy-dns/matrix/matrix/-/raw/master/source/tracking/domains.list | |
https://raw.githubusercontent.com/r-a-y/mobile-hosts/master/AdguardApps.txt | |
https://raw.githubusercontent.com/r-a-y/mobile-hosts/master/AdguardMobileAds.txt | |
https://raw.githubusercontent.com/FadeMind/hosts.extras/master/StreamingAds/hosts |
//First commit any outstanding code changes, and then, run this command: | |
git rm -r --cached . | |
//This removes any changed files from the index(staging area), then just run: | |
git add . | |
//Commit | |
git commit -m ".gitignore initiated" |
Hierarchical data metrics that allows fast read operations on tree like structures.
Based on Left and Right fields that are set during tree traversal. When entered into node value is set to it's Left, when exiting node value is set to it's Right.