Re: [nodejs] Help with JWT implementation

2015-08-06 Thread josh
now log in from anywhere, anytime until the JWT > expires. You verify the user by decoding the JWT. The whole point of having > JWT is to not store them in a db. > > On Wed, Aug 5, 2015 at 7:40 AM, josh > > wrote: > >> Thank you Alexander! >> >> so maybe

Re: [nodejs] Help with JWT implementation

2015-08-05 Thread josh
ds the web app. You always have to > render some boilerplate HTML and then let the client-side Javascript do the > authentication call for you. > > On Tue, Aug 4, 2015 at 4:01 AM, josh > > wrote: > >> We use OneLogIn for SSO and also SalesForce. We would like to h

[nodejs] Help with JWT implementation

2015-08-03 Thread josh
We use OneLogIn for SSO and also SalesForce. We would like to have a single auth service that will take care of authentication and authorization to all our apps. Is this diagram looks like a good approach? http://i.imgur.com/Ji1I1P4.png - Here is the suggested flow: email/password form -> auth

[nodejs] npm 1.4.14 missing from http://nodejs.org/dist/npm/

2014-07-24 Thread Josh Unger
I noticed 0.10.29 upgraded to npm 1.4.14. However, it appears to be missing in http://nodejs.org/dist/npm/. Shouldn't it exist in this directory? http://blog.nodejs.org/2014/06/16/node-v0-10-29-stable/ Thanks. -josh -- Job board: http://jobs.nodejs.org/ New group rules:

Re: [nodejs] Re: Unable to complete a PUT request of AngularJS data via a factory and node.js

2014-03-03 Thread Josh Longbrake
ient: res.send or something like that. > > Am Freitag, 28. Februar 2014 22:58:06 UTC+1 schrieb Josh Longbrake: >> >> I have been unable to complete this request, using a few different >> options, none of which are working as I believe implementation is >> incorrec

[nodejs] Unable to complete a PUT request of AngularJS data via a factory and node.js

2014-02-28 Thread Josh Longbrake
I have been unable to complete this request, using a few different options, none of which are working as I believe implementation is incorrect. How do I get the request through? my request: http{ host: 'hostsite.com', port: 443, data: data.body.prov, path:

Re: [nodejs] node.js and node-rest-client TypeError: Cannot read property 'tunnel' of undefined

2014-02-28 Thread Josh Longbrake
Just wanted to confirm that the github fixed version is working. On Thursday, February 27, 2014 4:07:22 PM UTC-6, // ravi wrote: > > On Feb 27, 2014, at 4:57 PM, Josh Longbrake > > > wrote: > > Hmm. Its the installed package from homebrew but it may be an older > v

Re: [nodejs] node.js and node-rest-client TypeError: Cannot read property 'tunnel' of undefined

2014-02-27 Thread Josh Longbrake
4, at 1:19 PM, Josh Longbrake > wrote: > > Sure here it is: > > TypeError: Cannot read property 'tunnel' of undefined > at new exports.Client > (/Users/jlongbrake/Desktop/sitename/node_modules/node-rest-client/lib/node-rest-client.js:14:42) > at /Users/jlongbra

Re: [nodejs] node.js and node-rest-client TypeError: Cannot read property 'tunnel' of undefined

2014-02-27 Thread Josh Longbrake
at /Users/jlongbrake/Desktop/sitename/controller/mdmController.js:10:22 would be this line from the code above: var client = new Client(); On Thursday, February 27, 2014 12:19:46 PM UTC-6, Josh Longbrake wrote: > > Sure here it is: > > TypeError: Cannot read property 'tun

Re: [nodejs] node.js and node-rest-client TypeError: Cannot read property 'tunnel' of undefined

2014-02-27 Thread Josh Longbrake
.id, method: 'PUT', headers: {'Authorization': 'Bearer 0c92f5177d5e818fcc680681f1e9b6895bd5491153'}}) On Thursday, February 27, 2014 11:01:43 AM UTC-6, // ravi wrote: > > On Feb 27, 2014, at 10:43 AM, Josh Longbrake > > > wrote: > > > &g

