How to Implement a new Migrator

Ondrej Zizka edited this page May 19, 2013 · 5 revisions

Stub

Implementation

  1. Create a new package in org.jboss.loom.migrators.*

  2. Implement IMigrator. You may use AbstractMigrator which deals with conf.<migratorName>.* app parameters by putting them to a Map<String, String>.

  3. If you need an action which is not in the existing set, first discuss on #jboss-migration IRC channel.

  4. If it's a warn-only implementation (let's user know that the impl is not done yet), create ManualAction(s) like this:

     // TODO: Report exactly what was found in which deployment.
     ManualAction manualAction = new ManualAction();
     manualAction.addWarning(
             "jboss-classloading.xml or/and jboss-web.xml was found in your deployments.\n"
             + "Migration of classloading configuration is not supported (yet).");
     ctx.getActions().add( manualAction );
    

Test Case

  • Use Arquillian
  • Use org.jboss.loom.TestAppConfig
  • Put the test in the same package
  • If it needs an app, see ShrinkWrap
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.