cancel
Showing results for 
Search instead for 
Did you mean: 

Namespace prefix not mapped error

brunoais
Champ in-the-making
Champ in-the-making
Happens on page:
http://localhost:8888/alfresco/service/enterprise/admin/admin-processengines

I'm using alfresco one demo.

<blockquote>
Message:   11190009 Wrapped Exception (with status template): 11190013 Failed to execute script 'classpath*:alfresco/enterprise/webscripts/org/alfresco/enterprise/repository/admin/repository-services/admin-processengines.get.js': org.alfresco.service.namespace.NamespaceException: Namespace prefix exc is not mapped to a namespace URI

Exception:   org.alfresco.service.namespace.NamespaceException - Namespace prefix exc is not mapped to a namespace URI
</blockquote>

I've checked everything I made and I appended ".bak" to the only file that references that prefix. It didn't solve that error.

What's causing the error?
12 REPLIES 12

mitpatoliya
Star Collaborator
Star Collaborator
you need to remove the context file which is referring that model file in which this prefix is mentioned.
Better you check the model from which this error is generated. It might be conflicting with some other name space or exc may not be the short name used for the namespace.

brunoais
Champ in-the-making
Champ in-the-making
Thank you for the answer.

It is mentioned in only one file. It is mentioned as:


   <namespaces>
      <namespace uri="http://www.exampleco.com/model/content/1.0" prefix="exc" />
   </namespaces>


and later many times in the

   <types>
      <type name="exc:estimateTask">
(…)
      </type>

      <type name="exc:assignTask">
(…)
      </type>
(…)
      <type name="exc:executeTask">
(…)
      </type>
      <type name="exc:confirmTaskConclusion">
(…)
      </type>
   </types>


Could it be that one of these has some sort of error or something like that?

mitpatoliya
Star Collaborator
Star Collaborator
could you post the content of admin-processengines.get.js file?

brunoais
Champ in-the-making
Champ in-the-making
Here you go:

<import resource="classpath:alfresco/enterprise/webscripts/org/alfresco/enterprise/repository/admin/admin-common.lib.js">

/**
* Repository Admin Console
*
* Process Engines GET method
*/
Admin.initModel(
   "Alfresco:Name=WorkflowInformation",
   ["ActivitiEngineEnabled","NumberOfActivitiWorkflowInstances","NumberOfActivitiWorkflowDefinitionsDeployed",
    "ActivitiWorkflowDefinitionsVisible","NumberOfActivitiTaskInstances","JBPMEngineEnabled",
    "NumberOfJBPMWorkflowInstances","NumberOfJBPMWorkflowDefinitionsDeployed",
    "JBPMWorkflowDefinitionsVisible","NumberOfJBPMTaskInstances"],
   "admin-processengines"
);

mitpatoliya
Star Collaborator
Star Collaborator
This looks good. now one more point the model file content which you have posted. there are few initial lines where you give name to model is it proper with the same prefix "exc"?

brunoais
Champ in-the-making
Champ in-the-making
Oh yeah! I forgot to post that!
I think so:


<?xml version="1.0" encoding="UTF-8"?>

<model name="exc:workModel" xmlns="http://www.alfresco.org/model/dictionary/1.0">

mitpatoliya
Star Collaborator
Star Collaborator
No issue with this as well.
The only thing remains is parts of definition file which you have omitted.
I suggest you to check each property and its name it should have exact prefix.

brunoais
Champ in-the-making
Champ in-the-making
this?


<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'http://www.springframework.org/dtd/spring-beans.dtd'>

<beans>
    <bean id="exampleco.dictionaryBootstrap" parent="dictionaryModelBootstrap" depends-on="dictionaryBootstrap">
        <property name="models">
            <list>
                <value>alfresco/extension/model/model.xml</value>
            </list>
        </property>
    </bean>

</beans>

mitpatoliya
Star Collaborator
Star Collaborator
Not that one pal, full contents from your model.xml