[nodejs] node.js and node-rest-client TypeError: Cannot read property 'tunnel' of undefined

2014-02-27 Thread Josh Longbrake
I am getting the error listed in the title when using the code posted below. This is based off of: https://www.npmjs.org/package/node-rest-client fyi: the Bearer, path and client url have been masked as they are client sensitive items. middleware: angular.module('ruleService', []) .

Re: [nodejs] Australian Node.js developers wanted (up to $110k) - Western Sydney

2014-01-24 Thread josh . e
ay. I hope the next job description is more fitting to your critical positioning. Many thanks, Josh On Friday, January 24, 2014 8:47:49 PM UTC+11, 3rdEden wrote: > > FYI: Nobody will take you serious when you put 1337 in job description. > According to news reported by various of news outlets,

Re: [nodejs] Australian Node.js developers wanted (up to $110k) - Western Sydney

2014-01-24 Thread josh . e
Genius. Good for you. Tell me ALL about how your ACTUAL 1337 skillz are earning you millions in some other language like Java, Ruby, C++, Python... :-P On Friday, January 24, 2014 9:21:45 PM UTC+11, Alex Kocharin wrote: > > > Yeah, "PHP/Wordpress" and "1337 skills" aren't really fit in one m

Re: [nodejs] Re: Australian Node.js developers wanted (up to $110k) - Western Sydney

2014-01-24 Thread Josh Ellis
visa status is the main concerning factor, though. The company is not willing to consider sponsorship at this stage. Thanks for your email. Josh On 24/01/2014 7:45 PM, "alessioalex" wrote: > Do you also accept rockstars and samurais? > > Also from what I understand this posi

[nodejs] Australian Node.js developers wanted (up to $110k) - Western Sydney

2014-01-23 Thread josh . e
You only want to work with the best, and here's an opportunity hot off the presses. The team consists of mostly young, energetic developers in a fun, funky environment. The office is modern and fresh. You don't need to wear a suit and tie, just semi-casual.*We know you've got to be comfortabl

[nodejs] Free Node.js Deployment to Heroku course

2013-10-04 Thread Josh Chittick
Javascript knowledge. https://www.udemy.com/nodejs-in-30/ Thanks, Josh -- -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group.

Re: [nodejs] Tagalog -- tagged logs

2013-08-17 Thread Josh Ragem
tagalog is under a half hour, so I wouldn't advise you to use it as much of anything right now. I used a proprietary tagged log system at a past job and my experience with tags has been so much better than with log levels. (I am aware that tagalog is a language, I've met many

[nodejs] Tagalog -- tagged logs

2013-08-17 Thread Josh Ragem
know that tomorrow me wants a particular log line at level 'EMERGENCY! OH NOES!'. To recap: 1. tagged logs 2. debug quickly 3. ???? 4. profit! Please check it out at https://github.com/JoshRagem/tagalog and see how this idea works for you. Josh -- -- Job Board: http://jobs.nodej

[nodejs] Re: Any suggestions for running mocha tests multiple times against different scenarios?

2013-05-16 Thread Josh Faul
Check out the info on shared behaviors in the mocha wiki: https://github.com/visionmedia/mocha/wiki/Shared-Behaviours On Wednesday, May 15, 2013 2:36:48 PM UTC-6, Sam Roberts wrote: > > I'm about to pull the test functions out into basically a library, and > essentially do: > > describe('apple

[nodejs] Re: How to use streams with feedparser

2013-03-19 Thread josh
works! is it identical to this one? if not, what is the difference? request(reqObj, function (err, response, body){ feedparser.parseString(body) .on('article', callback);}); On Tuesday, March 19, 2013 1:11:40 PM UTC-7, Dan MacTough wrote: > > Josh, sorry about the outdat

[nodejs] How to use streams with feedparser

2013-03-18 Thread josh
this is almost a copy paste from feedparser readme. I know I miss something but not sure what it is. var request = require('request'); var feedparser = require('feedparser'); request({ 'uri': 'http://substack.net/blog.xml' }).pipe(feedparser.stream); stream.js:52 dest.on('drain', ondrain);

