-
Tipos de IPC - Exemplos com Pythom: https://codecalamity.com/interprocess-communications/
-
Java - MsgPack With Jackson: https://github.com/msgpack/msgpack-java/tree/develop/msgpack-jackson
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
| import java.io.*; | |
| public class TestProcessIO { | |
| public static boolean isAlive(Process p) { | |
| try { | |
| p.exitValue(); | |
| return false; | |
| } | |
| catch (IllegalThreadStateException e) { |
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
| http://www.dscripts.net/2010/06/09/how-to-lock-a-process-in-java-to-prevent-multiple-instance-at-the-same-time/ | |
| //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
| // check if another process is running | |
| //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
| package utils; | |
| import java.io.File; | |
| import java.io.IOException; |
VERTX
vertx-base:
- git@github.com:abner/vertx-base.git
- /home/abner/Projetos/vertx/vertx-base
projeto-exemplo:
- /home/abner/Projetos/vertx/projeto-exemplo
db.votes.aggregate([{
$lookup: {
from: "users",
localField: "createdBy",
foreignField: "_id",
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/bash | |
| ssh root@10.139.7.126 "cd /home/abner/target-folder; tar zc data-bkp --verbose" | tar zx |
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/bash | |
| JQ_CMD="$PWD/jq" | |
| if [ ! -f $JQ_CMD ]; then | |
| echo "Downloading jq binary..." \ | |
| && wget https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64 -O $JQ_CMD \ | |
| && chmod +x $JQ_CMD \ | |
| && echo "JQ was downloaded" |
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
| export interface Environment { | |
| DEBUG : boolean; | |
| API_URL : string; | |
| WS_URL : string; | |
| BASE_URL : string; | |
| } |
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
| const asyncDispatcMiddleware = store => next => action => { | |
| let syncActivityFinished = false; | |
| let actionQueue = []; | |
| function flushQueue() { | |
| actionQueue.forEach(a => store.dispatch(a)); | |
| actionQueue = []; | |
| } | |
| function asyncDispatch(asyncAction) { |