Milos Gajdos
25148af44c
First commit to add etcd registry support
2019-10-02 18:56:53 +01:00
Asim Aslam
5d77ce9e9b
Rename rcache file to cache
2019-10-02 12:35:20 +01:00
b722798caa
some spelling fixes in memory and gossip registry
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2019-10-02 03:54:04 +03:00
Milos Gajdos
4b73ac9dc5
Simplified code. Small bug fix the used to lead to multi-registry loop.
2019-09-30 12:48:59 +01:00
Milos Gajdos
3f3f1272b3
Turn regular logs to Debug logs; annotate with Registry "tag"
2019-09-30 12:48:59 +01:00
Milos Gajdos
859ecb1872
Dont set default TTL. Stop tracking nodes with no TTL
2019-09-30 12:48:59 +01:00
Milos Gajdos
204c7d1fcf
Fixed options bug and proto indenting
2019-09-30 12:48:59 +01:00
Milos Gajdos
8417361bce
Set registry TTL to seconds, not the nanoseconds
2019-09-30 12:48:59 +01:00
Milos Gajdos
d85ca7abd2
Set registry TTL properly via protobuf Options
2019-09-30 12:48:59 +01:00
Milos Gajdos
e973bfaa25
Add TTL options to memory registry.
2019-09-30 12:48:59 +01:00
Milos Gajdos
27bd9581bf
Refresh TTL; prune expired nodes.
2019-09-30 12:48:59 +01:00
Milos Gajdos
16c7b3a390
Added Registry TTL to memory registry. Tracking node lifetimes.
2019-09-30 12:48:59 +01:00
lubaoquan
866631df1d
fixes https://github.com/micro/go-micro/issues/793
2019-09-30 10:36:43 +08:00
Milos Gajdos
87a5e85062
Add 1.13 support. Fix tests to enable 1.13 support
2019-09-27 17:14:24 +01:00
Asim Aslam
ef7bb46884
Don't shutdown old nodes in mdns registry
2019-09-26 16:46:09 +01:00
Asim Aslam
2b8210a106
Preserve cache in the face of failure
2019-09-25 19:44:46 +01:00
Asim Aslam
7fe64192a7
Add flag for registry service client
2019-09-25 11:09:19 +01:00
Milos Gajdos
1f23c8a85a
Emit memory registry event only when it actually happens
2019-09-25 01:58:28 +01:00
Milos Gajdos
39755721d0
Fix proto formatting
2019-09-24 14:39:51 +01:00
Milos Gajdos
ccda1d3559
Remove rpc Sync method from registry handler
2019-09-24 10:41:48 +01:00
Milos Gajdos
61ee436cc4
Added Sync RPC call; it's identical to ListServices for now
2019-09-23 21:08:31 +01:00
Milos Gajdos
04a5d884da
Move global vars to the top of the src file: conventions
2019-09-23 20:48:25 +01:00
Milos Gajdos
0ec1b840fd
Add registry event to registry package
2019-09-23 20:48:25 +01:00
Asim Aslam
04b31d374c
Merge pull request #745 from micro/registry-service
...
Add service registry
2019-09-09 13:05:46 -07:00
Asim Aslam
2c16c7e62f
Fix build breaks
2019-09-09 09:25:47 -07:00
Asim Aslam
1f44d7a4a1
Add registry handler
2019-09-09 09:20:17 -07:00
Asim Aslam
b076ef906a
Add service registry
2019-09-09 08:57:57 -07:00
Asim Aslam
c669a2b155
Use .micro domain for mdns
2019-09-09 05:11:25 -07:00
Shu Xian
bf0e46dc0d
fix registry addr error for mq-rpc
2019-08-14 21:32:28 +08:00
johnson
de34f259ba
update service not found error tooltip
...
fixing test failed issue
change back error type
change registry.ErrNotFound back to selector.ErrNotFound
change back error type
change registry.ErrNotFound back to selector.ErrNotFound
remove the single node tunnel test
Fix read yaml config from memory
package main
import (
"fmt"
"github.com/micro/go-micro/config"
"github.com/micro/go-micro/config/source/memory"
)
var configData = []byte(`
---
a: 1234
`)
func main() {
memorySource := memory.NewSource(
memory.WithYAML(configData),
)
// Create new config
conf := config.NewConfig()
// Load file source
conf.Load(memorySource)
fmt.Println(string(conf.Bytes()))
}
2019-08-11 19:31:22 +08:00
Asim Aslam
edb0fe4b16
fix the consul setup code
2019-08-06 19:43:46 +01:00
Asim Aslam
e16420fdbd
Consul config fix https://github.com/micro/go-micro/pull/641
2019-08-06 09:15:38 +01:00
Asim Aslam
b806e7bdf5
Stop a goroutine leak in registy
2019-08-01 23:03:11 +01:00
Milos Gajdos
c108188d65
Preallocate nodes slice in addNodes before populating it
2019-07-15 14:47:33 +01:00
Milos Gajdos
609934ce99
Preallocate slices; avoide append() reallocations when copying data
2019-07-15 11:13:58 +01:00
Asim Aslam
1f744b31a4
Return the dead node when deleting the service
2019-07-10 21:03:53 +01:00
Asim Aslam
e0bf1c2283
Remove Port from registry
2019-07-08 08:01:42 +01:00
Asim Aslam
a412486c39
Update registry util semantics
2019-07-04 11:36:49 +01:00
0e34c572b4
export registry util function to safe copy registry data
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2019-07-04 11:39:43 +03:00
Milos Gajdos
f6e064cdbd
Fixed router idempotency. Return registry.ErrWatchStopped from mdns reg
2019-07-01 15:46:26 +01:00
Milos Gajdos
c3d2043caf
Reverts c0a628d65b
...
Fixes #540
2019-06-22 19:01:03 +01:00
Milos Gajdos
c0a628d65b
Simplified delService code; properly delete service nodes
2019-06-18 21:39:00 +01:00
Asim Aslam
7266c62d09
remove comment
2019-06-18 15:33:31 +01:00
Asim Aslam
6459cdfc21
propagate updates to local watchers
2019-06-18 14:42:56 +01:00
ab692ff590
remove mock data from memory registry
...
memory registry can be used as fast inprocess registry,
so mock data needs to be in tests only
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2019-06-13 00:51:56 +03:00
Milos Gajdos
73b0a0ed0e
Return registry.ErrWatcherStopped when consul watcher stops.
...
The original code returns "result chan closed" errors.Error which does
not carry higher semantics signal to downstream despite go-micro having
a clearly defined Error for this behaviour. This commit fixes that and
lets the downstream i.e. consumer of this code to act based on different
errors.
2019-06-09 15:51:27 +01:00
Asim Aslam
4035ab5c7b
Change go-log links
2019-05-31 00:38:05 +01:00
Asim Aslam
a353c83f47
Add rcache => cache
2019-05-31 00:22:43 +01:00
Blair McMillan
389d141c5a
Use existing consul client for watcher
2019-05-16 12:37:48 +10:00
58775249c5
fix race with rcache
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2019-05-09 23:02:32 +03:00