Created
July 30, 2014 15:48
-
-
Save akfish/c3adba681865376f7cc3 to your computer and use it in GitHub Desktop.
seajs-worker map-reduce concept
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
# Implement worker class | |
class FooWorker extends SeaWorker | |
@worker_service 'fac', (n) -> do_stuff_with n | |
# Simple Array, maxiumn 10 workers | |
FooWorker.map [0, 1, 2, n], 'fac', 10 | |
# Reduce |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment