Uploaded image for project: 'Tools (JBoss Tools)'
  1. Tools (JBoss Tools)
  2. JBIDE-12575

Problem with CDI validator

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Minor
    • 4.5.1.AM2
    • 4.0.0.Alpha1
    • cdi
    • None
    • Hide

      EXEC: create dynamic web project without CDI support
      EXEC: create bean:

      import javax.enterprise.inject.Produces;
      import javax.inject.Inject;
      
      public class Test {
      
      	@Inject String injectionPoint;
      	
      	@Produces
      	public String value1() {
      		return null;
      	}
      	
      	@Produces
      	public String value2() {
      		return null;
      	}
      	
      }
      

      EXEC: enable CDI support into project
      ASSERT: injection point is validated by CDI validator (multiple beans eligible for injection)
      FAIL: there is no validation marker on injection point

      Show
      EXEC: create dynamic web project without CDI support EXEC: create bean: import javax.enterprise.inject.Produces; import javax.inject.Inject; public class Test { @Inject String injectionPoint; @Produces public String value1() { return null ; } @Produces public String value2() { return null ; } } EXEC: enable CDI support into project ASSERT: injection point is validated by CDI validator (multiple beans eligible for injection) FAIL: there is no validation marker on injection point
    • Workaround Exists
    • Hide

      1. Re-open the file with Java Editor after enabling CDI support
      OR
      2. Edit and save the file - this forces CDI validator to work

      Show
      1. Re-open the file with Java Editor after enabling CDI support OR 2. Edit and save the file - this forces CDI validator to work

    Description

      There is a problem to force CDI validator to work. In my case, I created simple dynamic web project without CDI support, added some bean with Multiple beans eligible case (message not present yet). Add CDI support into project. Expected validation messages won't appear - cleaning the project doesn't help either.

      Attachments

        Issue Links

          Activity

            People

              rawagner@redhat.com Rastislav Wagner
              jjankovi Jaroslav Jankovič (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: