Skip to content

Question: how to export existing site to xml for use by this library #30

Open
@nicerloop

Description

@nicerloop

Hi,

I have an existing Liferay Portal, living in database, and would like to export it as xml in order to consume it with this library. Can you give me some pointers?

Activity

ktor

ktor commented on Sep 9, 2021

@ktor
Member

Hi @nicerloop,

you can export Liferay data in LAR format (zipped xml) with standard Liferay tooling and import it with standard Liferay tooling as well.

The liferay-db-setup-core library however does not consume LAR format. The same goes the other way around. What is your use case? Is it backup?

nicerloop

nicerloop commented on Sep 9, 2021

@nicerloop
Author

Hi,

LAR export is not supported between Liferay versions, and will not evolve anymore (https://learn.liferay.com/dxp/latest/en/installation-and-upgrades/upgrading-liferay/reference/maintenance-mode-and-deprecations-in-7-3.html).

I would like to have my portal contents versioned as source, to deploy it without hassle in different contexts, flowing through different Liferay versions. But I would rather avoid re-authoring the existing content (multiple Liferay sites, complex contents, various environments) and have/get/build a way to export it to a versionable format.

This library seems to handle the implementation of an xml-described site into Liferay, I need the reverse operation to close the loop.

ktor

ktor commented on Sep 9, 2021

@ktor
Member

The feature is currently not supported but I could use it as well, especially for user created content like articles/pages. I imagine this could very well be developed organically.

For example I currently need basic site pages/configuration dump and I was going to write declarations manually but writing a dump tool seems to be a better idea and I could reuse it on other projects as well.

Let's say:

InputStream LiferaySetupDump#site(Long siteId)
InputStream LiferaySetupDump#article(Long articleId)
InputStream LiferaySetupDump#categories(Long vocabularyId)

What would be your idea of a dump API?

nicerloop

nicerloop commented on Sep 9, 2021

@nicerloop
Author

I'm quite new into Liferay, been discovering the product for some weeks with this project I'm newly involved with, so I'd imagine naively the reverse of the setup() methods: Setup LiferaySetup#dump(), or to allow for big sites, InputStream LiferaySetup#dump().

I currently do not master Liferay enough to suggest anything else, as I am in the process of researching how to make the current situation more manageable on the Liferay contents side.

Having a global view of the contents, even as a massive XML file, is a first step to managing the contents.

Alternatively, could the contents be dumped by parts following their nature, and be joined in a parent XML setup file following the XSD using XInclude?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    good first issueGood for newcomershelp wantedExtra attention is neededquestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @ktor@nicerloop

        Issue actions

          Question: how to export existing site to xml for use by this library · Issue #30 · ableneo/liferay-db-setup-core