Contains troubleshooting information
This article identifies the following issues that you might encounter and how to resolve them:
CA Live API Creatoris not working properly, you can:
- View the logs.
- View the logs for the container, such as Apache Tomcat or Jetty.
- (If the problem is client-only) Debug the browser issue.
For more information about how to resolve known error conditions, see Error Codes.
General Connection Issues
Contact CA Support to troubleshoot your connection issues. Include the following information:
- The main container log (catalina.outfor Tomcat, console output for the single-user version ofCA Live API Creator).
- The steps that you used to connect to the database.
- An export of the database, if possible.
You can encounter firewalls issues, particularly in large organizations. Verify that you can connect to the database from the machine hosting
CA Live API Creatorusing SQL Tools (for example, Toad, DbVisualizer, Razor, MySQL Workbench, and Microsoft SQL Server Management Studio).
MySQL SSL Exception
Recent versions of MySQL might require that you connect to a MySQL database using Secure Sockets Layer (SSL). The following error message indicates this requirement:
javax.net.ssl.SSLException: Unsupported record version Unknown-0.0
To avoid this error, add the following to the database URL (the
URLfield for the data source connection):
For more information about this field, see Database Connectivity.
Database Connects But No Tables - Ensure Active
CA Live API Creatorretrieves schema information only from active data sources.
CA Live API Creatorreads the metadata from the database schema or catalog. These metadata values must be correct for the connection to succeed and the tables to be populated.
For more information about how to mark a data source as active, see Database Connectivity.
Calling PostgreSQL Functions
PostgreSQL functions are not exposed as REST endpoints in
CA Live API Creator. This PostgreSQL JDBC driver limitation exposes inadequate information about the parameter datatypes to
CA Live API Creator.
External RESTFul Calls
If you are having issues invoking APIs from other servers, verify your URL and headers using REST tools, such as Postman or cURL.
For more information about how to debug using the
rest<verb>, see The SysUtility Object.
Schemas are cached in the Admin database, so a full load is only required initially, or when you refresh the schema. For large schemas, the initial load time might exceed the browser time-out time. In this case, an error appears, but the API Server continues the load process.
Reload API Creator in your browser, which loads the schema.
If you are continuing to have issues, contact CA Support.
Authentication Provider Not Set After Project Import
API Creator does not store the authentication provider in the
.jsonfile on export. Specify the authentication provider after you import your API.
For more information:
Named Filters gives SQL Error
The use of named filters allows creation of named parameter values to be used in place of column attributes. However, each database has its own rules on how to handle mixed case and quotes. Ensure that the column attribute names are in single quotes ('name'), double quotes ("name"), or back-ticks (`name`) based on Derby, MySQL, and Oracle requirements.
Connect to Large Schemas
For schemas that are more than several 100 tables, you might run into browser time-outs and heap errors. Browser timeouts reflect that the time to load the schema exceeded the browser timeout. To correct this issue, log in to API Creator again.
For heap errors, increase the heap size that is provided to the API Server. For example, in the single-user demonstration package of
CA Live API Creatorthat is based on Jetty, the Start command file (
) includes the following command:.bat
java -DSTOP.PORT=8123 -DSTOP.KEY=stop_caliveapicreator -jar ../start.jar $1 $2 $3 $4 $5 $6 $7 $8 $9
Change the command file to:
java-Xmx1024m-DSTOP.PORT=8123 <<< etc >>>
The default Java heap size is 256MB. We recommend a minimum of 512MB of heap and a maximum of 2GB.
For more information about the best practices for configuring your heap size, see Configuration Best Practices.
CA Live API Creatoron JDK 9 and Later
You can run
CA Live API Creatoron JDK 9 and later by passing the following option to the JVM:
For instance, if you use Tomcat, you can set the following environment variable before starting:
export CATALINA_OPTS="--add-modules java.xml.bind"
NullPointerException When Configuring MariaDB as My Admin Database with Apache Tomcat
The MariaDB JDBC driver version 1.5.6 has a bug which causes a NullPointerException RuntimeException. Use the version of the MariaDB JDBC driver that
CA Live API Creatorsupports.
For more information about the MariaDB JDBC driver version that
CA Live API Creatorsupports, see Installation Requirements and Supported Platforms.
You can log into API Creator, but then it becomes unresponsive
You might encounter this issue if you are running on an Amazon Linux instance. This issue is caused by the server name (as returned by the
hostnamecommand) not resolving properly to an IP address. This triggers the a known bug in some versions of Java, or possibly Linux kernel, which causes
InetAddress.getLocalHost().getHostName()to hang forever.
For more information about this bug, see the question Java DNS resolution hangs forever in StackOverflow.
You can fix this issue using
oneof the following methods:
- Use the following option on the Java command line:java -Djava.net.preferIPv4Stack=true ...
- Put the host name (as determined by thehostnamecommand) in the/etc/hostsfile, for example:127.0.0.1 localhost ip-12-34-56-78::1 localhost ip-12-34-56-78
If your machine does not have a fixed IP address, these methods are not a long-term solution.
There are many available methods to resolving this issue, some of which require expertise in Unix networking.
Monitor API Server Availability
You can check the health of your API Server and its availability using the
@heartbeatsystem REST endpoint. This endpoint retrieves API Server status.
For more information about this endpoint, see System REST Endpoints.
Data Explorer Does Not Show Tables
Ensure that you have logged on to API Creator as a user with at least one assigned role and the role has at least one table with read access. If you have changed your URL fragment or your API name, clear the internal API cache by switching to another API.
- In API Creator, on the APIs page, select a different API.
- Repeat the process selecting your original API.
CA Live API Creatorrebuilds the new URL endpoints.
Data Explorer Does Not Load Tables and Display Data
If you change the value of the
Metadata namefield on the Settings tab in API Creator, Data Explorer does not load tables and display data.
For more information about this setting, see API Properties.
API Docs - Swagger Not Showing After Import
API Creator includes the API Documentation role. You must be assigned this role, with access to read, insert, update, and delete. You can also allow the discovery of the API Swagger doc without authentication.
For more information about how to allow the discovery of the API Swagger doc without authentication, see API Properties.
Authentication Provider - Cannot Find Custom JS Library for Create Function
- On the APIs page, click theAuthentication Providerstab.
Allow Slash in Primary Key for Tomcat Installations
If you are running
CA Live API Creatoron Tomcat, and you have a slash in your primary key,
CA Live API Creatorreturns an error saying it cannot find the row. The Tomcat server attempts to decode the "/" before sending on to
CA Live API Creator.
For example, your key is
P5/P5Aand the href URL appears as (encoded):
You can enable Tomcat to accept encoded path separators, such as a slash in the primary key. Change the
CATALINA_OPTSenvironment variable. Add the following to the JVM args of the system (setenv):
Update Amazon EBS - Apache Proxy Server in the AWS Beanstalk Instance
Follow these steps:
- SSH into the machine.
- Issue the following command:cd /etc/httpd/conf.d
- Edit theelasticbeanstalk.conffile to have the following data: (Overwrite the file)
- Change the Tomcat config to allow encoded slashes (/usr/share/tomcat8/conf/tomcat8.conf):export CATALINA_OPTS="$CATALINA_OPTS -Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true
- Restart Tomcat and httpd services:sudoservice <servicename> restart
The Apache service can take a minute or two to be up.
Import API with Null Password Can Cause Database Issues
Migrating APIs from a previous
CA Live API Creatorversion to another can cause issues with some databases. These databases attempt to connect, fail, and then lock out the connection. To solve this, export your API and mark your data source to inactive. Because
CA Live API Creatordoes not export the password, when you import the API (the JSON file), you can then enter the password, test the connection, and then activate your data source.
For more information:
Resource Properties not Visible
Resource properties are not visible if your web browser is set to auto-fill values. API Creator disables this functionality, though certain browsers ignore the disabling. Correct the browser from ignoring the disabling.
For more information about how to disable autofill in the Google Chrome web browser, see Google Chrome help.
For more information about how to disable autofill in the Sarari web browser, see Apple Safari help.
The following issue is caused by passing a string instead of an object (or vice versa):
caused by: java.lang.ClassCastException: Cannot cast java.lang.String tojdk.nashorn.api.scripting.ScriptObjectMirror
To solve this issue, you can do one of the following:
- Convert a JSON string to an object using theJSON.parse()method.
- Convert an object to a JSON string using theJSON.stringify()method.