Skip to content

Instantly share code, notes, and snippets.

View th0j's full-sized avatar
💭
🚀 🚀

Tho Vo th0j

💭
🚀 🚀
View GitHub Profile
@th0j
th0j / User(lombok).java
Created June 9, 2017 03:33
User.java with Lombok library
import lombok.Getter;
import lombok.Setter;
public class User implements java.io.Serializable{
@Setter @Getter
public String username;
@Setter @Getter
public String email;
@th0j
th0j / User.java
Created June 9, 2017 03:24
Not use lombok
public class User implements java.io.Serializable{
public String username;
public String email;
public String getUsername() {
return username;
}
public void setUsername(String username) {
@th0j
th0j / find_second_salary.sql
Created June 8, 2017 14:04
find_second_salary.sql
select MAX(Salary) from Employee WHERE Salary NOT IN (select MAX(Salary) from Employee);
@th0j
th0j / install_server_centos.sh
Last active April 27, 2017 03:24
install_server_centos
echo 'UPDATE YUM'
yum update -y
yum upgrade -y
yum install -y wget
echo 'DISABLE FIREWALL'
service iptables stop
chkconfig iptables off
echo 'INSTALL JAVA'
@th0j
th0j / shellconfig.sh
Last active April 11, 2017 04:41
Vagrant Java
echo " ========== Install Java 8 ========== "
sudo add-apt-repository -y ppa:webupd8team/java
sudo apt-get update
echo "oracle-java8-installer shared/accepted-oracle-license-v1-1 select true" | sudo debconf-set-selections
sudo apt-get -f install -y oracle-java8-installer
echo 'JAVA_HOME="/usr/lib/jvm/java-8-oracle"' >> ~/.bash_profile
echo 'JAVA_HOME="/usr/lib/jvm/java-8-oracle"' >> ~/.bash
echo " ========== Install MYSQL 5.5 ========== "
export DEBIAN_FRONTEND=noninteractive