cancel
Showing results for 
Search instead for 
Did you mean: 

Switching between repositories

Michal_
Champ on-the-rise
Champ on-the-rise

I've already set up multiple repositories with single Nuxeo instance and my question is how to switch between them? In my nuxeo.conf file I have: nuxeo.templates=default,custom but after login I am always redirected to the default one. I would like to have 2 repos working at the same time and also an option that enables me to choose one of them.

I've got no errors in logs. This is what I did yet:

  1. I've created secondary-repository-config.xml with content like this:

    note relatedtext webp:content webc:welcomeText comment:comment post mail:mail dc:title dc:description org.postgresql.xa.PGXADataSource localhost 5432 secondary nuxeo nuxeo
  2. I've put this xml in NUXEO_HOME/templates/custom/nxserver/config

  3. In nuxeo.conf I've set nuxeo.templates=default,custom

  4. I've created proper datababase with PostgreSQL

  5. I am working with Tomcat distribution (v 5.5). Both of my repos are PostgreSQL, each of them has its own database.

1 ACCEPTED ANSWER

Julien_Carsique
Elite Collaborator
Elite Collaborator

You can choose the repository with the following URL: http://yourserver/nuxeo/nxpath/default@view_servers which is accessible from the breadcrumbs navigation, clicking on the left arrow. But if you're logging in as an administrator user, you should be redirected to this view after login.

If the only item you see on this page is the default repository, then you may have a configuration issue: please comment your post to give more information about what you did, and check if you have any errors in logs.

View answer in original post

7 REPLIES 7

Julien_Carsique
Elite Collaborator
Elite Collaborator

You can choose the repository with the following URL: http://yourserver/nuxeo/nxpath/default@view_servers which is accessible from the breadcrumbs navigation, clicking on the left arrow. But if you're logging in as an administrator user, you should be redirected to this view after login.

If the only item you see on this page is the default repository, then you may have a configuration issue: please comment your post to give more information about what you did, and check if you have any errors in logs.

One small change - I've put secondary-repository-config.xml in NUXEO_HOME/templates/custom/config instead of NUXEO_HOME/templates/custom/nxserver/config. New repo appeaed in NUXEO_HOME/nxserver/repos but http

Florent_Guillau
World-Class Innovator
World-Class Innovator

Check what is actually deployed after startup in NUXEO_HOME/nxserver to know if the templates are taken into account correctly.

Michal_
Champ on-the-rise
Champ on-the-rise

After deployment secondary-repository-config.xml appeared in NUXEO_HOME/nxserver/config and new repo is created in NUXEO_HOME/nxserver/repos/secondary. But after login I'm not redirected do http

Benjamin_Jalon1
Elite Collaborator
Elite Collaborator

I moved your next question into an [another question][1].

Benjamin_Jalon1
Elite Collaborator
Elite Collaborator

I found out that there is one more thing to do while setting up multiple repositories. I just had to contribute "repositories" extension point, just like this:

<component name="com.nuxeo.multi.repository">
    <require>org.nuxeo.ecm.platform.api.DefaultPlatform</require>
    <extension target="org.nuxeo.ecm.core.api.repository.RepositoryManager"
        point="repositories">
        <repository name="secondary" label="Secondary Repo" />
    </extension>
</component>

Everything seems to work fine, after login I'm able to choose repo.

Yes for historical reasons there are two repository registries that must be filled to declare a repository. We'll simplify this in the future.

Getting started

Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.