pinpoint
pinpoint copied to clipboard
How can I upgrade pinpoint from 1.8.3 to 2.4.0
Prerequisites
What version of pinpoint are you using? 1.8.3
How can I upgrade pinpoint from 1.8.3 to 2.4.0?
What you mean? care you to be more specific?
I currently use version 1.8.3, 1.8.3 is not very good for K8S container support, I need to upgrade the pinpoint to 2.3.0 or 2.4.0, but I have not seen the upgrade related documents, may I ask what I need to do if I want to upgrade.
Please approach as if you're reinstalling Pinpoint if you are upgrading from old versions (especially if it is the major version upgrade)
- Download images here: https://github.com/pinpoint-apm/pinpoint/releases
- See if your mysql and hbase schema is up-to-date (As far as I remember there has been schema updates for mysql and hbase?)
- https://github.com/pinpoint-apm/pinpoint/blob/master/hbase/scripts/hbase-create.hbase
- https://github.com/pinpoint-apm/pinpoint/blob/master/web/src/main/resources/sql/CreateTableStatement-mysql.sql
- Restart your agent, collector, and web with new images. See if this link helps: https://pinpoint-apm.gitbook.io/pinpoint/v/v2.4.0/getting-started/installation
I have compared the table structure of Hbase and MySQL. Hbase does not change from 1.8.x to 2.3.x. The differences in MySQL can be modified using scripts as follows:
use pinpoint;
DROP TABLE alarm_history;
CREATE TABLE `webhook` (
`webhook_id` INT UNSIGNED NOT NULL AUTO_INCREMENT,
`alias` VARCHAR(45) NULL,
`url` VARCHAR(45) NOT NULL,
`application_id` VARCHAR(45) NULL,
`service_name` VARCHAR(45) NULL,
PRIMARY KEY (`webhook_id`)
);
CREATE TABLE `webhook_send` (
`webhook_send_info_id` INT UNSIGNED NOT NULL AUTO_INCREMENT,
`webhook_id` INT UNSIGNED NOT NULL,
`rule_id` INT UNSIGNED NOT NULL,
PRIMARY KEY (`webhook_send_info_id`)
);
CREATE TABLE `alarm_history` (
`history_id` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
`rule_id` INT(10) UNSIGNED NOT NULL,
`application_id` VARCHAR(30) NOT NULL,
`checker_name` VARCHAR(50) NOT NULL,
`detected` CHAR(1) DEFAULT NULL,
`sequence_count` INT(10),
`timing_count` INT(10),
PRIMARY KEY (`history_id`)
);
alter table puser add phone_country_code int(10) NOT NULL DEFAULT '0';
alter table alarm_rule add webhook_send CHAR(1) DEFAULT NULL;
DROP INDEX application_id_checker_name_user_group_id_idx ON `alarm_rule`;
ALTER TABLE alarm_rule ADD INDEX application_id_checker_name_user_group_id_idx (application_id, user_group_id, checker_name);
ALTER TABLE alarm_history ADD INDEX application_id_checker_name_idx (application_id, checker_name);
Upgrade steps:
-
Update the mysql table structure
-
Deploy 2.3.x Pinpoint,web, Pinpoint collector, Pinpoint Batch
-
Update pinpoint agent(1.8.x agent and 2.3.x collector are compatible)