This file contains hidden or 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
@echo off | |
@setlocal enabledelayedexpansion | |
for /F "tokens=* delims=;" %%i in ('netstat -nao') do call :keller %%i | |
:keller | |
set a=%2 | |
echo %a% | |
if "%a%" equ "0.0.0.0:8081" (taskkill /F /PID %5) | |
shift |
This file contains hidden or 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
1, using system login | |
sqlplus system/password@xe | |
2, change system session configuration. | |
alter system set session_cached_cursors=200 scope=spfile; | |
alter system set session_max_open_files=200 scope=spfile; | |
alter system set sessions=20 scope=spfile; | |
alter system set license_max_sessions=200 scope=spfile; | |
alter system set license_sessions_warning=200 scope=spfile; | |
alter system set processes=200 scope=spfile; |
This file contains hidden or 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
##applicationContext-jms.xml | |
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd"> | |
<beans> | |
<bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"> | |
<property name="location" value="classpath:jboss.properties" /> | |
<!-- <property name="location" value="classpath:activemq.properties" /> --> | |
</bean> | |
<bean id="jndiTemplate" class="org.springframework.jndi.JndiTemplate"> | |
<property name="environment"> |
This file contains hidden or 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
<applet archive="applet.jar" code="demo.applet" width="0" height="0"> | |
<param name="separate_jvm" value="true"> | |
</applet> |
This file contains hidden or 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
<!-- call static method --> | |
<bean id="test" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean"> | |
<property name="targetClass" value="demo.Test" /> | |
<property name="targetMethod" value="staticmethod" /> | |
<property name="arguments"> | |
<list> | |
<value>test</value> | |
</list> | |
</property> | |
</bean> |
This file contains hidden or 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
<!--Spring Configuration--> | |
<http:conduit name="https://localhost:8083/WebService"> | |
<http:tlsClientParameters> | |
<sec:keyManagers keyPassword="keypassword"> | |
<sec:keyStore type="PKCS12" password="keypassword" file="keyfile"/> | |
</sec:keyManagers> | |
</http:tlsClientParameters> | |
</http:conduit> | |
<!-- Keystore File Format --> |
This file contains hidden or 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
#generate server and client keystore | |
keytool -genkeypair -alias server -keyalg RSA -dname "CN=Server,OU=Development,O=Test,L=Shanghai,S=SH,C=CN" -keystore server.keystore | |
keytool -genkeypair -alias client -keyalg RSA -dname "CN=Client,OU=Development,O=Test,L=Shanghai,S=SH,C=CN" -keystore client.keystore | |
keytool -list -keystore server.keystore | |
#copy server certificate into client.keystore | |
keytool -exportcert -alias server -file server-pub.cer -keystore server.keystore | |
keytool -importcert -alias server -file server-pub.cer -keystore client.keystore | |
keytool -list -keystore client.keystore |
This file contains hidden or 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
# add submodule web-static | |
git submodule add [email protected]:bulain/web-static.git src/main/webapp/web-static | |
git submodule add [email protected]:bulain/migration.git src/migration | |
# fetch submodule from remote | |
git submodule init | |
git submodule update | |
git submodule foreach git pull |
This file contains hidden or 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
# ssh remote | |
ssh -N -f -R 2080:127.0.0.1:80 bulain@remoteserver | |
# ssh local | |
ssh -N -f -L 80:127.0.0.1:2080 bulain@remoteserver | |
This file contains hidden or 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
#! /bin/sh | |
set -e | |
LIGHTY=/usr/local/sbin/lighttpd | |
LIGHTYCONFIG=/etc/lighttpd/lighttpd.conf | |
test -x $LIGHTY || exit 10 | |
test -e $LIGHTYCONFIG || exit 11 | |
. /lib/lsb/init-functions |
OlderNewer