search cancel

Java fails to start due to error "sun.net.www.protocol.file.FileURLConnection cannot be cast to java.net.HttpURLConnection"

book

Article ID: 256149

calendar_today

Updated On:

Products

CA Automic Applications Manager (AM)

Issue/Introduction

When double clicking on the RunClient.jar, nothing happens. A startclient.log is generated an contain the following error:

Exception in thread "main" java.lang.ClassCastException: sun.net.www.protocol.file.FileURLConnection cannot be cast to java.net.HttpURLConnection
 at com.appworx.client.local.RunClient.searchOJDBC(RunClient.java:120)
 at com.appworx.client.local.RunClient.getOJDBC(RunClient.java:145)
 at com.appworx.client.local.RunClient.main(RunClient.java:37)

Environment

Release : 9.3

Cause

The entry for the environment in the connections.properties may be incorrect.

Resolution

Review the connections.properties to make sure the parameter(s) are in the below example format:

AMPROD=http://127.0.0.1:8080/AMPROD