migration

package
v1.0.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 7, 2020 License: GPL-3.0, GPL-3.0 Imports: 19 Imported by: 0

Documentation

Overview

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developers <dev@pallet.one> * * @date 2018-2019 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developers <dev@pallet.one> * * @date 2018-2019 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developers <dev@pallet.one> * * @date 2018-2019 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developers <dev@pallet.one> * * @date 2018-2019 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developers <dev@pallet.one> * * @date 2018-2019 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developers <dev@pallet.one> * * @date 2018-2019 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developer albert <dev@pallet.one> * * @date 2019-2020 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developers <dev@pallet.one> * * @date 2019-2020 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developers <dev@pallet.one> * * @date 2018-2019 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developer albert <dev@pallet.one> * * @date 2019-2020 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developer albert <dev@pallet.one> * * @date 2018-2019 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developer albert <dev@pallet.one> * * @date 2019-2020 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developer albert <dev@pallet.one> * * @date 2019-2020 *

* * This file is part of go-palletone. * go-palletone is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * go-palletone is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * You should have received a copy of the GNU General Public License * along with go-palletone. If not, see <http://www.gnu.org/licenses/>. * / * * * @author PalletOne core developers <dev@pallet.one> * * @date 2018-2019 *

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMigrations

func NewMigrations(db ptndb.Database) map[string]IMigration

func RenameKey

func RenameKey(db ptndb.Database, oldKey, newKey []byte) error

func RenamePrefix

func RenamePrefix(db ptndb.Database, oldPrefix, newPrefix []byte) error

Types

type ChainParameters100 added in v1.0.2

type ChainParameters100 struct {
	ChainParametersBase102delta

	DepositDailyReward string
	DepositPeriod      string

	UccMemory     string
	UccMemorySwap string
	UccCpuShares  string
	UccCpuQuota   string
	UccCpuPeriod  string

	TempUccMemory     string
	TempUccMemorySwap string
	TempUccCpuShares  string
	TempUccCpuQuota   string

	ContractSignatureNum string
	ContractElectionNum  string
}

type ChainParameters102delta added in v1.0.3

type ChainParameters102delta struct {
	ChainParametersBase102delta

	UccMemory    string
	UccCpuShares string
	UccCpuQuota  string
	UccDisk      string

	TempUccMemory    string
	TempUccCpuShares string
	TempUccCpuQuota  string

	ContractSignatureNum string
	ContractElectionNum  string

	ContractTxTimeoutUnitFee string
	ContractTxSizeUnitFee    string

	ContractTxInstallFeeLevel string
	ContractTxDeployFeeLevel  string
	ContractTxInvokeFeeLevel  string
	ContractTxStopFeeLevel    string
}

type ChainParameters104alpha added in v1.0.4

type ChainParameters104alpha struct {
	core.ChainParametersBase

	UccMemory                 string
	UccCpuShares              string
	UccCpuQuota               string
	UccDisk                   string
	UccDuringTime             string
	TempUccMemory             string
	TempUccCpuShares          string
	TempUccCpuQuota           string
	ContractSystemVersion     string
	ContractSignatureNum      string
	ContractElectionNum       string
	ContractTxTimeoutUnitFee  string
	ContractTxSizeUnitFee     string
	ContractTxInstallFeeLevel string
	ContractTxDeployFeeLevel  string
	ContractTxInvokeFeeLevel  string
	ContractTxStopFeeLevel    string
}

type ChainParametersBase102delta added in v1.0.3

