Full name:

com.isomorphic:isc-maven-plugin:1.4.1:reify-import

Description:

Provides for single-step download and extraction of assets hosted on the Reify platform. While there is nothing to prevent a user from modifying the imported resources, changes should almost always be made using Reify and then re-imported. If necessary, use the API (e.g., RPCManager.createScreen, Canvas.getByLocalId) to modify imported screen definitions at runtime. Imported MockDataSources can simply be replaced using e.g., SQLDataSources having the same ID in another directory - there is no reason to modify the contents of the 'mock' subdirectory.

To encourage recommended usage, the reify-import goal takes steps to detect local changes and fail when any are found. Refer to the skipOverwriteProtection parameter for details. Further, a validation step (optional, see ImportMojo.skipValidationOnImport) attempts to detect commonly found discrepancies between your MockDataSources and working DataSources.

The Reify for Developers documentation topic contains further discussion around best practices during the design / development cycle.

If you've built your project using one of the Maven archetypes for either SmartGWT or SmartClient, you should have a skeleton configuration in you POM already. if not, add something like the following:

<pluginManagement>
    <plugins>
        <plugin>
            <groupId>com.isomorphic</groupId>
            <artifactId>isc-maven-plugin</artifactId>
            <version>1.4.0-SNAPSHOT</version>
            <!-- the m2pluginextras dependency will be required when skipValidationOnImport = false -->
            <dependencies>
                <dependency>
                    <groupId>com.isomorphic.extras</groupId>
                    <artifactId>isomorphic-m2pluginextras</artifactId>
                   <version>${smartgwt.version}</version>
                </dependency>       
            </dependencies>
        </plugin>
    </plugins>
</pluginManagement>                

<build>
    <plugins>
      <plugin>
          <groupId>com.isomorphic</groupId>
          <artifactId>isc-maven-plugin</artifactId>
          <configuration>
            <smartclientRuntimeDir>${project.parent.build.directory}/gwt/launcherDir/myapplication/sc</smartclientRuntimeDir>
            <dataSourcesDir>WEB-INF/ds/classic-models</dataSourcesDir>
          </configuration>
      </plugin>
    </plugins>
</build>
and check that the SmartClient runtime has been extracted to the configured location (via e.g., mvn war:exploded, mvn jetty:run).

Attributes:

Required Parameters

Name Type Since Description
projectName String 1.4.0 The name of the project as it's known by the reify.com environment.
Default value is: ${project.artifactId}.
User property is: projectName.

Optional Parameters

Name Type Since Description
dataSourcesDir String 1.4.0 The directory, relative to webappDir), in which your project's working datasources (i.e., other than mocks) reside.

Note that this will need to conform to the webapp's server.properties project.datasources configuration.


Default value is: WEB-INF/ds.
User property is: dataSourcesDir.
drawOnWelcomeFiles boolean 1.4.0 Like modifyWelcomeFiles, except this variant will draw the project's first screen when all of its screens have been loaded.
Default value is: false.
User property is: drawOnWelcomeFiles.
includeTestHtml boolean 1.4.0 If true, the import process will create an HTML launcher that loads the given project/s. The file's name and location can be configured via testHtmlPathname.
Default value is: false.
User property is: includeTestHtml.
includeTestJsp boolean 1.4.0 If true, the import process will create a JSP launcher that loads the given project/s. The file's name and location can be configured via testJspPathname.
Default value is: false.
User property is: includeTestJsp.
mockDataSourcesDir String 1.4.0 The directory, relative to webappDir), in which exported MockDataSources should ultimately reside.

Note that this will need to conform to the webapp's server.properties project.datasources configuration.


Default value is: WEB-INF/ds/mock.
User property is: mockDataSourcesDir.
modifyWelcomeFiles boolean 1.4.0 If true, the project's welcome files will be modified to include a script block that loads the imported project. Note that the loaded project is not drawn - for that, refer to drawOnWelcomeFiles. Welcome files are determined by scanning the project's web.xml file for the standard welcome-files declaration. If none is found, the webroot is searched for files named index.jsp and index.html.

Subsequent imports of other projects append the newly imported project name to the existing one/s.


