keytool -genkeypair -keyalg RSA -keysize 2048 -validity 365 -alias ca -dname "CN=ca,O=HMS,S=SE" -keystore ca.jks -storepass password
keytool -exportcert -rfc -alias ca -keystore ca.jks -storepass password > ca.pem
cat ca.pem | keytool -importcert -alias ca -noprompt -keystore trust.jks -storepass password
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
# Here are some JVM args that are extremely useful in production when things go wrong | |
-XX:+G1SummarizeRSetStats | |
-XX:G1SummarizeRSetStatsPeriod=10 | |
-XX:+PrintAdaptiveSizePolicy | |
-XX:+PrintJNIGCStalls | |
-XX:+PrintReferenceGC | |
-XX:+PrintGCCause | |
-XX:+PrintGCDateStamps | |
-XX:+PrintGCTimeStamps | |
-XX:+PrintGCDetails |
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
# To regenerate the test key and certificates | |
# Generate an RSA private key and convert it to PKCS8 wraped in PEM | |
openssl genrsa 2048 | openssl pkcs8 -topk8 -inform pem -outform pem -nocrypt -out rsa.key | |
# Generate a certificate signing request with the private key | |
openssl req -new -key rsa.key -out rsa.csr | |
# Sign request with private key | |
openssl x509 -req -days 10000 -in rsa.csr -signkey rsa.key -out rsa.crt | |
- Intellij Preferences > Live Templates > group
other
- Add a new one with
- abbreviation
rnn
- Description
requireNonNull
- Template text
java.util.Objects.requireNonNull($var$, "$var$ is null")
- Applicable contexts:
Java > Expression
- check
use static imports if possible
- abbreviation
- Edit variables button and there add
var
variable withvariableOfType("Object")
expression
mvn clean release:clean && mvn release:prepare
# `env GPG_TTY=$(tty)` may help with some sort of GPG problems
mvn release:perform
# See knownSparkVersions in gradle.properties for current list Spark versions
./gradlew -DsparkVersions=2.4,3.0,3.1,3.2,3.3 -x test -x integrationTest build publishToMavenLocal
# ... or pull the list automatically
./gradlew -DsparkVersions=$(sed -n 's/^systemProp.knownSparkVersions=//p' gradle.properties) \
-x test -x integrationTest build publishToMavenLocal
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
# store as docky/Dockerfile to match references in the other script | |
FROM ubuntu:latest | |
RUN true && \ | |
export DEBIAN_FRONTEND=noninteractive && \ | |
apt-get update && \ | |
apt-get install -y openssl && \ | |
apt-get clean && \ | |
echo OK |
OlderNewer