type ChainParametersBase102delta struct {
	GenerateUnitReward uint64 `json:"generate_unit_reward"` //每生产一个单元,奖励多少Dao的PTN
	PledgeDailyReward  uint64 `json:"pledge_daily_reward"`  //质押金的日奖励额
	RewardHeight       uint64 `json:"reward_height"`        //每多少高度进行一次奖励的派发
	UnitMaxSize        uint64 `json:"unit_max_size"`        //一个单元最大允许多大
	FoundationAddress  string `json:"foundation_address"`   //基金会地址,该地址具有一些特殊权限,比如发起参数修改的投票,发起罚没保证金等

	DepositAmountForMediator  uint64 `json:"deposit_amount_for_mediator"` //保证金的数量
	DepositAmountForJury      uint64 `json:"deposit_amount_for_jury"`
	DepositAmountForDeveloper uint64 `json:"deposit_amount_for_developer"`

	// 活跃mediator的数量。 number of active mediators
	ActiveMediatorCount uint8 `json:"active_mediator_count"`

	// 用户可投票mediator的最大数量。the maximum number of mediator users can vote for
	MaximumMediatorCount uint8 `json:"max_mediator_count"`

	// unit生产之间的间隔时间,以秒为单元。 interval in seconds between Units
	MediatorInterval uint8 `json:"mediator_interval"`

	// 区块链维护事件之间的间隔,以秒为单元。 interval in sections between unit maintenance events
	MaintenanceInterval uint32 `json:"maintenance_interval"`

	// 在维护时跳过的MediatorInterval数量。 number of MediatorInterval to skip at maintenance time
	MaintenanceSkipSlots uint8 `json:"maintenance_skip_slots"`

	// 目前的操作交易费,current schedule of fees
	MediatorCreateFee        uint64 `json:"mediator_create_fee"`
	AccountUpdateFee         uint64 `json:"account_update_fee"`
	TransferPtnBaseFee       uint64 `json:"transfer_ptn_base_fee"`
	TransferPtnPricePerKByte uint64 `json:"transfer_ptn_price_per_KByte"`
}

type DynamicGlobalProperty103beta added in v1.0.3

type DynamicGlobalProperty103beta struct {
	LastMediator       common.Address // 最新单元的生产 mediator
	IsShuffledSchedule bool           // 标记 mediator 的调度顺序是否刚被打乱

	NextMaintenanceTime uint32 // 下一次系统维护时间
	LastMaintenanceTime uint32 // 上一次系统维护时间

	CurrentASlot uint64

	RecentSlotsFilled uint64

	MaintenanceFlag bool
}

type DynamicGlobalProperty105delta added in v1.0.5

type DynamicGlobalProperty105delta struct {
	LastMediator        common.Address
	IsShuffledSchedule  bool
	NextMaintenanceTime uint32
	LastMaintenanceTime uint32
	CurrentASlot        uint64
	RecentSlotsFilled   Uint128_105delta
	MaintenanceFlag     bool
}

type GlobalPropBase100 added in v1.0.2

type GlobalPropBase100 struct {
	ImmutableParameters ImmutableChainParameters101 // 不可改变的区块链网络参数
	ChainParameters     ChainParameters100          // 区块链网络参数
}

type GlobalPropBase101 added in v1.0.2

type GlobalPropBase101 struct {
	ImmutableParameters ImmutableChainParameters101 // 不可改变的区块链网络参数
	ChainParameters     ChainParameters102delta     // 区块链网络参数
}

type GlobalPropBase102delta added in v1.0.3

type GlobalPropBase102delta struct {
	ImmutableParameters core.ImmutableChainParameters // 不可改变的区块链网络参数
	ChainParameters     ChainParameters102delta       // 区块链网络参数
}

type GlobalPropBase104alpha added in v1.0.4

type GlobalPropBase104alpha struct {
	ImmutableParameters core.ImmutableChainParameters // 不可改变的区块链网络参数
	ChainParametersTemp ChainParameters104alpha       // 区块链网络参数
}

type GlobalPropExtra105delta added in v1.0.5

type GlobalPropExtra105delta struct {
	ActiveJuries       []common.Address
	ActiveMediators    []common.Address
	PrecedingMediators []common.Address
}

type GlobalProperty100 added in v1.0.2

type GlobalProperty100 struct {
	GlobalPropBase100

	ActiveJuries       []common.Address
	ActiveMediators    []common.Address
	PrecedingMediators []common.Address
}

type GlobalProperty101 added in v1.0.2

type GlobalProperty101 struct {
	GlobalPropBase101

	ActiveJuries       []common.Address
	ActiveMediators    []common.Address
	PrecedingMediators []common.Address
}

type GlobalProperty102delta added in v1.0.3

