Warnings: Deprecated usage of method [org.apache.velocity.tools.generic.MathTool.toInteger]

My team did update of xwiki from 10.5 to 15.1. I’m not sure if it was done properly.

I noticed that all of the articles and configuration were restored from xar.
Now I have a lot of warnings like:

2023-10-13 13:51:10,615 [http-nio-8080-exec-1 - http://localhost:8080/bin/get/Admin/RunShellCommand?] WARN o.a.v.introspection - Deprecated usage of method [org.apache.velocity.tools.generic.MathTool.toInteger] in xwiki:XWiki.DocumentTree@117,41

Anyone has idea how to deal with this?

Hello

Could you explain how you performed the upgrade?

What do you mean by “articles” (is it wiki pages?) and what does “restore from xar” means? Does it mean you didn’t perform an XWiki upgrade as indicated on Upgrading (XWiki.org) and that instead you did a backup/restore of a XAR?

This simply means that the extension you installed and that brought the Admin.RunShellCommand wiki page is using some deprecated velocity call. It’s not a problem but that extension should be fixed or you should upgrade it if there’s a newer version.

Thanks

I have strong suspicious that it was done in this way. Backup XAR and restore it on fresh 15.1.

I tried update from 15.1 to 15.2 and updater show me that I have broken “base flavor”, even when I tried to Install new versions of extensions I still end up with warnings about velocity. How can I fix this extension? I don’t know how to edit it.

This seems to indicate that you indeed didn’t perform an upgrade… You should really follow Upgrading (XWiki.org)

You can try to fix the broken base flavor, by upgrading the flavor or by repairing it, see Extension Manager Application (XWiki.org)

Since you have imported an old XAR, it’s possible that this XAR was containing not only your content pages but also wiki pages coming from XWiki itself or extensions. After you’ve done the base flavor upgrade/repair, you’ll need to check this by doing a “compute changes” and check the diff, as shown at Extension Manager Application (XWiki.org)