blob: 5fcbbd29fd77ea101cbfdae481ce98f19652d744 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<HTML>
<HEAD>
<!-- $PAGETITLE -->
<TITLE>OpenEJB - Tips and Suggestions</TITLE>
<LINK href="http://openejb.apache.org/all.css" rel="stylesheet" type="text/css">
<!--[if IE]><link rel="stylesheet" type="text/css" media="screen, projection" href="openejb.apache.org/ie.css"><![endif]-->
<LINK rel="SHORTCUT ICON" href="http://openejb.apache.org/images/favicon.ico">
<META http-equiv="Content-Type" content="text/html;charset=UTF-8">
<SCRIPT language="javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.1/jquery.min.js" type="text/javascript"></SCRIPT>
<SCRIPT language="javascript" src="http://openejb.apache.org/tweet/jquery.tweet.js" type="text/javascript"></SCRIPT>
<SCRIPT type="text/javascript">
$(document).ready(function(){
$(".tweet").tweet({
avatar_size: 32,
count: 4,
fetch:25,
username: "openejb",
list: "contributors",
template:"{avatar}{text}",
filter: function(t){ return /openejb/i.test(t["tweet_raw_text"]); },
loading_text: "loading list..."
});
});
</SCRIPT>
</HEAD>
<BODY>
<!-- Delay the loading of the external javascript file needed for labels (as it takes too long to load and visibly holds loading of the page body) -->
<!-- To do this without javascript errors over undefined functions, we need to declare stubs here (that are overrided later by the proper implementations) -->
<SCRIPT language="JavaScript" type="text/javascript">
function doAddLabel(hideTextfieldAfterAddParam)
{
// stub
}
function onAddLabel()
{
// stub
}
function showLabelsInput()
{
// stub
}
</SCRIPT>
<A name="top"></A>
<TABLE class="frameTable" cellpadding="0" cellspacing="0" border="0">
<TR class="Row1">
<TD class="Col1"><IMG alt="" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col2"><IMG alt="" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col3"><IMG alt="" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col4"><IMG alt="" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col5"><IMG alt="" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
</TR>
<TR class="Row2">
<TD class="Col1"><IMG alt="" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col2">&nbsp;</TD>
<TD class="Col3" id="breadcrumbs">
<!-- $TOP_NAV_BAR -->
<A href="index.html" title="Index">Home</A> | <A href="news.html" title="News">News</A> | <A href="faq.html" title="FAQ">FAQ</A> | <A href="download.html" title="Download">Download</A> | <A href="mailing-lists.html" title="Mailing Lists">Lists</A> | <A href="http://issues.apache.org/jira/browse/OPENEJB" class="external-link" rel="nofollow">Issues</A>
</TD>
<TD class="Col4"><IMG alt="" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col5">&nbsp;</TD>
</TR>
<TR class="Row3">
<TD class="Col1"><IMG alt="" class="Row3Img" id="thinLine" src="http://openejb.apache.org/images/line_sm.gif"></TD>
<TD class="Col2"><IMG alt="" class="Row3Img" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col3"><IMG alt="" class="Row3Img" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col4"><IMG alt="" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col5"><IMG alt="" class="Row3Img" src="http://openejb.apache.org/images/dotTrans.gif"></TD>
</TR>
<TR class="Row4">
<TD class="Col1">
<SPAN id="Navigation">
<H3><A name="Navigation-Overview"></A>Overview</H3>
<UL class="alternate" type="square">
<LI><A href="index.html" title="Index">Home</A></LI>
<LI><A href="news.html" title="News">News</A></LI>
<LI><A href="faq.html" title="FAQ">FAQ</A></LI>
<LI><A href="download.html" title="Download">Download</A></LI>
<LI><A href="../OPENEJBx30/index.html" title="Index">Documentation</A></LI>
<LI><A href="examples.html" title="Examples">Examples</A></LI>
<LI><A href="http://cwiki.apache.org/confluence/display/OPENEJB/Lightening%20Demos" class="external-link" rel="nofollow">Lightning Demos</A></LI>
<LI><A href="mailing-lists.html" title="Mailing Lists">Mailing Lists</A></LI>
<LI><A href="source-code.html" title="Source Code">Source Code</A></LI>
<LI><A href="http://blogs.apache.org/openejb" class="external-link" rel="nofollow">Project Blog</A></LI>
</UL>
<H3><A name="Navigation-Servers"></A>Servers</H3>
<UL class="alternate" type="square">
<LI><A href="local-server.html" title="Local Server">Local</A></LI>
<LI><A href="remote-server.html" title="Remote Server">Remote</A></LI>
</UL>
<H3><A name="Navigation-Integrations"></A>Integrations</H3>
<UL class="alternate" type="square">
<LI><A href="../OPENEJBx30/tomcat.html" title="Tomcat">Tomcat</A></LI>
<LI><A href="geronimo.html" title="Geronimo">Geronimo</A></LI>
<LI><A href="webobjects.html" title="WebObjects">WebObjects</A></LI>
</UL>
<H3><A name="Navigation-Community"></A>Community</H3>
<UL class="alternate" type="square">
<LI><A href="team.html" title="Team">Team</A></LI>
<LI><A href="articles.html" title="Articles">Articles</A></LI>
<LI><A href="http://webchat.freenode.net/?channels=openejb" class="external-link" rel="nofollow">IRC</A></LI>
</UL>
<H3><A name="Navigation-RelatedProjects"></A>Related Projects</H3>
<UL class="alternate" type="square">
<LI><A href="http://activemq.apache.org/" class="external-link" rel="nofollow">ActiveMQ</A></LI>
<LI><A href="http://openjpa.apache.org/" class="external-link" rel="nofollow">OpenJPA</A></LI>
<LI><A href="http://cxf.apache.org/" class="external-link" rel="nofollow">CXF</A></LI>
</UL>
<H3><A name="Navigation-Index"></A>Index</H3>
<UL class="alternate" type="square">
<LI><A href="space-index.html" title="Space Index">Site Index</A></LI>
<LI><A href="../OPENEJBx30/space-index.html" title="Space Index">Doc Index</A></LI>
</UL>
<H3>
<A name="Navigation-Feeds"></A>
Feeds
</H3>
<UL class="feeds">
<LI>
<A href="http://cwiki.apache.org/confluence/spaces/rss.action?key=OPENEJB&newPages=false">
<IMG src="http://openejb.apache.org/images/rss.gif"></A>
<A class="feedsText" href="http://cwiki.apache.org/confluence/spaces/rss.action?key=OPENEJB&newPages=false">Site</A>
</LI>
<LI><A href="http://cwiki.apache.org/confluence/spaces/blogrss.action?key=OPENEJB">
<IMG src="http://openejb.apache.org/images/rss.gif"></A>
<A class="feedsText" href="http://cwiki.apache.org/confluence/spaces/blogrss.action?key=OPENEJB">News</A>
</LI>
</UL>
</SPAN>
</TD>
<TD class="Col2">&nbsp;</TD>
<TD class="Col3">
<TABLE id="PageHeader" border="0" width="100%">
<TR>
<TD>
<A href="http://openejb.org/">
<IMG hspace="0" src="http://openejb.apache.org/images/logo_openejb.gif" vspace="0">
</A>
</TD>
<TD align="right">
<A href="http://www.apache.org/">
<IMG src="http://www.apache.org/images/asf-logo.gif" width="258" height="66">
</A>
</TD>
</TR>
<TR>
<TD id="page_title">
<!-- $TITLE -->
Tips and Suggestions
</TD>
<TD align="right">
<BR><BR>
<!-- Google CSE Search Box Begins -->
<FORM id="searchbox_010475492895890475512:_t4iqjrgx90" action="http://www.google.com/cse">
<INPUT type="hidden" name="cx" value="010475492895890475512:_t4iqjrgx90">
<INPUT type="hidden" name="cof" value="FORID:0">
<INPUT name="q" type="text" size="25">
<INPUT type="submit" name="sa" value="Search">
</FORM>
<SCRIPT type="text/javascript" src="http://www.google.com/coop/cse/brand?form=searchbox_010475492895890475512:_t4iqjrgx90"></SCRIPT>
<!-- Google CSE Search Box Ends -->
</TD>
</TR>
</TABLE>
<P>
<!-- $BODY -->
<DIV id="PageContent">
<BLOCKQUOTE>
</BLOCKQUOTE>
<H2><A name="TipsandSuggestions-Usefulinformationforcontributors"></A>Useful information for contributors</H2>
<H3><A name="TipsandSuggestions-JIRAusage"></A>JIRA usage</H3>
<P>It's good to leverage JIRA, but everything that happens there should be considered invisible for the most part and only reviewed on a random and infrequent basis.</P>
<P>A good way to bring jira &quot;discussion&quot; back to the list is to follow up on the list rather than posting more jira comments. Maybe by having the first followup comment be a link to Nabble's &quot;forum&quot; view of the list. Optionally, you can Cc jira@apache.org and include &quot;<A href="https://cwiki.apache.org/confluence/pages/createpage.action?spaceKey=OPENEJB&title=jira&linkCreation=true&fromPageId=65635" class="createlink">jira</A> OPENEJB-XXX&quot; anywhere in your subject line and your email will get added as a jira comment.</P>
<P>For those looking to contribute, there are some good habits to put into use. We use a permission scheme called &quot;Interactive Permissions.&quot; It's description has some good information:</P>
<P> Interactive Permissions</P>
<P> This permissions model differs from the Standard Permissions<BR>
model in that people in the Contributor role must interact with<BR>
the dev list to get to get issues assigned to them and issues<BR>
closed. This isn't a trust issue, more that there are a few<BR>
benefits.</P>
<P> 1. Active contributors hitting the list to begin and end work<BR>
shows other people not yet active how to get involved.</P>
<P> 2. Adds more &quot;touch points&quot; between Contributors and<BR>
Committers. It should be possible to &quot;see&quot; the active<BR>
contributors even if you are not watching the JIRA or SVN<BR>
notifications. It's also hoped that the practice of<BR>
announcing your intentions on the dev list will persist<BR>
even when the Contributor becomes a Committer.</P>
<P> 3. Gives Committers the opportunity to help, mentor or<BR>
otherwise get the Contributor going in the right direction<BR>
before a task is started; potentially resulting in fewer<BR>
rejected patches, less waisted Contributor time, and more<BR>
collaborative development.</P>
<P> 4. Overall brings more communication to the dev list before<BR>
all work is done and all decisions made giving more<BR>
potential to collaboration.</P>
<P><INS>If you'd like to get added to the openejb-contributors JIRA group, just ping the list with your JIRA id and someone will add you.</INS></P>
<H3><A name="TipsandSuggestions-Commits"></A>Commits</H3>
<P><B>Contributed by</B>: David Blevins<BR>
<INS>Here is an email from David Blevins explaining the things he keeps in mind during commits.</INS> <B><INS>Definitely worth a read</INS></B><INS>:</INS></P>
<P>I generally <B>try never to reformat a file and make changes at the same time</B> as it makes it impossible for anyone to see what I've changed. Needle in a haystack. I <B>try to get the reformatting as its own commit</B> before or after I change a file.</P>
<P>A lot of times I end up tweaking a bunch of little unrelated things while working on a bigger change. <B>I tend to like to &quot;clear them out&quot; in separate commits as to isolate the big change in one commit</B>. Sometimes I'm not so good at that and other times I'm really meticulous about it.</P>
<P><B>Include the JIRA number and title (if there is a jira)</B>. I try never to say &quot;Fixed FOO-2543&quot; all by itself. Reviewing the last 10 changes on a file is a super big PITA when all you see is numbers to other systems. <B>I shoot for more or less &quot;Fixed &lt;issue-number&gt; &lt;issue-title&gt; &lt;how-did-i-fix-it&gt;&quot;</B> Sometimes the &quot;how did i fix it&quot; part is obvious by the title, other times not. Sometimes I'm too tired and the wife is impatiently waiting for me to leave the computer <IMG class="emoticon" src="https://cwiki.apache.org/confluence/images/icons/emoticons/smile.gif" height="20" width="20" align="absmiddle" alt="" border="0"><BR>
As far as jiras go, there doesn't have to be a jira for absolutely every commit &ndash; what's the point of that. I <B>try to make sure there's a jira for anything we'd definitely want to see in the release notes</B>. Sometimes I don't get the jira created till long after the change, towards release time when creating the release notes <IMG class="emoticon" src="https://cwiki.apache.org/confluence/images/icons/emoticons/smile.gif" height="20" width="20" align="absmiddle" alt="" border="0"> It's pretty easy to forget stuff that way though <IMG class="emoticon" src="https://cwiki.apache.org/confluence/images/icons/emoticons/smile.gif" height="20" width="20" align="absmiddle" alt="" border="0"></P>
<P>As far as jira titles, I always <B>try and make them short and succinct</B> for the future release notes.</P>
<H3><A name="TipsandSuggestions-SVNJIRA"></A>SVN + JIRA</H3>
<H4><A name="TipsandSuggestions-Contributedby%3AVamsi"></A><B>Contributed by</B>: Vamsi</H4>
<P>I had trouble figuring out if a revision is related to a JIRA and what all revisions corresponded to a particular JIRA. So, I always include the JIRA number (if there is an associated JIRA) in the svn comment and once committed, I add the revision number to the JIRA comment. It may be a minute or two more to do this. But, it saves a lot of time if you ever have to investigate a regression or if there are multiple revisions for a JIRA you know where to find the revision numbers instead of having to mine the svn logs.</P>
<P>Some files may be missing $Rev$ and $Date$ in the header. Whenever I modify an existing file, I always check if I have to add these missing $Rev$ $Date$ and add those so that the file will have them from my next commit onwards.</P>
<H4><A name="TipsandSuggestions-Contributedby%3ADavidBlevins"></A><B>Contributed by</B>: David Blevins</H4>
<BLOCKQUOTE>
<P>If you put &quot;[jira] OPENEJB-XXX&quot; anywhere in your subject line and cc jira@apache.org our email gets added as a comment with all '&gt; quoted' text stripped out.</P></BLOCKQUOTE>
<P>PS: XXX is the JIRA issue number</P>
<H4><A name="TipsandSuggestions-Details"></A>Details</H4>
<P>The following subject lines did work:</P>
<UL class="alternate" type="square">
<LI>Subject: [jira] OPENEJB-670</LI>
<LI>Subject: Some other subject prefix ([jira] OPENEJB-670)</LI>
<LI>Subject: Re: Some other subject prefix ([jira] OPENEJB-670)</LI>
</UL>
<P>The following subject lines did <B>not</B> work:</P>
<UL class="alternate" type="square">
<LI>Subject: OPENEJB-670</LI>
<LI>Subject: Some other subject prefix (jira: OPENEJB-670)</LI>
<LI>Subject: Some other subject prefix (jira OPENEJB-670)</LI>
<LI>Subject: Some other subject prefix (OPENEJB-670)</LI>
</UL>
<P>It appears that as long as the subject contains &quot;[jira] FOO-XXX&quot; the email contents will be added as comments.</P>
<P>It also appears that all quoted text regardless of place in the email is stripped out and the remaining text is added as the comment.</P>
<P>The exact email bodies, white space and all, for the &quot;reply text&quot; comments above are:</P>
<P>&lt;one&gt;<BR>
Reply text at the top.</P>
<P>&ndash; David</P>
<P>On Aug 23, 2007, at 1:02 PM, David Blevins wrote:</P>
<P>Testing adding comments via email with this subject line &quot;Some other subject prefix ([jira] OPENEJB-670)&quot;</P>
<P>&lt;/one&gt;</P>
<P>&lt;two&gt;</P>
<P>On Aug 23, 2007, at 1:02 PM, David Blevins wrote:</P>
<P>Testing adding comments via email with this subject line &quot;Some other subject prefix ([jira] OPENEJB-670)&quot;</P>
<P>Reply text at the bottom.</P>
<P>&ndash;<BR>
David</P>
<P>&lt;/two&gt;</P>
<P>&lt;three&gt;<BR>
On Aug 23, 2007, at 1:02 PM, David Blevins wrote:</P>
<P>Testing adding comments via email</P>
<P>Some reply text</P>
<P>with this subject line &quot;Some other subject prefix ([jira] OPENEJB-670)&quot;</P>
<P>Some more reply text</P>
<P>&ndash;<BR>
David</P>
<P>&lt;/three&gt;</P>
<H3><A name="TipsandSuggestions-scp%2Cssh%2Candrsyncexamplesforworkingwithfilesanddirectoriesonpeople.apache.org"></A>scp, ssh, and rsync examples for working with files and directories on people.apache.org</H3>
<P><B>Contributed by</B>: David Blevins</P>
<P><B>copying a file to apache from locahost</B><BR>
scp topsecret.tar.gz kmalhi@people.apache.org:<BR>
scp index.html kmalhi@people.apache.org:public_html/</P>
<P><B>copying a file from apache to localhost &ndash; reverse of the above</B><BR>
scp kmalhi@people.apache.org:topsecret.tar.gz ./<BR>
scp kmalhi@people.apache.org:public_html/index.html ./</P>
<P><B>copying directories</B><BR>
scp &#45;r kmalhi@people.apache.org:public_html ./<BR>
scp &#45;r public_html kmalhi@people.apache.org:</P>
<P><B>When the directory exists, better to rsync</B></P>
<P><B>pull a dir from apache</B><BR>
rsync &#45;v &#45;e ssh &#45;lzrptog kmalhi@people.apache.org:public_html ./<BR>
rsync &#45;v &#45;e ssh &#45;lzrptog kmalhi@people.apache.org:/home/kmalhi/public_html ./</P>
<P><B>the two above commands do the exact same thing</B></P>
<P><B>push the same dir to apache</B><BR>
rsync &#45;v &#45;e ssh &#45;lzrptog ./public_html kmalhi@people.apache.org:<BR>
rsync &#45;v &#45;e ssh &#45;lzrptog ./public_html kmalhi@people.apache.org:/home/kmalhi/</P>
<P><B>the two above commands do the exact same thing</B></P>
<P><B>sometimes useful to execute commands over ssh (piping works too)</B><BR>
ssh people.apache.org ls /home &#124; tee home-dirs-on-apache.txt<BR>
echo &#45;e 'Hello, me\n\nHow am I doing today?' &#124; ssh<BR>
kmalhi@people.apache.org mail &#45;s 'Greetings' kmalhi@apache.org</P>
<P><B>For Putty users</B><BR>
<B>Contributed by:</B> Mohammad<BR>
I have Putty on my linux machine and it is easier to use, Putty has a Windows version too, I issue this command to upload a file to my home dir on people.apache.org</P>
<DIV class="code panel" style="border-width: 1px;"><DIV class="codeContent panelContent">
<PRE class="code-java">
pscp [[file-name] | [dir]] mnour@people.apache.org:~/
</PRE>
</DIV></DIV>
<P>and if you want to access your home page, you should create a dir with the name public_html, and then upload files to it.</P>
<H3><A name="TipsandSuggestions-Acoolsubversiontip"></A>A cool subversion tip</H3>
<P><B>Contributed by</B>: Jacek Laskowski.</P>
<P><B>It'll let you forget about some svn administrative commands you'd otherwise have to type in on the command line.</B><BR>
Edit/Add the following configurations to &#126;/.subversion/config:</P>
<DIV class="code panel" style="border-width: 1px;"><DIV class="codeContent panelContent">
<PRE class="code-java">
[miscellany]
global-ignores = *.log *.save *.o *.lo *.la #*# .*~ *~ .#* .DS_Store
build dist target *.ipr *.iml *.iws .project .classpath .settings
enable-auto-props = yes
[auto-props]
*.c = svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Author Id Revision HeadURL
*.cpp = svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Author Id Revision HeadURL
*.h = svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Author Id Revision HeadURL
*.dsp = svn:eol-style=CRLF
*.dsw = svn:eol-style=CRLF
*.sh = svn:executable;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.cmd = svn:mime-type=text/plain;svn:eol-style=CRLF
*.bat = svn:mime-type=text/plain;svn:eol-style=CRLF
Makefile = svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Author Id Revision HeadURL
*.obj = svn:mime-type=application/octet-stream
*.bin = svn:mime-type=application/octet-stream
*.bmp = svn:mime-type=image/bmp
*.class = svn:mime-type=application/java
*.doc = svn:mime-type=application/msword
*.exe = svn:mime-type=application/octet-stream
*.gif = svn:mime-type=image/gif
*.gz = svn:mime-type=application/x-gzip
*.jar = svn:mime-type=application/java-archive
*.jelly = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date
Revision
*.jpg = svn:mime-type=image/jpeg
*.jpeg = svn:mime-type=image/jpeg
*.pdf = svn:mime-type=application/pdf
*.png = svn:mime-type=image/png
*.tgz = svn:mime-type=application/octet-stream
*.tif = svn:mime-type=image/tiff
*.tiff = svn:mime-type=image/tiff
*.zip = svn:mime-type=application/zip
*.txt = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.xml = svn:mime-type=text/xml;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.ent = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.dtd = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.vsl = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.xsd = svn:mime-type=text/xml;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.xsl = svn:mime-type=text/xml;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.wsdl = svn:mime-type=text/xml;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.htm = svn:mime-type=text/html;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.html = svn:mime-type=text/html;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.css = svn:mime-type=text/css;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.js = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.jsp = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.txt = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
*.java = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date
Revision
*.properties = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date
Revision
*.sql = svn:mime-type=text/plain;svn:eol-style=<SPAN class="code-keyword">native</SPAN>;svn:keywords=Date Revision
</PRE>
</DIV></DIV>
<H3><A name="TipsandSuggestions-Maventips"></A>Maven tips</H3>
<P><B>Contributed by:</B> Jacek and David<BR>
<B>I want to make a small change in a module , for example openejb-core and then want to build a snapshot of openejb-standalone, start the server and test my change. What is the easiest and fastest way of doing it?</B><BR>
Run the following from within openejb-core</P>
<DIV class="code panel" style="border-width: 1px;"><DIV class="codeContent panelContent">
<PRE class="code-java">
mvn -Dtest=none install
</PRE>
</DIV></DIV>
<P>Now run the following from within openejb-standalone</P>
<DIV class="code panel" style="border-width: 1px;"><DIV class="codeContent panelContent">
<PRE class="code-java">
mvn -Dtest=none clean <SPAN class="code-keyword">package</SPAN>
</PRE>
</DIV></DIV>
<P><B>So what if I wanted to do the above in a single command?</B><BR>
It's possible with ${module} and ${assemble} properties and <B>create a profile or a plugin</B></P>
<P>Another option is and <B>if you're in bash</B>, here's what could be done</P>
<DIV class="code panel" style="border-width: 1px;"><DIV class="codeContent panelContent">
<PRE class="code-java">
# camping out in assembly/openejb-standalone/
$ (cd ../../container/openejb-core &amp;&amp; mvn clean install -Dtest=skip) &amp;&amp; mvn clean install &amp;&amp; ./<SPAN class="code-keyword">try</SPAN>.sh
</PRE>
</DIV></DIV>
<P>That's one command, parens and all. The first &quot;$&quot; is the prompt,don't type that. Then just edit ./try.sh to do what you're looking for on the standalone zip.</P>
<P>The parens in bash are great as nothing done in there lasts &ndash; at least no changes to the environment. So you can 'cd' around all you want and not have to 'cd' back when done.</P>
<P>For example</P>
<DIV class="code panel" style="border-width: 1px;"><DIV class="codeContent panelContent">
<PRE class="code-java">
$ export FOO=hello &amp;&amp; (export FOO=byebye) &amp;&amp; echo $FOO
hello
$ cd ~ &amp;&amp; echo $PWD &amp;&amp; (cd /tmp &amp;&amp; echo $PWD) &amp;&amp; echo $PWD
/Users/dblevins
/tmp
/Users/dblevins
</PRE>
</DIV></DIV>
<P>As well, several commands can be combined with '&amp;&amp;'. Far better than just separating commands with ';' as if one of the commands fail, the remaining commands will not be executed.</P>
<P><B>Suggestion from Dain</B></P>
<BLOCKQUOTE>
<P>&nbsp;I suggest that you always do a full build (with tests) before committing. I do this even if the change is small because I have been burned too many times by trivial changes. At the very least I suggest you run</P>
<DIV class="code panel" style="border-width: 1px;"><DIV class="codeContent panelContent">
<PRE class="code-java">
mvn -Dtest=none clean install
</PRE>
</DIV></DIV>
<P>Using &#45;Dtest=none instead of &#45;Dmaven.test.skip=true causes maven to compile the test classes so you know that your change doesn't have compile errors.<BR>
If you want to be thorough, run with &#45;Dassemble.</P></BLOCKQUOTE>
<H3><A name="TipsandSuggestions-JAXBUsage"></A>JAXB Usage</H3>
<DIV class="panelMacro"><TABLE class="noteMacro"><COLGROUP><COL width="24"><COL></COLGROUP><TR><TD valign="top"><IMG src="https://cwiki.apache.org/confluence/images/icons/emoticons/warning.gif" width="16" height="16" align="absmiddle" alt="" border="0"></TD><TD><B>TODO</B><BR>Create a write up from here <A href="http://www.nabble.com/jaxb-question-td18023648.html" class="external-link" rel="nofollow">http://www.nabble.com/jaxb-question-td18023648.html</A></TD></TR></TABLE></DIV>
</DIV>
</P>
</TD>
<TD class="Col4"><IMG src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col5">
</TD>
</TR>
<TR class="Row5">
<TD class="Col1">&nbsp;</TD>
<TD class="Col2">&nbsp;</TD>
<TD class="Col3">
<BR>
<BR>
<IMG width="100%" height="1" src="http://openejb.apache.org/images/line_light.gif">
<TABLE width="100%">
<TR>
<TD>
<SPAN class="bodyGrey">
<SMALL>
<NOTICE><!-- $FOOTER -->
Apache OpenEJB is an project of The Apache Software Foundation (ASF)
</NOTICE>
<BR>
Site Powered by
<A href="http://atlassian.com/">Atlassian</A>
<A href="http://atlassian.com/confluence/">Confluence</A>
.
</SMALL>
</SPAN>
</TD>
<TD align="right">
<A style="color:#999;font-size:small;font-weight:normal;" href="https://cwiki.apache.org/confluence/pages/editpage.action?spaceKey=OPENEJB&title=Tips%20and%20Suggestions">[ edit ]</A>
</TD>
</TR>
</TABLE>
<BR>
</TD>
<TD class="Col4"><IMG src="http://openejb.apache.org/images/dotTrans.gif"></TD>
<TD class="Col5">&nbsp;</TD>
</TR>
</TABLE>
<!-- Needed for composition plugin -->
<!-- delay the loading of large javascript files to the end so that they don't interfere with the loading of page content -->
<SPAN style="display: none">
<SCRIPT type="text/javascript" language="JavaScript" src="http://cwiki.apache.org/confluence/labels-javascript"></SCRIPT>
<SCRIPT src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</SCRIPT>
<SCRIPT type="text/javascript">
_uacct = "UA-2717626-1";
urchinTracker();
</SCRIPT>
</SPAN>
</BODY>
</HTML>