[nodejs] Re: NodeJs e-commerce solution?

2013-02-28 Thread Josh Kurz
@Nicotene any progress on releasing some of the npm modules? Or do you have any suggestions as to ecommerce modules that have been effective in your development process? On Thursday, May 10, 2012 2:55:51 PM UTC-4, guzelgoz wrote: > > Hi all, > > I've been searching and searching but couldn't fi

[nodejs] Re: Running tests directly and as part of a suite

2013-01-27 Thread josh
Daniel, your suggestion will make my test files shorter and DRY, but on the other hand running my tests might be less intuitive than before - node unit/test/test_404.js vs node unit/test/runner.js unit/test/test_404.js. I want to make it easy as possible to run the tests, so at the moment I pref

[nodejs] converting a string to binary

2013-01-27 Thread josh
I need to emit LWES event, and reading about an event structure here http://www.lwes.org/docs/doxygen/html/structlwes__event.html it looks like i need 1 byte string, 2 bytes number a struct and a hash of attributes. I know about dgram but not sure how to send the correct info in the socket. an

[nodejs] Running tests directly and as part of a suite

2013-01-26 Thread josh
I want to run my test file alone - node test/unit/test_404.js but also with the test suite - node test/unit/runner.js to achieve that I added an if/else statement in each test file to check if the code is running directly with the node executable or if it's required by other file. if it was run

[nodejs] Re: Simple chat-room example?

2013-01-07 Thread Josh Santangelo
In case anyone else comes across this thread, the answer was to not use a raw socket, but rather to use a full client. There is a .NET client here: http://socketio4net.codeplex.com/ On Monday, January 7, 2013 2:32:13 PM UTC-8, Josh Santangelo wrote: > > I tried the very basic sample cod

[nodejs] Re: Simple chat-room example?

2013-01-07 Thread Josh Santangelo
I tried the very basic sample code from the socket.io home page in a browser and that seemed to work correctly, further confirming my suspicion that it's on the client side. On Monday, January 7, 2013 1:20:25 PM UTC-8, Josh Santangelo wrote: > > Thanks for the replies, all. I'

[nodejs] Re: Simple chat-room example?

2013-01-07 Thread Josh Santangelo
013 7:27:35 PM UTC-8, Ben Evans wrote: > > Hi Josh, > > If it's any use to you, when i first gave Node a shot I wrote a very basic > chat app. Feel free to use it/reference: > https://github.com/bencevans/Little-Chat-Script > > Features: > > * Socket.IO Realtime Me

[nodejs] Simple chat-room example?

2013-01-04 Thread Josh Santangelo
dules would be better, but I'm surprised I couldn't find a code sample for this use case since it sounds like it's a pretty common node.js usage. Obviously this is my first time using node.js! Any pointers would be very helpful. thanks, -josh -- Job Board: http://jobs.nodejs.org/ P

[nodejs] Re: Architecture of a scalable push notification service

2012-12-17 Thread josh
Redis might not be optimal for my case since it store everything in memory and i might be in a situation where apple server is not available and many failed messages will be saved in memory very quickly. also, if I plan to keep those messages for reporting etc, i should store it in a more persi

[nodejs] Re: Architecture of a scalable push notification service

2012-12-16 Thread josh
also, if I have 2 cores, should i have node+Redis on each? -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group

[nodejs] Architecture of a scalable push notification service

2012-12-16 Thread josh
I am about to build a push notification service for iOS (android in the future). I don't know at the moment how much load it should handle, but let's assume it's 500 requests per second. it might be lower, but i would rather built it to handle it. I found a good post about flickr - http://code

Re: [nodejs] [ANN] node-avro 0.2: Avro support for Node.js

2012-11-07 Thread Josh Faul
master/ext/ruby_generator Props to BJ and Brandon for awesomeness. :) --Josh On Wednesday, November 7, 2012 11:54:58 AM UTC-7, Jacob wrote: > > Since we're on this topic, what is the general state of > Avro/Thrift/Protobufs. Are many people using them in production? I > know Thrift

