cancel
Showing results for 
Search instead for 
Did you mean: 

A namespace prefix is not registered - Simple OCR

anoopkr
Confirmed Champ
Confirmed Champ

Hi,

In our 6.2 installation we have or rather had this OCR module (2.3.1) it worked flawlessly. We are now migrating the 6.2 to latest version, we did it through version 7 and all are working (seemingly) fine, except, in Workspace application and error comes at certain entries, "This item no longer exists or you don't have permission to view it. ", the error log says  " A namespace prefix is not registered for uri http://www.keensoft.es/model/content/ocr/1.0". We had removed the jar files and global-properties entries related to OCR and all the folder rules before taking the backup of both content store and DB in 6.2 and we suspect this could be the error. Someone please help to tackle this issue, apart from this everything looks okay.

An excerpt from the log file.

Caused by: org.alfresco.scripts.ScriptException: 09090057 Failed to execute script 'classpath*:alfresco/templates/webscripts/org/alfresco/repository/metadata/metadata.get.js': A namespace prefix is not registered for uri http://www.keensoft.es/model/content/ocr/1.0
Caused by: org.alfresco.service.namespace.NamespaceException: A namespace prefix is not registered for uri http://www.keensoft.es/model/content/ocr/1.0
2024-10-09 04:52:07,076 WARN [org.alfresco.repo.module.ModuleServiceImpl] [main] A previously-installed module 'simple-ocr-repo' (version 2.3.1) is not present in your distribution.
2024-10-09 05:13:13,023 ERROR [org.springframework.extensions.webscripts.AbstractRuntime] [http-nio-8080-exec-7] Exception from executeScript: 09090017 Wrapped Exception (with status template): 09090054 Failed to execute script 'classpath*:alfresco/templates/webscripts/org/alfresco/repository/metadata/metadata.get.js': A namespace prefix is not registered for uri http://www.keensoft.es/model/content/ocr/1.0
org.springframework.extensions.webscripts.WebScriptException: 09090017 Wrapped Exception (with status template): 09090054 Failed to execute script 'classpath*:alfresco/templates/webscripts/org/alfresco/repository/metadata/metadata.get.js': A namespace prefix is not registered for uri http://www.keensoft.es/model/content/ocr/1.0

Regards

ANOOP KR

 

1 ACCEPTED ANSWER

Please, use the last version of the Alfresco Model Extractor app:

https://github.com/aborroy/alfresco-model-extractor/releases/tag/0.2.0

The previous one (0.1.0) was creating the JAR with an incorrect module version.

Create again the JAR and apply it again to your Alfresco deployment.

Hyland Developer Evangelist

View answer in original post

32 REPLIES 32

angel-borroy
Employee
Employee

There are nodes in your repository with the custom Content Model applied (http://www.keensoft.es/model/content/ocr/1.0). You can delete these nodes or maintain the previous Content Model in your new deployment.

Hi,

Thanks for the quick reply, We are no experts is Alfresco but Linux admins, can you elaborate a little ?

Regards.

 

Hi,

We would rather like to delete the model, because that OCR solution does not work in 23.X, that is why we tried to delete it. BTW is it possible to apply docker for the OCR solution ? Our installation is done through zip files, using Angel Borroy's scripts, because we could not find another OCR solution rather than the docker one.

 

Regards

You cannot delete the model, but you can apply it creating a new module containing the definition (https://github.com/keensoft/alfresco-simple-ocr/blob/master/simple-ocr-repo/src/main/resources/alfre...).

You can use the OCR module for ACS 7.x or later available in https://github.com/aborroy/alf-tengine-ocr

This module supports both ZIP Distribution files and Docker deployment.

Is there a way to just copy the data (+db) leaving all these complexities behind, so that we can have the latest server as it is just installed and populated with the data ? And all the office, OCR, etc can be added later ?

Regards

Hi,

I tried the new OCR module in a separate installation (23.x, fresh), I was able to set the rules but no action is being taken on the files uploaded, how could I troubleshoot it ? If somehow I made it possible can I integrate it with the upgraded installation (The same upgraded installation where I was not able to start and you people helped me to resolve it)

Regards

ANOOP

douglascrp
World-Class Innovator
World-Class Innovator

What rules are you talking about? Are you talking about this?
In order to have it running, you need to configure the transformer, as described here https://github.com/aborroy/alf-tengine-ocr?tab=readme-ov-file#adding-alfresco-ocr-transformer-to-doc...

Hi,

We deployed the .jar file (https://github.com/aborroy/alf-tengine-ocr/releases/download/1.0.0/embed-metadata-action-1.0.0.jar) in alfresco/module/platform and wrote the basic config lines in global properties, then the said rules are able to be set but no action is being taken.

Then,

From the source code, compiled the "ocr-share-action-1.0.0.amp" and deployed in the share.war, now a context menu with "Start OCR" comes and on clicking that button a pop up comes and says "Started the OCR process successfully" but no changes are made to the file.

What should I look for next ?

Regards

ANOOP

douglascrp
World-Class Innovator
World-Class Innovator

And I forgot the answer about integration it with the upgraded installation... yes, it's totally possible. All you need to do is to execute the configuration I mentioned in the previous answer.