Uploaded image for project: 'Teiid'
  1. Teiid
  2. TEIID-4756

Improve log messages when using an UDAF without the required classes defined in VDB

    Details

    • Type: Enhancement
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 9.1.2
    • Fix Version/s: 9.2, 8.12.14.6_4
    • Component/s: Server
    • Labels:
      None

      Description

      When using an UDAF in a VDB, the required JAVA_CLASS and JAVA_METHOD are specified in the VDB.

      When for some reason the JAVA_CLASS or JAVA_METHOD do not exist in the library, the message from the system is quite imperceptible.

      In the following log excerpt, GlobalTitleRangeCheck class does not exist in the jar rangecreator. The model name that is defining the VIRTUAL FUNCTION is RangeGroupConcat. The VDB name is CountryServiceListVDB.

      Log excerpt

      DEBUG [org.teiid.RUNTIME] (Worker53_async-teiid-threads203) TEIID50104 VDB CountryServiceListVDB.1 model "RangeGroupConcat" Using translator null and connection null to load metadata.

      ...

      INFO [org.teiid.RUNTIME] (Worker53_async-teiid-threads203) TEIID40073 The metadata for the VDB CountryServiceListVDB.1 is loaded, however it is not valid. Check models for errors. Correct the metadata and re-deploy.

      INFO [org.teiid.RUNTIME.VDBLifeCycleListener] (Worker53_async-teiid-threads203) TEIID40003 VDB CountryServiceListVDB.1 is set to FAILED

      As observed from the log excerpt, the only possible hint to know what the problem is with the FAILED deploy might be:

      model "RangeGroupConcat" Using translator null and connection null to load metadata.

      But this is a normal logging message that doesn't have nothing to do with the real problem.

      When putting the entire system logging ALL levels, then is easy to see what the problem is:

      Log excerpt

      DEBUG [org.teiid.RUNTIME] (Worker52_async-teiid-threads202) TEIID50104 VDB CountryServiceListVDB.1 model "RangeGroupConcat" Using translator null and connection null to load metadata.

      INFO [org.teiid.RUNTIME] (Worker52_async-teiid-threads202) TEIID50030 VDB CountryServiceListVDB.1 model "RangeGroupConcat" metadata loaded. End Time: 10/02/17 10:56

      TRACE [org.jboss.modules] (Worker52_async-teiid-threads202) Finding class com.truphone.teiid.udaf.GlobalTitleRangeCheck from Module "deployment.countryServiceList-vdb.xml:main" from Service Module Loader

      TRACE [org.jboss.modules] (Worker52_async-teiid-threads202) Finding local class com.truphone.teiid.udaf.GlobalTitleRangeCheck from Module "mnom.rangecreator:main" from local module loader @33e5ccce (finder: local module finder @5a42bbf4 (roots: /home/mnom/teiid/teiid-9.1.2/modules,/home/mnom/teiid/teiid-9.1.2/modules/system/layers/dv,/home/mnom/teiid/teiid-9.1.2/modules/system/layers/base))

      TRACE [org.jboss.modules] (Worker52_async-teiid-threads202) Loading class com.truphone.teiid.udaf.GlobalTitleRangeCheck locally from Module "mnom.rangecreator:main" from local module loader @33e5ccce (finder: local module finder @5a42bbf4 (roots: /home/mnom/teiid/teiid-9.1.2/modules,/home/mnom/teiid/teiid-9.1.2/modules/system/layers/dv,/home/mnom/teiid/teiid-9.1.2/modules/system/layers/base))

      TRACE [org.jboss.modules] (Worker52_async-teiid-threads202) No local specification found for class com.truphone.teiid.udaf.GlobalTitleRangeCheck in Module "mnom.rangecreator:main" from local module loader @33e5ccce (finder: local module finder @5a42bbf4 (roots: /home/mnom/teiid/teiid-9.1.2/modules,/home/mnom/teiid/teiid-9.1.2/modules/system/layers/dv,/home/mnom/teiid/teiid-9.1.2/modules/system/layers/base))

      TRACE [org.jboss.modules] (Worker52_async-teiid-threads202) Class com.truphone.teiid.udaf.GlobalTitleRangeCheck not found from Module "deployment.countryServiceList-vdb.xml:main" from Service Module Loader

      INFO [org.teiid.RUNTIME] (Worker52_async-teiid-threads202) TEIID40073 The metadata for the VDB CountryServiceListVDB.1 is loaded, however it is not valid. Check models for errors. Correct the metadata and re-deploy.

      INFO [org.teiid.RUNTIME.VDBLifeCycleListener] (Worker52_async-teiid-threads202) TEIID40003 VDB CountryServiceListVDB.1 is set to FAILED

      Here it is observable what the real problem is:

      No local specification found for class com.truphone.teiid.udaf.GlobalTitleRangeCheck in Module "mnom.rangecreator:main"

      So, to avoid unnecessarily losing time to investigate what the problem is, the message that is currently in TRACE level should be in, at least, INFO level.

        Gliffy Diagrams

          Attachments

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            Activity

              People

              • Assignee:
                shawkins Steven Hawkins
                Reporter:
                pringi Pedro InĂ¡cio
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: