Skip to content

Instantly share code, notes, and snippets.

View guotie's full-sized avatar

铁哥 guotie

View GitHub Profile
@guotie
guotie / gob_test.go
Last active May 1, 2019 13:13
A test case to compare encode/gob & encoding/json performance
package gobtest
import (
"bytes"
"encoding/gob"
"encoding/json"
"fmt"
"math/rand"
"testing"
)
@guotie
guotie / client.go
Last active September 11, 2016 00:39
oauth2 client
package user
import (
"fmt"
"time"
//"dxmall/utils"
"github.com/jinzhu/gorm"
)
package user
import (
"fmt"
"time"
"dxmall/utils"
"github.com/satori/go.uuid"
"github.com/smtc/glog"
@guotie
guotie / user.go
Created September 11, 2016 00:48
package user
import (
"fmt"
"regexp"
"strconv"
"time"
"dxmall/utils"
@guotie
guotie / oauth.go
Created September 11, 2016 00:52
package main
import (
"dxmall/models/user"
"dxmall/utils"
"fmt"
"net/http"
"strings"