Question

Error running BIX PegaSample!Sample extractor

I'm running Pega 8.2 with BIX installed and am using the attached prbootstrap.properties, prconfig.xml, and bix.sh files (renamed to allow uploading; sanitized prior to upload). I am able to successfully connect to the PostgreSQL database using other Java apps and pgAdmin.

When I execute bix.sh I get the attached output (bix.log.txt). The classpath is:

  1. ./lib/jsr94-1.0.jar:./lib/prbootstrap-api.jar:./lib/prbootstrap.jar:./lib/prdbcp.jar:./extra-libs/postgresql-42.2.5.jar

The JDBC driver is present on the classpath, however, as you can see in bix.log.txt, there is still a problem connecting to the database ("Missing JDBC driver class setting"). Further down it appears prbootphase2.jar is expected to be loaded from ./lib/boot but that file isn't provided with the Pega Additional_Products.

Has anyone else encountered/overcome either of these?

Correct Answer
August 6, 2019 - 9:46am

Figured it out.  The dbcpsource didn't follow the "<unique-identifier>.<dbtype>" naming convention.

Comments

Keep up to date on this post and subscribe to comments

Pega
August 2, 2019 - 9:22am

Hi,

Could you please review your prbootstarp.properties file if the DB URL,username , password, rule schema name and data schema name are correct.

Also could you please provide the snapshot of the BIX configuration.

Thank You,

Pega
August 5, 2019 - 4:13am

Try to include current directory in your classpath:

.:./lib/jsr94-1.0.jar:./lib/prbootstrap-api.jar:./lib/prbootstrap.jar:./lib/prdbcp.jar:./extra-libs/postgresql-42.2.5.jar

Regards

Simon

August 5, 2019 - 9:49am

Thanks for the responses.  I verified the database URL, username, password, and schema.  Found a typo on the schema (rulesset rather than ruleset).  Otherwise, they are correct.  Also added current directory to the classpath.  I can successfully connect to the database and query rulesset.pr_operators in a stand-alone Java app.  The following "BIX invocation" still apparently fails to connect to the database:

  1. java -Xms512m -Xmx768m \
  2. -Dpegarules.config=./config/prconfig.xml \
  3. -Dcom.pega.pegarules.bootstrap.properties.url="file:///home/sdcavan/projects/BIX/config/prbootstrap.properties" \
  4. -Dpegarules.logging.configuration=./config/prlog4j2.xml \
  5. -Dcom.pega.pegarules.bootstrap.ignorejndi=true \
  6. -cp ".:./lib/jsr94-1.0.jar:./lib/prbootstrap-api.jar:./lib/prbootstrap.jar:./lib/prdbcp.jar:./extra-libs/postgresql-42.2.5.jar" \
  7. com.pega.pegarules.pub.PegaRULES com.pega.pegarules.data.internal.access.ExtractImpl \
  8. -I PegaSample_Sample.xml

