Commit d541828f authored by hezhengjun's avatar hezhengjun

rename x2Ethereum to x2ethereum

parent 5d7a4b17
...@@ -30,5 +30,5 @@ import ( ...@@ -30,5 +30,5 @@ import (
_ "github.com/33cn/plugin/plugin/dapp/trade" //auto gen _ "github.com/33cn/plugin/plugin/dapp/trade" //auto gen
_ "github.com/33cn/plugin/plugin/dapp/unfreeze" //auto gen _ "github.com/33cn/plugin/plugin/dapp/unfreeze" //auto gen
_ "github.com/33cn/plugin/plugin/dapp/valnode" //auto gen _ "github.com/33cn/plugin/plugin/dapp/valnode" //auto gen
_ "github.com/33cn/plugin/plugin/dapp/x2Ethereum" //auto gen _ "github.com/33cn/plugin/plugin/dapp/x2ethereum" //auto gen
) )
...@@ -5,8 +5,8 @@ ...@@ -5,8 +5,8 @@
# 3. make build # 3. make build
# ... # ...
SRC_EBCLI := github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebcli SRC_EBCLI := github.com/33cn/plugin/plugin/dapp/x2ethereum/ebcli
SRC_EBRELAYER := github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer SRC_EBRELAYER := github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer
CLI_A := build/ebcli_A CLI_A := build/ebcli_A
CLI_B := build/ebcli_B CLI_B := build/ebcli_B
CLI_C := build/ebcli_C CLI_C := build/ebcli_C
......
...@@ -4,8 +4,8 @@ strpwd=$(pwd) ...@@ -4,8 +4,8 @@ strpwd=$(pwd)
strcmd=${strpwd##*dapp/} strcmd=${strpwd##*dapp/}
strapp=${strcmd%/cmd*} strapp=${strcmd%/cmd*}
SRC_EBCLI=github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebcli SRC_EBCLI=github.com/33cn/plugin/plugin/dapp/x2ethereum/ebcli
SRC_EBRELAYER=github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer SRC_EBRELAYER=github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer
OUT_DIR="${1}/$strapp" OUT_DIR="${1}/$strapp"
FLAG=$2 FLAG=$2
......
...@@ -10,9 +10,9 @@ import ( ...@@ -10,9 +10,9 @@ import (
types2 "github.com/33cn/chain33/rpc/types" types2 "github.com/33cn/chain33/rpc/types"
"github.com/33cn/chain33/system/dapp/commands" "github.com/33cn/chain33/system/dapp/commands"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebcli/buildflags" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebcli/buildflags"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/utils" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/utils"
types3 "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" types3 "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )
......
...@@ -8,8 +8,8 @@ import ( ...@@ -8,8 +8,8 @@ import (
"github.com/33cn/chain33/rpc/jsonclient" "github.com/33cn/chain33/rpc/jsonclient"
rpctypes "github.com/33cn/chain33/rpc/types" rpctypes "github.com/33cn/chain33/rpc/types"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/utils" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/utils"
types2 "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" types2 "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )
......
...@@ -5,7 +5,7 @@ import ( ...@@ -5,7 +5,7 @@ import (
"github.com/33cn/chain33/rpc/jsonclient" "github.com/33cn/chain33/rpc/jsonclient"
rpctypes "github.com/33cn/chain33/rpc/types" rpctypes "github.com/33cn/chain33/rpc/types"
ebTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )
......
...@@ -6,7 +6,7 @@ package main ...@@ -6,7 +6,7 @@ package main
import ( import (
"github.com/33cn/chain33/rpc/jsonclient" "github.com/33cn/chain33/rpc/jsonclient"
rpctypes "github.com/33cn/chain33/rpc/types" rpctypes "github.com/33cn/chain33/rpc/types"
relayerTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" relayerTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )
......
...@@ -6,9 +6,9 @@ import ( ...@@ -6,9 +6,9 @@ import (
"github.com/33cn/chain33/common" "github.com/33cn/chain33/common"
"github.com/33cn/chain33/rpc/jsonclient" "github.com/33cn/chain33/rpc/jsonclient"
rpctypes "github.com/33cn/chain33/rpc/types" rpctypes "github.com/33cn/chain33/rpc/types"
ebTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/utils" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/utils"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
ethTypes "github.com/ethereum/go-ethereum/core/types" ethTypes "github.com/ethereum/go-ethereum/core/types"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )
......
...@@ -12,7 +12,7 @@ import ( ...@@ -12,7 +12,7 @@ import (
"github.com/33cn/chain33/common/log" "github.com/33cn/chain33/common/log"
"github.com/33cn/chain33/pluginmgr" "github.com/33cn/chain33/pluginmgr"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebcli/buildflags" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebcli/buildflags"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )
......
...@@ -2,7 +2,7 @@ package main ...@@ -2,7 +2,7 @@ package main
import ( import (
"github.com/33cn/chain33/rpc/jsonclient" "github.com/33cn/chain33/rpc/jsonclient"
ebTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )
......
...@@ -7,10 +7,10 @@ import ( ...@@ -7,10 +7,10 @@ import (
"testing" "testing"
"time" "time"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/test/setup" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/test/setup"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethtxs" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethtxs"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/events" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/events"
"github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum"
"github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/accounts/abi/bind/backends" "github.com/ethereum/go-ethereum/accounts/abi/bind/backends"
......
...@@ -4,7 +4,7 @@ import ( ...@@ -4,7 +4,7 @@ import (
"crypto/ecdsa" "crypto/ecdsa"
"math/big" "math/big"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethtxs" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethtxs"
"github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/accounts/abi/bind/backends" "github.com/ethereum/go-ethereum/accounts/abi/bind/backends"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
......
...@@ -3,7 +3,7 @@ package ethtxs ...@@ -3,7 +3,7 @@ package ethtxs
import ( import (
"strings" "strings"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
"github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/accounts/abi"
) )
......
...@@ -8,8 +8,8 @@ import ( ...@@ -8,8 +8,8 @@ import (
"github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/events" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/events"
"github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/core/types"
......
...@@ -12,7 +12,7 @@ import ( ...@@ -12,7 +12,7 @@ import (
"github.com/ethereum/go-ethereum/ethclient" "github.com/ethereum/go-ethereum/ethclient"
"github.com/33cn/chain33/common/log/log15" "github.com/33cn/chain33/common/log/log15"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
"github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
) )
......
...@@ -15,9 +15,9 @@ import ( ...@@ -15,9 +15,9 @@ import (
"strings" "strings"
chain33Types "github.com/33cn/chain33/types" chain33Types "github.com/33cn/chain33/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/events" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/events"
ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
) )
......
...@@ -4,7 +4,7 @@ import ( ...@@ -4,7 +4,7 @@ import (
"context" "context"
"errors" "errors"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
"github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/ethclient" "github.com/ethereum/go-ethereum/ethclient"
......
...@@ -3,7 +3,7 @@ package ethtxs ...@@ -3,7 +3,7 @@ package ethtxs
import ( import (
"errors" "errors"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
"github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
) )
......
...@@ -8,8 +8,8 @@ import ( ...@@ -8,8 +8,8 @@ import (
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/ethclient" "github.com/ethereum/go-ethereum/ethclient"
bridgeRegistry "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" bridgeRegistry "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
) )
// ContractRegistry : // ContractRegistry :
......
...@@ -14,8 +14,8 @@ import ( ...@@ -14,8 +14,8 @@ import (
"github.com/33cn/chain33/rpc/jsonclient" "github.com/33cn/chain33/rpc/jsonclient"
rpctypes "github.com/33cn/chain33/rpc/types" rpctypes "github.com/33cn/chain33/rpc/types"
chain33Types "github.com/33cn/chain33/types" chain33Types "github.com/33cn/chain33/types"
ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
) )
// RelayLockToChain33 : RelayLockToChain33 applies validator's signature to an EthBridgeClaim message // RelayLockToChain33 : RelayLockToChain33 applies validator's signature to an EthBridgeClaim message
......
...@@ -6,8 +6,8 @@ import ( ...@@ -6,8 +6,8 @@ import (
"github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/33cn/chain33/common/log/log15" "github.com/33cn/chain33/common/log/log15"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/events" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/events"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/crypto"
) )
......
...@@ -3,7 +3,7 @@ package ethtxs ...@@ -3,7 +3,7 @@ package ethtxs
import ( import (
"math/big" "math/big"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/events" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/events"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
) )
......
...@@ -8,7 +8,7 @@ import ( ...@@ -8,7 +8,7 @@ import (
"sync" "sync"
"time" "time"
ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum"
"github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
......
...@@ -8,7 +8,7 @@ package events ...@@ -8,7 +8,7 @@ package events
import ( import (
"math/big" "math/big"
ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebrelayerTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/accounts/abi"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
) )
......
...@@ -19,10 +19,10 @@ import ( ...@@ -19,10 +19,10 @@ import (
logf "github.com/33cn/chain33/common/log" logf "github.com/33cn/chain33/common/log"
"github.com/33cn/chain33/common/log/log15" "github.com/33cn/chain33/common/log/log15"
chain33Types "github.com/33cn/chain33/types" chain33Types "github.com/33cn/chain33/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/relayer" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/relayer"
chain33Relayer "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/relayer/chain33" chain33Relayer "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/relayer/chain33"
ethRelayer "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/relayer/ethereum" ethRelayer "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/relayer/ethereum"
relayerTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" relayerTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
tml "github.com/BurntSushi/toml" tml "github.com/BurntSushi/toml"
"github.com/btcsuite/btcd/limits" "github.com/btcsuite/btcd/limits"
"github.com/prometheus/common/log" "github.com/prometheus/common/log"
......
...@@ -7,7 +7,7 @@ import ( ...@@ -7,7 +7,7 @@ import (
//dbm "github.com/33cn/chain33/common/db" //dbm "github.com/33cn/chain33/common/db"
chain33Types "github.com/33cn/chain33/types" chain33Types "github.com/33cn/chain33/types"
wcom "github.com/33cn/chain33/wallet/common" wcom "github.com/33cn/chain33/wallet/common"
x2ethTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" x2ethTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
) )
var ( var (
......
...@@ -19,13 +19,13 @@ import ( ...@@ -19,13 +19,13 @@ import (
"github.com/33cn/chain33/rpc/jsonclient" "github.com/33cn/chain33/rpc/jsonclient"
rpctypes "github.com/33cn/chain33/rpc/types" rpctypes "github.com/33cn/chain33/rpc/types"
chain33Types "github.com/33cn/chain33/types" chain33Types "github.com/33cn/chain33/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
relayerTx "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethtxs" relayerTx "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethtxs"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/events" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/events"
syncTx "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/relayer/chain33/transceiver/sync" syncTx "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/relayer/chain33/transceiver/sync"
ebTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/utils" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/utils"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
ethCommon "github.com/ethereum/go-ethereum/common" ethCommon "github.com/ethereum/go-ethereum/common"
) )
......
...@@ -5,8 +5,8 @@ import ( ...@@ -5,8 +5,8 @@ import (
"sync/atomic" "sync/atomic"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
ebTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/utils" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/utils"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
) )
......
...@@ -7,7 +7,7 @@ import ( ...@@ -7,7 +7,7 @@ import (
dbm "github.com/33cn/chain33/common/db" dbm "github.com/33cn/chain33/common/db"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/utils" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/utils"
"github.com/pkg/errors" "github.com/pkg/errors"
) )
......
...@@ -14,9 +14,9 @@ import ( ...@@ -14,9 +14,9 @@ import (
dbm "github.com/33cn/chain33/common/db" dbm "github.com/33cn/chain33/common/db"
l "github.com/33cn/chain33/common/log/log15" l "github.com/33cn/chain33/common/log/log15"
"github.com/33cn/chain33/rpc/jsonclient" "github.com/33cn/chain33/rpc/jsonclient"
rpctypes "github.com/33cn/chain33/rpc/types"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
relayerTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" "github.com/33cn/chain33/blockchain"
relayerTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/rs/cors" "github.com/rs/cors"
) )
...@@ -120,17 +120,20 @@ func checkClient(addr string, expectClient string) bool { ...@@ -120,17 +120,20 @@ func checkClient(addr string, expectClient string) bool {
//首次注册功能,如果没有进行过注册,则进行首次注册 //首次注册功能,如果没有进行过注册,则进行首次注册
//如果已经注册,则继续推送 //如果已经注册,则继续推送
func bindOrResumePush(cfg *relayerTypes.SyncTxReceiptConfig) { func bindOrResumePush(cfg *relayerTypes.SyncTxReceiptConfig) {
params := types.SubscribeTxReceipt{ contract := make(map[string]bool)
contract["x2ethereum"] = true
params := types.PushSubscribeReq{
Name: cfg.PushName, Name: cfg.PushName,
URL: cfg.PushHost, URL: cfg.PushHost,
Encode: "proto", Encode: "proto",
LastSequence: cfg.StartSyncSequence, LastSequence: cfg.StartSyncSequence,
LastHeight: cfg.StartSyncHeight, LastHeight: cfg.StartSyncHeight,
LastBlockHash: cfg.StartSyncHash, LastBlockHash: cfg.StartSyncHash,
Contract: "x2ethereum", Type: blockchain.PushTxReceipt,
Contract: contract,
} }
var res rpctypes.Reply var res types.ReplySubscribePush
ctx := jsonclient.NewRPCCtx(cfg.Chain33Host, "Chain33.AddSubscribeTxReceipt", params, &res) ctx := jsonclient.NewRPCCtx(cfg.Chain33Host, "Chain33.AddPushSubscribe", params, &res)
_, err := ctx.RunResult() _, err := ctx.RunResult()
if err != nil { if err != nil {
fmt.Println("Failed to AddSubscribeTxReceipt to rpc addr:", cfg.Chain33Host, "ReplySubTxReceipt", res) fmt.Println("Failed to AddSubscribeTxReceipt to rpc addr:", cfg.Chain33Host, "ReplySubTxReceipt", res)
...@@ -138,7 +141,7 @@ func bindOrResumePush(cfg *relayerTypes.SyncTxReceiptConfig) { ...@@ -138,7 +141,7 @@ func bindOrResumePush(cfg *relayerTypes.SyncTxReceiptConfig) {
} }
if !res.IsOk { if !res.IsOk {
fmt.Println("Failed to AddSubscribeTxReceipt to rpc addr:", cfg.Chain33Host, "ReplySubTxReceipt", res) fmt.Println("Failed to AddSubscribeTxReceipt to rpc addr:", cfg.Chain33Host, "ReplySubTxReceipt", res)
panic("bindOrResumePush client failed due to:" + res.Msg) panic("bindOrResumePush client failed due to:" + string(res.Msg))
} }
log.Info("bindOrResumePush", "Succeed to AddSubscribeTxReceipt for rpc address:", cfg.Chain33Host) log.Info("bindOrResumePush", "Succeed to AddSubscribeTxReceipt for rpc address:", cfg.Chain33Host)
fmt.Println("Succeed to AddSubscribeTxReceipt") fmt.Println("Succeed to AddSubscribeTxReceipt")
......
...@@ -13,7 +13,7 @@ import ( ...@@ -13,7 +13,7 @@ import (
"github.com/33cn/chain33/system/crypto/secp256k1" "github.com/33cn/chain33/system/crypto/secp256k1"
chain33Types "github.com/33cn/chain33/types" chain33Types "github.com/33cn/chain33/types"
wcom "github.com/33cn/chain33/wallet/common" wcom "github.com/33cn/chain33/wallet/common"
x2ethTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" x2ethTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/common/math" "github.com/ethereum/go-ethereum/common/math"
"github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/crypto"
......
...@@ -19,8 +19,8 @@ import ( ...@@ -19,8 +19,8 @@ import (
"sync/atomic" "sync/atomic"
"time" "time"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethcontract/generated" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethcontract/generated"
x2ethTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2ethTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
"github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum"
"github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind"
"github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/crypto"
...@@ -33,9 +33,9 @@ import ( ...@@ -33,9 +33,9 @@ import (
chain33Crypto "github.com/33cn/chain33/common/crypto" chain33Crypto "github.com/33cn/chain33/common/crypto"
dbm "github.com/33cn/chain33/common/db" dbm "github.com/33cn/chain33/common/db"
log "github.com/33cn/chain33/common/log/log15" log "github.com/33cn/chain33/common/log/log15"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethtxs" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethtxs"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/events" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/events"
ebTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
) )
type Relayer4Ethereum struct { type Relayer4Ethereum struct {
......
...@@ -7,8 +7,8 @@ import ( ...@@ -7,8 +7,8 @@ import (
dbm "github.com/33cn/chain33/common/db" dbm "github.com/33cn/chain33/common/db"
chain33Types "github.com/33cn/chain33/types" chain33Types "github.com/33cn/chain33/types"
ebTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" ebTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/utils" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/utils"
"github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/core/types"
) )
......
...@@ -12,12 +12,12 @@ import ( ...@@ -12,12 +12,12 @@ import (
"github.com/33cn/chain33/common/log/log15" "github.com/33cn/chain33/common/log/log15"
rpctypes "github.com/33cn/chain33/rpc/types" rpctypes "github.com/33cn/chain33/rpc/types"
chain33Types "github.com/33cn/chain33/types" chain33Types "github.com/33cn/chain33/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/ethtxs" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/ethtxs"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/relayer/chain33" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/relayer/chain33"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/relayer/ethereum" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/relayer/ethereum"
relayerTypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/types" relayerTypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/types"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/ebrelayer/utils" "github.com/33cn/plugin/plugin/dapp/x2ethereum/ebrelayer/utils"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
"github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common"
lru "github.com/hashicorp/golang-lru" lru "github.com/hashicorp/golang-lru"
) )
......
...@@ -8,7 +8,7 @@ import ( ...@@ -8,7 +8,7 @@ import (
"github.com/33cn/chain33/common/address" "github.com/33cn/chain33/common/address"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
x2eTy "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2eTy "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
) )
/* /*
......
...@@ -4,7 +4,7 @@ import ( ...@@ -4,7 +4,7 @@ import (
"strconv" "strconv"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
x2eTy "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2eTy "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
) )
/* /*
......
...@@ -14,7 +14,7 @@ import ( ...@@ -14,7 +14,7 @@ import (
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
chain33types "github.com/33cn/chain33/types" chain33types "github.com/33cn/chain33/types"
"github.com/33cn/chain33/util" "github.com/33cn/chain33/util"
types2 "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" types2 "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
"github.com/stretchr/testify/mock" "github.com/stretchr/testify/mock"
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
) )
......
...@@ -5,7 +5,7 @@ import ( ...@@ -5,7 +5,7 @@ import (
"strconv" "strconv"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
x2eTy "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2eTy "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
) )
func NewProphecy(id string) *x2eTy.ReceiptEthProphecy { func NewProphecy(id string) *x2eTy.ReceiptEthProphecy {
......
...@@ -6,7 +6,7 @@ import ( ...@@ -6,7 +6,7 @@ import (
"github.com/33cn/chain33/account" "github.com/33cn/chain33/account"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
x2eTy "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2eTy "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
) )
func (x *x2ethereum) Query_GetEthProphecy(in *x2eTy.QueryEthProphecyParams) (types.Message, error) { func (x *x2ethereum) Query_GetEthProphecy(in *x2eTy.QueryEthProphecyParams) (types.Message, error) {
......
...@@ -4,7 +4,7 @@ import ( ...@@ -4,7 +4,7 @@ import (
log "github.com/33cn/chain33/common/log/log15" log "github.com/33cn/chain33/common/log/log15"
drivers "github.com/33cn/chain33/system/dapp" drivers "github.com/33cn/chain33/system/dapp"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
x2eTy "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2eTy "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
) )
/* /*
......
...@@ -9,7 +9,7 @@ import ( ...@@ -9,7 +9,7 @@ import (
"github.com/33cn/chain33/common/address" "github.com/33cn/chain33/common/address"
dbm "github.com/33cn/chain33/common/db" dbm "github.com/33cn/chain33/common/db"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
x2eTy "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2eTy "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
"github.com/pkg/errors" "github.com/pkg/errors"
) )
......
...@@ -8,7 +8,7 @@ import ( ...@@ -8,7 +8,7 @@ import (
"github.com/33cn/chain33/common/address" "github.com/33cn/chain33/common/address"
dbm "github.com/33cn/chain33/common/db" dbm "github.com/33cn/chain33/common/db"
"github.com/33cn/chain33/types" "github.com/33cn/chain33/types"
x2eTy "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2eTy "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
) )
type Oracle struct { type Oracle struct {
......
...@@ -2,10 +2,10 @@ package x2ethereum ...@@ -2,10 +2,10 @@ package x2ethereum
import ( import (
"github.com/33cn/chain33/pluginmgr" "github.com/33cn/chain33/pluginmgr"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/commands" "github.com/33cn/plugin/plugin/dapp/x2ethereum/commands"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/executor" "github.com/33cn/plugin/plugin/dapp/x2ethereum/executor"
"github.com/33cn/plugin/plugin/dapp/x2Ethereum/rpc" "github.com/33cn/plugin/plugin/dapp/x2ethereum/rpc"
x2ethereumtypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2ethereumtypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
) )
/* /*
......
...@@ -2,7 +2,7 @@ package rpc ...@@ -2,7 +2,7 @@ package rpc
import ( import (
rpctypes "github.com/33cn/chain33/rpc/types" rpctypes "github.com/33cn/chain33/rpc/types"
x2ethereumtypes "github.com/33cn/plugin/plugin/dapp/x2Ethereum/types" x2ethereumtypes "github.com/33cn/plugin/plugin/dapp/x2ethereum/types"
) )
/* /*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment