Author Topic: Error: Unknown Package Connector Source or Target  (Read 1225 times)

freek

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Error: Unknown Package Connector Source or Target
« on: March 09, 2017, 08:49:39 pm »
I have browsed all the references to the above error when importing .xmi which stretch over more than 11 years now.  Everywhere the answer is that there are some connectors dangling.

Unfortunately I cannot find any solutions to this problem which has now become a serious problem.

Using .xmi files from OMG, I have narrowed the error down to references to external packages in a packageImport which is located on the web.  You get exactly one error for each of these "importedPackage href=" entries.  Here is an example causing the error.

      <packageImport xmi:type="uml:PackageImport" xmi:id="_packageImport.0">
         <importedPackage href="http://www.omg.org/spec/UML/20131001/PrimitiveTypes.xmi#_0"/>
      </packageImport>

Is there anybody who can point me to what I should do to fix the problem?  Obviously the importer cannot find the external packages on the web (even though they are there).  Should I copy all the imported files to a local disk and modify the OMG .xmi files?
« Last Edit: March 09, 2017, 08:53:03 pm by freek »

qwerty

  • EA Guru
  • *****
  • Posts: 9425
  • Karma: +150/-138
  • I'm no guru at all
    • View Profile
Re: Error: Unknown Package Connector Source or Target
« Reply #1 on: March 09, 2017, 09:42:57 pm »
Searching somewhere in the vicinity of my memory. I don't think that this is due to the OMG XMI files (who knows whether EA reads them at all; you could verify by unplugging the network cable). But likely it's something in the export which bites EA. I'd recommend to contact Sparx support and supply them with a copy of your XMI on request. They are usually quite helpful when it comes to such kind of issues.

q.

freek

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: Error: Unknown Package Connector Source or Target
« Reply #2 on: March 09, 2017, 10:06:15 pm »
I have tried importing a whole range of .xmi files from OMG and I get one these errors for each OMG file that is referenced in the .xmi using the <importedPackage href=.... .   

This includes (but are not limited to) uml.xml, StandardProfile.xmi, UAFP_Profile.xmi, mof.xmi, SysML.xmi,...

The only one that does not throw the error is PrimitiveTypes.xmi as it does not reference any other files.
 


qwerty

  • EA Guru
  • *****
  • Posts: 9425
  • Karma: +150/-138
  • I'm no guru at all
    • View Profile
Re: Error: Unknown Package Connector Source or Target
« Reply #3 on: March 10, 2017, 12:08:01 am »
Can you give the links? I'd try here. Some time ago I imported metamodels from OMG (which I still use) and had no issue i can remember.

q.


freek

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: Error: Unknown Package Connector Source or Target
« Reply #5 on: March 14, 2017, 06:35:24 pm »
When importing, I get the following in the import log file:

Importing Model from XMI
Root Package: SysML
Add Classifier: FlowDirection
Add Classifier: FullPort
Add Classifier: ProxyPort
Add Classifier: FlowProperty
Add Classifier: ItemFlow
Add Classifier: InterfaceBlock
Add Classifier: InvocationOnNestedPortAction
Add Classifier: TriggerOnNestedPort
Add Classifier: AcceptChangeStructuralFeatureEventAction
Add Classifier: ChangeStructuralFeatureEvent
Add Classifier: DirectedFeature
Add Classifier: FeatureDirection
Add Classifier: FlowPort
Add Classifier: FlowSpecification
Add Classifier: AllocateActivityPartition
Add Classifier: Allocate
Add Classifier: Allocated
Add Classifier: DistributedProperty
Add Classifier: PropertySpecificType
Add Classifier: ParticipantProperty
Add Classifier: ValueType
Add Classifier: QuantityKind
Add Classifier: Block
Add Classifier: ConnectorProperty
Add Classifier: Unit
Add Classifier: NestedConnectorEnd
Add Classifier: BindingConnector
Add Classifier: ConstraintBlock
Add Classifier: ConstraintProperty
Add Classifier: Requirement
Add Classifier: Verify
Add Classifier: TestCase
Add Classifier: Satisfy
Add Classifier: VerdictKind
Add Classifier: RequirementRelated
Add Classifier: DeriveReqt
Add Classifier: Copy
Add Classifier: Probability
Add Classifier: Optional
Add Classifier: NoBuffer
Add Classifier: Rate
Add Classifier: ControlOperator
Add Classifier: Continuous
Add Classifier: Overwrite
Add Classifier: Discrete
Add Classifier: Viewpoint
Add Classifier: Rationale
Add Classifier: Conform
Add Classifier: View
Add Classifier: Problem
Add Classifier: Real
Add Classifier: Number
Add Classifier: Boolean
Add Classifier: Integer
Add Classifier: String
Add Classifier: Complex
Add Classifier: ControlValue
Resolving Classifiers
Resolving Owners
Resolving Attribute Types
Resolving Parameter Types
Error: Unknown Package Connector Source or Target
Error: Unknown Generalization Source or Target
Error: Unknown Generalization Source or Target
Error: Unknown Generalization Source or Target
Error: Unknown Generalization Source or Target
Error: Unknown Package Connector Source or Target
Error: Unknown Package Connector Source or Target
Resolving Association-Classes
Resolving Properties for Association Ends
Resolving InteractionOccurences
Fixup external references
Import Complete!


qwerty

  • EA Guru
  • *****
  • Posts: 9425
  • Karma: +150/-138
  • I'm no guru at all
    • View Profile
Re: Error: Unknown Package Connector Source or Target
« Reply #6 on: March 14, 2017, 07:46:10 pm »
I'll try that later. But those message tell exactly that you have not yet imported packages which are being referenced. Once you have the import complete, a re-import will no longer croak - if the references are resolved by the imports.

q.

freek

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: Error: Unknown Package Connector Source or Target
« Reply #7 on: March 14, 2017, 08:53:54 pm »
Yes.  This is what I am trying to resolve.  For starters I cannot import directly from the URL, Enterprise Architect just hangs if I try this and I have to kill it off.

Copying all the related .xmi files from OMG and importing them in order does not solve the problem either.

qwerty

  • EA Guru
  • *****
  • Posts: 9425
  • Karma: +150/-138
  • I'm no guru at all
    • View Profile
Re: Error: Unknown Package Connector Source or Target
« Reply #8 on: March 14, 2017, 09:14:23 pm »
I had no issues importing those XMIs: https://dl.dropboxusercontent.com/u/66691423/sysml.eap.zip

q.

freek

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: Error: Unknown Package Connector Source or Target
« Reply #9 on: March 15, 2017, 12:02:54 am »
Thank you for the effort. 

I am actually trying to import the OMG UAF 1.0 profile, as the support which Enterprise Architect gives for it is very (extremely) poor.  As it's import failed, I then tried all the others. 

I have come to the conclusion that Enterprise Architect:
1.  Cannot import standard .xmi files as released by OMG without logging errors,
2.  Cannot maintain an ownedComment on a packagedElement but moves it to the containing Package when importing,
3.  Cannot import ownedRule even when written in OCL and throws it away,
... etc ...