-
Notifications
You must be signed in to change notification settings - Fork 12
PowerAuth Push Server 0.21.0
PowerAuth Push Server documentation has been moved to: https://developers.wultra.com/docs/develop/powerauth-push-server/PowerAuth-Push-Server-0.21.0
Please use the new developer portal to access documentation.
This guide contains instructions for migration from PowerAuth Push Server version 0.19.0 to version 0.21.0.
Following DB changes occurred between version 0.19.0 and 0.21.0:
- Table
push_app_credentials
- added columnandroid_private_key
which contains the Firebase service account private key used when obtaining access tokens for FCM HTTP v1 API. - Table
push_app_credentials
- added columnandroid_project_id
which contains the Firebase project ID. - Table
push_app_credentials
- dropped columnandroid_server_key
which was used by legacy FCM HTTP API. - Table
push_app_credentials
- dropped columnandroid_bundle
which was replaced byandroid_project_id
.
Migration scripts are available for Oracle and MySQL.
DB migration script for Oracle:
--
-- Updated columns for FCM
--
ALTER TABLE PUSH_APP_CREDENTIALS ADD ANDROID_PRIVATE_KEY BLOB DEFAULT NULL;
ALTER TABLE PUSH_APP_CREDENTIALS ADD ANDROID_PROJECT_ID VARCHAR2(255) DEFAULT NULL;
ALTER TABLE PUSH_APP_CREDENTIALS DROP COLUMN ANDROID_SERVER_KEY;
ALTER TABLE PUSH_APP_CREDENTIALS DROP COLUMN ANDROID_BUNDLE;
DB migration script for MySQL:
--
-- Updated columns for FCM
--
alter table push_app_credentials add `android_private_key` blob DEFAULT NULL;
alter table push_app_credentials add `android_project_id` varchar(255) DEFAULT NULL;
alter table push_app_credentials drop column `android_server_key`;
alter table push_app_credentials drop column `android_bundle`;
DB migration script for Oracle and MySQL:
--
-- Dropped columns for legacy end-to-end encryption
--
ALTER TABLE PUSH_DEVICE_REGISTRATION DROP COLUMN ENCRYPTION_KEY;
ALTER TABLE PUSH_DEVICE_REGISTRATION DROP COLUMN ENCRYPTION_KEY_INDEX;
ALTER TABLE PUSH_MESSAGE DROP COLUMN IS_ENCRYPTED;
You can apply following database indexes to improve database performance of Push Server.
The DDL script is identical for all supported databases:
CREATE UNIQUE INDEX PUSH_APP_CRED_APP ON PUSH_APP_CREDENTIALS(APP_ID);
CREATE INDEX PUSH_DEVICE_APP_TOKEN ON PUSH_DEVICE_REGISTRATION(APP_ID, PUSH_TOKEN);
CREATE INDEX PUSH_DEVICE_USER_APP ON PUSH_DEVICE_REGISTRATION(USER_ID, APP_ID);
CREATE INDEX PUSH_DEVICE_ACTIVATION ON PUSH_DEVICE_REGISTRATION(ACTIVATION_ID);
CREATE INDEX PUSH_MESSAGE_STATUS ON PUSH_MESSAGE(STATUS);
CREATE INDEX PUSH_CAMPAIGN_SENT ON PUSH_CAMPAIGN(IS_SENT);
CREATE INDEX PUSH_CAMPAIGN_USER_CAMPAIGN ON PUSH_CAMPAIGN_USER(CAMPAIGN_ID, USER_ID);
CREATE INDEX PUSH_CAMPAIGN_USER_DETAIL ON PUSH_CAMPAIGN_USER(USER_ID);
Push server no longer stores sent push messages. You can enable storing of sent messages in database using following property:
powerauth.push.service.message.storage.enabled=true
Push server contains a new REST API which needs to be configured in case Push Server runs on non-standard port, non-standard context path or uses HTTPS. You can configure the service URL using following property:
powerauth.push.service.url=http://localhost:8080/powerauth-push-server
Push server started to use FCM HTTP API v1 in version 0.21.0.
The configuration parameters have changed for FCM HTTP API v1:
-
Private key
needs to be configured instead of server key (which was removed from configuration). -
Project ID
needs to be configured.
You can obtain both parameters from Firebase Console. The project ID is visible in Project Settings | General. The private key can be generated using Project Settings | Service Accounts | Firebase Admin SDK, as described in FCM documentation. Use the whole generated JSON file when configuring private key in Push server.
Deployment Tutorials
Integration Tutorials
Reference Manual
Technical Topics