And I get the following results:

  1. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrapDataSource
  2. 1050: Loading bootstrap properties from file:///home/sdcavan/projects/BIX/config/prbootstrap.properties
  3. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.SettingReaderJNDI
  4. INFO: Could not find java:comp/env/prbootstrap/ in the local JNDI context, skipping prconfig setting lookup
  5. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.SettingReaderJNDI
  6. INFO: Could not find prbootstrap in the local JNDI context, skipping prconfig setting lookup
  7. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrapDataSource
  8. 1050: Bootstrap datatables schema: rulesset
  9. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrapDataSource
  10. 1050: Insufficient data supplied in prbootstrap.properties to create a datasource
  11. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrapDataSource
  12. 1050: Missing JDBC driver class setting "null.jdbc.class"
  13. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrapDataSource
  14. 1050: Unable to locate archive.properties properties, setting warVersion to -1
  15. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrap
  16. 1050: Engine schema defined in allclasses: rulesset
  17. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrap
  18. 1050: Engine classes schema: rulesset
  19. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrap
  20. 1050: Assembled classes schema: rulesset
  21. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrap
  22. 1050: prbootstrap.properties merged with prbootstrap entries in Data-Admin-System-Settings
  23. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrapDataSource
  24. 1050: Insufficient data supplied in prbootstrap.properties to create a datasource
  25. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrapDataSource
  26. 1050: Missing JDBC driver class setting "null.jdbc.class"
  27. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrap
  28. 1050: PRBootstrap.calculateEngineCodeVersionFromDB() - unable to calculate codeset version from database: null
  29. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRMiniLoader
  30. 1050: Will load phase 2 bootstrap from Pega-EngineCode:
  31. /home/sdcavan/projects/BIX/lib/boot/prbootphase2.jar (No such file or directory)
  32. Perhaps executing with a non-standard classpath (e.g. JUnit tests)?
  33. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrap
  34. 1050:
  35. ============ PegaRULES Bootstrap Configuration ============
  36. Date: Mon Aug 05 09:46:34 EDT 2019
  37. Java Version: Oracle Corporation 1.8.0_201
  38. Configuration: file:/home/sdcavan/projects/BIX/config/prbootstrap.properties
  39. Pega-EngineCode:
  40.  
  41. (!) Ignored JNDI Options
  42. (!) Unable to locate classes on filesystem
  43. =============== End Bootstrap Configuration ===============
  44.  
  45. Unable to load phase 2 bootstrap class: com.pega.pegarules.internal.bootstrap.phase2.PRBootstrapImpl
  46. Aug 05, 2019 9:46:34 AM com.pega.pegarules.internal.bootstrap.PRBootstrap
  47. SEVERE: Error initializing PRAppLoader
  48. java.lang.ClassNotFoundException: com.pega.pegarules.internal.bootstrap.phase2.PRBootstrapImpl
  49. at com.pega.pegarules.internal.bootstrap.PRMiniLoader.loadClass(PRMiniLoader.java:381)
  50. at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
  51. at com.pega.pegarules.internal.bootstrap.PRBootstrap.loadPhase2BootstrapClass(PRBootstrap.java:731)
  52. at com.pega.pegarules.internal.bootstrap.PRBootstrap.checkForStartup(PRBootstrap.java:673)
  53. at com.pega.pegarules.internal.bootstrap.PRBootstrap.invokeMethodPropagatingThrowable(PRBootstrap.java:419)
  54. at com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega.invokeMethodPropagatingThrowable(AppServerBridgeToPega.java:224)
  55. at com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega.invokeMethod(AppServerBridgeToPega.java:273)
  56. at com.pega.pegarules.pub.PegaRULES.main(PegaRULES.java:85)
  57.  
  58. Aug 05, 2019 9:46:34 AM com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega
  59. SEVERE: Problem during method invocation (main)
  60. java.lang.RuntimeException: PRAppLoader was not properly initialized, unable to load class com.pega.pegarules.data.internal.access.ExtractImpl
  61. at com.pega.pegarules.internal.bootstrap.PRBootstrap.getImplementationOf(PRBootstrap.java:219)
  62. at com.pega.pegarules.internal.bootstrap.PRBootstrap.getEntry(PRBootstrap.java:335)
  63. at com.pega.pegarules.internal.bootstrap.PRBootstrap.getMethod(PRBootstrap.java:315)
  64. at com.pega.pegarules.internal.bootstrap.PRBootstrap.invokeMethodPropagatingThrowable(PRBootstrap.java:420)
  65. at com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega.invokeMethodPropagatingThrowable(AppServerBridgeToPega.java:224)
  66. at com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega.invokeMethod(AppServerBridgeToPega.java:273)
  67. at com.pega.pegarules.pub.PegaRULES.main(PegaRULES.java:85)
  68.  
  69. Exception in thread "main" java.lang.RuntimeException: Problem during method invocation (main)
  70. at com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega.invokeMethod(AppServerBridgeToPega.java:279)
  71. at com.pega.pegarules.pub.PegaRULES.main(PegaRULES.java:85)
  72. Caused by: java.lang.RuntimeException: PRAppLoader was not properly initialized, unable to load class com.pega.pegarules.data.internal.access.ExtractImpl
  73. at com.pega.pegarules.internal.bootstrap.PRBootstrap.getImplementationOf(PRBootstrap.java:219)
  74. at com.pega.pegarules.internal.bootstrap.PRBootstrap.getEntry(PRBootstrap.java:335)
  75. at com.pega.pegarules.internal.bootstrap.PRBootstrap.getMethod(PRBootstrap.java:315)
  76. at com.pega.pegarules.internal.bootstrap.PRBootstrap.invokeMethodPropagatingThrowable(PRBootstrap.java:420)
  77. at com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega.invokeMethodPropagatingThrowable(AppServerBridgeToPega.java:224)
  78. at com.pega.pegarules.boot.internal.extbridge.AppServerBridgeToPega.invokeMethod(AppServerBridgeToPega.java:273)
  79. ... 1 more

 

