<div dir="ltr">Ok.</div><div class="gmail_extra"><br><div class="gmail_quote">2015-03-29 19:16 GMT-03:00 Stuart Douglas <span dir="ltr"><<a href="mailto:stuart.w.douglas@gmail.com" target="_blank">stuart.w.douglas@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br><br><div class="gmail_quote"><span class="">On Sun, 29 Mar 2015 at 21:34 Eduardo Sant´Ana da Silva <<a href="mailto:eduardo.santanadasilva@gmail.com" target="_blank">eduardo.santanadasilva@gmail.com</a>> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">
<p>Ok,</p>
<p>My approach will be create the following classes:<br><br></p>
<p>* ProhibitedEJBAnnotationsAnnotationMarker - Mark the deployment if it has EJB annotations that are not allowed (Similar to CDI Annotation marker no Weld)</p></div></blockquote><div><br></div></span><div>I don't really see why you would need to mark the deployment if it has invalid annotations, you should be able to just fail immediately. </div><div><br></div><div>I think all you need is a single DUP that looks at every EJB component description for this annotation, and if it is present throw an exception. </div><span class="HOEnZb"><font color="#888888"><div><br></div><div>Stuart</div></font></span><div><div class="h5"><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">
<p>* ProhibitedEJBAnnotationsDeploymentUnitProcessor - Do the deployment rollback in case of the marker is present.</p>
<p><br>Add the proper cleanup of the attachments no EjbCleanUpProcessor<br></p>
<p>Some auxilar classes to be created:<br></p>
<p><span>public</span><span> </span><span>enum</span><span> </span>ProhibitedEJBAnnotations<span> {</span><br></p>
<p> <span>/**<br></span> * javax.transaction.Transactional annotation.</p><p> */</p><p><span> </span>TRANSACTIONAL<span>(Constants.J</span>AVAX_TRANSACTION<span>, </span><span>"Transactional"</span><span>),</span></p>
<p>...<br></p>
<p> <span>private</span> <span>static</span> <span>class</span> Constants {<br></p>
<p> <span>/**<br></span> * package javax.transaction<br> */</p>
<p> <span>public</span> <span>static</span> <span>final</span> DotName <span>JAVAX_TRANSACTION</span> = DotName.createSimple(<span>"javax.transaction"</span>);</p>
<p>...</p>
<p>//////////////////////////////////////<br>/**<br> * Marker for deployments that have prohibited EJB annotations present<br> */</p>
<p><span>public</span> <span>final</span> <span>class</span> <span>ProhibitedEJBAnnotations</span>AnnotationMarker { (Similar to CdiAnnotationMarker on Weld)</p>
<p>...<br></p>
<p><span>public</span> <span>class</span> ProhibitedEJBAnnotationsDeploymentUnitProcessor <span>implements</span><br></p><p>DeploymentUnitProcessor {</p>
<p><br>If you guys came up with better names it will be good.<br></p><p>I was wondering as well if the CDIAnnotationMarker can be used directly from the Weld subsystem or it will be better isolate the subsystems?</p><p>Thx</p></div><div dir="ltr"><div style="font-size:12.8000001907349px"><span style="font-family:Arial;font-size:small">________________</span><span style="font-family:Arial;font-size:small">__________</span><br></div><div style="font-size:12.8000001907349px"><div align="left" style="font-family:Arial;font-size:small">Eduardo Sant'Ana da Silva </div></div></div><div dir="ltr"></div><div class="gmail_extra"><br><div class="gmail_quote">2015-03-28 15:05 GMT-03:00 Jason T. Greene <span dir="ltr"><<a href="mailto:jason.greene@redhat.com" target="_blank">jason.greene@redhat.com</a>></span>:</div></div><div class="gmail_extra"><div class="gmail_quote"><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><div>Good question. The easiest solution is probably to change one of the EJB dups that looks at annotations to also check for @Transactional and fail accordingly.</div><div><br>Sent from my iPhone</div><div><div><div><br>On Mar 28, 2015, at 11:56 AM, Eduardo Sant´Ana da Silva <<a href="mailto:eduardo.santanadasilva@gmail.com" target="_blank">eduardo.santanadasilva@gmail.com</a>> wrote:<br><br></div><blockquote type="cite"><div><div dir="ltr">
<p>I'm looking at this issue:<br><a href="https://issues.jboss.org/browse/WFLY-4169" target="_blank">https://issues.jboss.org/browse/WFLY-4169</a></p>
<p>In the ejb-3_2 specification :<br>It is illegal to associate JTA transactional interceptors (see [8]) with Enterprise JavaBeans. The EJB Container should fail deployment of such applications.[39]</p>
<p>@Transaction annotation was introduced in JTA 1.2, <br></p>
<p>As Narayana 5.0.0.M3 is now JTA 1.2 compliant, and it was introduced on Wildfly since version WildFly 8.0.0.Beta1, what should be done?<br></p>
<p>Because this restriction could be removed in the future versions:<br></p>
<p>[39] This restriction may be removed in a future release of this specification<br></p>
<p>If this is needed, how to proceed? Should be done on Weld subsystem, something similar with the annotations markers, just to log the problem or it will be more tricky, since the deployment should be rolled back (by the specification)?</p>-- <br><div><div dir="ltr"><div><span style="font-family:Arial;font-size:small">________________</span><span style="font-family:Arial;font-size:small">__________</span><br></div><div><div align="left" style="font-family:Arial;font-size:small">Eduardo Sant'Ana da Silva</div><div style="font-family:Arial;font-size:small"><br></div></div></div></div>
</div>
</div></blockquote></div></div><blockquote type="cite"><div><span>_______________________________________________</span><br><span>wildfly-dev mailing list</span><br><span><a href="mailto:wildfly-dev@lists.jboss.org" target="_blank">wildfly-dev@lists.jboss.org</a></span><br><span><a href="https://lists.jboss.org/mailman/listinfo/wildfly-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/wildfly-dev</a></span></div></blockquote></div></blockquote></div></div><div class="gmail_extra"><br><br clear="all"><div><br></div>-- <br><div><div dir="ltr"><div><span style="font-family:Arial;font-size:small">________________</span><span style="font-family:Arial;font-size:small">__________</span><br></div><div><div align="left" style="font-family:Arial;font-size:small">Eduardo Sant'Ana da Silva - Dr.</div><div style="font-family:Arial;font-size:small"><font face="Arial">Pesquisador / Consultor de TI<br></font></div><div style="font-family:Arial;font-size:small"><br></div></div></div></div>
</div>
______________________________<u></u>_________________<br>
wildfly-dev mailing list<br>
<a href="mailto:wildfly-dev@lists.jboss.org" target="_blank">wildfly-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/wildfly-dev" target="_blank">https://lists.jboss.org/<u></u>mailman/listinfo/wildfly-dev</a></blockquote></div></div></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div><span style="font-family:Arial;font-size:small">________________</span><span style="font-family:Arial;font-size:small">__________</span><br></div><div><div align="left" style="font-family:Arial;font-size:small">Eduardo Sant'Ana da Silva - Dr.</div><div style="font-family:Arial;font-size:small"><font face="Arial">Pesquisador / Consultor de TI<br></font></div><div style="font-family:Arial;font-size:small"><br></div></div></div></div>
</div>