<div dir="ltr">Yes, <div><br><div><span style="color:rgb(0,0,0);font-family:"Courier New";font-size:9pt;white-space:pre-wrap">logger(</span><span style="font-family:"Courier New";font-size:9pt;white-space:pre-wrap;color:rgb(0,128,0);font-weight:bold">"com.company.controllers"</span><span style="color:rgb(0,0,0);font-family:"Courier New";font-size:9pt;white-space:pre-wrap">, </span><span style="font-family:"Courier New";font-size:9pt;white-space:pre-wrap;color:rgb(102,14,122);font-weight:bold;font-style:italic">INFO</span><span style="color:rgb(0,0,0);font-family:"Courier New";font-size:9pt;white-space:pre-wrap">, [</span><span style="font-family:"Courier New";font-size:9pt;white-space:pre-wrap;color:rgb(0,128,0);font-weight:bold">'STDOUT'</span><span style="color:rgb(0,0,0);font-family:"Courier New";font-size:9pt;white-space:pre-wrap">],false)</span><br></div><div><span style="color:rgb(0,0,0);font-family:"Courier New";font-size:9pt;white-space:pre-wrap"><br></span></div><div><span style="color:rgb(0,0,0);font-size:9pt;white-space:pre-wrap"><font face="arial, helvetica, sans-serif">should do it.</font></span></div></div><div><span style="color:rgb(0,0,0);font-size:9pt;white-space:pre-wrap"><font face="arial, helvetica, sans-serif"> (*Chris*)</font></span></div></div><br><div class="gmail_quote"><div dir="ltr">On Thu, Nov 29, 2018 at 8:48 AM Joud Kassem <<a href="mailto:joud.kassem79@gmail.com">joud.kassem79@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi guys,<div><br></div><div>I'm upgrading my grails 2.5 app to grails 3.3.8 and started using logback, am new to it. My question is:</div><div>I have long package hierarchy, for example:</div><div>-----com</div><div>----------company</div><div>----------------controllers</div><div>--------------------client</div><div>-----------------------class1.groovy</div><div>-----------------------class2.groovy</div><div>-----------------------class3.groovy</div><div>-----------------------class4.groovy</div><div>-----------------------class5.groovy<br></div><div>--------------------auth</div><div><div>-----------------------class1.groovy</div><div>-----------------------class2.groovy</div><div>-----------------------class3.groovy</div><div>-----------------------class4.groovy</div><div>-----------------------class5.groovy</div></div><div>--------------------security</div><div><div>-----------------------class1.groovy</div><div>-----------------------class2.groovy</div><div>-----------------------class3.groovy</div><div>-----------------------class4.groovy</div><div>-----------------------class5.groovy</div></div><div><br></div><div>I want to define logger for all the controllers (all the included classes), is it possible to do something like:</div><div><pre style="color:rgb(0,0,0);font-family:"Courier New";font-size:9pt">logger(<span style="color:rgb(0,128,0);font-weight:bold">"com.company.controllers.*"</span>, <span style="color:rgb(102,14,122);font-weight:bold;font-style:italic">INFO</span>, [<span style="color:rgb(0,128,0);font-weight:bold">'STDOUT'</span>],false) ?</pre><pre style="color:rgb(0,0,0);font-family:"Courier New";font-size:9pt">or I have to do like this:</pre><pre style="color:rgb(0,0,0);font-family:"Courier New";font-size:9pt"><pre style="font-family:"Courier New";font-size:9pt">logger(<span style="color:rgb(0,128,0);font-weight:bold">"com.company.controllers.client"</span>, <span style="color:rgb(102,14,122);font-weight:bold;font-style:italic">INFO</span>, [<span style="color:rgb(0,128,0);font-weight:bold">'STDOUT'</span>],false)</pre><pre style="font-family:"Courier New";font-size:9pt"><pre style="font-size:9pt;font-family:"Courier New"">logger(<span style="color:rgb(0,128,0);font-weight:bold">"com.company.controllers.auth"</span>, <span style="color:rgb(102,14,122);font-weight:bold;font-style:italic">INFO</span>, [<span style="color:rgb(0,128,0);font-weight:bold">'STDOUT'</span>],false)</pre><pre style="font-size:9pt;font-family:"Courier New""><pre style="font-size:9pt;font-family:"Courier New"">logger(<span style="color:rgb(0,128,0);font-weight:bold">"com.company.controllers.security"</span>, <span style="color:rgb(102,14,122);font-weight:bold;font-style:italic">INFO</span>, [<span style="color:rgb(0,128,0);font-weight:bold">'STDOUT'</span>],false)</pre><pre style="font-size:9pt;font-family:"Courier New"">What is the best solution to not repeat a lot since I have a lot of child packages.s.</pre><pre style="font-size:9pt;font-family:"Courier New"">Thanks in advance,</pre><pre style="font-size:9pt;font-family:"Courier New"">Joud</pre>
</pre>
</pre>
</pre><pre style="color:rgb(0,0,0);font-family:"Courier New";font-size:9pt"><br></pre></div></div>
_______________________________________________<br>
logback-user mailing list<br>
<a href="mailto:logback-user@qos.ch" target="_blank">logback-user@qos.ch</a><br>
<a href="http://mailman.qos.ch/mailman/listinfo/logback-user" rel="noreferrer" target="_blank">http://mailman.qos.ch/mailman/listinfo/logback-user</a></blockquote></div>