mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Remove useless debug instrumentation row_print_geometry_data
This commit is contained in:
@ -1,21 +1,5 @@
|
|||||||
SET default_storage_engine=InnoDB;
|
SET default_storage_engine=InnoDB;
|
||||||
SET innodb_strict_mode=OFF;
|
SET innodb_strict_mode=OFF;
|
||||||
SET SESSION debug="+d,row_print_geometry_data";
|
|
||||||
SHOW VARIABLES LIKE '%engine%';
|
|
||||||
Variable_name Value
|
|
||||||
default_storage_engine InnoDB
|
|
||||||
default_tmp_storage_engine InnoDB
|
|
||||||
disabled_storage_engines
|
|
||||||
internal_tmp_disk_storage_engine InnoDB
|
|
||||||
USE test;
|
|
||||||
DROP TABLE IF EXISTS t1, gis_point, gis_line, gis_polygon;
|
|
||||||
DROP TABLE IF EXISTS gis_multi_point, gis_multi_line, gis_multi_polygon;
|
|
||||||
DROP TABLE IF EXISTS gis_geometrycollection, gis_geometry;
|
|
||||||
DROP TABLE IF EXISTS tab,tab2,tab3,parent,emp2;
|
|
||||||
DROP PROCEDURE IF EXISTS geominout;
|
|
||||||
DROP PROCEDURE IF EXISTS geom_insert;
|
|
||||||
DROP TRIGGER IF EXISTS geom_trigger;
|
|
||||||
DROP PROCEDURE IF EXISTS geom_cursor;
|
|
||||||
CREATE TABLE gis_point (fid INTEGER NOT NULL PRIMARY KEY, g POINT) ENGINE=InnoDB;
|
CREATE TABLE gis_point (fid INTEGER NOT NULL PRIMARY KEY, g POINT) ENGINE=InnoDB;
|
||||||
CREATE TABLE gis_line (fid INTEGER NOT NULL PRIMARY KEY, g LINESTRING) ENGINE=InnoDB;
|
CREATE TABLE gis_line (fid INTEGER NOT NULL PRIMARY KEY, g LINESTRING) ENGINE=InnoDB;
|
||||||
CREATE TABLE gis_polygon (fid INTEGER NOT NULL PRIMARY KEY, g POLYGON) ENGINE=InnoDB;
|
CREATE TABLE gis_polygon (fid INTEGER NOT NULL PRIMARY KEY, g POLYGON) ENGINE=InnoDB;
|
||||||
@ -1136,15 +1120,10 @@ COMMIT;
|
|||||||
SELECT COUNT(*) FROM tab3;
|
SELECT COUNT(*) FROM tab3;
|
||||||
COUNT(*)
|
COUNT(*)
|
||||||
0
|
0
|
||||||
DROP TABLE IF EXISTS gis_point, gis_line, gis_polygon, gis_multi_point;
|
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point;
|
||||||
DROP TABLE IF EXISTS gis_multi_line, gis_multi_polygon;
|
DROP TABLE gis_multi_line, gis_multi_polygon;
|
||||||
DROP TABLE IF EXISTS gis_geometrycollection, gis_geometry;
|
DROP TABLE gis_geometrycollection, gis_geometry;
|
||||||
DROP TABLE IF EXISTS tab,tab2,tab3,parent,emp2;
|
DROP TABLE tab,tab2,tab3,parent;
|
||||||
Warnings:
|
DROP PROCEDURE geominout;
|
||||||
Note 1051 Unknown table 'test.emp2'
|
DROP PROCEDURE geom_insert;
|
||||||
DROP PROCEDURE IF EXISTS geominout;
|
DROP PROCEDURE geom_cursor;
|
||||||
DROP PROCEDURE IF EXISTS geom_insert;
|
|
||||||
DROP TRIGGER IF EXISTS geom_trigger;
|
|
||||||
Warnings:
|
|
||||||
Note 1360 Trigger does not exist
|
|
||||||
DROP PROCEDURE IF EXISTS geom_cursor;
|
|
||||||
|
@ -1,6 +1,3 @@
|
|||||||
SET SESSION debug="+d,row_print_geometry_data";
|
|
||||||
Warnings:
|
|
||||||
Warning 1287 '@@debug' is deprecated and will be removed in a future release. Please use '@@debug_dbug' instead
|
|
||||||
CREATE TABLE t_wl6455 ( i INT, g GEOMETRY NOT NULL) ENGINE=InnoDB;
|
CREATE TABLE t_wl6455 ( i INT, g GEOMETRY NOT NULL) ENGINE=InnoDB;
|
||||||
SHOW CREATE TABLE t_wl6455;
|
SHOW CREATE TABLE t_wl6455;
|
||||||
Table Create Table
|
Table Create Table
|
||||||
|
@ -9,37 +9,15 @@
|
|||||||
# All Geometric functions.
|
# All Geometric functions.
|
||||||
#********************************************************
|
#********************************************************
|
||||||
--source include/have_geometry.inc
|
--source include/have_geometry.inc
|
||||||
--source include/not_embedded.inc
|
|
||||||
--source include/have_debug.inc
|
|
||||||
--source include/have_innodb.inc
|
--source include/have_innodb.inc
|
||||||
|
|
||||||
SET default_storage_engine=InnoDB;
|
SET default_storage_engine=InnoDB;
|
||||||
SET innodb_strict_mode=OFF;
|
SET innodb_strict_mode=OFF;
|
||||||
|
|
||||||
# Turn on the geometry data print.
|
|
||||||
SET SESSION debug="+d,row_print_geometry_data";
|
|
||||||
|
|
||||||
SHOW VARIABLES LIKE '%engine%';
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Spatial objects
|
# Spatial objects
|
||||||
#
|
#
|
||||||
|
|
||||||
USE test;
|
|
||||||
|
|
||||||
--disable_warnings
|
|
||||||
DROP TABLE IF EXISTS t1, gis_point, gis_line, gis_polygon;
|
|
||||||
DROP TABLE IF EXISTS gis_multi_point, gis_multi_line, gis_multi_polygon;
|
|
||||||
DROP TABLE IF EXISTS gis_geometrycollection, gis_geometry;
|
|
||||||
DROP TABLE IF EXISTS tab,tab2,tab3,parent,emp2;
|
|
||||||
DROP PROCEDURE IF EXISTS geominout;
|
|
||||||
DROP PROCEDURE IF EXISTS geom_insert;
|
|
||||||
DROP TRIGGER IF EXISTS geom_trigger;
|
|
||||||
DROP PROCEDURE IF EXISTS geom_cursor;
|
|
||||||
|
|
||||||
|
|
||||||
--enable_warnings
|
|
||||||
|
|
||||||
CREATE TABLE gis_point (fid INTEGER NOT NULL PRIMARY KEY, g POINT) ENGINE=InnoDB;
|
CREATE TABLE gis_point (fid INTEGER NOT NULL PRIMARY KEY, g POINT) ENGINE=InnoDB;
|
||||||
CREATE TABLE gis_line (fid INTEGER NOT NULL PRIMARY KEY, g LINESTRING) ENGINE=InnoDB;
|
CREATE TABLE gis_line (fid INTEGER NOT NULL PRIMARY KEY, g LINESTRING) ENGINE=InnoDB;
|
||||||
CREATE TABLE gis_polygon (fid INTEGER NOT NULL PRIMARY KEY, g POLYGON) ENGINE=InnoDB;
|
CREATE TABLE gis_polygon (fid INTEGER NOT NULL PRIMARY KEY, g POLYGON) ENGINE=InnoDB;
|
||||||
@ -694,11 +672,10 @@ COMMIT;
|
|||||||
|
|
||||||
SELECT COUNT(*) FROM tab3;
|
SELECT COUNT(*) FROM tab3;
|
||||||
|
|
||||||
DROP TABLE IF EXISTS gis_point, gis_line, gis_polygon, gis_multi_point;
|
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point;
|
||||||
DROP TABLE IF EXISTS gis_multi_line, gis_multi_polygon;
|
DROP TABLE gis_multi_line, gis_multi_polygon;
|
||||||
DROP TABLE IF EXISTS gis_geometrycollection, gis_geometry;
|
DROP TABLE gis_geometrycollection, gis_geometry;
|
||||||
DROP TABLE IF EXISTS tab,tab2,tab3,parent,emp2;
|
DROP TABLE tab,tab2,tab3,parent,emp2;
|
||||||
DROP PROCEDURE IF EXISTS geominout;
|
DROP PROCEDURE geominout;
|
||||||
DROP PROCEDURE IF EXISTS geom_insert;
|
DROP PROCEDURE geom_insert;
|
||||||
DROP TRIGGER IF EXISTS geom_trigger;
|
DROP PROCEDURE geom_cursor;
|
||||||
DROP PROCEDURE IF EXISTS geom_cursor;
|
|
||||||
|
@ -6,13 +6,6 @@
|
|||||||
# Restarting is not supported in embedded
|
# Restarting is not supported in embedded
|
||||||
--source include/not_embedded.inc
|
--source include/not_embedded.inc
|
||||||
--source include/have_innodb.inc
|
--source include/have_innodb.inc
|
||||||
--source include/have_debug.inc
|
|
||||||
|
|
||||||
# Avoid CrashReporter popup on Mac
|
|
||||||
--source include/not_crashrep.inc
|
|
||||||
|
|
||||||
# Turn on the geometry data print.
|
|
||||||
SET SESSION debug="+d,row_print_geometry_data";
|
|
||||||
|
|
||||||
# Test GEOMETRY datatype.
|
# Test GEOMETRY datatype.
|
||||||
CREATE TABLE t_wl6455 ( i INT, g GEOMETRY NOT NULL) ENGINE=InnoDB;
|
CREATE TABLE t_wl6455 ( i INT, g GEOMETRY NOT NULL) ENGINE=InnoDB;
|
||||||
|
@ -306,29 +306,6 @@ row_mysql_store_geometry(
|
|||||||
mach_write_to_n_little_endian(dest, dest_len - 8, src_len);
|
mach_write_to_n_little_endian(dest, dest_len - 8, src_len);
|
||||||
|
|
||||||
memcpy(dest + dest_len - 8, &src, sizeof src);
|
memcpy(dest + dest_len - 8, &src, sizeof src);
|
||||||
|
|
||||||
DBUG_EXECUTE_IF("row_print_geometry_data",
|
|
||||||
{
|
|
||||||
String res;
|
|
||||||
Geometry_buffer buffer;
|
|
||||||
String wkt;
|
|
||||||
|
|
||||||
/** Show the meaning of geometry data. */
|
|
||||||
Geometry* g = Geometry::construct(
|
|
||||||
&buffer, (const char*)src, (uint32) src_len);
|
|
||||||
|
|
||||||
if (g)
|
|
||||||
{
|
|
||||||
/*
|
|
||||||
if (g->as_wkt(&wkt) == 0)
|
|
||||||
{
|
|
||||||
ib::info() << "Write geometry data to"
|
|
||||||
" MySQL WKT format: "
|
|
||||||
<< wkt.c_ptr_safe() << ".";
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*******************************************************************//**
|
/*******************************************************************//**
|
||||||
@ -349,29 +326,6 @@ row_mysql_read_geometry(
|
|||||||
|
|
||||||
memcpy(&data, ref + col_len - 8, sizeof data);
|
memcpy(&data, ref + col_len - 8, sizeof data);
|
||||||
|
|
||||||
DBUG_EXECUTE_IF("row_print_geometry_data",
|
|
||||||
{
|
|
||||||
String res;
|
|
||||||
Geometry_buffer buffer;
|
|
||||||
String wkt;
|
|
||||||
|
|
||||||
/** Show the meaning of geometry data. */
|
|
||||||
Geometry* g = Geometry::construct(
|
|
||||||
&buffer, (const char*) data, (uint32) *len);
|
|
||||||
|
|
||||||
if (g)
|
|
||||||
{
|
|
||||||
/*
|
|
||||||
if (g->as_wkt(&wkt) == 0)
|
|
||||||
{
|
|
||||||
ib::info() << "Read geometry data in"
|
|
||||||
" MySQL's WKT format: "
|
|
||||||
<< wkt.c_ptr_safe() << ".";
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
return(data);
|
return(data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user