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
/*! | |
* IpcManager.js | |
* | |
* Responsible for communicating between node processes | |
*/ | |
var IpcManager = { | |
HandleMessageOnWorker: function(message){ | |
if(message != null && message.type != null){ |
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
package main | |
import ( | |
"crypto" | |
"crypto/rsa" | |
"crypto/sha1" | |
"crypto/x509" | |
"encoding/base64" | |
"fmt" | |
) |
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
package main | |
import ( | |
"crypto" | |
"crypto/rsa" | |
"crypto/sha1" | |
"crypto/x509" | |
"encoding/base64" | |
"fmt" | |
) |
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
SELECT install.os, | |
install.country, | |
Count(DISTINCT install.device_tag) AS installs, | |
Count(DISTINCT economy.device_tag) AS spenders, | |
Sum(economy.spend_amount) AS total_spent | |
FROM install | |
LEFT OUTER JOIN economy | |
ON ( install.device_tag = economy.device_tag | |
AND economy.spend_type = 'cash_purchase' | |
AND Datediff('day', economy.ingest_datetime, |
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
SELECT To_char(install.ingest_datetime, 'YYYY-MM-DD') AS install_date, | |
install.os, | |
install.country, | |
Count(DISTINCT install.device_tag) AS installs, | |
Count(DISTINCT( CASE | |
WHEN event.kingdom = 'FTUE.Comic.Start' THEN | |
event.device_tag | |
ELSE '' | |
end )) - 1 AS "FTUE.Comic.Start", | |
Count(DISTINCT( CASE |
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
SELECT To_char(Date_trunc('day',cohort.local_datetime), 'MM-DD-YYYY') AS date, | |
cohort.os, | |
Count(DISTINCT cohort.device_tag) AS installs, | |
100*Cast(Count(DISTINCT step1.device_tag) AS FLOAT)/Cast(Count(DISTINCT cohort.device_tag) AS FLOAT) AS "FTUE.Comic.Start", | |
100*Cast(Count(DISTINCT step2.device_tag) AS FLOAT)/Cast(Count(DISTINCT cohort.device_tag) AS FLOAT) AS "FTUE.Comic.End", | |
100*Cast(Count(DISTINCT step3.device_tag) AS FLOAT)/Cast(Count(DISTINCT cohort.device_tag) AS FLOAT) AS "FTUE.Commander.LoadComplete", | |
100*Cast(Count(DISTINCT step4.device_tag) AS FLOAT)/Cast(Count(DISTINCT cohort.device_tag) AS FLOAT) AS "FTUE.Commander.Tapped", | |
100*Cast(Count(DISTINCT step5.device_tag) AS FLOAT)/Cast(Count(DISTINCT cohort.device_tag) AS FLOAT) AS "FTUE.Commander.Confirmed" | |
FROM ( | |
SELECT install.device_tag, |
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
SELECT allsteps.device_tag, | |
allsteps.os, | |
Max(CASE | |
WHEN allsteps.kingdom = 'FTUE.Comic.Start' THEN 1 | |
ELSE 0 | |
end) AS "step1", | |
Max(CASE | |
WHEN allsteps.kingdom = 'FTUE.Comic.END' THEN 1 | |
ELSE 0 | |
end) AS "step2" |
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 | |
. /etc/rc.d/init.d/functions | |
USER="root" | |
DAEMON="/etc/rpcs/Main" | |
SCRIPT="$(basename $0)" | |
PIDFILE="/var/run/$SCRIPT.pid" |
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
require('./classes/gamelog.js') | |
require('./classes/proto.js'); | |
require('./classes/service-locator.js'); | |
fs = require('fs'); | |
var context = require("./classes/context.js"); | |
var cluster = require('cluster'); | |
var os = require("os"); | |
var hostname = os.hostname(); | |
//console.log("hostname is " + hostname!); | |
var IS_MASTER_SHUTTING_DOWN = false; |
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
var vertices = []; | |
var edges = []; | |
vertices.push("A"); | |
vertices.push("B"); | |
vertices.push("C"); | |
vertices.push("D"); | |
vertices.push("E"); | |
edges.push(["A", "B"]); |