Skip to content

Commit

Permalink
Reorder imports.
Browse files Browse the repository at this point in the history
  • Loading branch information
mofirouz committed Aug 20, 2019
1 parent e222a57 commit 4418a9a
Show file tree
Hide file tree
Showing 18 changed files with 39 additions and 21 deletions.
3 changes: 2 additions & 1 deletion api/api.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion rtapi/realtime.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions runtime/runtime.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ package runtime
import (
"context"
"database/sql"

"github.com/heroiclabs/nakama/api"
"github.com/heroiclabs/nakama/rtapi"
)
Expand Down
7 changes: 4 additions & 3 deletions server/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,15 @@ import (
"database/sql"
"encoding/base64"
"fmt"
"go.opencensus.io/stats"
"go.opencensus.io/tag"
"go.opencensus.io/trace"
"net"
"net/http"
"strings"
"time"

"go.opencensus.io/stats"
"go.opencensus.io/tag"
"go.opencensus.io/trace"

"github.com/heroiclabs/nakama/api"

"google.golang.org/grpc/peer"
Expand Down
3 changes: 2 additions & 1 deletion server/api_authenticate.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,13 @@ package server

import (
"errors"
"go.uber.org/zap"
"math/rand"
"regexp"
"strings"
"time"

"go.uber.org/zap"

"github.com/dgrijalva/jwt-go"
"github.com/gofrs/uuid"
"github.com/heroiclabs/nakama/api"
Expand Down
1 change: 1 addition & 0 deletions server/api_notification.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import (
"context"
"encoding/base64"
"encoding/gob"

"github.com/gofrs/uuid"
"github.com/golang/protobuf/ptypes/empty"
"github.com/heroiclabs/nakama/api"
Expand Down
1 change: 1 addition & 0 deletions server/api_storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ package server

import (
"encoding/json"

"go.uber.org/zap"

"github.com/gofrs/uuid"
Expand Down
5 changes: 3 additions & 2 deletions server/api_unlink.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,16 @@
package server

import (
"strconv"
"strings"

"github.com/gofrs/uuid"
"github.com/golang/protobuf/ptypes/empty"
"github.com/heroiclabs/nakama/api"
"go.uber.org/zap"
"golang.org/x/net/context"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
"strconv"
"strings"
)

func (s *ApiServer) UnlinkCustom(ctx context.Context, in *api.AccountCustom) (*empty.Empty, error) {
Expand Down
3 changes: 2 additions & 1 deletion server/core_group.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,12 @@ import (
"encoding/gob"
"encoding/json"
"fmt"
"github.com/heroiclabs/nakama/rtapi"
"strconv"
"strings"
"time"

"github.com/heroiclabs/nakama/rtapi"

"github.com/gofrs/uuid"
"github.com/golang/protobuf/ptypes/timestamp"
"github.com/golang/protobuf/ptypes/wrappers"
Expand Down
3 changes: 2 additions & 1 deletion server/pipeline.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,11 @@ import (
"database/sql"
"fmt"

"strings"

"github.com/golang/protobuf/jsonpb"
"github.com/heroiclabs/nakama/rtapi"
"go.uber.org/zap"
"strings"
)

type Pipeline struct {
Expand Down
3 changes: 2 additions & 1 deletion server/runtime.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,12 @@ package server
import (
"context"
"database/sql"
"github.com/heroiclabs/nakama/runtime"
"os"
"path/filepath"
"strings"

"github.com/heroiclabs/nakama/runtime"

"github.com/gofrs/uuid"
"github.com/golang/protobuf/jsonpb"
"github.com/heroiclabs/nakama/api"
Expand Down
9 changes: 5 additions & 4 deletions server/runtime_go.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@ import (
"context"
"database/sql"
"errors"
"path/filepath"
"plugin"
"strings"
"sync"

"github.com/gofrs/uuid"
"github.com/golang/protobuf/ptypes/timestamp"
"github.com/heroiclabs/nakama/api"
Expand All @@ -26,10 +31,6 @@ import (
"github.com/heroiclabs/nakama/social"
"go.uber.org/zap"
"google.golang.org/grpc/codes"
"path/filepath"
"plugin"
"strings"
"sync"
)

// No need for a stateful RuntimeProviderGo here.
Expand Down
1 change: 1 addition & 0 deletions server/runtime_go_context.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ package server

import (
"context"

"github.com/heroiclabs/nakama/runtime"
)

Expand Down
1 change: 1 addition & 0 deletions server/runtime_go_match_core.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import (
"database/sql"
"errors"
"fmt"

"github.com/gofrs/uuid"
"github.com/heroiclabs/nakama/rtapi"
"github.com/heroiclabs/nakama/runtime"
Expand Down
3 changes: 2 additions & 1 deletion server/runtime_lua.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,15 @@ import (
"encoding/json"
"errors"
"fmt"
"go.uber.org/atomic"
"io/ioutil"
"os"
"path/filepath"
"sort"
"strings"
"sync"

"go.uber.org/atomic"

"github.com/gofrs/uuid"
"github.com/golang/protobuf/jsonpb"
"github.com/golang/protobuf/proto"
Expand Down
3 changes: 2 additions & 1 deletion server/runtime_lua_context.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@ package server

import (
"fmt"
"github.com/yuin/gopher-lua"
"time"

"github.com/yuin/gopher-lua"
)

const (
Expand Down
3 changes: 2 additions & 1 deletion server/session_registry.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,10 @@ package server

import (
"context"
"go.uber.org/atomic"
"sync"

"go.uber.org/atomic"

"github.com/gofrs/uuid"
"github.com/heroiclabs/nakama/rtapi"
"go.uber.org/zap"
Expand Down
7 changes: 4 additions & 3 deletions server/session_ws.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,11 @@ import (
"context"
"errors"
"fmt"
"github.com/golang/protobuf/proto"
"sync"
"time"

"github.com/golang/protobuf/proto"

"net"

"github.com/gofrs/uuid"
Expand Down Expand Up @@ -113,8 +114,8 @@ func NewSessionWS(logger *zap.Logger, config Config, format SessionFormat, userI
pipeline: pipeline,
runtime: runtime,

stopped: false,
conn: conn,
stopped: false,
conn: conn,
receivedMessageCounter: config.GetSocket().PingBackoffThreshold,
pingTimer: time.NewTimer(time.Duration(config.GetSocket().PingPeriodMs) * time.Millisecond),
pingTimerCAS: atomic.NewUint32(1),
Expand Down

0 comments on commit 4418a9a

Please sign in to comment.