Default value is: false.
User property is: modifyWelcomeFiles.
projectFileDir String 1.4.0 The directory to which the exported project file should ultimately reside, relative to webappDir. Note that this will need to conform to the webapp's server.properties project.project configuration.
Default value is: WEB-INF/ui.
User property is: projectFileDir.
serverId String 1.4.0 The id of a server configuration containing authentication credentials for the reify.com website, used to download exported projects.
Default value is: smartclient-developer.
User property is: serverId.
skipOverwriteProtection boolean 1.4.0 When a project is imported, its screen and datasource assets are marked with a checksum representing the contents of each file. Subsequent imports are preceded by a check to make sure each of these checksums still match the file's content. In the event that any do not, the import fails by default.

To override this behavior, you may set this parameter value to true, in which case the file will simply be overwritten. Use this feature at your own risk.


Default value is: false.
User property is: skipOverwriteProtection.
skipValidationOnImport boolean 1.4.0 When true, DataSource validation will be skipped following import. The ValidateMojo can still be executed independently at any time.
Default value is: false.
User property is: skipValidationOnImport.
smartclientRuntimeDir File 1.4.0 The directory containing the Isomorphic runtime. The default value is appropriate for the path created by a typical mvn war:exploded invocation. Alternatively, set this to the path created by mvn jetty:run, or any other path where an appropriate SmartClient runtime may be found. Note that SmartGWT users may need to change the value to something like:

${project.build.directory}/${project.build.finalName}/${gwtModuleName}/sc


Default value is: ${project.build.directory}/${project.build.finalName}/isomorphic.
User property is: smartclientRuntimeDir.
testHtmlPathname String 1.4.0 The name (and optional path, relative to webappDir) of the HTML launcher to be created when includeTestHtml is true.
Default value is: ${projectName}.run.html.
User property is: testHtmlPathname.
testJspPathname String 1.4.0 The name (and optional path, relative to webappDir) of the JSP launcher to be created when includeTestJsp is true.
Default value is: ${projectName}.run.jsp.
User property is: testJspPathname.
uiDir String 1.4.0 The directory in which exported screens should ultimately reside, relative to webappDir. Note that this will need to conform to the webapp's server.properties project.ui configuration.
Default value is: WEB-INF/ui.
User property is: uiDir.
validationFailureThreshold ErrorMessage$Severity 1.4.0 One of INFO, ERROR, WARN that will determine the level of severity tolerated in any validation error. Any error at or above this threshold will result in "BUILD FAILURE".
Default value is: ERROR.
User property is: validationFailureThreshold.
webappDir File 1.4.0 The directory containing web application sources.
Default value is: ${project.basedir}/src/main/webapp.
User property is: webappDir.
workdir File 1.4.0 The directory to which the archive is downloaded and unpacked. Note that this is not the final destination of exported assets. For that, see ImportMojo.webappDir.
Default value is: ${project.build.directory}/reify.
User property is: workdir.

Parameter Details

dataSourcesDir:

The directory, relative to webappDir), in which your project's working datasources (i.e., other than mocks) reside.

Note that this will need to conform to the webapp's server.properties project.datasources configuration.

  • Type: java.lang.String
  • Since: 1.4.0
  • Required: No
  • User Property: dataSourcesDir
  • Default: WEB-INF/ds

drawOnWelcomeFiles:

Like modifyWelcomeFiles, except this variant will draw the project's first screen when all of its screens have been loaded.
  • Type: boolean
  • Since: 1.4.0
  • Required: No
  • User Property: drawOnWelcomeFiles
  • Default: false

includeTestHtml:

If true, the import process will create an HTML launcher that loads the given project/s. The file's name and location can be configured via testHtmlPathname.
  • Type: boolean
  • Since: 1.4.0
  • Required: No
  • User Property: includeTestHtml
  • Default: false

includeTestJsp:

If true, the import process will create a JSP launcher that loads the given project/s. The file's name and location can be configured via testJspPathname.
  • Type: boolean
  • Since: 1.4.0
  • Required: No
  • User Property: includeTestJsp
  • Default: false

mockDataSourcesDir:

The directory, relative to webappDir), in which exported MockDataSources should ultimately reside.

Note that this will need to conform to the webapp's server.properties project.datasources configuration.

  • Type: java.lang.String
  • Since: 1.4.0
  • Required: No
  • User Property: mockDataSourcesDir
  • Default: WEB-INF/ds/mock

modifyWelcomeFiles:

