Displaying 20 results from an estimated 10000 matches similar to: "Send email with delayed job"
2011 Dec 02
2
problem setting expectation for test with delayed::job
I''ve got something like this:
# post_observer.rb
after_create
# ...stuff
Delayed::Job.enqueue(PostSharer.new(post, post.user))
end
...
# post_sharer.rb
class PostSharer < Struct.new(:post, user)
def perform
# Delayed::Job calls .perform on the object passed into enqueue
end
end
# post_controller_spec.rb
it "shares the post" do
2011 May 17
1
uninitialized constant Delayed::Job (NameError)
hi I am implementing delayed_job in my rails app.
*my code is:*
file name is: my_worker.rb
require "delayed_job"
require "rubygems"
class MyClass
def perform
while true do
puts "I am in My class!!!"
sleep 2
end
end
end
Delayed::Job.enqueue( MyClass.new )
#m.perform
when i am executing this(ruby my_worker.rb ) file it gives me error
2008 Oct 22
1
Sending thousands of email with ar_mailer
Hi,
to send an email with ar_mailer I need to generate it and save it to
the db, right?
Currently the code looks very simple:
Newsletter.recepients.each do |recepient|
NewsletterMailer.deliver_dedicated(request, recepient, newsletter)
end
But for i.e. 30000 receivers it''s going to take a long while anyway.
Should I create them somehow in the background using BackgrounDRb or
something
2011 Aug 05
1
jagged array (matrices of different dimensions)
Dear all,
I am having trouble creating a "jagged array" in R. I have found no commentary on how to do it in the help files, but maybe I am misunderstanding the purpose of some of the array functions (e.g. tapply).
I am using a longitudinal dataset where each individual has a different number of time points (observations). I need to create correlation structures for each
2010 Aug 09
0
Logging form delayed job class
I have asked this before without any luck, trying again.
this is what I have in my dj.rb initializer
Delayed::Worker.backend = :active_record
Delayed::Worker.logger = Rails.logger
#Delayed::Worker.logger = ActiveSupport::BufferedLogger.new("log/
##{Rails.env}_delayed_jobs.log", Rails.logger.level)
class Delayed::Job
def logger
Delayed::Worker.logger
end
end
if
2012 Aug 16
5
[PATCH] AMD, powernow: Update P-state directly when _PSD's CoordType is DOMAIN_COORD_TYPE_HW_ALL
# HG changeset patch
# User Boris Ostrovsky <boris.ostrovsky@amd.com>
# Date 1345135101 -7200
# Node ID 85190245a94d9945b7656c971ba36f7d1eff5c19
# Parent 6d56e31fe1e1dc793379d662a36ff1731760eb0c
AMD, powernow: Update P-state directly when _PSD''s CoordType is DOMAIN_COORD_TYPE_HW_ALL
When _PSD''s CoordType is DOMAIN_COORD_TYPE_HW_ALL (i.e. shared_type is
2011 Jul 29
2
'breackpoints' (package 'strucchange'): 2 blocking error messages when using for multiple regression model testing
Good morning to all,
I am encountering a blocking issue when using the function 'breackpoints'
from package 'strucchange'.
*Context:*
I use a data frame, 248 observations of 5 variables, no NA.
I compute a linear model, as y~x1+...+x4
x4 is a dummy variable (0 or 1).
I want to check this model for structural changes.
*Process & issues:*
*First, I used function Fstats.* It
2009 Feb 10
3
[PATCH 2/2] Use correct config option for ixgbe VMDq
The correct kernel configuration for VMDq support is
CONFIG_XEN_NETDEV2_VMQ, not CONFIG_XEN_NETDEV2_BACKEND.
Signed-off-by: Mitch Williams <mitch.a.williams@intel.com>
diff -urpN a/drivers/net/ixgbe/ixgbe.h b/drivers/net/ixgbe/ixgbe.h
--- a/drivers/net/ixgbe/ixgbe.h 2009-02-06 09:03:44.000000000 -0800
+++ b/drivers/net/ixgbe/ixgbe.h 2009-02-10 14:32:57.000000000 -0800
@@ -35,7 +35,7 @@
2011 Jan 31
2
[LLVMdev] llvm::Pass::Pass(llvm::PassKind, intptr_t): Assertion `pid && "pid cannot be 0"' failed.
I have written a new pass, it compiles ok but crashes when i run it
with error (llvm::Pass::Pass(llvm::PassKind, intptr_t): Assertion `pid
&& "pid cannot be 0"' failed.).
The pass is :
using namespace llvm;
namespace
{
struct Dfl : public FunctionPass {
static char ID;
Dfl() : FunctionPass(ID) { }
virtual bool runOnFunction(Function &F) {
bool
2013 Aug 27
2
[PATCH] AMD IOMMU: add missing checks
For one we shouldn''t accept IVHD tables specifying IO-APIC IDs beyond
the limit we support (MAX_IO_APICS, currently 128).
And then we shouldn''t memset() a pointer allocation of which failed.
Signed-off-by: Jan Beulich <jbeulich@suse.com>
--- a/xen/drivers/passthrough/amd/iommu_acpi.c
+++ b/xen/drivers/passthrough/amd/iommu_acpi.c
@@ -674,6 +674,13 @@ static u16 __init
2011 Jan 31
2
[LLVMdev] Error : llvm/include/llvm/Pass.h:188: error: incomplete type 'llvm::DominatorTree' used in nested name specifier
I am creating a new pass (function pass) called Dfl from the Hello
example and notes on "Writing an LLVM Pass". When I compile the
program I get inncomplete type error (llvm/include/llvm/Pass.h:188:
error: incomplete type 'llvm::DominatorTree' used in nested name
specifier). The code is given below.
Surinder
struct Dfl : public FunctionPass {
raw_ostream *Out;
static
2018 May 03
1
[PATCH] daemon: fix memory allocation and leaks in OCaml stubs
Use the cleanup handlers to free the structs (and list of structs) in
case their OCaml->C transformation fails for any reason; use calloc()
to not try to use uninitialized memory.
In case of lists, avoid allocating the memory for the array if there
are no elements, since the returned pointer in that case is either NULL,
or a free()-only pointer; also, set the list size only after the array
is
2002 May 05
16
More on qdiscs
I notice one other small problem with my modified version of SFQ.
The fact that packets can be dropped at dequeue time is incompatible
with the way HTB (and probably CBQ and others modeled on it) keep
statistics. When I fill a low rate queue causing packets to expire
and be dropped at dequeue I get interesting statistics like this:
This is my variant of SFQ
qdisc plfq 8016: dev eth1
...
Sent
2011 Jan 31
0
[LLVMdev] llvm::Pass::Pass(llvm::PassKind, intptr_t): Assertion `pid && "pid cannot be 0"' failed.
llvm/include/llvm/Pass.h:93: llvm::Pass::Pass(llvm::PassKind,
intptr_t): Assertion `pid && "pid cannot be 0"' failed.
On Mon, Jan 31, 2011 at 3:55 PM, Surinder <surifilms at gmail.com> wrote:
> I have written a new pass, it compiles ok but crashes when i run it
> with error (llvm::Pass::Pass(llvm::PassKind, intptr_t): Assertion `pid
> && "pid
2019 Apr 26
1
Fix: menu indent for menu entry
Hello,
While experimenting with possible menu layout found this issue; the entry for MENU BEGIN doesn't follow MENU INDENT.
*Sample config*
label -
menu disable
menu label Distro
label rhel
menu indent 2
menu label RHEL
label cent
menu indent 2
menu label Centos
label fed
menu indent 2
menu label Fedora
menu begin
menu indent 2
menu label Others
menu end
# 'Others'
2019 Jul 18
2
[PATCH v4 4/5] vhost/vsock: split packets to send using multiple buffers
On Thu, Jul 18, 2019 at 09:50:14AM +0200, Stefano Garzarella wrote:
> On Wed, Jul 17, 2019 at 4:55 PM Michael S. Tsirkin <mst at redhat.com> wrote:
> >
> > On Wed, Jul 17, 2019 at 01:30:29PM +0200, Stefano Garzarella wrote:
> > > If the packets to sent to the guest are bigger than the buffer
> > > available, we can split them, using multiple buffers and
2019 Jul 18
2
[PATCH v4 4/5] vhost/vsock: split packets to send using multiple buffers
On Thu, Jul 18, 2019 at 09:50:14AM +0200, Stefano Garzarella wrote:
> On Wed, Jul 17, 2019 at 4:55 PM Michael S. Tsirkin <mst at redhat.com> wrote:
> >
> > On Wed, Jul 17, 2019 at 01:30:29PM +0200, Stefano Garzarella wrote:
> > > If the packets to sent to the guest are bigger than the buffer
> > > available, we can split them, using multiple buffers and
2007 Apr 18
1
[PATCH 2/9] 00mm2 pte clear not present.patch
Change pte_clear_full to a more appropriately named pte_clear_not_present,
allowing optimizations when not-present mapping changes need not be
reflected in the hardware TLB for protected page table modes. There is
also another case that can use it in the fremap code.
Signed-off-by: Zachary Amsden <zach@vmware.com>
Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com>
---
2004 Jun 17
2
[PATCH] (1/4) delay scheduler enqueue always succeeds.
If underlying fifo enqueue fails, return the status not 0.
Same patch should apply to both 2.6 and 2.4
Signed-off-by: Stephen Hemminger <shemminger@osdl.org>
diff -Nru a/net/sched/sch_delay.c b/net/sched/sch_delay.c
--- a/net/sched/sch_delay.c 2004-06-17 15:13:15 -07:00
+++ b/net/sched/sch_delay.c 2004-06-17 15:13:15 -07:00
@@ -69,7 +69,7 @@
sch->stats.bytes += skb->len;
2011 Jan 31
0
[LLVMdev] Error : llvm/include/llvm/Pass.h:188: error: incomplete type 'llvm::DominatorTree' used in nested name specifier
Hi Surinder,
Did you remember to #include "llvm/Analysis/Dominators.h"?
Best,
Douglas
On Sun, Jan 30, 2011 at 11:24 PM, Surinder <surifilms at gmail.com> wrote:
> I am creating a new pass (function pass) called Dfl from the Hello
> example and notes on "Writing an LLVM Pass". When I compile the
> program I get inncomplete type error