Command Line
pry -r ./config/app_init_file.rb
- load your app into a pry session (look at the file loaded by config.ru)pry -r ./config/environment.rb
- load your rails into a pry session
Debugger
Command Line
pry -r ./config/app_init_file.rb
- load your app into a pry session (look at the file loaded by config.ru)pry -r ./config/environment.rb
- load your rails into a pry sessionDebugger
Magic words:
psql -U postgres
Some interesting flags (to see all, use -h
or --help
depending on your psql version):
-E
: will describe the underlaying queries of the \
commands (cool for learning!)-l
: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)#! /bin/bash | |
# This script will set up a full tyk environment on your machine | |
# and also create a demo user for you with one command | |
# USAGE | |
# ----- | |
# | |
# $> ./tyk_quickstart.sh {IP ADDRESS OF DOCKER VM} |
#!/bin/bash | |
# | |
# Detects mysql deadlocks and notify developers by email | |
# Notification sent on new deadlocks only | |
# monuser must have "PROCESS" permission in mysql server | |
# Set EXCLUDE_PTRN to avoid alerting if the pattern was found | |
# | |
host=$1 | |
user=monuser |
@credit Yan Zhu (https://github.com/nina-zhu)
Jersey is the most popular amongst Restful web service development. Latest Jersey 2.x version has been developed by Oracle/Glassfish team in accordance with JAX-RS 2.0 specification. Earlier Jersey 1.x version was developed and supported by Oracle/Sun team.
Latest Jersey release version is 2.25 see here and look documentation and API for details. We will implement a Jersey example in this article based on latest 2.x version.
In this article, we will use Hibernate's rich API to interact with MariaDB database or in general any ORM compliant database. We will create a
package main | |
import ( | |
"errors" | |
"fmt" | |
"sync" | |
"time" | |
) | |
const ( |