-
Open the ChatGPT Codex task setup panel. This is where you configure your environment before starting a task.
-
Locate the "Setup Script" field. You’ll see a note that internet access is disabled after the script runs.
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 http = require('http'); | |
var express = require('express'); | |
var router = express.Router(); | |
/* GET users listing. */ | |
router.get('/', function(req, res) { | |
var request = require('request'); | |
var url = req.query.url; |
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
# benchmark immutable.js with my transducers lib: https://github.com/jlongster/transducers.js | |
% node bench/immut.js | |
Immutable map/filter (1000) x 5,497 ops/sec ±2.63% (91 runs sampled) | |
transducer map/filter (1000) x 7,309 ops/sec ±0.73% (100 runs sampled) | |
Immutable map/filter (100000) x 62.73 ops/sec ±0.85% (67 runs sampled) | |
transducer map/filter (100000) x 80.15 ops/sec ±0.48% (71 runs sampled) |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
From Meteor's documentation:
In Meteor, your server code runs in a single thread per request, not in the asynchronous callback style typical of Node. We find the linear execution model a better fit for the typical server code in a Meteor application.
This guide serves as a mini-tour of tools, trix and patterns that can be used to run async code in Meteor.
Sometimes we need to run async code in Meteor.methods
. For this we create a Future
to block until the async code has finished. This pattern can be seen all over Meteor's own codebase:
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
# A little Meteor CheatSheet about Iron-Router. (updated on a weekly basis) | |
# Check our Studio: https://gentlenode.com/ | |
meteor add iron:router | |
meteor update iron:router | |
# Iron Router > Configuration |
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
# add something like this to config.ru | |
# see https://github.com/kzk/unicorn-worker-killer | |
if Integer(ENV['UNICORN_KILLER'] || 0) != 0 | |
require 'unicorn/worker_killer' | |
# Max memory size (RSS) per worker | |
use Unicorn::WorkerKiller::Oom, (350*(1024**2)), (400*(1024**2)), 30, true | |
end |
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
# This file is used by Rack-based servers to start the application. | |
# GC_FREQUENCY = 8 | |
# require "unicorn/oob_gc" | |
# GC.disable # Don't run GC during requests | |
# use Unicorn::OobGC, GC_FREQUENCY # Only GC once every GC_FREQUENCY requests | |
# # Unicorn self-process killer | |
require "unicorn/worker_killer" |
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
docker-machine create -d virtualbox cluster-store | |
CLUSTER_STORE_IP=$(docker-machine ip cluster-store) | |
docker $(docker-machine config cluster-store) run -d \ | |
--restart="always" \ | |
--publish="2379:2379" \ | |
microbox/etcd:2.1.1 \ | |
-name etcd0 \ | |
-advertise-client-urls http://${CLUSTER_STORE_IP}:2379 \ | |
-listen-client-urls http://0.0.0.0:2379 \ |
NewerOlder