nameservice: change Record message types for chiba-clonk-client

This commit is contained in:
nabarun 2022-04-08 13:03:58 +05:30
parent 39b742874c
commit 555934b799
13 changed files with 243 additions and 184 deletions

4
go.mod
View File

@ -3,6 +3,7 @@ module github.com/tharsis/ethermint
go 1.17
require (
github.com/99designs/gqlgen v0.17.2
github.com/btcsuite/btcd v0.22.0-beta
github.com/btcsuite/btcutil v1.0.3-0.20201208143702-a53e38424cce
github.com/cosmos/cosmos-sdk v0.45.1
@ -35,6 +36,7 @@ require (
github.com/tendermint/tendermint v0.34.14
github.com/tendermint/tm-db v0.6.7
github.com/tyler-smith/go-bip39 v1.1.0
github.com/vektah/gqlparser/v2 v2.4.1
google.golang.org/genproto v0.0.0-20220401170504-314d38edb7de
google.golang.org/grpc v1.45.0
google.golang.org/protobuf v1.28.0
@ -44,7 +46,6 @@ require (
require (
filippo.io/edwards25519 v1.0.0-beta.2 // indirect
github.com/99designs/gqlgen v0.17.2 // indirect
github.com/99designs/keyring v1.1.6 // indirect
github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d // indirect
github.com/DataDog/zstd v1.4.5 // indirect
@ -152,7 +153,6 @@ require (
github.com/tendermint/go-amino v0.16.0 // indirect
github.com/tklauser/go-sysconf v0.3.5 // indirect
github.com/tklauser/numcpus v0.2.2 // indirect
github.com/vektah/gqlparser/v2 v2.4.1 // indirect
github.com/whyrusleeping/cbor-gen v0.0.0-20200123233031-1cdf64d27158 // indirect
github.com/zondax/hid v0.9.0 // indirect
go.etcd.io/bbolt v1.3.6 // indirect

7
go.sum
View File

@ -115,11 +115,13 @@ github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk5
github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM=
github.com/allegro/bigcache v1.2.1 h1:hg1sY1raCwic3Vnsvje6TT7/pnZba83LeFck5NrFKSc=
github.com/allegro/bigcache v1.2.1/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM=
github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883 h1:bvNMNQO63//z+xNgfBlViaCIJKLlCJ6/fmUseuG0wVQ=
github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883/go.mod h1:rCTlJbsFo29Kk6CurOXKm700vrz8f0KW0JNfpkRJY/8=
github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY=
github.com/apache/arrow/go/arrow v0.0.0-20191024131854-af6fa24be0db/go.mod h1:VTxUBvSJ3s3eHAg65PNgrsn5BtqCRPdmyXh6rAfdxN0=
github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ=
github.com/apache/thrift v0.13.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ=
github.com/arbovm/levenshtein v0.0.0-20160628152529-48b4e1c0c4d0 h1:jfIu9sQUG6Ig+0+Ap1h4unLjW6YQJpKZVmUzxsD4E/Q=
github.com/arbovm/levenshtein v0.0.0-20160628152529-48b4e1c0c4d0/go.mod h1:t2tdKJDJF9BV14lnkjHmOQgcvEKgtqs5a1N3LNdJhGE=
github.com/aristanetworks/goarista v0.0.0-20170210015632-ea17b1a17847/go.mod h1:D/tb0zPVXnP7fmsLZjtdUhSsumbK/ij54UXjjVgMGxQ=
github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o=
@ -282,6 +284,7 @@ github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUn
github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y=
github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw=
github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
github.com/dgryski/trifles v0.0.0-20200323201526-dd97f9abfb48 h1:fRzb/w+pyskVMQ+UbP35JkH8yB7MYb4q/qhBarqZE6g=
github.com/dgryski/trifles v0.0.0-20200323201526-dd97f9abfb48/go.mod h1:if7Fbed8SFyPtHLHbg49SI7NAdJiC5WIA09pe59rfAA=
github.com/dlclark/regexp2 v1.2.0/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc=
github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc=
@ -993,6 +996,7 @@ github.com/segmentio/fasthash v1.0.3/go.mod h1:waKX8l2N8yckOgmSsXJi7x1ZfdKZ4x7KR
github.com/segmentio/kafka-go v0.1.0/go.mod h1:X6itGqS9L4jDletMsxZ7Dz+JFWxM6JHfPOCvTvk+EJo=
github.com/segmentio/kafka-go v0.2.0/go.mod h1:X6itGqS9L4jDletMsxZ7Dz+JFWxM6JHfPOCvTvk+EJo=
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
github.com/sergi/go-diff v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0=
github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM=
github.com/shirou/gopsutil v2.20.5+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA=
github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible h1:Bn1aCHHRnjv4Bl16T8rcaFjYSrGrIZvpiGO6P3Q4GpU=
@ -1112,7 +1116,6 @@ github.com/urfave/cli/v2 v2.3.0/go.mod h1:LJmUH05zAU44vOAcrfzZQKsZbVcdbOG8rtL3/X
github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc=
github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8=
github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ=
github.com/vektah/gqlparser/v2 v2.4.0 h1:EmA4dw9mqHm0j6Xzb9T21hOrp3oXmxnS40vwki70DZU=
github.com/vektah/gqlparser/v2 v2.4.0/go.mod h1:flJWIR04IMQPGz+BXLrORkrARBxv/rtyIAFvd/MceW0=
github.com/vektah/gqlparser/v2 v2.4.1 h1:QOyEn8DAPMUMARGMeshKDkDgNmVoEaEGiDB0uWxcSlQ=
github.com/vektah/gqlparser/v2 v2.4.1/go.mod h1:flJWIR04IMQPGz+BXLrORkrARBxv/rtyIAFvd/MceW0=
@ -1524,8 +1527,8 @@ golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.5 h1:ouewzE6p+/VEB31YYnTbEJdi8pFqKp4P4n85vwo3DHA=
golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.9 h1:j9KsMiaP1c3B0OTQGth0/k+miLGTgLsAFUCrF2vLcF8=
golang.org/x/tools v0.1.9/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=

View File

@ -3,13 +3,14 @@ package gql
import (
"context"
"encoding/base64"
"strconv"
"github.com/cosmos/cosmos-sdk/client"
authtypes "github.com/cosmos/cosmos-sdk/x/auth/types"
banktypes "github.com/cosmos/cosmos-sdk/x/bank/types"
auctiontypes "github.com/tharsis/ethermint/x/auction/types"
bondtypes "github.com/tharsis/ethermint/x/bond/types"
nstypes "github.com/tharsis/ethermint/x/nameservice/types"
"strconv"
)
// DefaultLogNumLines is the number of log lines to tail by default.
@ -139,16 +140,18 @@ func (q queryResolver) GetRecordsByIds(ctx context.Context, ids []string) ([]*Re
gqlResponse := make([]*Record, len(ids))
for i, id := range ids {
// TODO: Implement HasRecord query similar to https://github.com/vulcanize/dxns/blob/main/gql/resolver.go#L325
res, err := nsQueryClient.GetRecord(context.Background(), &nstypes.QueryRecordByIdRequest{Id: id})
if err != nil {
return nil, err
}
gqlResponse[i] = nil
} else {
record, err := getGQLRecord(context.Background(), q, res.GetRecord())
if err != nil {
return nil, err
}
gqlResponse[i] = record
}
}
return gqlResponse, nil
}

View File

@ -3,12 +3,13 @@ package gql
import (
"context"
"encoding/json"
"reflect"
"strconv"
sdk "github.com/cosmos/cosmos-sdk/types"
auctiontypes "github.com/tharsis/ethermint/x/auction/types"
bondtypes "github.com/tharsis/ethermint/x/bond/types"
nstypes "github.com/tharsis/ethermint/x/nameservice/types"
"reflect"
"strconv"
)
// OwnerAttributeName denotes the owner attribute name for a bond.
@ -72,8 +73,8 @@ func getGQLRecord(ctx context.Context, resolver QueryResolver, record nstypes.Re
return &Record{
ID: record.Id,
BondID: record.GetBondId(),
CreateTime: record.GetCreateTime().String(),
ExpiryTime: record.GetExpiryTime().String(),
CreateTime: record.GetCreateTime(),
ExpiryTime: record.GetExpiryTime(),
Owners: record.GetOwners(),
Attributes: attributes,
References: references,

View File

@ -32,6 +32,8 @@ cat $HOME/.chibaclonkd/config/genesis.json | jq '.app_state["staking"]["params"]
cat $HOME/.chibaclonkd/config/genesis.json | jq '.app_state["crisis"]["constant_fee"]["denom"]="aphoton"' > $HOME/.chibaclonkd/config/tmp_genesis.json && mv $HOME/.chibaclonkd/config/tmp_genesis.json $HOME/.chibaclonkd/config/genesis.json
cat $HOME/.chibaclonkd/config/genesis.json | jq '.app_state["gov"]["deposit_params"]["min_deposit"][0]["denom"]="aphoton"' > $HOME/.chibaclonkd/config/tmp_genesis.json && mv $HOME/.chibaclonkd/config/tmp_genesis.json $HOME/.chibaclonkd/config/genesis.json
cat $HOME/.chibaclonkd/config/genesis.json | jq '.app_state["mint"]["params"]["mint_denom"]="aphoton"' > $HOME/.chibaclonkd/config/tmp_genesis.json && mv $HOME/.chibaclonkd/config/tmp_genesis.json $HOME/.chibaclonkd/config/genesis.json
cat $HOME/.chibaclonkd/config/genesis.json | jq '.app_state["nameservice"]["params"]["record_rent"]["denom"]="aphoton"' > $HOME/.chibaclonkd/config/tmp_genesis.json && mv $HOME/.chibaclonkd/config/tmp_genesis.json $HOME/.chibaclonkd/config/genesis.json
# increase block time (?)
cat $HOME/.chibaclonkd/config/genesis.json | jq '.consensus_params["block"]["time_iota_ms"]="1000"' > $HOME/.chibaclonkd/config/tmp_genesis.json && mv $HOME/.chibaclonkd/config/tmp_genesis.json $HOME/.chibaclonkd/config/genesis.json

View File

@ -68,21 +68,17 @@ message Record {
string bond_id = 2 [
(gogoproto.moretags) = "json:\"bondId\" yaml:\"bondId\""
];
google.protobuf.Timestamp create_time = 3 [
(gogoproto.stdtime) = true,
(gogoproto.nullable) = false,
string create_time = 3 [
(gogoproto.moretags) = "json:\"createTime\" yaml:\"createTime\""
];
google.protobuf.Timestamp expiry_time = 4 [
(gogoproto.stdtime) = true,
(gogoproto.nullable) = false,
string expiry_time = 4 [
(gogoproto.moretags) = "json:\"expiryTime\" yaml:\"expiryTime\""
];
bool deleted = 5;
repeated string owners = 6 [
(gogoproto.moretags) = "json:\"owners\" yaml:\"owners\""
];
bytes attributes = 7 [
string attributes = 7 [
(gogoproto.moretags) = "json:\"attributes\" yaml:\"attributes\""
];
}

View File

@ -1,6 +1,8 @@
package nameservice
import (
"time"
sdk "github.com/cosmos/cosmos-sdk/types"
abci "github.com/tendermint/tendermint/abci/types"
"github.com/tharsis/ethermint/x/nameservice/keeper"
@ -14,9 +16,12 @@ func InitGenesis(ctx sdk.Context, keeper keeper.Keeper, data types.GenesisState)
keeper.PutRecord(ctx, record)
// Add to record expiry queue if expiry time is in the future.
if record.ExpiryTime.After(ctx.BlockTime()) {
expiryTime, err := time.Parse(time.RFC3339, record.ExpiryTime)
if err == nil {
if expiryTime.After(ctx.BlockTime()) {
keeper.InsertRecordExpiryQueue(ctx, record)
}
}
// Note: Bond genesis runs first, so bonds will already be present.
if record.BondId != "" {

View File

@ -2,6 +2,9 @@ package keeper
import (
"fmt"
"sort"
"time"
"github.com/cosmos/cosmos-sdk/codec"
"github.com/cosmos/cosmos-sdk/codec/legacy"
sdk "github.com/cosmos/cosmos-sdk/types"
@ -13,8 +16,6 @@ import (
bondkeeper "github.com/tharsis/ethermint/x/bond/keeper"
"github.com/tharsis/ethermint/x/nameservice/helpers"
"github.com/tharsis/ethermint/x/nameservice/types"
"sort"
"time"
)
var (
@ -198,8 +199,8 @@ func (k Keeper) processRecord(ctx sdk.Context, record *types.RecordType, isRenew
return err
}
record.CreateTime = ctx.BlockHeader().Time
record.ExpiryTime = ctx.BlockHeader().Time.Add(params.RecordRentDuration)
record.CreateTime = ctx.BlockHeader().Time.Format(time.RFC3339)
record.ExpiryTime = ctx.BlockHeader().Time.Add(params.RecordRentDuration).Format(time.RFC3339)
record.Deleted = false
k.PutRecord(ctx, record.ToRecordObj())
@ -268,9 +269,13 @@ func (k Keeper) GetRecordExpiryQueueTimeSlice(ctx sdk.Context, timestamp time.Ti
// InsertRecordExpiryQueue inserts a record CID to the appropriate timeslice in the record expiry queue.
func (k Keeper) InsertRecordExpiryQueue(ctx sdk.Context, val types.Record) {
timeSlice := k.GetRecordExpiryQueueTimeSlice(ctx, val.ExpiryTime)
expiryTime, err := time.Parse(time.RFC3339, val.ExpiryTime)
if err == nil {
timeSlice := k.GetRecordExpiryQueueTimeSlice(ctx, expiryTime)
timeSlice = append(timeSlice, val.Id)
k.SetRecordExpiryQueueTimeSlice(ctx, val.ExpiryTime, timeSlice)
k.SetRecordExpiryQueueTimeSlice(ctx, expiryTime, timeSlice)
}
}
// GetModuleBalances gets the nameservice module account(s) balances.

View File

@ -2,6 +2,8 @@ package keeper
import (
"fmt"
"time"
"github.com/cosmos/cosmos-sdk/codec"
sdk "github.com/cosmos/cosmos-sdk/types"
sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"
@ -159,12 +161,16 @@ func (k Keeper) ProcessRenewRecord(ctx sdk.Context, msg types.MsgRenewRecord) er
// Check if renewal is required (i.e. expired record marked as deleted).
record := k.GetRecord(ctx, msg.RecordId)
if !record.Deleted || record.ExpiryTime.After(ctx.BlockTime()) {
expiryTime, err := time.Parse(time.RFC3339, record.ExpiryTime)
if err == nil {
if !record.Deleted || expiryTime.After(ctx.BlockTime()) {
return sdkerrors.Wrap(sdkerrors.ErrInvalidRequest, "Renewal not required.")
}
}
recordType := record.ToRecordType()
err := k.processRecord(ctx, &recordType, true)
err = k.processRecord(ctx, &recordType, true)
if err != nil {
return err
}

View File

@ -158,11 +158,11 @@ func (m *Params) GetAuthorityAuctionMinimumBid() types.Coin {
type Record struct {
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty" json:"id" yaml:"id"`
BondId string `protobuf:"bytes,2,opt,name=bond_id,json=bondId,proto3" json:"bond_id,omitempty" json:"bondId" yaml:"bondId"`
CreateTime time.Time `protobuf:"bytes,3,opt,name=create_time,json=createTime,proto3,stdtime" json:"create_time" json:"createTime" yaml:"createTime"`
ExpiryTime time.Time `protobuf:"bytes,4,opt,name=expiry_time,json=expiryTime,proto3,stdtime" json:"expiry_time" json:"expiryTime" yaml:"expiryTime"`
CreateTime string `protobuf:"bytes,3,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty" json:"createTime" yaml:"createTime"`
ExpiryTime string `protobuf:"bytes,4,opt,name=expiry_time,json=expiryTime,proto3" json:"expiry_time,omitempty" json:"expiryTime" yaml:"expiryTime"`
Deleted bool `protobuf:"varint,5,opt,name=deleted,proto3" json:"deleted,omitempty"`
Owners []string `protobuf:"bytes,6,rep,name=owners,proto3" json:"owners,omitempty" json:"owners" yaml:"owners"`
Attributes []byte `protobuf:"bytes,7,opt,name=attributes,proto3" json:"attributes,omitempty" json:"attributes" yaml:"attributes"`
Attributes string `protobuf:"bytes,7,opt,name=attributes,proto3" json:"attributes,omitempty" json:"attributes" yaml:"attributes"`
}
func (m *Record) Reset() { *m = Record{} }
@ -212,18 +212,18 @@ func (m *Record) GetBondId() string {
return ""
}
func (m *Record) GetCreateTime() time.Time {
func (m *Record) GetCreateTime() string {
if m != nil {
return m.CreateTime
}
return time.Time{}
return ""
}
func (m *Record) GetExpiryTime() time.Time {
func (m *Record) GetExpiryTime() string {
if m != nil {
return m.ExpiryTime
}
return time.Time{}
return ""
}
func (m *Record) GetDeleted() bool {
@ -240,11 +240,11 @@ func (m *Record) GetOwners() []string {
return nil
}
func (m *Record) GetAttributes() []byte {
func (m *Record) GetAttributes() string {
if m != nil {
return m.Attributes
}
return nil
return ""
}
// AuthorityEntry defines the nameservice module AuthorityEntries
@ -764,88 +764,89 @@ func init() {
}
var fileDescriptor_c2009c2df775dbad = []byte{
// 1295 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0x00, 0x00,
// 1299 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x57, 0xcd, 0x6e, 0x1b, 0x45,
0x1c, 0xcf, 0xc6, 0x89, 0x13, 0x8f, 0x1b, 0x83, 0x86, 0xb4, 0x75, 0x02, 0xf5, 0x06, 0xa3, 0xaa,
0xad, 0x42, 0xbc, 0x94, 0x1e, 0xca, 0x87, 0x10, 0xca, 0x26, 0x69, 0x1a, 0x10, 0x10, 0x26, 0xb9,
0xc0, 0xc5, 0xcc, 0xee, 0x4e, 0xec, 0xa1, 0xde, 0x5d, 0x6b, 0x67, 0x36, 0xd4, 0x70, 0xe2, 0x0d,
0x22, 0x71, 0xa9, 0x04, 0xe2, 0x05, 0x40, 0xe2, 0x31, 0xe8, 0xb1, 0x47, 0x84, 0x84, 0x41, 0xc9,
0x1b, 0xf8, 0x09, 0xd0, 0xce, 0xcc, 0x7e, 0xda, 0xae, 0xa3, 0xf6, 0xb6, 0xff, 0xcf, 0xf9, 0xfd,
0x3f, 0x67, 0x16, 0x18, 0xa7, 0x61, 0xcf, 0xc6, 0x1e, 0xfd, 0x9e, 0x18, 0x1e, 0x76, 0x09, 0x23,
0xc1, 0x29, 0xb5, 0x89, 0x71, 0x7a, 0xd7, 0x22, 0x1c, 0xdf, 0xcd, 0xf2, 0x5a, 0xfd, 0xc0, 0xe7,
0x3e, 0xbc, 0x91, 0x18, 0xb4, 0xb2, 0x42, 0x65, 0xb0, 0xde, 0xe8, 0xf8, 0x7e, 0xa7, 0x47, 0x0c,
0xa1, 0x6c, 0x85, 0x27, 0x86, 0x13, 0x06, 0x98, 0x53, 0xdf, 0x93, 0xe6, 0xeb, 0x7a, 0x51, 0xce,
0xa9, 0x4b, 0x18, 0xc7, 0x6e, 0x5f, 0x29, 0xac, 0x76, 0xfc, 0x8e, 0x2f, 0x3e, 0x8d, 0xe8, 0x4b,
0x71, 0x1b, 0xb6,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, 0x00, 0xff, 0xff, 0x6a, 0x12, 0x43, 0x47, 0x57,
0x0f, 0x00, 0x00,
}
func (m *Params) Marshal() (dAtA []byte, err error) {
@ -1017,22 +1018,20 @@ func (m *Record) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i--
dAtA[i] = 0x28
}
n11, err11 := github_com_gogo_protobuf_types.StdTimeMarshalTo(m.ExpiryTime, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(m.ExpiryTime):])
if err11 != nil {
return 0, err11
}
i -= n11
i = encodeVarintNameservice(dAtA, i, uint64(n11))
if len(m.ExpiryTime) > 0 {
i -= len(m.ExpiryTime)
copy(dAtA[i:], m.ExpiryTime)
i = encodeVarintNameservice(dAtA, i, uint64(len(m.ExpiryTime)))
i--
dAtA[i] = 0x22
n12, err12 := github_com_gogo_protobuf_types.StdTimeMarshalTo(m.CreateTime, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(m.CreateTime):])
if err12 != nil {
return 0, err12
}
i -= n12
i = encodeVarintNameservice(dAtA, i, uint64(n12))
if len(m.CreateTime) > 0 {
i -= len(m.CreateTime)
copy(dAtA[i:], m.CreateTime)
i = encodeVarintNameservice(dAtA, i, uint64(len(m.CreateTime)))
i--
dAtA[i] = 0x1a
}
if len(m.BondId) > 0 {
i -= len(m.BondId)
copy(dAtA[i:], m.BondId)
@ -1112,12 +1111,12 @@ func (m *NameAuthority) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
n14, err14 := github_com_gogo_protobuf_types.StdTimeMarshalTo(m.ExpiryTime, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(m.ExpiryTime):])
if err14 != nil {
return 0, err14
n12, err12 := github_com_gogo_protobuf_types.StdTimeMarshalTo(m.ExpiryTime, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(m.ExpiryTime):])
if err12 != nil {
return 0, err12
}
i -= n14
i = encodeVarintNameservice(dAtA, i, uint64(n14))
i -= n12
i = encodeVarintNameservice(dAtA, i, uint64(n12))
i--
dAtA[i] = 0x3a
if len(m.BondId) > 0 {
@ -1498,10 +1497,14 @@ func (m *Record) Size() (n int) {
if l > 0 {
n += 1 + l + sovNameservice(uint64(l))
}
l = github_com_gogo_protobuf_types.SizeOfStdTime(m.CreateTime)
l = len(m.CreateTime)
if l > 0 {
n += 1 + l + sovNameservice(uint64(l))
l = github_com_gogo_protobuf_types.SizeOfStdTime(m.ExpiryTime)
}
l = len(m.ExpiryTime)
if l > 0 {
n += 1 + l + sovNameservice(uint64(l))
}
if m.Deleted {
n += 2
}
@ -2200,7 +2203,7 @@ func (m *Record) Unmarshal(dAtA []byte) error {
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field CreateTime", wireType)
}
var msglen int
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowNameservice
@ -2210,30 +2213,29 @@ func (m *Record) Unmarshal(dAtA []byte) error {
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
intStringLen := int(stringLen)
if intStringLen < 0 {
return ErrInvalidLengthNameservice
}
postIndex := iNdEx + msglen
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return ErrInvalidLengthNameservice
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if err := github_com_gogo_protobuf_types.StdTimeUnmarshal(&m.CreateTime, dAtA[iNdEx:postIndex]); err != nil {
return err
}
m.CreateTime = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 4:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field ExpiryTime", wireType)
}
var msglen int
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowNameservice
@ -2243,24 +2245,23 @@ func (m *Record) Unmarshal(dAtA []byte) error {
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
intStringLen := int(stringLen)
if intStringLen < 0 {
return ErrInvalidLengthNameservice
}
postIndex := iNdEx + msglen
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return ErrInvalidLengthNameservice
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
if err := github_com_gogo_protobuf_types.StdTimeUnmarshal(&m.ExpiryTime, dAtA[iNdEx:postIndex]); err != nil {
return err
}
m.ExpiryTime = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
case 5:
if wireType != 0 {
@ -2318,7 +2319,7 @@ func (m *Record) Unmarshal(dAtA []byte) error {
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Attributes", wireType)
}
var byteLen int
var stringLen uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowNameservice
@ -2328,25 +2329,23 @@ func (m *Record) Unmarshal(dAtA []byte) error {
}
b := dAtA[iNdEx]
iNdEx++
byteLen |= int(b&0x7F) << shift
stringLen |= uint64(b&0x7F) << shift
if b < 0x80 {
break
}
}
if byteLen < 0 {
intStringLen := int(stringLen)
if intStringLen < 0 {
return ErrInvalidLengthNameservice
}
postIndex := iNdEx + byteLen
postIndex := iNdEx + intStringLen
if postIndex < 0 {
return ErrInvalidLengthNameservice
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
m.Attributes = append(m.Attributes[:0], dAtA[iNdEx:postIndex]...)
if m.Attributes == nil {
m.Attributes = []byte{}
}
m.Attributes = string(dAtA[iNdEx:postIndex])
iNdEx = postIndex
default:
iNdEx = preIndex

View File

@ -20,6 +20,7 @@ import (
"google.golang.org/grpc"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/grpclog"
"google.golang.org/grpc/metadata"
"google.golang.org/grpc/status"
)
@ -30,6 +31,7 @@ var _ status.Status
var _ = runtime.String
var _ = utilities.NewDoubleArray
var _ = descriptor.ForMessage
var _ = metadata.Join
func request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
var protoReq QueryParamsRequest
@ -466,12 +468,14 @@ func local_request_Query_GetAuthorityExpiryQueue_0(ctx context.Context, marshale
// RegisterQueryHandlerServer registers the http handlers for service Query to "mux".
// UnaryRPC :call QueryServer directly.
// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.
// Note that using this registration option will cause many gRPC library features (such as grpc.SendHeader, etc) to stop working. Consider using RegisterQueryHandlerFromEndpoint instead.
// Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead.
func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error {
mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -479,6 +483,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -492,6 +497,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_ListRecords_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -499,6 +506,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_ListRecords_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -512,6 +520,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_GetRecord_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -519,6 +529,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_GetRecord_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -532,6 +543,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_GetRecordByBondId_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -539,6 +552,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_GetRecordByBondId_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -552,6 +566,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_GetNameServiceModuleBalance_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -559,6 +575,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_GetNameServiceModuleBalance_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -572,6 +589,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_ListNameRecords_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -579,6 +598,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_ListNameRecords_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -592,6 +612,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_Whois_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -599,6 +621,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_Whois_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -612,6 +635,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_LookupWrn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -619,6 +644,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_LookupWrn_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -632,6 +658,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_ResolveWrn_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -639,6 +667,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_ResolveWrn_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -652,6 +681,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_GetRecordExpiryQueue_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -659,6 +690,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_GetRecordExpiryQueue_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
@ -672,6 +704,8 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
mux.Handle("GET", pattern_Query_GetAuthorityExpiryQueue_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
ctx, cancel := context.WithCancel(req.Context())
defer cancel()
var stream runtime.ServerTransportStream
ctx = grpc.NewContextWithServerTransportStream(ctx, &stream)
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
if err != nil {
@ -679,6 +713,7 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv
return
}
resp, md, err := local_request_Query_GetAuthorityExpiryQueue_0(rctx, inboundMarshaler, server, req, pathParams)
md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer())
ctx = runtime.NewServerMetadataContext(ctx, md)
if err != nil {
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)

View File

@ -23,6 +23,12 @@ func NewMsgSetRecord(payload Payload, bondID string, signer sdk.AccAddress) MsgS
}
}
// Route Implements Msg.
func (msg MsgSetRecord) Route() string { return RouterKey }
// Type Implements Msg.
func (msg MsgSetRecord) Type() string { return "set-record" }
func (msg MsgSetRecord) ValidateBasic() error {
if len(msg.Signer) == 0 {
return sdkerrors.Wrap(sdkerrors.ErrInvalidAddress, msg.Signer)

View File

@ -2,9 +2,9 @@ package types
import (
"crypto/sha256"
canonicalJson "github.com/gibson042/canonicaljson-go"
"github.com/tharsis/ethermint/x/nameservice/helpers"
"time"
)
const (
@ -24,11 +24,9 @@ type PayloadType struct {
func (payloadObj *PayloadType) ToPayload() Payload {
var payload = Payload{
Record: &Record{
CreateTime: time.Time{},
ExpiryTime: time.Time{},
Deleted: false,
Owners: nil,
Attributes: helpers.MarshalMapToJSONBytes(payloadObj.Record),
Attributes: helpers.BytesToBase64(helpers.MarshalMapToJSONBytes(payloadObj.Record)),
},
Signatures: payloadObj.Signatures,
}
@ -40,7 +38,7 @@ func (payloadObj *PayloadType) ToPayload() Payload {
func (payload Payload) ToReadablePayload() PayloadType {
var payloadType PayloadType
payloadType.Record = helpers.UnMarshalMapFromJSONBytes(payload.Record.Attributes)
payloadType.Record = helpers.UnMarshalMapFromJSONBytes(helpers.BytesFromBase64(payload.Record.Attributes))
payloadType.Signatures = payload.Signatures
@ -58,7 +56,7 @@ func (r *Record) ToRecordType() RecordType {
resourceObj.ExpiryTime = r.ExpiryTime
resourceObj.Deleted = r.Deleted
resourceObj.Owners = r.Owners
resourceObj.Attributes = helpers.UnMarshalMapFromJSONBytes(r.Attributes)
resourceObj.Attributes = helpers.UnMarshalMapFromJSONBytes(helpers.BytesFromBase64(r.Attributes))
return resourceObj
}
@ -68,8 +66,8 @@ type RecordType struct {
Id string `json:"id,omitempty"`
Names []string `json:"names,omitempty"`
BondId string `json:"bondId,omitempty"`
CreateTime time.Time `json:"createTime,omitempty"`
ExpiryTime time.Time `json:"expiryTime,omitempty"`
CreateTime string `json:"createTime,omitempty"`
ExpiryTime string `json:"expiryTime,omitempty"`
Deleted bool `json:"deleted,omitempty"`
Owners []string `json:"owners,omitempty"`
Attributes map[string]interface{} `json:"attributes,omitempty"`
@ -86,7 +84,7 @@ func (r *RecordType) ToRecordObj() Record {
resourceObj.ExpiryTime = r.ExpiryTime
resourceObj.Deleted = r.Deleted
resourceObj.Owners = r.Owners
resourceObj.Attributes = helpers.MarshalMapToJSONBytes(r.Attributes)
resourceObj.Attributes = helpers.BytesToBase64(helpers.MarshalMapToJSONBytes(r.Attributes))
return resourceObj
}