If true, the project's welcome files will be modified to include a script block that loads the imported project. Note that the loaded project is not drawn - for that, refer to drawOnWelcomeFiles. Welcome files are determined by scanning the project's web.xml file for the standard welcome-files declaration. If none is found, the webroot is searched for files named index.jsp and index.html.

Subsequent imports of other projects append the newly imported project name to the existing one/s.

  • Type: boolean
  • Since: 1.4.0
  • Required: No
  • User Property: modifyWelcomeFiles
  • Default: false

projectFileDir:

The directory to which the exported project file should ultimately reside, relative to webappDir. Note that this will need to conform to the webapp's server.properties project.project configuration.
  • Type: java.lang.String
  • Since: 1.4.0
  • Required: No
  • User Property: projectFileDir
  • Default: WEB-INF/ui

projectName:

The name of the project as it's known by the reify.com environment.
  • Type: java.lang.String
  • Since: 1.4.0
  • Required: Yes
  • User Property: projectName
  • Default: ${project.artifactId}

serverId:

The id of a server configuration containing authentication credentials for the reify.com website, used to download exported projects.
  • Type: java.lang.String
  • Since: 1.4.0
  • Required: No
  • User Property: serverId
  • Default: smartclient-developer

skipOverwriteProtection:

When a project is imported, its screen and datasource assets are marked with a checksum representing the contents of each file. Subsequent imports are preceded by a check to make sure each of these checksums still match the file's content. In the event that any do not, the import fails by default.

To override this behavior, you may set this parameter value to true, in which case the file will simply be overwritten. Use this feature at your own risk.

  • Type: boolean
  • Since: 1.4.0
  • Required: No
  • User Property: skipOverwriteProtection
  • Default: false

skipValidationOnImport:

When true, DataSource validation will be skipped following import. The ValidateMojo can still be executed independently at any time.
  • Type: boolean
  • Since: 1.4.0
  • Required: No
  • User Property: skipValidationOnImport
  • Default: false

smartclientRuntimeDir:

The directory containing the Isomorphic runtime. The default value is appropriate for the path created by a typical mvn war:exploded invocation. Alternatively, set this to the path created by mvn jetty:run, or any other path where an appropriate SmartClient runtime may be found. Note that SmartGWT users may need to change the value to something like:

${project.build.directory}/${project.build.finalName}/${gwtModuleName}/sc

  • Type: java.io.File
  • Since: 1.4.0
  • Required: No
  • User Property: smartclientRuntimeDir
  • Default: ${project.build.directory}/${project.build.finalName}/isomorphic

testHtmlPathname:

The name (and optional path, relative to webappDir) of the HTML launcher to be created when includeTestHtml is true.
  • Type: java.lang.String
  • Since: 1.4.0
  • Required: No
  • User Property: testHtmlPathname
  • Default: ${projectName}.run.html

testJspPathname:

The name (and optional path, relative to webappDir) of the JSP launcher to be created when includeTestJsp is true.
  • Type: java.lang.String
  • Since: 1.4.0
  • Required: No
  • User Property: testJspPathname
  • Default: ${projectName}.run.jsp

uiDir:

The directory in which exported screens should ultimately reside, relative to webappDir. Note that this will need to conform to the webapp's server.properties project.ui configuration.
  • Type: java.lang.String
  • Since: 1.4.0
  • Required: No
  • User Property: uiDir
  • Default: WEB-INF/ui

validationFailureThreshold:

One of INFO, ERROR, WARN that will determine the level of severity tolerated in any validation error. Any error at or above this threshold will result in "BUILD FAILURE".
  • Type: com.isomorphic.util.ErrorMessage$Severity
  • Since: 1.4.0
  • Required: No
  • User Property: validationFailureThreshold
  • Default: ERROR

webappDir:

The directory containing web application sources.
  • Type: java.io.File
  • Since: 1.4.0
  • Required: No
  • User Property: webappDir
  • Default: ${project.basedir}/src/main/webapp

workdir:

The directory to which the archive is downloaded and unpacked. Note that this is not the final destination of exported assets. For that, see ImportMojo.webappDir.
  • Type: java.io.File
  • Since: 1.4.0
  • Required: No
  • User Property: workdir
  • Default: ${project.build.directory}/reify

Back to top

Reflow Maven skin by Andrius Velykis.