type GlobalProperty102delta struct {
	GlobalPropBase102delta
	ActiveJuries       []common.Address
	ActiveMediators    []common.Address
	PrecedingMediators []common.Address
}

type GlobalProperty104alpha added in v1.0.4

type GlobalProperty104alpha struct {
	GlobalPropBase104alpha

	ActiveJuries       []common.Address
	ActiveMediators    []common.Address
	PrecedingMediators []common.Address
}

type GlobalProperty105delta added in v1.0.5

type GlobalProperty105delta struct {
	modules.GlobalPropBaseTemp
	GlobalPropExtra105delta
}

type IMigration

type IMigration interface {
	FromVersion() string
	ToVersion() string
	ExecuteUpgrade() error
}

type ImmutableChainParameters101 added in v1.0.2

type ImmutableChainParameters101 struct {
	MinimumMediatorCount uint8    `json:"min_mediator_count"`    // 最小活跃mediator数量
	MinMediatorInterval  uint8    `json:"min_mediator_interval"` // 最小的生产槽间隔时间
	UccPrivileged        bool     `json:"ucc_privileged"`        // 防止容器以root权限运行
	UccCapDrop           []string `json:"ucc_cap_drop"`          // 确保容器以最小权限运行
	UccNetworkMode       string   `json:"ucc_network_mode"`      // 容器运行网络模式
	UccOOMKillDisable    bool     `json:"ucc_oom_kill_disable"`  // 是否内存使用量超过上限时系统杀死进程
}

type MediatorApplyInfo100 added in v1.0.2

type MediatorApplyInfo100 struct {
	ApplyInfo string `json:"applyInfo"` //  申请信息
}

type MediatorInfo100 added in v1.0.2

type MediatorInfo101 added in v1.0.2

type MediatorInfo105alpha added in v1.0.5

type MediatorInfoBase101 added in v1.0.2

type MediatorInfoBase101 struct {
	AddStr     string `json:"account"`    // mediator账户地址
	InitPubKey string `json:"initPubKey"` // mediator的群签名初始公钥
	Node       string `json:"node"`       // mediator节点网络信息,包括ip和端口等
}

type Migration100_101 added in v1.0.1

type Migration100_101 struct {
	// contains filtered or unexported fields
}

func NewMigration100_101 added in v1.0.1

func NewMigration100_101(db ptndb.Database) *Migration100_101

func (*Migration100_101) ExecuteUpgrade added in v1.0.1

func (m *Migration100_101) ExecuteUpgrade() error

func (*Migration100_101) FromVersion added in v1.0.1

func (m *Migration100_101) FromVersion() string

func (*Migration100_101) ToVersion added in v1.0.1

func (m *Migration100_101) ToVersion() string

type Migration101_102 added in v1.0.2

type Migration101_102 struct {
	// contains filtered or unexported fields
}

func NewMigration101_102 added in v1.0.2

func NewMigration101_102(db ptndb.Database) *Migration101_102

func (*Migration101_102) ExecuteUpgrade added in v1.0.2

func (m *Migration101_102) ExecuteUpgrade() error

func (*Migration101_102) FromVersion added in v1.0.2

func (m *Migration101_102) FromVersion() string

func (*Migration101_102) ToVersion added in v1.0.2

func (m *Migration101_102) ToVersion() string

type Migration102beta_102gamma added in v1.0.2

type Migration102beta_102gamma struct {
	// contains filtered or unexported fields
}

func NewMigration102beta_102gamma added in v1.0.2

func NewMigration102beta_102gamma(db ptndb.Database) *Migration102beta_102gamma

func (*Migration102beta_102gamma) ExecuteUpgrade added in v1.0.2

func (m *Migration102beta_102gamma) ExecuteUpgrade() error

func (*Migration102beta_102gamma) FromVersion added in v1.0.2

func (m *Migration102beta_102gamma) FromVersion() string

func (*Migration102beta_102gamma) ToVersion added in v1.0.2

func (m *Migration102beta_102gamma) ToVersion() string

type Migration102delta_103alpha added in v1.0.3

type Migration102delta_103alpha struct {
	// contains filtered or unexported fields
}

func NewMigration102delta_103alpha added in v1.0.3

