Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-125420 Simplify the build of benchmarks in portal
  3. LPS-125421

Provide a more easy way to import the data build by SampleSQLBuilder into database

Details

    • Technical Task
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • Master
    • None

    Description

      Provide a more easy way to import the data built by SampleSQLBuilder into the database

      An example for Mysql:

      1>Create a property file named "benchmarks.${user.name}.properties" put it under ${PortalSource}/benchmarks to override these properties in benchmarks.properties

      For example,

      Set these properties in the property file:

      sample.sql.db.time.zone=GMT
      sample.sql.db.type=mysql
      sample.sql.max.asset.category.count=0
      sample.sql.max.asset.entry.to.asset.category.count=0
      sample.sql.max.asset.entry.to.asset.tag.count=0
      sample.sql.max.asset.publisher.page.count=0
      sample.sql.max.asset.tag.count=0
      sample.sql.max.asset.vocabulary.count=0
      sample.sql.max.blogs.entry.comment.count=0
      sample.sql.max.blogs.entry.count=0
      sample.sql.max.commerce.product.count=0
      sample.sql.max.commerce.product.definition.count=0
      sample.sql.max.commerce.product.instance.count=0
      sample.sql.max.content.layout.count=0
      sample.sql.max.ddl.custom.field.count=0
      sample.sql.max.ddl.record.count=0
      sample.sql.max.ddl.record.set.count=0
      sample.sql.max.dl.file.entry.count=0
      sample.sql.max.dl.file.entry.size=0
      sample.sql.max.dl.folder.count=0
      sample.sql.max.dl.folder.depth=0
      sample.sql.max.group.count=1
      sample.sql.max.journal.article.count=1
      sample.sql.max.journal.article.page.count=2
      sample.sql.max.journal.article.size=120
      sample.sql.max.journal.article.version.count=1
      sample.sql.max.mb.category.count=0
      sample.sql.max.mb.message.count=0
      sample.sql.max.mb.thread.count=0
      sample.sql.max.segments.entry.count=0
      sample.sql.max.user.count=100
      sample.sql.max.user.to.group.count=1
      sample.sql.max.wiki.node.count=0
      sample.sql.max.wiki.page.comment.count=0
      sample.sql.max.wiki.page.count=0
      sample.sql.optimize.buffer.size=8192
      sample.sql.output.merge=true
      sample.sql.script=com/liferay/portal/tools/sample/sql/builder/dependencies/sample.ftl

      3>Run "ant build-sample-sql " under ${PortalSource}/benchmarks

      4>Create a database in Mysql and import the sql file named sample-data-mysql.sql under ${PortalSource}/benchmarks/build into the db.

      Note:
      when start portal with the data SampleSQLBuilder generated, these properties need be setted in portal-ext.properties
      1>passwords.encryption.algorithm=NONE
      2>After Mysql 5.7, need assign "serverTimezone" in property "jdbc.default.url" for example"jdbc.default.url=jdbc:mysql://localhost/test?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false&serverTimezone=Asia/Shanghai"

      Attachments

        Activity

          People

            lily.chi Lily Chi
            lily.chi Lily Chi
            Brian Chan Brian Chan
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              1 year, 39 weeks, 1 day ago

              Packages

                Version Package
                Master