Pega
August 5, 2019 - 11:50pm

Hi,

Could please review the below lines in prbootstrap.properties.

com.pega.pegarules.bootstrap.allclasses.schema=ruleset (should be rule schema name)
com.pega.pegarules.bootstrap.datatables.schema=ruleset (should be data schema name)

Also check the below command which is working fine for me.

java -classpath ".;./lib/prbootstrap-7.4.0-185.jar;./lib/prbootstrap-api-7.4.0-185.jar;./lib/prdbcp-7.4.0-185.jar;./lib/jsr94-1.0.jar;./lib/postgresql-42.2.2.jar;" -Dpegarules.config="/config/prconfig.xml" -Dcom.pega.pegarules.bootstrap.properties.url="file:///C:/Users/xxx/enablement_software/115943_Pega7.4/Additional_Products/BIX/config/prbootstrap.properties" -Dpega.prbootstrap.config="config\prbootstrap.properties" -Dcom.pega.pegarules.bootstrap.ignorejndi=true -Dpegarules.keyring="C:\Users\xxx\enablement_software\115943_Pega7.4\Additional_Products\BIX\config\pegarules.keyring" -Dpegarules.logging.configuration="config\prlogging.xml" com.pega.pegarules.pub.PegaRULES com.pega.pegarules.data.internal.access.ExtractImpl -a usernameforprpclogin -p passwordforprpclogin -i bixextractclassname!bixextractrulename

Thank You,

August 6, 2019 - 7:49am

I have the following for prbootstrap.properties:

  1. com.pega.pegarules.bootstrap.ignorejndi=TRUE
  2. com.pega.pegarules.bootstrap.allclasses.dbcpsource=bixpg
  3. bixpg.url=jdbc:postgresql://__DBHOST__:5432/pegadb
  4. bixpg.username=__DBUSER__
  5. bixpg.password=__DBPASS__
  6. postgresql.jdbc.class=org.postgresql.Driver
  7.  
  8. com.pega.pegarules.bootstrap.allclasses.schema=rulesset
  9. com.pega.pegarules.bootstrap.datatables.schema=rulesset

The schema really is "rulesset" rather than "ruleset". 

The error/output (see below) makes me think the jdbc class property isn't correctly named:

  1. Aug 06, 2019 7:39:48 AM com.pega.pegarules.internal.bootstrap.PRBootstrapDataSource
  2. 1050: Insufficient data supplied in prbootstrap.properties to create a datasource
  3. Aug 06, 2019 7:39:48 AM com.pega.pegarules.internal.bootstrap.PRBootstrapDataSource
  4. 1050: Missing JDBC driver class setting "null.jdbc.class"

 

August 6, 2019 - 9:46am

Figured it out.  The dbcpsource didn't follow the "<unique-identifier>.<dbtype>" naming convention.