Results 1 to 2 of 2
  1. #1
    jackett_dad is offline Member
    Join Date
    Mar 2012
    Posts
    2
    Rep Power
    0

    Default Maven module version management and web service stub generation

    I'm at a company that has many individual projects that sometimes inter-depend, but rarely co-exist in the same development environment. When I came on board, having a need to debug through many of these applications, I cobbled these modules together under a master pom project and have to restrict incoming changes to the pom files for each module since the version number is always changing, which cause my development environment to use the build artifact instead of the module dependency, mussing up my project until I get it all synchronized up again. It's a pain, but I'm hoping to make this right.

    So I'd like to demonstrate what the construct at the company is vs. what I have in my local environment. Maybe there is a change we can make to our process so that this won't always be an issue.

    What we have is several service and web modules. The services are typically depended upon by several web clients. To make it simple, here are the services:

    DB Service:
    XML Code:
    <groupId>com.co.services</groupId>
    <artifactId>dbservice</artifactId>
    <version>1.0.10</version>
    REST Service:

    XML Code:
    <groupId>com.co.rest</groupId>
    <artifactId>restservice</artifactId>
    <version>2.0.10</version>
    
    <dependencies>
        <dependency>
            <groupId>com.co.services</groupId>
            <artifactId>dbservice</artifactId>
            <version>1.0.10</version>
        </dependency>
    </dependencies>
    Web Client:

    XML Code:
    <groupId>com.co.web</groupId>
    <artifactId>client</artifactId>
    <version>3.0.10</version>
    <!-- Does not have direct dependencies on REST Service, uses URLs only -->
    Whenever the DB Service is built, it's version number is automatically changed. So for the next build, version 1.0.11 will be the latest version number, and I have to update the dependency in REST_SERVICE to match. Otherwise, by development environment will use the historical previous version (1.0.11). Is there a way I can automatically use whatever version is most recent? I'd like to be able to allow the pom to be updated when I pull the latest code, but if a version mismatch occurs, I have to fix my environment and I have taken to just ignoring server changes to pom.xml.

    The second part of my question concerns a glitchy build procedure we have. We have several web services for which WSDL's are often regenerated, this whenever a change to the public interface has been made. What the folks here do is to generate a client service stub jar that each web service client depends on. This jar is built manually and manually deployed to our corporate repository, which is a huge pain in the you-know-what. Especially since I sometimes make changes in these services and I have to send an email off to request this step be done. Then I have to update my dependency version for the client stubs jar and then I'm OK.

    I personally am fine with generating the client service stubs on my own in my project as I need them, but when the project goes to staging, I have to go by the rules since the build is done on another machine (my local pom entries for generating client service stubs is not on the build machine, and so if the client services stub is not current then there is a problem).

    So how would you slice this problem up so that the process is streamlined?

    Thanks for any advice you can provide.

    Scott
    Last edited by jackett_dad; 12-28-2012 at 03:56 PM. Reason: Formatting changes

  2. #2
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,250
    Rep Power
    19

Similar Threads

  1. Replies: 0
    Last Post: 12-17-2012, 01:32 PM
  2. How to convert from Ant project to maven project?
    By jiapei100 in forum New To Java
    Replies: 0
    Last Post: 06-08-2011, 10:01 AM
  3. Using Maven
    By tascoa in forum New To Java
    Replies: 0
    Last Post: 08-21-2009, 03:45 PM
  4. Replies: 0
    Last Post: 04-20-2009, 06:26 PM
  5. Maven
    By Java Tutorial in forum Java Tutorial
    Replies: 0
    Last Post: 06-02-2008, 12:58 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •