Changed package name to go.neonxp.dev/jsonrpc2
This commit is contained in:
parent
4a8f9ef10e
commit
d4708a3665
9 changed files with 16 additions and 13 deletions
|
@ -13,7 +13,7 @@ Go 1.18+ required
|
||||||
|
|
||||||
1. Create JSON-RPC/HTTP server:
|
1. Create JSON-RPC/HTTP server:
|
||||||
```go
|
```go
|
||||||
import "github.com/neonxp/jsonrpc2/http"
|
import "go.neonxp.dev/jsonrpc2/http"
|
||||||
...
|
...
|
||||||
s := http.New()
|
s := http.New()
|
||||||
```
|
```
|
||||||
|
@ -48,8 +48,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
|
||||||
httpRPC "github.com/neonxp/jsonrpc2/http"
|
httpRPC "go.neonxp.dev/jsonrpc2/http"
|
||||||
"github.com/neonxp/jsonrpc2/rpc"
|
"go.neonxp.dev/jsonrpc2/rpc"
|
||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"errors"
|
"errors"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
|
||||||
httpRPC "github.com/neonxp/jsonrpc2/http"
|
httpRPC "go.neonxp.dev/jsonrpc2/http"
|
||||||
"github.com/neonxp/jsonrpc2/rpc"
|
"go.neonxp.dev/jsonrpc2/rpc"
|
||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
|
2
go.mod
2
go.mod
|
@ -1,3 +1,3 @@
|
||||||
module github.com/neonxp/jsonrpc2
|
module go.neonxp.dev/jsonrpc2
|
||||||
|
|
||||||
go 1.18
|
go 1.18
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
//
|
//
|
||||||
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
||||||
//
|
//
|
||||||
//This file is part of github.com/neonxp/jsonrpc2 project.
|
//This file is part of go.neonxp.dev/jsonrpc2 project.
|
||||||
//
|
//
|
||||||
//This program is free software: you can redistribute it and/or modify
|
//This program is free software: you can redistribute it and/or modify
|
||||||
//it under the terms of the GNU General Public License as published by
|
//it under the terms of the GNU General Public License as published by
|
||||||
|
@ -23,7 +23,7 @@ import (
|
||||||
"bufio"
|
"bufio"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
|
||||||
"github.com/neonxp/jsonrpc2/rpc"
|
"go.neonxp.dev/jsonrpc2/rpc"
|
||||||
)
|
)
|
||||||
|
|
||||||
type Server struct {
|
type Server struct {
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
//
|
//
|
||||||
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
||||||
//
|
//
|
||||||
//This file is part of github.com/neonxp/jsonrpc2 project.
|
//This file is part of go.neonxp.dev/jsonrpc2 project.
|
||||||
//
|
//
|
||||||
//This program is free software: you can redistribute it and/or modify
|
//This program is free software: you can redistribute it and/or modify
|
||||||
//it under the terms of the GNU General Public License as published by
|
//it under the terms of the GNU General Public License as published by
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
//
|
//
|
||||||
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
||||||
//
|
//
|
||||||
//This file is part of github.com/neonxp/jsonrpc2 project.
|
//This file is part of go.neonxp.dev/jsonrpc2 project.
|
||||||
//
|
//
|
||||||
//This program is free software: you can redistribute it and/or modify
|
//This program is free software: you can redistribute it and/or modify
|
||||||
//it under the terms of the GNU General Public License as published by
|
//it under the terms of the GNU General Public License as published by
|
||||||
|
|
3
rpc/meta.go
Normal file
3
rpc/meta.go
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
package rpc
|
||||||
|
|
||||||
|
type Meta map[string]interface{}
|
|
@ -2,7 +2,7 @@
|
||||||
//
|
//
|
||||||
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
||||||
//
|
//
|
||||||
//This file is part of github.com/neonxp/jsonrpc2 project.
|
//This file is part of go.neonxp.dev/jsonrpc2 project.
|
||||||
//
|
//
|
||||||
//This program is free software: you can redistribute it and/or modify
|
//This program is free software: you can redistribute it and/or modify
|
||||||
//it under the terms of the GNU General Public License as published by
|
//it under the terms of the GNU General Public License as published by
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
//
|
//
|
||||||
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
//Copyright (C) 2022 Alexander Kiryukhin <i@neonxp.dev>
|
||||||
//
|
//
|
||||||
//This file is part of github.com/neonxp/jsonrpc2 project.
|
//This file is part of go.neonxp.dev/jsonrpc2 project.
|
||||||
//
|
//
|
||||||
//This program is free software: you can redistribute it and/or modify
|
//This program is free software: you can redistribute it and/or modify
|
||||||
//it under the terms of the GNU General Public License as published by
|
//it under the terms of the GNU General Public License as published by
|
||||||
|
|
Loading…
Reference in a new issue