3

Although I was able to generate docs using schemaSpy 5.0.0, I'm constantly having problems with version 6.0.0. Do we have anybody here who has gone through this successfully?

Preconditions:

Properties file has been extracted from the driver and looks as follows:

description=Force
driver=com.claimvantage.force.jdbc.ForceMetaDataDriver
connectionSpec=jdbc:claimvantage:force

Parameters:

java -jar schemaspy-6.0.0.jar -dp force-metadata-jdbc-driver-2.2.jar
-loglevel severe -t force -u myUsername -p myPass -o TEST -db TEST -debug

Result: enter image description here

Plain text:

ForceMetaDataDriver: Filter [exclusionNames=[user], inclusionNames=[], keepCustom=true, keepStandard=false]
ERROR - null
java.lang.NullPointerException: null
        at org.schemaspy.service.DbmsService.lambda$fetchDbmsMeta$5(DbmsService.java:107)
        at org.schemaspy.service.DbmsService.onlyLogException(DbmsService.java:123)
        at org.schemaspy.service.DbmsService.fetchDbmsMeta(DbmsService.java:107)
        at org.schemaspy.service.SqlService.connect(SqlService.java:71)
        at org.schemaspy.SchemaAnalyzer.analyze(SchemaAnalyzer.java:186)
        at org.schemaspy.SchemaAnalyzer.analyze(SchemaAnalyzer.java:107)
        at org.schemaspy.cli.SchemaSpyRunner.runAnalyzer(SchemaSpyRunner.java:97)
        at org.schemaspy.cli.SchemaSpyRunner.run(SchemaSpyRunner.java:86)
        at org.schemaspy.Main.main(Main.java:48)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48)
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:87)
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:50)
        at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:51)

1 Answer 1

2

Looking at a GitHub copy of SchemaSpy 6, the SchemaSpy line is:

onlyLogException(() -> builder.systemFunctions(formatSqlKeyWords(
        databaseMetaData.getSystemFunctions().split(",")
        )));

so the probable cause is this force-metadata-jdbc-driver method:

public String getSystemFunctions() throws SQLException {

    return null;
}

that if changed to return an empty string would stop the exception. (Only the methods that were needed for SchemaSpy 5 were implemented, and it looks like SchemaSpy 6 needs more methods implementing.)

At least these methods will also have to return an empty string:

getStringFunctions()
getNumericFunctions()
getTimeDateFunctions()

and there may be further problems. The good news is that as both are open source, the problems can often be diagnosed starting from the stack trace.

Given that Google Code is no longer active, I've put a copy of the code here https://claimvantage.github.io/force-metadata-jdbc-driver/. If you work out the problems and want to submit a pull request go ahead here https://github.com/claimvantage/force-metadata-jdbc-driver/pulls and I will review/merge.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .