sqlsim

package
v1.6.1 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2022 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var SimDMLFuncs = []func(report *task.BugReport, conn *connector.Connector) error{
	frmWith,
	rmUnion,
	frmHint,
	rmOrderBy,
	frmTimeFunc,
	frmStrFunc,
	frmInfoFunc,
	frmCharset,
}

do not adjust the order! must be synchronized!

Functions

func PrepareAndRunSqlSimTask

func PrepareAndRunSqlSimTask(taskConfigJsonPath string,
	waitGroup *sync.WaitGroup,
	conn *connector.Connector, connPool *connector.ConnectorPool)

func SimDML

func SimDML(bug *task.BugReport, conn *connector.Connector) error

func SqlSim

func SqlSim(conn *connector.Connector, outputPath string, ddlPath string, bugJsonPath string) error

SqlSim:

1. simplify dml: try to remove each node in original/mutated sql, simplify if the implication oracle can still detect the bug.

2. write the simplified ddl and bug(json+log) into sqlsim.

func SqlSimTask

func SqlSimTask(config *task.TaskConfig, publicConn *connector.Connector) error

SqlSimTask:

ckstable first!

1. mkdir sqlsim, read bugs and ddl in task path if exists, create connector

2. for each bug in bugs, simplify (ddl, bug) and save the result in sqlsim. see SqlSim.

Update: During affversion, we found that some new features cannot run on the old version of DBMS. We will try to simplify these new features in sqlsim. Actually, we will verify which features in ./resources/impo.yy can not run on mysql 5.0.15 (the oldest version in mysql download page: https://downloads.mysql.com/archives/community/), and try to remove them.

There are a lot of functions with prefix rm or frm in sqlsim.

- rm means it is a normal simplified function.

- frm means it is responsible for simplifying new features.

func SqlSimTaskPool

func SqlSimTaskPool(config *task.TaskPoolConfig, threadNum int) error

SqlSimTaskPool: like task and task pool, see SqlSimTask

Types

This section is empty.

Jump to

Keyboard shortcuts

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