Giter VIP home page Giter VIP logo

Comments (8)

tschellenbach avatar tschellenbach commented on May 20, 2024

Hi !

The global name is used for the storing the activity. (mapping the id to the activity)
(For which we should probably really find a way to make it smaller)
(@tbarbugli, ideas on this?)

So its normal for data to end up in global.
From your setup i would expect:
1 in feed:user
1 in global
number of followers in the feed:normal

The feedly setup looks ok. I see two possible reasons why there is nothing in feed:normal

A.) the list of follower ids returned is empty
B.) the celery tasks generated by create fanout tasks don't get processed

(You could try enabling
CELERY_ALWAYS_EAGER = True
CELERY_EAGER_PROPAGATES_EXCEPTIONS = True)
Dont use these settings in production though!

What sort of application are you building?

Best of luck!

from stream-framework.

andrenro avatar andrenro commented on May 20, 2024

Hi!:)

Im building a social gift-planner/wishlist-app! Im trying to integrate feedly so that I can make REST-based feeds on the form "User1 added product1 to wishlist1" :) So what i would need is that other users (User1's friends) can receive this kind of feed.
I would guess possibility B) , but I've tried with those settings, nothing happened..Any other possible solutions?

Current settings.py:
FEEDLY_NYDUS_CONFIG = {
'CONNECTIONS': {
'redis': {
'engine': 'nydus.db.backends.redis.Redis',
'router': 'nydus.db.routers.redis.PrefixPartitionRouter',
'hosts': {
0: {'prefix': 'default', 'db': 0, 'host': '127.0.0.1', 'port': 6379},
}
},
}
}

BROKER_URL = 'redis://127.0.0.1:6379/0'
CELERY_RESULT_BACKEND = 'redis://localhost:6379/0'
CELERY_ALWAYS_EAGER = True
CELERY_EAGER_PROPAGATES_EXCEPTIONS = True

I will check get_user_follower_ids() for emptiness (I am pretty certain that the friend-relationships exists in the database though). I would need something that works in production also :)

from stream-framework.

tschellenbach avatar tschellenbach commented on May 20, 2024

Sounds cool,

Celery is a great for running async tasks, but it can be a bit of a learning curve.
The docs are here:
http://www.celeryproject.org/

Try to verify that the code reaches
UserWishFeedly.fanout
Could you dump the local variables you get when going into UserWishFeedly.fanout?

from stream-framework.

andrenro avatar andrenro commented on May 20, 2024

I think there might be a problem with my redis setup as well, I've
installed rabbitMQ and Redis but it seems that the settings for
redis/celery does nothing . If i stop the rabbitMQ (rabbitmqctl stop) i
will get an "error [111] connection refused" when I try to add something to
the feeds. My impression was that Redis was now my backend, and that I do
not need to have rabbitMQ server running? Im confused.. Celery uses EITHER
rabbitMQ or Redis as its task broker, right?

On Wed, Dec 18, 2013 at 12:33 PM, Thierry Schellenbach <
[email protected]> wrote:

Sounds cool,

Celery is a great for running async tasks, but it can be a bit of a
learning curve.
The docs are here:
http://www.celeryproject.org/

Try to verify that the code reaches
UserWishFeedly.fanout
Could you dump the local variables you get when going into
UserWishFeedly.fanout?


Reply to this email directly or view it on GitHubhttps://github.com//issues/16#issuecomment-30834733
.

Mvh Andreas Røed

from stream-framework.

tbarbugli avatar tbarbugli commented on May 20, 2024

when CELERY_ALWAYS_EAGER is set to True tasks are executed in the same
thread and celery does not connect to the task broker.
I think that your celery settings are ignored / unused; you can find docs
about this here
https://docs.celeryproject.org/en/latest/django/first-steps-with-django.html

2013/12/18 Andreas Røed [email protected]

I think there might be a problem with my redis setup as well, I've
installed rabbitMQ and Redis but it seems that the settings for
redis/celery does nothing . If i stop the rabbitMQ (rabbitmqctl stop) i
will get an "error [111] connection refused" when I try to add something
to
the feeds. My impression was that Redis was now my backend, and that I do
not need to have rabbitMQ server running? Im confused.. Celery uses EITHER
rabbitMQ or Redis as its task broker, right?

On Wed, Dec 18, 2013 at 12:33 PM, Thierry Schellenbach <
[email protected]> wrote:

Sounds cool,

Celery is a great for running async tasks, but it can be a bit of a
learning curve.
The docs are here:
http://www.celeryproject.org/

Try to verify that the code reaches
UserWishFeedly.fanout
Could you dump the local variables you get when going into
UserWishFeedly.fanout?


