Foren

Liferay upgrade to 6.1.0

Balaji Chopparapu, geändert vor 12 Jahren.

Liferay upgrade to 6.1.0

New Member Beiträge: 22 Beitrittsdatum: 08.10.10 Neueste Beiträge
Hi,

We are upgrading from liferay 5.2 to latest version liferay 6.1.0. I converted ext to ext plugin using the upgrade utility provided by the liferay but observed following issues.

In liferay 6.1.0 we couldn’t find the classes “MBMessageFlagLocalServiceUtil.java” and “BBCodeUtil.java”. Are they removed? If it is. What are the other alternate classes provided?

Thanks in Advance
Balaji
thumbnail
Alexander Chow, geändert vor 12 Jahren.

RE: Liferay upgrade to 6.1.0 (Antwort)

Liferay Master Beiträge: 518 Beitrittsdatum: 20.07.05 Neueste Beiträge
MBMessageFlagLocalServiceUtil was renamed and optimised into MBThreadFlagLocalServiceUtil. See LPS-20275.

BBCodeUtil was merged with a few other things and renamed BBCodeTranslatorUtil. See LPS-20791

Alex
Balaji Chopparapu, geändert vor 12 Jahren.

RE: Liferay upgrade to 6.1.0

New Member Beiträge: 22 Beitrittsdatum: 08.10.10 Neueste Beiträge
Thanks Alexander. It worked.
Farrel Chen, geändert vor 12 Jahren.

RE: Liferay upgrade to 6.1.0

New Member Beiträge: 18 Beitrittsdatum: 20.04.11 Neueste Beiträge
Thanks for the useful info. However, do you know what are these functions changed to?

The method hasReadFlag(long, MBThread) is undefined for the type MBThreadFlagLocalServiceUtil
The method hasAnswerFlag(long) is undefined for the type MBThreadFlagLocalServiceUtil
The method hasQuestionFlag(long) is undefined for the type MBThreadFlagLocalServiceUtil
The method hasReadFlag(long, MBThread) is undefined for the type MBThreadFlagLocalServiceUtil
thumbnail
Jan Eerdekens, geändert vor 12 Jahren.

RE: Liferay upgrade to 6.1.0

New Member Beiträge: 15 Beitrittsdatum: 20.01.11 Neueste Beiträge
I'm running into the same kind of issue after an upgrade. Before I was perfectly able to add question/answer flags using the MBMessageFlagLocalServiceUtil, but now I can't seem to find the new counterparts. Time and time again Liferay keeps breaking APIs without providing enough information, e.g. documentation, on how to migrate code that uses APIs that have changed.
Farrel Chen, geändert vor 12 Jahren.

RE: Liferay upgrade to 6.1.0

New Member Beiträge: 18 Beitrittsdatum: 20.04.11 Neueste Beiträge
Yes that really sucks.
I later figured that it's easier to use the 6.1 version as base, and redo the customization -- I located all the customized code by comparing my code and the 6.0.5 source code.
thumbnail
Jan Eerdekens, geändert vor 12 Jahren.

RE: Liferay upgrade to 6.1.0

New Member Beiträge: 15 Beitrittsdatum: 20.01.11 Neueste Beiträge
It seems that now in 6.1 when you create your category you have to pass in "question" as the 5th parameter to the addCategory call instead of adding a question flag later. If you then want to mark an answer you need to do
MBMessageLocalServiceUtil.updateAnswer(answer.getMessageId(), true, false);
instead of adding an answer flag like before. At least this is what did the trick for me.