[nodejs] Re: a simple http server making current folder accessible from web?

2012-10-31 Thread Josh Faul
I actually use this in my .zshrc: alias servethis="python -m SimpleHTTPServer " And then I have an easily accessible bookmark for it. Very handy for testing simple things. On Sunday, October 28, 2012 5:48:39 AM UTC-6, Angelo Chen wrote: > > I did some google, and found out python has that:

Re: [nodejs] Re: A quest for a more accurate net.isIP() for IPv6

2012-10-04 Thread Josh Erickson
Thanks guys! I didn't know that about split operations. Jonny, do you have benchmarks handy on your django port? If not, I'll hack something together and get them myself. If it is faster, I'd just rather it be brought into node itself then me stumble around in the dark anymore. This past day I'

[nodejs] A quest for a more accurate net.isIP() for IPv6

2012-10-04 Thread Josh Erickson
and run the tests against it, so getting this into the pull request queue may take some time. In the mean time, could I get some scathing commentary on my approach and any pointers on how this could be done better or faster? Thanks, Josh Erickson //Begin Code var new_isIP = function(input)

[nodejs] ANN: statelet

2012-08-23 Thread Josh Johnston
Hi all, I've published a module that I've been using for a little while and find quite useful: https://npmjs.org/package/statelet Take a look at the examples, feedback greatly appreciated. TLDR: States are a lot like Events, but more permanent in nature. An Event describes a change at a poin

Re: [nodejs] Re: what does the \n in response.write('hello\n'); responsible for?

2012-08-11 Thread josh
var http = require('http'); http.createServer(function (request, response) { response.write('Hello'); setTimeout(function(){ response.end('world'); }, 5000); }).listen(3001); this code will not display 'Hello' right away. it will display 'Hello world' after 5 seconds. changing it to

[nodejs] what does the \n in response.write('hello\n'); responsible for?

2012-08-09 Thread josh
i noticed that response.write('hello\n'); will send 'hello' to the client. but ommiting the \n does not. is it chrome specific or is that node's way to stream part of the response to it's clients? also, is node server always streams the response back to it's client? -- Job Board: http://jobs.no

Re: [nodejs] how to do performance test of my POST service

2012-08-03 Thread josh
awesome advice. i wanted to do that but didn't figure it out yet! -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to thi

[nodejs] how to do performance test of my POST service

2012-08-03 Thread josh
I am trying to improve our existing file upload API (using sinatra) and see if Node can be a better alternative. i am using formidable to upload the file, than I stream(read) the file from disk into put request that saves it on our cloud servers, and finally, I save some meta data into a mysql.

[nodejs] creating tpkg for node.js on centOS

2012-07-31 Thread josh
i create tgkg with this script http://pastebin.com/QBVDSqXC and was able to run node. but when i type npm i get: '/home/t/bin/npm: Permission denied' any ideas? #!/bin/sh set -e VERSION=0.8.4 PKGVER=1 OS=`tpkg --qenv | grep 'Operating System' | awk '{print $NF}'` ARCH=`tpkg --qenv | grep '

[nodejs] Re: making a POST to node service from an html form that served by non-node server

2012-07-26 Thread josh
any opinions? On Wednesday, July 25, 2012 7:23:23 PM UTC-7, mscdex wrote: > > On Jul 25, 9:32 pm, josh wrote: > > method="post"> > > After removing these asterisks, your example worked just fine for me. > > Is your html being served by a webserver or a

[nodejs] making a POST to node service from an html form that served by non-node server

2012-07-25 Thread josh
I have existing ruby site with a big csv file I need to upload, process and send some progress info to the browser and to a mysql. I decided to do that upload + process in node by POSTING to my node server and use socket.io to push some stats back to the browser. I have a form with action='127.0

[nodejs] Re: sending a file using HTTP PUT

