Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Job Schedule in Mongodb
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  8 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Tom Vo  
View profile  
 More options Oct 2 2012, 10:43 pm
From: Tom Vo <tom...@nexcel.vn>
Date: Tue, 2 Oct 2012 19:43:52 -0700 (PDT)
Local: Tues, Oct 2 2012 10:43 pm
Subject: Job Schedule in Mongodb

Dear all
Mongodb have support JS function like store procedure, function in SQL
Server. Does Mongodb have to support Job Schedule? How do you do on it?

Thanks and Regards.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
William Zola  
View profile  
 More options Oct 3 2012, 12:58 pm
From: William Zola <william.z...@10gen.com>
Date: Wed, 3 Oct 2012 09:58:56 -0700 (PDT)
Local: Wed, Oct 3 2012 12:58 pm
Subject: Re: Job Schedule in Mongodb

Hi Tom!

1) You should avoid using MongoDB stored JavaScript procedures if you
possibly can.  The JavaScript engine is single-threaded.  If you run
critical processes using the JavaScript stored procedures you are likely to
have performance problems.

2) MongoDB currently does not have any ability to schedule any tasks to
run.  There is an existing SERVER ticket with a request to add this
functionality.  You can follow this ticket and vote it up here:
https://jira.mongodb.org/browse/SERVER-2573

3) If you want to schedule a task to run in MongoDB, the best way to do
this is with the operating system scheduler.  For example, 'cron' on
Unix/Linux.

Have a great day!

 -William


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Tom Vo  
View profile  
 More options Oct 3 2012, 10:46 pm
From: Tom Vo <tom...@nexcel.vn>
Date: Thu, 4 Oct 2012 09:45:55 +0700
Local: Wed, Oct 3 2012 10:45 pm
Subject: Re: [mongodb-user] Re: Job Schedule in Mongodb

Hi William
1) As your guide, I should not use Stored JavaScript Procedures on MongoDB.
I have to execute JavaScript file on Mongo Client.

2) You said that the JavaScript engine is single-threaded. That's
mean MongoDB will be write locked when this script have not been finished.
Could you give me document introduce about them?

http://www.mongodb.org/display/DOCS/Server-side+Code+Execution

Thank you for your reply and kindly supports.

On Wed, Oct 3, 2012 at 11:58 PM, William Zola <william.z...@10gen.com>wrote:

--

Thanks and Best Regards
--------------------------------------------------------------------------- ----------------------------------
*Tom Vo*


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Sam Millman  
View profile  
 More options Oct 4 2012, 4:58 am
From: Sam Millman <sam.mill...@gmail.com>
Date: Thu, 4 Oct 2012 09:58:47 +0100
Local: Thurs, Oct 4 2012 4:58 am
Subject: Re: [mongodb-user] Re: Job Schedule in Mongodb

Server-side execution will lock yes.

I am unsure why you need to run a file in the mongo client application from
your own server side application.

Why can you not run this from your application directly?

On 4 October 2012 03:45, Tom Vo <tom...@nexcel.vn> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Tom Vo  
View profile  
 More options Oct 4 2012, 5:12 am
From: Tom Vo <tom...@nexcel.vn>
Date: Thu, 4 Oct 2012 16:12:13 +0700
Local: Thurs, Oct 4 2012 5:12 am
Subject: Re: [mongodb-user] Re: Job Schedule in Mongodb

Hi Wiliam

I need summary data from some collections and insert to other collection. I
setup Mongodb on Windows Server 2008 and used to Task Schedule to run it.

--

Thanks and Best Regards
--------------------------------------------------------------------------- ----------------------------------
*TOM*


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Sam Millman  
View profile  
 More options Oct 4 2012, 5:15 am
From: Sam Millman <sam.mill...@gmail.com>
Date: Thu, 4 Oct 2012 10:15:39 +0100
Local: Thurs, Oct 4 2012 5:15 am
Subject: Re: [mongodb-user] Re: Job Schedule in Mongodb

If this is a one time event, guessing not from the task Schedule instance,
then it is ok.

Normally you will find it more performant to do multiple runs of this fro
your own server-side coding like C# or C++.

On 4 October 2012 10:12, Tom Vo <tom...@nexcel.vn> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
William Zola  
View profile  
 More options Oct 9 2012, 4:58 pm
From: William Zola <william.z...@10gen.com>
Date: Tue, 9 Oct 2012 13:58:30 -0700 (PDT)
Local: Tues, Oct 9 2012 4:58 pm
Subject: Re: [mongodb-user] Re: Job Schedule in Mongodb

Hi Tom!

To answer your questions:

1) The JavaScript engine does not take a read lock or a write lock.  There
is a separate JavaScript lock.  You can have multiple readers or writers
while a JavaScript thread is executing, but you cannot have two threads
using JavaScript running at the same time.

This is not a limitation of MongoDB.  This is a limitation of the
SpiderMonkey JavaScript engine that MongoDB uses.

Ref:
 -
https://github.com/mongodb/mongo/blob/master/src/mongo/scripting/engi...

If your JavaScript code reads or writes to the database, then -- and only
then -- will it take a read lock or write lock, as necessary.

2) If you need to run regular scheduled jobs, then running them with Task
Scheduler is a good way to do it.

Let me know if you have further questions.  Have a great day!

 -William


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Tom Vo  
View profile  
 More options Oct 9 2012, 9:05 pm
From: Tom Vo <tom...@nexcel.vn>
Date: Wed, 10 Oct 2012 08:05:00 +0700
Subject: Re: [mongodb-user] Re: Job Schedule in Mongodb

Dear William
Thank you again for your kindly support.
Have a great day.

On Wed, Oct 10, 2012 at 3:58 AM, William Zola <william.z...@10gen.com>wrote:

--

Thanks and Best Regards
--------------------------------------------------------------------------- ----------------------------------
*TOM Vo*


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic