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
import java.io.Serializable; | |
import java.util.List; | |
import javax.persistence.EntityManager; | |
import org.springframework.data.domain.Page; | |
import org.springframework.data.domain.Pageable; | |
import org.springframework.data.domain.Sort; | |
import org.springframework.data.jpa.domain.Specification; | |
import org.springframework.data.jpa.repository.support.JpaEntityInformation; |
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
Verifying that +yanaga is my blockchain ID. https://onename.com/yanaga |
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
import java.text.Normalizer; | |
public class SemAcentoNemCedilha { | |
public static String normalizar(String s) { | |
return Normalizer.normalize(value, Normalizer.Form.NFD).replaceAll("[^\\p{ASCII}]", ""); | |
} | |
} |
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
import java.io.FileNotFoundException; | |
import javax.annotation.PostConstruct; | |
import org.springframework.context.annotation.Configuration; | |
import org.springframework.context.annotation.Profile; | |
import org.springframework.util.Log4jConfigurer; | |
@Configuration | |
@Profile("production") |
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
RBC WaterPark Workshop - 10/02/2020 | |
Openshift Master Console: http://console-openshift-console.apps.cluster-yyz-3dca.yyz-3dca.example.opentlc.com | |
Openshift API for command line 'oc' client: https://api.cluster-yyz-3dca.yyz-3dca.example.opentlc.com:6443 | |
Download oc client from https://mirror.openshift.com/pub/openshift-v4/clients/ocp/4.3.0/openshift-client-linux-4.3.0.tar.gz | |
You can choose any combination of username/password on the first time you login. |
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
public boolean isValid(String s) { | |
if (s.matches("[1-2]\\d{10}00[0-1]\\d") || s.matches("[7-9]\\d{14}")) { | |
return somaPonderada(s) % 11 == 0; | |
} | |
return false; | |
} | |
private int somaPonderada(String s) { | |
char[] cs = s.toCharArray(); | |
int soma = 0; |
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
sudo fallocate -l 4G /swapfile | |
sudo chmod 600 /swapfile | |
sudo mkswap /swapfile | |
sudo swapon /swapfile | |
cat << EOF | sudo tee -a /etc/fstab | |
/swapfile none swap sw 0 0 | |
EOF |
OlderNewer