Questions tagged [node-fibers]

A fiber is a particularly lightweight kernel thread scheduler dependent thread of execution using co-operative multitasking.

A fiber is a particularly lightweight thread of execution.

Like threads, fibers share address space. However, fibers use co-operative multitasking while threads use pre-emptive multitasking. Threads often depend on the kernel's thread scheduler to preempt a busy thread and resume another thread; fibers yield themselves to run another fiber while executing.

node-fiber introduces Fiber support for v8 and Node JS

Source: Wikipedia

114 questions
1
vote
0 answers

Can't generate V8-4.3 node-fibers binaries for Electron

Ok so I have a nicely bundled Meteor app that should now be Node runnable. I'm trying to get it to work with Electron. I run npm install to add my modules and everything works except fibers creates a folder called win32-x64-3.28 and when I run…
RobotiX
  • 137
  • 8
1
vote
1 answer

Wrapping MongoDB calls within a Promise

I'm using Meteor (1.0.3) in general, but for one particular case I'm using a raw server side route to render a file -- so I'm outside a Meteor method. I'm using node fs.writeFile/fs.readFile and exec commands to call out to Linux command-line…
Aaron
  • 3,068
  • 2
  • 21
  • 44
1
vote
0 answers

Error using Phantom.js with Meteor.js: Meteor code must always run within a Fiber

When using Phantom.js and the phantom NPM package in Meteor.js, I'm getting an error stating that Meteor code must always run within a Fiber. Try wrapping callbacks that you pass to non-Meteor libraries with Meteor.bindEnvironment. I tried wrapping…
Nyxynyx
  • 61,411
  • 155
  • 482
  • 830
1
vote
1 answer

Meteor doesn't throw error but crashes

I want to implement error handling in my app but when I throw a Meteor.Error my server crashes. This might be because I'm using a future to wait for the result. How can I get this running? Meteor.methods({ '/app/pdf/download': function (url, name)…
zimt28
  • 705
  • 2
  • 7
  • 20
1
vote
1 answer

Does node's exec call block meteor application?

I am building a meteor application that creates pdf files from a web page using phantomjs. PhantomJS is called with node's child_process.exec function within a fiber using Meteor._wrapAsync. When I am using any url like google.com, it is working…
leoweigand
  • 154
  • 1
  • 9
1
vote
1 answer

Meteor Fiber Email

I'm attempting to send a simple email (locally, so my environment variables aren't set), and I get: Error: Meteor code must always run within a Fiber. Try wrapping callbacks that you pass to non-Meteor libraries with Meteor.bindEnvironment. Here's…
Alex_Faber
  • 117
  • 1
  • 8
1
vote
0 answers

how can i use mongo-sync?

i was got the mongo-sync from git,and then take a try with readme. i codeing test.js like that: var Server = require("mongo-sync").Server; var server = new Server('127.0.0.1'); var result =…
Shura
  • 25
  • 1
  • 7
1
vote
1 answer

How can I fix this error: Error: Can't wait without a fiber?

I've tried just about everything that I can think of from using Fiber to Meteor.bindEnvironment. No matter which way I code it, I get some kind of fiber error, or variables are being reset. My First attempt: I tried wrapping the code in a fiber:…
Scott
  • 1,322
  • 4
  • 23
  • 37
1
vote
1 answer

Will node-fibers break node domains?

I'm currently using node-fibers to write synchronous server-side code. I primarily do error handling through try-catch blocks, but there's always a possibility of an error occurring in external libraries or other little bits of asynchronous code. …
josh
  • 9,038
  • 8
  • 31
  • 37
1
vote
2 answers

How to make fibrous wait in Node.js?

I'm new to Node.js, and realized that one of the big differences with it and client side javascript is how asynchronous everything is. To try and address this, I'm attempting to use fibrous to turn my code back into a more functional style of…
Brad Parks
  • 66,836
  • 64
  • 257
  • 336
1
vote
3 answers

Can node-fibers be implemented using ES6 generators?

Wikipedia suggests that coroutines can be implemented with generators. Does this mean node-fibers could be implemented using ES6 generators?
hurrymaplelad
  • 26,645
  • 10
  • 56
  • 76
1
vote
1 answer

Node Fibers Trouble with Meteor

I'm trying to write a simple authentication backend for Meteor that authenticates against an LDAP server. I need the function registered as login handler (the input to Accounts.registerLoginHandler) to return the id the of the user just logged…
mwillsey
  • 41
  • 4
1
vote
4 answers

Meteor (Fibers) loop and callback

Meteor fibers "sync" mode is driving me crazy. Here is a simple code example : var feedsData = feeds.fetch(); // [{_id: "1234"}, {_id: "6789", url: "http://...."}] for(var i = 0, len = feedsData.length; i < len; i++) { var feed = feedsData[i]; …
Olivier
  • 1,270
  • 1
  • 10
  • 24
1
vote
1 answer

Cannot find module build.js while installing fibers with node.js

I am extremely new to Node and my decision to try/start using it is the Meteor Framework. I installed it on OSX first, and it all works fine. But I would like it to work on another machine which is using Windows. I use a MSI package that seems to…
TigrouMeow
  • 1,038
  • 4
  • 19
  • 30
0
votes
1 answer

Node fibers error while running RocketChat self hosted on M1 Mac

Setup Reference https://developer.rocket.chat/open-source-projects/server/server-environment-setup/mac-osx Error screenshot: enter image description here I am trying to setup RocketChat v6 on a local M1 MacBook Air. The yarn dev should ideally start…