Announcement Announcement Module
Collapse
No announcement yet.
Configuring Ivy Cache as additonal library repository. Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Configuring Ivy Cache as additonal library repository.

    First off, great work on the new dm Server. You guys are turning stuff around at an incredible pace!

    I have read the dm Server User Guide chapter on configuring the server to scan my ivy-cache for looking up bundles. However, the guide is ambiguous in regards to the setup for searching for libraries in the ivy-cache. I've tried several configurations and cannot seem to get it to work.

    My ivy-cache is laid out in the following manner:
    • org (ex: org.springframework)
      • name (ex: org.springframework.spring-library)
        • version (ex: 3.0.0.M3)
          • library file (ex: org.springframework.spring-library-3.0.0.M3.libd)

    I think it would be helpful to list examples on how the wildcards resolve (i.e., {org}, {name}, {version}, {bundle}, {library}, etc.). Also, I'm curious why the internal dm Server repository search paths for bundles only use {bundle} and not {bundle}.jar?

  • #2
    Originally posted by marshallmccain View Post
    First off, great work on the new dm Server. You guys are turning stuff around at an incredible pace!
    Thanks! It's great to hear that you like it.

    I have read the dm Server User Guide chapter on configuring the server to scan my ivy-cache for looking up bundles. However, the guide is ambiguous in regards to the setup for searching for libraries in the ivy-cache. I've tried several configurations and cannot seem to get it to work.

    My ivy-cache is laid out in the following manner:
    • org (ex: org.springframework)
      • name (ex: org.springframework.spring-library)
        • version (ex: 3.0.0.M3)
          • library file (ex: org.springframework.spring-library-3.0.0.M3.libd)

    I think it would be helpful to list examples on how the wildcards resolve (i.e., {org}, {name}, {version}, {bundle}, {library}, etc.).
    The repository implementation uses Ant-style path matching under the covers, with each of the {foo} wildcards simply being an alias for a * in an Ant-style path. In your case, the configuration should be {org}/{name}/{version}/{library}.libd. This'll map down to */*/*/*.libd. You can use the Ant-style format in the configuration if you'd prefer. The {foo} wildcard format is simply there to aid readability.

    Also, if a path in the configuration is relative, it's taken as being relative to the server's home. You can also use an absolute path in the configuration.

    Let me know how you get on, please. Once we've got you up and running, and like to know what information was missing / unclear in the user guide so that we can improve it.

    Also, I'm curious why the internal dm Server repository search paths for bundles only use {bundle} and not {bundle}.jar?
    The reason for this is that the repository supports "exploded" bundles, i.e. a bundle that's in the form of a nested directory structure. In this case the name of the bundle's directory is unlikely to end with .jar so {bundle} is used so that all files (jars and directories) are found by the repository.

    Comment


    • #3
      What about the jars in /lib

      Thanks Andy, that clears things up. I was assuming specific values were being substituted for each wildcard; however, I now understand it only references an Ant "*" path.

      I'm not sure if this is the right place to continue my query, but what about the jars in /lib (I'll copy this query on the STS forums as well).

      I need to import org.slf4j package into my bundles for logging support. The jars in /lib (where the SLF4J API bundle is located) are not referenced in the repository configuration; however, they do get loaded up at runtime as I can confirm this from the OSGi console.

      I'm using the Eclipse based Spring Tool Suite for my IDE and am unable to validate my MANIFEST.MF files after setting my targeted runtime environment to the dm Server 2.0 installation. It seems like the bundles from /lib may not be showing up in the classpath container. Do bundles in the repository or bundles in /lib take order precedence when loading, especially if I extend my repository search paths to include my local ivy-cache?

      I assume STS references the dm Server repository configuration when building its class path for a projects targeted runtime environment.

      Any ideas? Who should I consult about this?

      Thanks,
      Marshall

      Comment

      Working...
      X