fixed debugging

- I was never able to get delve and visual studio code to work properly with this project.
- not sure if it is too complex, however a simple application could be debugged just fine.
- I’ve implemented godebug, and resolved the vendor dependancies
- now able to debug in development, and build self-contained code into QA/STAGING.
- this resolves the issues at this point.
This commit is contained in:
Henry Camacho 2017-02-19 15:51:54 -06:00
parent dbfccc4a0c
commit 43bf242ffd
2 changed files with 4 additions and 1 deletions

2
d Executable file
View File

@ -0,0 +1,2 @@
godebug build -instrument git.daplie.com/Daplie/go-rvpn-server/rvpn/connection -o debug main.go

View File

@ -44,6 +44,7 @@ func (c *Table) ConnByDomain(domain string) (conn *Connection, ok bool) {
//reaper --
func (c *Table) reaper(delay int, idle int) {
_ = "breakpoint"
for {
loginfo.Println("Reaper waiting for ", delay, " seconds")
time.Sleep(time.Duration(delay) * time.Second)
@ -64,7 +65,7 @@ func (c *Table) reaper(delay int, idle int) {
func (c *Table) Run() {
loginfo.Println("ConnectionTable starting")
go c.reaper(10, 20)
go c.reaper(300, 60)
for {
select {