-
-
Notifications
You must be signed in to change notification settings - Fork 518
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Callback queue #29
Callback queue #29
Conversation
examples/callbacks/callbacks.go
Outdated
@@ -4,7 +4,7 @@ import ( | |||
"fmt" | |||
"time" | |||
|
|||
"github.com/muesli/cache2go" | |||
"github.com/trapajim/cache2go" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Careful, I assume you accidentally committed that change. Please revert it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry for that. I've changed it.
Nice contribution, thank you! |
examples/callbacks/callbacks.go
Outdated
@@ -35,6 +38,8 @@ func main() { | |||
// Deleting the item will execute the AboutToDeleteItem callback. | |||
cache.Delete("someKey") | |||
|
|||
//remove AddedItemCallbacks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That comment feels a bit redundant 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure what i've thought there, I removed the comment.
Awesome, thanks for updating. One more thing occurred to me in the meantime though: this could lead to breaking existing clients, if they relied on the behavior of the old callbacks being overwritten. Here's an idea: how about we keep the |
That makes sense, I didn't think about that. I'll implement that soon. |
@muesli just checking in if you saw the changes |
@trapajim I'm terribly sorry, it seems I have indeed missed that notification! Thanks for your contributions, really appreciated! |
i've added a simple fifo queue for the callbacks.
requested in #19