Menu

#829 PrefixDeploymentSorter and non-digit URL

v3.0 Rabbit Hole
closed-fixed
nobody
5
2002-09-24
2002-09-17
No

If using
org.jboss.deployment.scanner.PrefixDeploymentSorter
those files beginning with non-digit are deployed FIRST, not LAST
as declared in comments inside jboss-service.xml.
This is
because private int getPrefixValue(URL url) returns -1 if no digital
prefix exists. It should return Integer.MAX_VALUE or something.

Discussion

  • Christian Riege

    Christian Riege - 2002-09-17

    Logged In: YES
    user_id=176671

    The question is if this is a bug in the "documentation" or
    in the "implementation" :). The JavaDoc comments in
    PrefixDeploymentSorter are misleading here, too as they state:

    "... If there is no leading digits, then they will compare
    as less than any name with leading digits."

    and a few lines further down:

    "Ex.these names are in ascending order:
    001test.jar, 5test.rar, 5foo.jar, 120bar.jar, test.sar,
    crap.ear )"

    which contradicts the previous statement.

    Which one is the "correct" behaviour here? I would opt for
    the "deploy with no prefix first" strategy (as it is
    implemted ATM) and fix the comments in the .xml file.

     
  • Larry Sanderson

    Larry Sanderson - 2002-09-17

    Logged In: YES
    user_id=379453

    This was my bad - the original implementation of this was to
    deploy prefixed first (as all the comments indicate).

    Then it was agreed to change this to prefixed last. I changed
    the code, but not the docs.

    I'll check in new docs today.

     
  • Scott M Stark

    Scott M Stark - 2002-09-24

    Logged In: YES
    user_id=175228

    The docs have been updated.

     
  • Scott M Stark

    Scott M Stark - 2002-09-24
    • status: open --> closed-fixed
     

Log in to post a comment.