Comments (13)
Hi Adirio,
I haven't spent much time looking at this project recently, but I've been looking for a reason to come back to it.
If it's something that you would find useful, I would be happy to implement it for you.
from smudge.
That feature and IPv6 support, as I found while lookig at the code that only IPv4 support is provided, are two things that would be quite nice.
from smudge.
from smudge.
Taking a look at multicast support now.
from smudge.
I'm wondering if multicast discovery should be left up to the application using smudge.
For example you could have 2 applications on a network that both use smudge to broadcast messages but should not connect to each others nodes as they do not share the same message model.
from smudge.
It seems appropriate for Smudge to do as part of the discovery process, but you're right that we need some way to distinguish between multiple collections that happen to share the same network.
Elasticsearch solves this problem by requiring that each cluster have a name/I'd set in each node by configuration, and announcements from nodes with a different name are simply ignored.
Thoughts?
from smudge.
That could work. That name should be replace foobar
in the mdns example in this repo: https://github.com/hashicorp/mdns.
I also think that multicast discovery should be optional.
from smudge.
I agree, discovery options should be configurable: the user has the option to introduce some seeds him/herself or use multicast discovery by providing a namespace.
from smudge.
Absolutely agree on all points.
I've almost got a working prototype together if you're interested (the issue6-multicast branch). Keep in mind that it's a feature-incomplete WIP though.
from smudge.
membership.go lines 211-234:
func getMulticastAddress() string {
if ipLen == net.IPv4len {
if multicastAddress == "" {
if ipLen == net.IPv6len {
multicastAddress = defaultIPv6MulticastAddress
} else if ipLen == net.IPv4len {
multicastAddress = defaultIPv4MulticastAddress
} else {
logFatal("Failed to determine IPv4/IPv6")
}
}
}
return multicastAddress
}
You probably want to remove the outter if ipLen == net.IPv4len
as it will not work properly for IPv6. You have the IP version check inside.
from smudge.
Wait, what's that doing there? 😆
Good catch. I have no idea what I was thinking.
from smudge.
I created PR #13 if you'd like to take a look at what I have.
If anybody wants to be a full-fledged collaborator so you can do proper code reviews, I'm certainly open to that as well. :)
from smudge.
Merged #13.
from smudge.
Related Issues (17)
- Question: Future direction of this project HOT 10
- Pluggable logging HOT 1
- Description for OnBroadcast() not correct HOT 2
- Race condition in Broadcast HOT 1
- Announcing presence on IPv6 results in error HOT 1
- Any configuration to work with Smudge locally ? HOT 12
- Typo or intentionally? HOT 2
- Race condition: data race HOT 4
- Inefficient locking HOT 1
- Provide better documentation about how broadcasts work (and don't work) HOT 3
- Is this project still restricted to LAN? HOT 2
- Smudge vs serf/memberlist HOT 1
- Calling AddBroadcastListener is not thread safe HOT 2
- Usage Query HOT 3
- IPv6 support HOT 1
- Include node status change source in the gossip messages HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from smudge.