2012-07-25 Thread josh
problem solved: var file = fs.createReadStream(path) .pipe(request.put({url: url, headers:{'Content-Length': fileSize}}, function(err, res, body){ if(err) { console.log('error', err); } else { console.log('status', res.statusCode); if(res.st

[nodejs] Re: API for uploading files using formidable - don't see the temporary file and 'file' event not emitted

2012-07-24 Thread josh
works. thank you! -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com T

[nodejs] Re: API for uploading files using formidable - don't see the temporary file and 'file' event not emitted

2012-07-24 Thread josh
I still don't see the image on the server. btw, now the fields is outputing: { myupload: 'pic.JPG' } here is the verbose output: curl -F "myupload=pic.JPG" 0.0.0.0:3001/api -v * About to connect() to 0.0.0.0 port 3001 (#0) * Trying 0.0.0.0... connected * Connected to 0.0.0.0 (0.0.0.0) port 300

[nodejs] API for uploading files using formidable - don't see the temporary file and 'file' event not emitted

2012-07-24 Thread josh
I want to create an end-point for uploading image files. i want it to be as fast as possible I use formidable but the 'file' event never being emitted and i don't see the file in /tmp/upload (process.env.TMP). any idea why? http://pastebin.com/sMefhfsf maybe it's the way i curl it? curl -H "

Re: [nodejs] sending a file using HTTP PUT

2012-07-24 Thread josh
btw i am able to do PUT using fs.readFile but i don't want to load each file into memory. is my api suppose to support streaming or should this piping approach works with any server? -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Post

Re: [nodejs] sending a file using HTTP PUT

2012-07-24 Thread josh
great. it works for simple string - body: 'I am an attachment' now I want to stream a file. I am trying to pipe the readable stream of my file into the put request: file = fs.createReadStream('test-file').pipe(request.put('http://api.my-server.com:3000/test.foo/test-7)); and it looks fine (noth

[nodejs] sending a file using HTTP PUT

2012-07-23 Thread josh
I try to make an HTTP PUT to an API. this endpoint allow sending a file and it saves it somewhere for later retrieval. Here is the way I do it (successfully) with curl: curl -sSf -T file1 http://api.my-server/file1 (PUT)andcurl -O -L http://api.my-server/file1 (GET) Here is a verbose

Re: [nodejs] the advantge node gives for mobile

2012-07-23 Thread josh
thanks. How is it different than any server side technology? What about the streaming API? does it give any advantages? (maybe on server memory?) -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this messa

[nodejs] the advantge node gives for mobile

2012-07-23 Thread josh
I read Hughes-Croucher slides from his talk at velocity conference - "Using Node.js to improve the performance of Mobile apps and Mobile web". can someone explain slide 50 - "Node.js allows you to tune rendering between client and server based on the network - http://www.slideshare.net/sh1mmer/u

Re: [nodejs] Re: e-Commerce platform

2012-07-21 Thread josh
1) for any open source project your goal is to get as many people as possible participating. there are a lot more JS programmers than CS programmers out there. by choosing CS you are reducing the number of people who can contribute to your project. 2) ECMAScript 6 is going to add the -> operator

[nodejs] how to display the value of a variable in the deugger?

2012-07-12 Thread josh
// test.js var i=0; debugger; // node debug test.js // n(next) // backtrace=> #0 test.js:2:1 // i => i not defined how to display the value of i? -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List

[nodejs] why is node server easier for maintaining state between requests?

2012-07-09 Thread josh
http://vimeo.com/40554843 this is Mikeal's presentation from 'Keeping It Realtime Conference' watch minute 7:30-8:30. he say that node, unlike ruby/php/python allow you to store your cache in the server process and instead of an external process (i assume memcached is a common one). is that d

[nodejs] Re: accessing a variable in a function that is exported from a module (using mapletree routing module)

2012-07-04 Thread josh
thanks guys. both ways works. i prefer the module.export.foo way since i don't need to pass the variable to multiple functions. On Tuesday, July 3, 2012 2:47:58 PM UTC-7, josh wrote: > > I have a variable in server.js. how to access it from within a function > that is exported

Re: [nodejs] accessing a variable in a function that is exported from a module (using mapletree routing module)

2012-07-03 Thread josh
fast routing library. instead of using express i use plain node.js + routing lib - https://github.com/saambarati/mapleTree On Tuesday, July 3, 2012 2:49:06 PM UTC-7, Marak Squires wrote: > > What is a Maple Tree? > > On Tue, Jul 3, 2012 at 2:47 PM, josh wrote: > >>

[nodejs] accessing a variable in a function that is exported from a module (using mapletree routing module)

2012-07-03 Thread josh
I have a variable in server.js. how to access it from within a function that is exported from a module? I use mapletree as my routes library that provide me define function - var usersCollections = {}; router.define( '/user', require('./routes/user.js') //routes/user.js module.exports = user;

[nodejs] Re: simple post request using row node and using the request package

2012-06-23 Thread josh
it always the same in node? On Saturday, June 23, 2012 3:17:33 PM UTC-7, josh wrote: > > I try to POST to this url - https://browserid.org/verify. using row node > i get: getaddrinfo ENOENT and using the request package i get: Content-Type > expected to be one of: application

[nodejs] Re: simple post request using row node and using the request package

2012-06-23 Thread josh
thanks. i figure it out and here are the 2 examples: // raw var https = require('https'); var querystring = require('querystring'); var post_data = querystring.stringify({ 'assertion' : 'abc' 'audience' : '0.0.0.0' }); var options = { host: 'browserid.org', path: '/verify', method: 'P

[nodejs] simple post request using row node and using the request package

2012-06-23 Thread josh
I try to POST to this url - https://browserid.org/verify. using row node i get: getaddrinfo ENOENT and using the request package i get: Content-Type expected to be one of: application/x-www-form-urlencoded, application/json. Another question - Is there any reason not to use browserID for authen

[nodejs] Re: 2 issues - 'Error: socket hang up' and too many phantom.js processes running

2012-05-01 Thread josh
Here is what I did to solve it. I am curious to know if there are better ideas. I added a check for stream.fd to the 'end' event and I only move the file to the real folder if it's not null. this solved the issue with corrupted files. res.on('end', function (chunk) { if(stream.fd ===

[nodejs] Re: 2 issues - 'Error: socket hang up' and too many phantom.js processes running

2012-04-30 Thread josh
I found out the reason for those issues - disconnecting from the internet for a split second. when i disconnected my laptop, the socket error showed up and i noticed more and more instances of phantom.js being created, but never dies. the image updater service didn't crash (if i remember correctl

Re: [nodejs] 2 issues - 'Error: socket hang up' and too many phantom.js processes running

2012-04-30 Thread josh
thank you. i'll add it to my code. -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@g

[nodejs] 2 issues - 'Error: socket hang up' and too many phantom.js processes running

2012-04-30 Thread josh
I have 2 tiny node services: 1. screenshot service (https://github.com/fzaninotto/screenshot-as-a-service) - get's url and can stream back a snapshop of it. 2. image updater - calls the screenshot service every few minutes with 5 urls. Here is the code for the image updater. require('http'); v

[nodejs] Re: updating my UI when my server got a message via socket.io

2012-04-22 Thread josh
Thank you Guillermo. So I'll end up with 3 (probably more in the future) apps that talk to each other using socket.io. is there a good way to manage them and not getting lost with the configuration and provisioning? I noticed a few project by substack that might be relevant, but I don't understand

[nodejs] Re: updating my UI when my server got a message via socket.io

2012-04-22 Thread josh
the socket ids). I am still considering splitting it into 3 apps, so the socket.io server will stand on it's own. any pro/cons about this? On Saturday, April 21, 2012 7:54:32 PM UTC-7, josh wrote: > > I am building 2 separate express sites: > clients website - visitors can talk

[nodejs] updating my UI when my server got a message via socket.io

2012-04-22 Thread josh
I am building 2 separate express sites: clients website - visitors can talk to me (the admin of the site) via chat (1 on 1 only. they can't see each other). admin website - for me, the admin, to see all current conversations and the ability to reply to whatever user I want. I am using socket.io to