Arcane zip commands for your ADF App and Hudson

I'm in the process of automating the builds of some of my sample applications that I create for proof of concepts and the like, and based on the fact that I'm heavily involved in the Hudson project now it made a lot of sense to use Hudson to help me. Now this entry is not about Hudson per-say, it is, however, related in that it's the type of syntax that you would use in a shell command executed from Hudson.

In this case I have a standard ADF project (Model, ViewController and the like)  which has been checked out from Subversion by Hudson and built with OJDeploy.  What I wanted to do in this case was also create a clean source archive from the checked out sources, without having to do a separate SVN export to get a clean copy.  So this involved working out the correct syntax of the unix zip command to exclude the artifacts (such as classes, WAR files and .svn directories) that I didn't want in the source zip file.

Anyway here's the command that creates the source zip in my top level deploy directory - hopefully it will save you a bunch of time if you ever need to do the same thing, it's one of those fiddly to get right things that always takes up way too much time.

The following is all one command, I've just split it up onto two lines for readability:

zip -r ./deploy/${JOB_NAME}_${BUILD_NUMBER}_src.zip * 
    -x 'deploy/*' -x */deploy/* -x *classes/* -x *.data* -x *.svn*

This command is issued as a Hudson build step from the ${WORKSPACE} which is also the ADF Application workspace root directory

Comments:

Hi Duncan,

I have a general question for you. I'm on a SOA project. We are using JDeveloper for the web services and UI. I'm new to the project and have noticed that we don't have Data Controls for any of the web services. Plus, very few of the UI pages have PageDef files so I think that means they don't utilize ADF bindings. The reason I'm given is because the government client has a "three zone architecture" and that business components would not work. I'm wondering if you know of a compelling reason to use ADF without using the bindings and business components?

Thanks for reading,
Dave Gress

Posted by guest on August 11, 2011 at 04:11 PM BST #

Well not really related to the posting but it's not Spam so I'll give an opinion.
The key attributes of am ADF Applicaiton are the use of ADF Bindings and the ADF Controller, as well as the UI components.
To get maximum value out of the framework you really need to be using at least those three bits.
ADF Business Components is not a must have - that just depends on the use case of where your data / services are coming from.
If, as is apparently the case here you are just using the UI Components on their own then you're loosing out on a lot of free functionality and you won't be able to use ADF security for example, which in turn would open up the door to integration with all of the Oracle security stack without having to write code (always a nice thing!)
Saying that the UI components on their own are simply the best set of JSF components out there so you're going to get a lot of value from just that.

Posted by Duncan on August 12, 2011 at 02:32 AM BST #

Post a Comment:
Comments are closed for this entry.
About

Hawaii, Yes! Duncan has been around Oracle technology way too long but occasionally has interesting things to say. He works in the Development Tools Division at Oracle, but you guessed that right? In his spare time he contributes to the Hudson CI Server Project at Eclipse
Follow DuncanMills on Twitter

Note that comments on this blog are moderated so (1) There may be a delay before it gets published (2) I reserve the right to ignore silly questions and comment spam is not tolerated - it gets deleted so don't even bother, we all have better things to do with our lives.
However, don't be put off, I want to hear what you have to say!

Search

Archives
« April 2014
MonTueWedThuFriSatSun
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
    
       
Today