Reply to this email directly or view it on GitHub<
https://github.com/tschellenbach/Feedly/issues/16#issuecomment-30834733>
.

Mvh Andreas Røed


Reply to this email directly or view it on GitHubhttps://github.com//issues/16#issuecomment-30837484
.

from stream-framework.

andrenro avatar andrenro commented on May 20, 2024

So I got it working correctly when using CELERY_ALWAYS_EAGER = True ! :)
Only thing left is to make the broker settings work correctly! I don't get
any errors when CELERY_ALWAYS_EAGER = False, it just doesn't fetch the
newest feeds properly..

On Wed, Dec 18, 2013 at 1:49 PM, Tommaso Barbugli
[email protected]:

when CELERY_ALWAYS_EAGER is set to True tasks are executed in the same
thread and celery does not connect to the task broker.
I think that your celery settings are ignored / unused; you can find docs
about this here

https://docs.celeryproject.org/en/latest/django/first-steps-with-django.html

2013/12/18 Andreas Røed [email protected]

I think there might be a problem with my redis setup as well, I've
installed rabbitMQ and Redis but it seems that the settings for
redis/celery does nothing . If i stop the rabbitMQ (rabbitmqctl stop) i
will get an "error [111] connection refused" when I try to add something
to
the feeds. My impression was that Redis was now my backend, and that I
do
not need to have rabbitMQ server running? Im confused.. Celery uses
EITHER
rabbitMQ or Redis as its task broker, right?

On Wed, Dec 18, 2013 at 12:33 PM, Thierry Schellenbach <
[email protected]> wrote:

Sounds cool,

Celery is a great for running async tasks, but it can be a bit of a
learning curve.
The docs are here:
http://www.celeryproject.org/

Try to verify that the code reaches
UserWishFeedly.fanout
Could you dump the local variables you get when going into
UserWishFeedly.fanout?


Reply to this email directly or view it on GitHub<
https://github.com/tschellenbach/Feedly/issues/16#issuecomment-30834733>

.

Mvh Andreas Røed


Reply to this email directly or view it on GitHub<
https://github.com/tschellenbach/Feedly/issues/16#issuecomment-30837484>
.


Reply to this email directly or view it on GitHubhttps://github.com//issues/16#issuecomment-30838903
.

Mvh Andreas Røed

from stream-framework.

tbarbugli avatar tbarbugli commented on May 20, 2024

Thats because tasks are waiting in the broker to be consumed by a celery
worker.
You need to start a celery worker for that ;)
On 18 Dec 2013 14:24, "Andreas Røed" [email protected] wrote:

So I got it working correctly when using CELERY_ALWAYS_EAGER = True ! :)
Only thing left is to make the broker settings work correctly! I don't get
any errors when CELERY_ALWAYS_EAGER = False, it just doesn't fetch the
newest feeds properly..

On Wed, Dec 18, 2013 at 1:49 PM, Tommaso Barbugli
[email protected]:

when CELERY_ALWAYS_EAGER is set to True tasks are executed in the same
thread and celery does not connect to the task broker.
I think that your celery settings are ignored / unused; you can find
docs
about this here

https://docs.celeryproject.org/en/latest/django/first-steps-with-django.html

2013/12/18 Andreas Røed [email protected]

I think there might be a problem with my redis setup as well, I've
installed rabbitMQ and Redis but it seems that the settings for
redis/celery does nothing . If i stop the rabbitMQ (rabbitmqctl stop)
i
will get an "error [111] connection refused" when I try to add
something
to
the feeds. My impression was that Redis was now my backend, and that I
do
not need to have rabbitMQ server running? Im confused.. Celery uses
EITHER
rabbitMQ or Redis as its task broker, right?

On Wed, Dec 18, 2013 at 12:33 PM, Thierry Schellenbach <
[email protected]> wrote:

Sounds cool,

Celery is a great for running async tasks, but it can be a bit of a
learning curve.
The docs are here:
http://www.celeryproject.org/

Try to verify that the code reaches
UserWishFeedly.fanout
Could you dump the local variables you get when going into
UserWishFeedly.fanout?


Reply to this email directly or view it on GitHub<

https://github.com/tschellenbach/Feedly/issues/16#issuecomment-30834733>

.

Mvh Andreas Røed


Reply to this email directly or view it on GitHub<
https://github.com/tschellenbach/Feedly/issues/16#issuecomment-30837484>

.


Reply to this email directly or view it on GitHub<
https://github.com/tschellenbach/Feedly/issues/16#issuecomment-30838903>
.

Mvh Andreas Røed


Reply to this email directly or view it on GitHubhttps://github.com//issues/16#issuecomment-30840972
.

from stream-framework.

thedrow avatar thedrow commented on May 20, 2024

So this should be closed?

from stream-framework.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.