func NewMigration102delta_103alpha(db ptndb.Database) *Migration102delta_103alpha

func (*Migration102delta_103alpha) ExecuteUpgrade added in v1.0.3

func (m *Migration102delta_103alpha) ExecuteUpgrade() error

func (*Migration102delta_103alpha) FromVersion added in v1.0.3

func (m *Migration102delta_103alpha) FromVersion() string

func (*Migration102delta_103alpha) ToVersion added in v1.0.3

func (m *Migration102delta_103alpha) ToVersion() string

type Migration102gamma_102delta added in v1.0.2

type Migration102gamma_102delta struct {
	// contains filtered or unexported fields
}

func NewMigration102gamma_102delta added in v1.0.2

func NewMigration102gamma_102delta(db ptndb.Database) *Migration102gamma_102delta

func (*Migration102gamma_102delta) ExecuteUpgrade added in v1.0.2

func (m *Migration102gamma_102delta) ExecuteUpgrade() error

func (*Migration102gamma_102delta) FromVersion added in v1.0.2

func (m *Migration102gamma_102delta) FromVersion() string

func (*Migration102gamma_102delta) ToVersion added in v1.0.2

func (m *Migration102gamma_102delta) ToVersion() string

type Migration103alpha_103beta added in v1.0.3

type Migration103alpha_103beta struct {
	// contains filtered or unexported fields
}

func NewMigration103alpha_103beta added in v1.0.3

func NewMigration103alpha_103beta(db ptndb.Database) *Migration103alpha_103beta

func (*Migration103alpha_103beta) ExecuteUpgrade added in v1.0.3

func (m *Migration103alpha_103beta) ExecuteUpgrade() error

func (*Migration103alpha_103beta) FromVersion added in v1.0.3

func (m *Migration103alpha_103beta) FromVersion() string

func (*Migration103alpha_103beta) ToVersion added in v1.0.3

func (m *Migration103alpha_103beta) ToVersion() string

type Migration103beta_103gamma added in v1.0.3

type Migration103beta_103gamma struct {
	// contains filtered or unexported fields
}

func NewMigration103beta_103gamma added in v1.0.3

func NewMigration103beta_103gamma(db ptndb.Database) *Migration103beta_103gamma

func (*Migration103beta_103gamma) ExecuteUpgrade added in v1.0.3

func (m *Migration103beta_103gamma) ExecuteUpgrade() error

func (*Migration103beta_103gamma) FromVersion added in v1.0.3

func (m *Migration103beta_103gamma) FromVersion() string

func (*Migration103beta_103gamma) ToVersion added in v1.0.3

func (m *Migration103beta_103gamma) ToVersion() string

type Migration104alpha_104beta added in v1.0.4

type Migration104alpha_104beta struct {
	// contains filtered or unexported fields
}

func NewMigration104alpha_104beta added in v1.0.4

func NewMigration104alpha_104beta(db ptndb.Database) *Migration104alpha_104beta

func (*Migration104alpha_104beta) ExecuteUpgrade added in v1.0.4

func (m *Migration104alpha_104beta) ExecuteUpgrade() error

func (*Migration104alpha_104beta) FromVersion added in v1.0.4

func (m *Migration104alpha_104beta) FromVersion() string

func (*Migration104alpha_104beta) ToVersion added in v1.0.4

func (m *Migration104alpha_104beta) ToVersion() string

type Migration104beta_105alpha added in v1.0.5

type Migration104beta_105alpha struct {
	// contains filtered or unexported fields
}

func NewMigration104beta_105alpha added in v1.0.5

func NewMigration104beta_105alpha(db ptndb.Database) *Migration104beta_105alpha

func (*Migration104beta_105alpha) ExecuteUpgrade added in v1.0.5

func (m *Migration104beta_105alpha) ExecuteUpgrade() error

func (*Migration104beta_105alpha) FromVersion added in v1.0.5

func (m *Migration104beta_105alpha) FromVersion() string

func (*Migration104beta_105alpha) ToVersion added in v1.0.5

func (m *Migration104beta_105alpha) ToVersion() string

type Migration105alpha_105beta added in v1.0.5

type Migration105alpha_105beta struct {
	// contains filtered or unexported fields
}

