1 2 Previous Next 19 Replies Latest reply on Jan 21, 2009 6:06 PM by Jeremy Smartt

    Searching Content

    Jeremy Smartt Newbie

      Is the integration with Lucene or some search capability available? Even if it is in the src code right now.

        • 1. Re: Searching Content
          Randall Hauch Master

          No, we don't yet have search functionality. We plan on doing that after the 0.4 release.

          Best regards,


          • 2. Re: Searching Content
            Jeremy Smartt Newbie

            Is it possible for now to use Lucene with the Jackrabbit that is underneath DNA for now?

            • 3. Re: Searching Content
              Randall Hauch Master

              I believe that Jackrabbit already uses Lucene to index all content placed into Jackrabbit.

              • 4. Re: Searching Content
                Jeremy Smartt Newbie

                So i I used DNA to aggregate all the different datas from different repositories and then I could then use Lucene to search through the data DNA brought into Jackrabbit based on the attributes in the metadata?

                • 5. Re: Searching Content
                  Randall Hauch Master

                  Sorry, I misunderstood your question. If you were to use DNA sequencers on top of a Jackrabbit repository, you could use Jackrabbit's search/query functionality.

                  But the federation capability does not currently have any integration with Lucene - we don't yet have a "unified search" capability that allows you to search over all of the federated content. Obviously that will be a major goal (and is part of our JCR implementation effort, which is currently our #1 priority).

                  If any of the sources you are federating is Jackrabbit (or any other source with search capability), you could directly search those sources (since each Jackrabbit repository uses Lucene internally). Not an ideal situation, but it might work in the interim.

                  • 6. Re: Searching Content
                    Jeremy Smartt Newbie

                    When I ran through the examples it looked like it was storing all the metadata in Jackrabbit, like the repository demo with the cars and such. Is that not the case?

                    • 7. Re: Searching Content
                      Randall Hauch Master

                      The sequencer example does use a single instance of Jackrabbit as the JCR repository. The repositories example does use federation, but it does not use Jackrabbit at all.

                      • 8. Re: Searching Content
                        Jeremy Smartt Newbie

                        where is the metadata stored? Can we get to it through an Api or through the DNA src code?

                        • 9. Re: Searching Content
                          Randall Hauch Master

                          In the case of the repositories example, the configuration information is stored in a repository source (named "Configuration"). You could create a JCR Session with that source name, then access the configuration information through JCR:

                          Session session = jcrRepository.login("Configuration");

                          Each "repository source" really is just a repository that uses the DNA Graph API (simpler than JCR). This is what makes it easy to write connectors to new sources - you don't have to fully implement JCR. In fact, it's far, far simpler than than.

                          You can actually see the RepositoryClient code start up the sources in the "startRepositories()" method. This code instantiates a DNA RepositoryLibrary (a library of repository source instances), programmatically adds one named "Configuration", and imports the configRepository.xml file into this source. Then, the code creates and starts up the RepositoryService, passing into the constructor the name of the repository source that it should use to read its configuration. So, the RepositoryService reads the configuration information and then sets up the other repository sources (two in-memory sources and one federating source). Since the in-memory sources don't have any data, the last few lines of the "startRepositories()" method imports their data from XML files. But the federated repository has no data, since it dynamically federates its content from the other sources.

                          Now, this is all pretty low-level plumbing that we will be hiding soon. You'll be able to just create a DnaConfiguration object and use its methods to configure everything (or load config information from a file, or use a central configuration repository), then use that to create JCR Repository implementations.

                          Also, right now, if the configuration information is changed, the services don't really know about it. We'll be changing that, too, so that you can change the configuration repository content, and the services will receive those events and will adjust themselves to reflect the configuration. And since the configuration is just another repository, changing the configuration will be just like any other JCR client.

                          Hope this helps.

                          • 10. Re: Searching Content
                            Jeremy Smartt Newbie

                            So you could do something like this:

                            Session session = jcrRepository.login("Cars");
                            Node root = session.getRootNode();
                            for (NodeIterator iter = root .getNodes(); iter.hasNext();) {
                             Node someNode = iter.nextNode();
                             ...do something...

                            And in the Cars example you would be able to traverse down to the actual data nodes that use a specific metadata, or should one use Graphs for this?

                            • 11. Re: Searching Content
                              Randall Hauch Master

                              Yes, you would be able to do that and do anything you want with the content in the "Cars" repository. At this point, it's just a (read-only) JCR repository ... write support will be coming this next release, followed by search/query.

                              • 12. Re: Searching Content
                                Jeremy Smartt Newbie

                                And if the Cars Repository happened to be Federated you will still be able to traverse around in this same way?

                                • 13. Re: Searching Content
                                  Randall Hauch Master

                                  Yes, you could also navigate the "Cars" content by looking in the "Vehicles" repository; the "/Vehicles/Cars" node will be the same thing as the "/Cars" node in the "Cars" repository (as prescribed by the federated configuration).

                                  • 14. Re: Searching Content
                                    Jeremy Smartt Newbie

                                    okay, thanks!

                                    When is the next release planned with the ability to write to the repository?
                                    And even further, is there a plan for when search/query will be done?

                                    1 2 Previous Next