Showing posts with label Artifactory. Show all posts
Showing posts with label Artifactory. Show all posts

Wednesday, May 09, 2007

Artifactory Dependency Viewer

Here are some nice digrams of my bookstore dependencies. Your able to see all direct and all transetive dependencies. You just need to use Artifactory as your Maven-Proxy and then you can get the Dependency Viewer which generates those cind of diagrams. Very nice!

From Misc

And now with all test-dependencies turned on (only junit ;o):


From Misc

You're also able to customize the diagram by dragging the dependencies where you want to have them. You just have to pass the pom-file of the project of which you want the dep-viewer to generate the diagram.

Try it out!

Cheers

Friday, April 27, 2007

Artifactory 1.2.1-rc1 released

Today I changed my Artifactory maven-prox version from 1.2.1-rc0 tp 1.2.1-rc1. Just copy the bin, lib, webapp and artifactory.jar to your existing artifactory application and overwrite it. Then restart your proxy and everything just should work right. To get the actual release-notes please check out the following link.

From Maven


From Maven

Take care

Wednesday, April 25, 2007

Maven & Co

Today, I decided to set up myself a reference-environtment with the following technologies and how you have to configure this tools that they work properly together. The following list shows all technologies and their versions I've used to set up this environment:

Reference-Project Bookstore

My plan is to develop an online bookstore just to show how maven works with a small web-app which consists of some submodules. In this first post I'd like to show only the build-configuration settings for this web-app. First I created a file structure where to store all my tools, projects and their settings. I created the following folders:

  • Continuum (my Build-Server)
  • Locals (my local maven-repository)
  • Projects (all my projects)
  • Proxies (all maven-proxies => e.g. Artifactory)
  • SVN (my Suversion-Repository)

The following picture shows the file-structure. I haven't collapse all folders because those are just some configuration-specific folders of the tools.

From Maven

All folders marked green are ander Subversion source-control. After I created this structure I had to create a subversion-repository. You just have to invoke the command 'svnadmin create path/to/your/custom/folder' and then import your structure with 'svn import /path/to/repo/ -m "some message"'. Then you have to checkout the project for the first time with 'svn checkout /path/to/repo'.


If everything works fine you can now set up you Continuum build-server to interact with your subversion-repo. This server will execute a specific maven commands (which you will be able to configure) to a certain time (cron job syntax) so you always will haven an overview of the checked in sources and if the application is clean.


There is one custom configuration you have to do if you would like to use the file-protocoll when you would like to set the path to your project's pom-file. By default the file-protocoll is turned off but you can turn it on by setting the 'allowedScheme'file'allowedScheme' in the application.xml of continuum which you will find in the CONTINUUM_HOME\apps\continuum\conf folder.

From Maven


After changing this property everything should work fine. Now you will be able to set up a maven-proxy which enables you to share your application and other artefacts with more developer.

From Maven

Artifactory is really easy to configure but I'm still a bit confused about some settings. I'm going to write about it in upcoming posts. There is only one thing, if you are behind a proxy you have to configure it in the artifactory.config.xml which you can find in the etc-folder of your Artifactory-installation. The following screenshots show some interesting maven-settings about the scm-Tag (Subversion) and the distributionManagement-Tag which configures the path to the snapshot-repository where you can deploy your snapshot-releases to the Artifactory repositories.



From Maven


From Maven

The last thing is to install a webserver where you can deploy your project-site. I have installed Xampp for this kind of purpose. You just have to confiugre your site-tag within your distributionManagement-Tag and then after invoking the mvn site:site site:deploy command your complete project-site will be generated and transfered to your configured path.

So now you have set up a good infrastructure to develop your application and can concentrate on your application logic. In upoming posts I will begin to design my bookstore-application and try to solve the remaining build-configuration-issues
.

Of course you're welcome to descripe your best-practices with this kind of technologies and I also would like to mention the fact that this is not a complete description but should give you an idea on how to set up a possible way for a building-environment for a Java-based web-application.

Cheers

Tuesday, April 24, 2007

Archivia doesn't work either

In my last post I tried to find a solution to learn maven to skip external, public repositories e.g. Ibiblio/repo1 if I invoke any maven-commands and only check the local and the internal maven-proxy. First I thought Archiva was the solution for my problem but I was wrong. Archiva will also behave like Mave-Proxy if I configure any remote repositories over Archivia's web-interface.

So, I kept researching and after a while I found another maven-proxy called Artifactory. As I read the description I recognized the fact that Artifactory is a complete rewrite of the old Maven-Proxy with many new features. For a detailed overview please check out Artifactory's official website.

So, filled with new hope I installed Artifactory and after a few configuration-troubles maven and this new proxy worked fine, but to my regret the feature I would like have also didn't work so I decided to write a mail to Artifactory's lead-developer and hope he will have a solution for my problem.

In spite of everything I would like to mention the cool Ajax-based feature of Artifactory's repository-browser and pom-preview. The following picutres shows the login, the browser, a right click on a pom-file and the preview.


From Maven


From Maven


From Maven


From Maven


I also found a thread on Nabble where two workarounds are described but both of them didn't work with my environment. So please, if you have any ideas let me know! *help*


Cheers