func NewMigration105alpha_105beta added in v1.0.5

func NewMigration105alpha_105beta(db ptndb.Database) *Migration105alpha_105beta

func (*Migration105alpha_105beta) ExecuteUpgrade added in v1.0.5

func (m *Migration105alpha_105beta) ExecuteUpgrade() error

func (*Migration105alpha_105beta) FromVersion added in v1.0.5

func (m *Migration105alpha_105beta) FromVersion() string

func (*Migration105alpha_105beta) ToVersion added in v1.0.5

func (m *Migration105alpha_105beta) ToVersion() string

type Migration105beta_105gamma added in v1.0.5

type Migration105beta_105gamma struct {
	// contains filtered or unexported fields
}

func NewMigration105beta_105gamma added in v1.0.5

func NewMigration105beta_105gamma(db ptndb.Database) *Migration105beta_105gamma

func (*Migration105beta_105gamma) ExecuteUpgrade added in v1.0.5

func (m *Migration105beta_105gamma) ExecuteUpgrade() error

func (*Migration105beta_105gamma) FromVersion added in v1.0.5

func (m *Migration105beta_105gamma) FromVersion() string

func (*Migration105beta_105gamma) ToVersion added in v1.0.5

func (m *Migration105beta_105gamma) ToVersion() string

type Migration105delta_105rc1 added in v1.0.5

type Migration105delta_105rc1 struct {
	// contains filtered or unexported fields
}

func NewMigration105delta_105rc1 added in v1.0.5

func NewMigration105delta_105rc1(db ptndb.Database) *Migration105delta_105rc1

func (*Migration105delta_105rc1) ExecuteUpgrade added in v1.0.5

func (m *Migration105delta_105rc1) ExecuteUpgrade() error

func (*Migration105delta_105rc1) FromVersion added in v1.0.5

func (m *Migration105delta_105rc1) FromVersion() string

func (*Migration105delta_105rc1) ToVersion added in v1.0.5

func (m *Migration105delta_105rc1) ToVersion() string

type Migration105gamma_105delta added in v1.0.5

type Migration105gamma_105delta struct {
	// contains filtered or unexported fields
}

func NewMigration105gamma_105delta added in v1.0.5

func NewMigration105gamma_105delta(db ptndb.Database) *Migration105gamma_105delta

func (*Migration105gamma_105delta) ExecuteUpgrade added in v1.0.5

func (m *Migration105gamma_105delta) ExecuteUpgrade() error

func (*Migration105gamma_105delta) FromVersion added in v1.0.5

func (m *Migration105gamma_105delta) FromVersion() string

func (*Migration105gamma_105delta) ToVersion added in v1.0.5

func (m *Migration105gamma_105delta) ToVersion() string

type NewContract added in v1.0.5

type NewContract struct {
	// 根据用户创建合约实例申请的RequestId截取其后20字节生成
	ContractId   []byte
	TemplateId   []byte
	Name         string
	Status       byte   // 合约状态
	Creator      []byte // address 20bytes
	CreationTime uint64 // creation  date
	DuringTime   uint64 //合约部署持续时间,单位秒
	Version      string
}

type NothingMigration

type NothingMigration struct {
	// contains filtered or unexported fields
}

如果从一个版本升级到另一个版本,数据库不需要做任何更改时,使用该实例

func NewNothingMigration

func NewNothingMigration(from, to string) *NothingMigration

func (*NothingMigration) ExecuteUpgrade

func (m *NothingMigration) ExecuteUpgrade() error

func (*NothingMigration) FromVersion

func (m *NothingMigration) FromVersion() string

func (*NothingMigration) ToVersion

func (m *NothingMigration) ToVersion() string

type OldContract added in v1.0.5

type OldContract struct {
	// 根据用户创建合约实例申请的RequestId截取其后20字节生成
	ContractId   []byte
	TemplateId   []byte
	Name         string
	Status       byte   // 合约状态
	Creator      []byte // address 20bytes
	CreationTime uint64 // creation  date
	DuringTime   uint64 //合约部署持续时间,单位秒
}

type Uint128_105delta added in v1.0.5

type Uint128_105delta struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL