This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns pdms.core | |
(:use korma.core | |
[korma.db :only (defdb)])) | |
(def db-spec {:subprotocol "postgresql" | |
:subname "//localhost/pdms" | |
:user "huleehom" | |
:password ""}) | |
(defdb db db-spec) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set nocompatible | |
filetype off | |
set rtp+=~/.vim/bundle/vundle | |
call vundle#begin() | |
Plugin 'gmarik/vundle' | |
"Plugin 'ervandew/supertab' | |
Plugin 'nanotech/jellybeans.vim' | |
Plugin 'scrooloose/nerdtree' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT | |
a.*, c.categoryName as articleCategoryName | |
FROM | |
ctms_article a | |
LEFT JOIN ctms_article b ON a.articleCategoryId = b.articleCategoryId | |
AND a.lastModified < b.lastModified | |
LEFT JOIN ctms_article_category c ON a.articleCategoryId = c.articleCategoryId | |
WHERE | |
a.state = 1 | |
GROUP BY |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<body id="Hallo" onload=""> | |
<script src="https://gist.github.com/2035118.js"> </script> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>com.zyxel</groupId> | |
<artifactId>sting</artifactId> | |
<name>abc</name> | |
<packaging>war</packaging> | |
<version>1.0.0-BUILD-SNAPSHOT</version> | |
<properties> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8" standalone="no"?> | |
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-2.0.xsd"> | |
<changeSet author="sting (generated)" id="1307605540491-1"> | |
<createTable tableName="ADDRESSES"> | |
<column name="ID" type="INT"> | |
<constraints nullable="false" primaryKey="true" primaryKeyName="CONSTRAINT_D"/> | |
</column> | |
<column name="NAME" type="VARCHAR(255)"/> | |
</createTable> | |
</changeSet> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MyMeta(type): | |
def __init__(cls, name, bases, attrs): | |
print "__init__ is called" | |
type.__init__(cls, name, bases, attrs) | |
def __call__(cls, *args, **kargs): | |
print "I am called" | |
return type.__call__(cls, *args, **kargs) | |
def __setattr__(cls, name, value): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
net.core.rmem_max=16777216 | |
net.core.wmem_max=16777216 | |
net.core.rmem_default=65536 | |
net.core.wmem_default=65536 | |
net.ipv4.tcp_rmem=4096 87380 16777216 | |
net.ipv4.tcp_wmem=4096 65536 16777216 | |
net.ipv4.tcp_mem=16777216 16777216 16777216 | |
net.ipv4.route.flush=1 | |
net.core.netdev_max_backlog=30000 | |
net.ipv4.udp_mem=16777216 16777216 16777216 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static final int _1M = 1024 * 1024; | |
/** | |
* Test with -verbose:gc -XX:+PrintGCDetails -Xms20M -Xmx20M -Xmn10M | |
*/ | |
public void testMinorGc() { | |
byte[] a1, a2, a3, a4; | |
a1 = new byte[_1MG / 2]; | |
System.out.println(1); | |
a2 = new byte[3 * _1MG]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static final int _1M = 1024 * 1024; | |
/** | |
* Test with -verbose:gc -XX:+PrintGCDetails -Xms20M -Xmx20M -Xmn10M -XX:MaxTenuringThreshold=1 | |
*/ | |
public static void testMaxTenuringThreshold() { | |
byte[] a1, a2, a3; | |
a1 = new byte[_1M / 4]; | |
System.out.println(1); |
OlderNewer