When creating tables, if you have to select a column type that does not exist in your own database, you should consider alternatives. For example, as specified in the table below, it is recommended to use ‘CLOB’ instead of ‘LONGTEXT’ in Oracle. You should make the correct choice considering your application’s needs and existing database configuration.
Unsent Message
Copy
CREATE TABLE UnsentMessage (
id VARCHAR(255) PRIMARY KEY,
created TIMESTAMP,
connectorId VARCHAR(50),
content LONGTEXT
);
Audit Event
Copy
CREATE TABLE AuditEvent (
id VARCHAR(255) PRIMARY KEY,
auditEventDate TIMESTAMP,
principal VARCHAR(255),
state VARCHAR(255),
objectId VARCHAR(255),
objectName VARCHAR(255),
referenceObjectJson LONGTEXT,
projectId VARCHAR(255),
className VARCHAR(255)
);
Application Log
Copy
CREATE TABLE ApplicationLog (
id VARCHAR(255) PRIMARY KEY,
env_name VARCHAR(255),
api_proxy_id VARCHAR(255),
api_proxy_name VARCHAR(255),
correlation_id VARCHAR(255),
created TIMESTAMP,
level VARCHAR(255),
message TEXT,
stack_trace TEXT,
host_name VARCHAR(255),
enum_application_log VARCHAR(255),
total_duration INT
);
Token Traffic Log
Copy
CREATE TABLE ApiProxyTokenTrafficLog (
id VARCHAR(255) PRIMARY KEY,
created TIMESTAMP,
apinizerCorrelationId VARCHAR(255),
environmentId VARCHAR(255),
projectId VARCHAR(255),
applicationId VARCHAR(255),
applicationName VARCHAR(255),
apiProxyId VARCHAR(255),
apiProxyName VARCHAR(255),
xForwardedFor VARCHAR(255),
httpRequestRemoteAddress VARCHAR(255),
httpRequestHttpMethod VARCHAR(255),
httpRequestContentType VARCHAR(255),
usernameOrKey VARCHAR(255),
timeTotal INTEGER,
statusCode INTEGER,
errorType VARCHAR(255),
parentErrorType VARCHAR(255),
resultType VARCHAR(255),
toClientHeader TEXT,
toClientBody TEXT,
authTokenType VARCHAR(255),
audience VARCHAR(255),
clientInfo VARCHAR(255),
tokenNeverExpires BOOLEAN,
issuedAt TIMESTAMP,
expiresAt TIMESTAMP,
expiresIn INTEGER,
scope VARCHAR(255),
refreshTokenAllowed BOOLEAN,
refreshTokenIssuedAt TIMESTAMP,
refreshTokenExpiresAt TIMESTAMP,
refreshTokenExpiresIn INTEGER,
refreshCount INTEGER,
maxRefreshCount INTEGER
);
Api Proxy Traffic Log
Copy
CREATE TABLE ApiProxyTrafficLog (
id VARCHAR(255) PRIMARY KEY,
created TIMESTAMP,
apinizer_correlation_id VARCHAR(255),
environment_id VARCHAR(255),
project_id VARCHAR(255),
application_id VARCHAR(255),
application_name VARCHAR(255),
api_proxy_id VARCHAR(255),
api_proxy_name VARCHAR(255),
enum_api_type VARCHAR(255),
api_proxy_relative_path VARCHAR(255),
api_proxy_method_id VARCHAR(255),
api_proxy_method_name VARCHAR(255),
x_forwarded_for VARCHAR(255),
username_or_key VARCHAR(255),
http_request_context_path VARCHAR(255),
http_request_remote_address VARCHAR(255),
http_request_http_method VARCHAR(255),
http_request_content_type VARCHAR(255),
http_request_path_info VARCHAR(255),
http_request_query_string VARCHAR(255),
http_request_remote_user VARCHAR(255),
http_request_requested_session_id VARCHAR(255),
http_request_request_uri VARCHAR(255),
http_request_character_encoding VARCHAR(255),
http_request_content_length INTEGER,
http_request_protocol VARCHAR(255),
http_request_scheme VARCHAR(255),
http_request_server_name VARCHAR(255),
http_request_server_port INTEGER,
http_request_remote_host VARCHAR(255),
http_request_remote_port INTEGER,
http_request_local_name VARCHAR(255),
http_request_local_addr VARCHAR(255),
http_request_local_port INTEGER,
from_client_read_only_parameter TEXT,
from_client_read_only_header TEXT,
from_client_read_only_body LONGTEXT,
to_backend_api_parameter TEXT,
to_backend_api_header TEXT,
to_backend_api_body LONGTEXT,
routing_address VARCHAR(255),
routing_retry_count INTEGER,
routing_failover_count INTEGER,
from_backend_api_read_only_header TEXT,
from_backend_api_read_only_body LONGTEXT,
to_client_header TEXT,
to_client_body LONGTEXT,
time_request_pipeline_total INTEGER,
time_response_pipeline_total INTEGER,
time_routing_total INTEGER,
time_api_proxy_total INTEGER,
size_request_total INTEGER,
size_response_total INTEGER,
cache_hit BOOLEAN,
status_code INTEGER,
error_type VARCHAR(255),
parent_error_type VARCHAR(255),
result_type VARCHAR(255),
location_lat DOUBLE,
location_lon DOUBLE
);

