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
| from confluent_kafka import Consumer, KafkaError | |
| import logging | |
| import sys | |
| import json | |
| import datetime | |
| logging.basicConfig(format='%(process)d >> %(asctime)s - %(message)s', level=logging.INFO) | |
| settings = { | |
| 'bootstrap.servers': 'localhost:9092', |
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
| from flask import Flask, request | |
| from confluent_kafka import Producer | |
| import json | |
| import logging | |
| logging.basicConfig(format='%(process)d >> %(asctime)s - %(message)s', level=logging.INFO) | |
| app = Flask(__name__) | |
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 logging | |
| import datetime | |
| import random | |
| import time | |
| import threading | |
| import requests | |
| logging.basicConfig(format='%(process)d >> %(asctime)s - %(message)s', level=logging.INFO) | |
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
| // using bcrypt | |
| const express = require("express"); | |
| const bodyParser = require("body-parser"); | |
| const mongoose = require("mongoose"); | |
| const bcrypt = require('bcrypt'); | |
| const sessions = require("client-sessions"); | |
| const saltRounds = 10; | |
| const app = express(); |
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
| // using bcrypt | |
| const express = require("express"); | |
| const bodyParser = require("body-parser"); | |
| const mongoose = require("mongoose"); | |
| const bcrypt = require('bcrypt'); | |
| const saltRounds = 0; | |
| const app = express(); | |
| mongoose.connect("mongodb://localhost:27017/userDB", { |
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
| // with mongoose-encryption | |
| const express = require("express"); | |
| const bodyParser = require("body-parser"); | |
| const mongoose = require("mongoose"); | |
| const encrypt = require('mongoose-encryption'); | |
| const app = express(); | |
| mongoose.connect("mongodb://localhost:27017/userDB", { |
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
| <!-- register.html --> | |
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Register</title> | |
| </head> |
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 org.altbeacon.beaconreference; | |
| import android.app.Application; | |
| import android.app.Notification; | |
| import android.app.NotificationChannel; | |
| import android.app.NotificationManager; | |
| import android.app.PendingIntent; | |
| import android.app.TaskStackBuilder; | |
| import android.content.Context; | |
| import android.content.Intent; |
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
| module.exports = { | |
| config: { | |
| // default font size in pixels for all tabs | |
| fontSize: 12, | |
| // font family with optional fallbacks | |
| fontFamily: 'Menlo, "DejaVu Sans Mono", Consolas, "Lucida Console", monospace', | |
| // terminal cursor background color and opacity (hex, rgb, hsl, hsv, hwb or cmyk) | |
| cursorColor: 'rgba(248,28,229,0.8)', |