ReSharper File Layout for explicit implemented interfaces - resharper

I'm trying to configure the File Layout of ReSharper in such a way that formatting the code does respect the 'StyleCop SA1202' rule.
See https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/SA1202.md for more information.
Basically, this rule says that the order of elements is required to match a given pattern.
First 'Public', followed by 'Internal' ...
When I have a class that implements an interface explicit, it's in fact 'public'.
See the following code:
void IDisposable.Dispose()
{
// Implementation
}
When I configure ReSharper File Layout with the following configuration:
<Entry DisplayName="Methods">
<Entry.Match>
<Kind Is="Method" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal Protected" />
</Entry.SortBy>
</Entry>
The explicit implemented interface is placed as the after any public methods.
Is there any way to configure ReSharper's File Layout so that rule SA1202 is respected when using explicit interface implementations?
Kind regards

I am using the StyleCop file layout and added a special rule for Dispose methods at the end:
<?xml version="1.0" encoding="utf-16"?>
<Patterns
xmlns="urn:schemas-jetbrains-com:member-reordering-patterns">
<TypePattern DisplayName="Non-reorderable types">
<TypePattern.Match>
<Or>
<And>
<Kind Is="Interface" />
<Or>
<HasAttribute Name="System.Runtime.InteropServices.InterfaceTypeAttribute" />
<HasAttribute Name="System.Runtime.InteropServices.ComImport" />
</Or>
</And>
<Kind Is="Struct" />
<HasAttribute Name="JetBrains.Annotations.NoReorderAttribute" />
<HasAttribute Name="JetBrains.Annotations.NoReorder" />
</Or>
</TypePattern.Match>
</TypePattern>
<TypePattern DisplayName="xUnit.net Test Classes" RemoveRegions="All">
<TypePattern.Match>
<And>
<Kind Is="Class" />
<HasMember>
<And>
<Kind Is="Method" />
<HasAttribute Name="Xunit.FactAttribute" Inherited="True" />
</And>
</HasMember>
</And>
</TypePattern.Match>
<Entry DisplayName="Setup/Teardown Methods">
<Entry.Match>
<Or>
<Kind Is="Constructor" />
<And>
<Kind Is="Method" />
<ImplementsInterface Name="System.IDisposable" />
</And>
</Or>
</Entry.Match>
<Entry.SortBy>
<Kind Order="Constructor" />
</Entry.SortBy>
</Entry>
<Entry DisplayName="All other members" />
<Entry DisplayName="Test Methods" Priority="100">
<Entry.Match>
<And>
<Kind Is="Method" />
<HasAttribute Name="Xunit.FactAttribute" />
</And>
</Entry.Match>
<Entry.SortBy>
<Name />
</Entry.SortBy>
</Entry>
</TypePattern>
<TypePattern DisplayName="NUnit Test Fixtures" RemoveRegions="All">
<TypePattern.Match>
<And>
<Kind Is="Class" />
<HasAttribute Name="NUnit.Framework.TestFixtureAttribute" Inherited="True" />
</And>
</TypePattern.Match>
<Entry DisplayName="Setup/Teardown Methods">
<Entry.Match>
<And>
<Kind Is="Method" />
<Or>
<HasAttribute Name="NUnit.Framework.SetUpAttribute" Inherited="True" />
<HasAttribute Name="NUnit.Framework.TearDownAttribute" Inherited="True" />
<HasAttribute Name="NUnit.Framework.FixtureSetUpAttribute" Inherited="True" />
<HasAttribute Name="NUnit.Framework.FixtureTearDownAttribute" Inherited="True" />
</Or>
</And>
</Entry.Match>
</Entry>
<Entry DisplayName="All other members" />
<Entry DisplayName="Test Methods" Priority="100">
<Entry.Match>
<And>
<Kind Is="Method" />
<HasAttribute Name="NUnit.Framework.TestAttribute" />
</And>
</Entry.Match>
<Entry.SortBy>
<Name />
</Entry.SortBy>
</Entry>
</TypePattern>
<TypePattern DisplayName="StyleCop Classes, Interfaces, & Structs" RemoveRegions="All">
<TypePattern.Match>
<Or>
<Kind Is="Class" />
<Kind Is="Struct" />
<Kind Is="Interface" />
</Or>
</TypePattern.Match>
<Entry DisplayName="Constants">
<Entry.Match>
<Kind Is="Constant" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Fields">
<Entry.Match>
<Kind Is="Field" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Constructors">
<Entry.Match>
<Kind Is="Constructor" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Destructors">
<Entry.Match>
<Kind Is="Destructor" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Delegates">
<Entry.Match>
<Kind Is="Delegate" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Events">
<Entry.Match>
<Kind Is="Event" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Enums">
<Entry.Match>
<Kind Is="Enum" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Interfaces">
<Entry.Match>
<Kind Is="Interface" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Properties">
<Entry.Match>
<Kind Is="Property" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Indexers">
<Entry.Match>
<Kind Is="Indexer" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Methods">
<Entry.Match>
<Kind Is="Method" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Structs">
<Entry.Match>
<Kind Is="Struct" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Classes">
<Entry.Match>
<Kind Is="Class" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
<Entry DisplayName="Dispose">
<Entry.Match>
<Name Is="Dispose" />
</Entry.Match>
<Entry.SortBy>
<Access Order="Public Internal ProtectedInternal Protected Private" />
<Static />
<Readonly />
</Entry.SortBy>
</Entry>
</TypePattern>
</Patterns>

You can create a new region where you capture properties that are private and that implement an interface and in the name of the interface use the regex "I.*"
<Region Name="Explicit interface implementation">
<Entry DisplayName="Interface properties">
<Entry.Match>
<And>
<Kind Is="Property" />
<ImplementsInterface Name="I.*" />
<Access Is="Private" />
</And>
</Entry.Match>
</Entry>
</Region>

Related

phonegap permissions not being asked when installing apk

This is my config.xml for phonegap with JQM
but when i install the APK after compiling with adobe build it asks me only for GPS & Audio recording. Not for camera etc. then the camera function is not available to my APP of course. any ideas?
<plugin name="cordova-plugin-geolocation" />
<plugin name="cordova-plugin-camera" />
<plugin name="cordova-plugin-file" />
<plugin name="cordova-plugin-media" />
<plugin name="cordova-plugin-media-capture" />
<plugin name="cordova-plugin-dialogs" />
<plugin name="cordova-plugin-file-transfer" />
<plugin name="cordova-plugin-whitelist" version="1" />
<preference name="permissions" value="none"/>
<preference name="stay-in-webview" value="false" />
<preference name="InAppBrowserStorageEnabled" value="true"/>
<feature name="http://api.phonegap.com/1.0/camera"/>
<feature name="http://api.phonegap.com/1.0/file"/>
<feature name="http://api.phonegap.com/1.0/geolocation"/>
<feature name="http://api.phonegap.com/1.0/media"/>
<feature name="http://api.phonegap.com/1.0/network"/>
<feature name="http://api.phonegap.com/1.0/notification"/>
<icon src="icon.png" />
<access origin="*" />
<allow-intent href="http://*/*" />
<allow-intent href="https://*/*" />
<allow-intent href="tel:*" />
<allow-intent href="sms:*" />
<allow-intent href="mailto:*" />
<allow-intent href="geo:*" />
<platform name="android">
<allow-intent href="market:*" />
</platform>
<platform name="ios">
<allow-intent href="itms:*" />
<allow-intent href="itms-apps:*" />
</platform>
Make sure you include source="npm" at the end of your tags like so:
<plugin name="cordova-plugin-dialogs" source="npm"/>
J

Mobicents diameter no connection to peer error message

I am new to mobicents diameter and followed the example downloaded here.
Executing both ExampleClient and ExampleServer on the same machine with different ports the "Result-code" is 3002
"Error-message" is "No connection to peer"
Where am I wrong?
Protocol error:
DIAMETER_UNABLE_TO_DELIVER 3002
This error is given when Diameter can not deliver the message to
the destination, either because no host within the realm
supporting the required application was available to process the
request, or because Destination-Host AVP was given without the
associated Destination-Realm AVP.
client-jdiameter-config.xml
<?xml version="1.0"?>
<Configuration xmlns="http://www.jdiameter.org/jdiameter-server">
<LocalPeer>
<URI value="aaa://127.0.0.1:1812" />
<IPAddresses>
<IPAddress value="127.0.0.1" />
</IPAddresses>
<Realm value="mobicents.org" />
<VendorID value="0" />
<ProductName value="jDiameter" />
<FirmwareRevision value="1" />
<OverloadMonitor>
<Entry index="1" lowThreshold="0.5" highThreshold="0.6">
<ApplicationID>
<VendorId value="0" />
<AuthApplId value="333333" />
<AcctApplId value="0" />
</ApplicationID>
</Entry>
</OverloadMonitor>
</LocalPeer>
<Parameters>
<AcceptUndefinedPeer value="false" />
<DuplicateProtection value="true" />
<DuplicateTimer value="240000" />
<UseUriAsFqdn value="false" />
<QueueSize value="10000" />
<MessageTimeOut value="60000" />
<StopTimeOut value="10000" />
<CeaTimeOut value="10000" />
<IacTimeOut value="30000" />
<DwaTimeOut value="10000" />
<DpaTimeOut value="5000" />
<RecTimeOut value="10000" />
<Concurrent>
<Entity name="ThreadGroup" size="64" />
<Entity name="ProcessingMessageTimer" size="1" />
<Entity name="DuplicationMessageTimer" size="1" />
<Entity name="RedirectMessageTimer" size="1" />
<Entity name="PeerOverloadTimer" size="1" />
<Entity name="ConnectionTimer" size="1" />
<Entity name="StatisticTimer" size="1" />
</Concurrent>
</Parameters>
<Network>
<Peers>
<Peer name="aaa://127.0.0.1:3868" attempt_connect="true" rating="1" />
</Peers>
<Realms>
<Realm name="mobicents.org" peers="127.0.0.1"
local_action="LOCAL" dynamic="false" exp_time="1">
<ApplicationID>
<VendorId value="0" />
<AuthApplId value="333333" />
<AcctApplId value="0" />
</ApplicationID>
</Realm>
</Realms>
</Network>
<Extensions />
</Configuration>
server-jdiameter-config.xml
<?xml version="1.0"?>
<Configuration xmlns="http://www.jdiameter.org/jdiameter-server">
<LocalPeer>
<URI value="aaa://127.0.0.1:3868" />
<IPAddresses>
<IPAddress value="127.0.0.1" />
</IPAddresses>
<Realm value="mobicents.org" />
<VendorID value="0" />
<ProductName value="jDiameter" />
<FirmwareRevision value="1" />
<OverloadMonitor>
<Entry index="1" lowThreshold="0.5" highThreshold="0.6">
<ApplicationID>
<VendorId value="0" />
<AuthApplId value="333333" />
<AcctApplId value="0" />
</ApplicationID>
</Entry>
</OverloadMonitor>
</LocalPeer>
<Parameters>
<!-- set to true, we can safely remove client def in this case -->
<AcceptUndefinedPeer value="true" />
<DuplicateProtection value="true" />
<DuplicateTimer value="240000" />
<UseUriAsFqdn value="false" />
<QueueSize value="10000" />
<MessageTimeOut value="60000" />
<StopTimeOut value="10000" />
<CeaTimeOut value="10000" />
<IacTimeOut value="30000" />
<DwaTimeOut value="10000" />
<DpaTimeOut value="5000" />
<RecTimeOut value="10000" />
<Concurrent>
<Entity name="ThreadGroup" size="64" />
<Entity name="ProcessingMessageTimer" size="1" />
<Entity name="DuplicationMessageTimer" size="1" />
<Entity name="RedirectMessageTimer" size="1" />
<Entity name="PeerOverloadTimer" size="1" />
<Entity name="ConnectionTimer" size="1" />
<Entity name="StatisticTimer" size="1" />
</Concurrent>
</Parameters>
<Network>
<Peers>
<!-- our client, lets define it -->
<Peer name="aaa://127.0.0.1:1812" attempt_connect="false"
rating="1" />
</Peers>
<Realms>
<Realm name="mobicents.org" peers="127.0.0.1" local_action="LOCAL" dynamic="false" exp_time="1">
<ApplicationID>
<VendorId value="0" />
<AuthApplId value="333333" />
<AcctApplId value="0" />
</ApplicationID>
</Realm>
</Realms>
</Network>
<Extensions />
</Configuration>

Custom BCS indexing connector with changelog inremental crawl is not working properly

I am writing a custom indexing connector using changelog incremental crawl approach.
I'm using sample from http://msdn.microsoft.com/en-us/library/ff625800%28v=office.14%29.aspx and trying to change it for me.
My model has next stereotypes: IdEnumerator, ChangedIdEnumerator, DeletedIdEnumerator, SpecificFinder, Finder, StreamAccessor
If I'm starting full crawl, IdEnumerator, ChangedIdEnumerator, DeletedIdEnumerator will be called.
First problem: the SpecificFinder is not called.
If I'm starting incremental crawl, ChangedIdEnumerator and DeletedIdEnumerator will be called.
DeletedIdEnumerator is working: items with deleted ids are deleted from the index.
Second problem: ChangedIdEnumerator is not working. Nothing happens after I returned the changed ids.
There are now errors in the crowl log.
My model is here:
<Model xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" Name="MyFileModel" xmlns="http://schemas.microsoft.com/windows/2007/BusinessDataCatalog">
<LobSystems>
<LobSystem Name="MyFileSystem" Type="Custom">
<Properties>
<Property Name="SystemUtilityTypeName" Type="System.String">MyFileConnector.MyFileConnector, MyFileConnector, Version=1.0.0.0, Culture=neutral, PublicKeyToken=15865f58b9878bf8</Property>
<Property Name="SystemUtilityInstallDate" Type="System.DateTime">2013-01-01 00:00:00Z</Property>
<Property Name="InputUriProcessor" Type="System.String">MyFileConnector.MyFileLobUri, MyFileConnector, Version=1.0.0.0, Culture=neutral, PublicKeyToken=15865f58b9878bf8</Property>
<Property Name="OutputUriProcessor" Type="System.String">MyFileConnector.MyFileNamingContainer, MyFileConnector, Version=1.0.0.0, Culture=neutral, PublicKeyToken=15865f58b9878bf8</Property>
</Properties>
<LobSystemInstances>
<LobSystemInstance Name="MyFileConnector_instance">
<Properties>
<Property Name="AuthenticationType" Type="System.String">Credentials</Property>
</Properties>
</LobSystemInstance>
</LobSystemInstances>
<Entities>
<Entity Name="MyFolder" Namespace="MyFileConnector" Version="1.0.0.1">
<Properties>
<Property Name="Title" Type="System.String">Name</Property>
</Properties>
<Identifiers>
<Identifier Name="ID" TypeName="System.String" />
</Identifiers>
<Methods>
<!-- IdEnumerator -->
<Method Name="ReadAllIds" DefaultDisplayName="ReadAllIds" IsStatic="false">
<Parameters>
<Parameter Name="returnIds" Direction="Return">
<TypeDescriptor Name="Nodes" TypeName="Microsoft.BusinessData.Runtime.DynamicType[]" IsCollection="true">
<TypeDescriptors>
<TypeDescriptor TypeName="Microsoft.BusinessData.Runtime.DynamicType" Name="Node">
<TypeDescriptors>
<TypeDescriptor Name="ID" TypeName="System.String" IdentifierName="ID" />
</TypeDescriptors>
</TypeDescriptor>
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Type="IdEnumerator" Name="ReadAllIds" DefaultDisplayName="ReadAllIds" ReturnParameterName="returnIds" Default="true">
<Properties>
<Property Name="RootFinder" Type="System.String">true</Property>
</Properties>
<AccessControlList>
<AccessControlEntry Principal="NT AUTHORITY\Authenticated Users">
<Right BdcRight="Execute" />
</AccessControlEntry>
<AccessControlEntry Principal="NT AUTHORITY\System">
<Right BdcRight="SetPermissions"/>
</AccessControlEntry>
</AccessControlList>
</MethodInstance>
</MethodInstances>
</Method>
<!-- ChangedIdEnumerator -->
<Method Name="ReadIncrementalList" IsStatic="false">
<FilterDescriptors>
<FilterDescriptor Name="LastCrawl" Type="InputOutput">
<Properties>
<Property Name="SynchronizationCookie" Type="System.String">x</Property>
</Properties>
</FilterDescriptor>
<FilterDescriptor Name="Timestamp" Type="Timestamp" />
</FilterDescriptors>
<Parameters>
<Parameter Name="lastCrawlDate" Direction="InOut">
<TypeDescriptor Name="LastCrawlDate" TypeName="System.DateTime" IsCollection="false" AssociatedFilter="LastCrawl">
<Interpretation>
<NormalizeDateTime LobDateTimeMode="Local" />
</Interpretation>
</TypeDescriptor>
</Parameter>
<Parameter Name="returnIds" Direction="Return">
<TypeDescriptor TypeName="Microsoft.BusinessData.Runtime.DynamicType[]" Name="Nodes" IsCollection="true" >
<TypeDescriptors>
<TypeDescriptor TypeName="Microsoft.BusinessData.Runtime.DynamicType" Name="Node">
<TypeDescriptors>
<TypeDescriptor TypeName="System.String" IdentifierName="ID" Name="ID" />
</TypeDescriptors>
</TypeDescriptor>
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Name="ReadIncrementalListInstance" Type="ChangedIdEnumerator" ReturnParameterName="returnIds" Default="true">
<AccessControlList>
<AccessControlEntry Principal="NT AUTHORITY\Authenticated Users">
<Right BdcRight="Execute" />
<Right BdcRight="SetPermissions" />
</AccessControlEntry>
</AccessControlList>
</MethodInstance>
</MethodInstances>
</Method>
<!-- DeletedIdEnumerator -->
<Method Name="ReadDeletedIncrementalList" IsStatic="false" DefaultDisplayName="ReadDeletedIncrementalList">
<FilterDescriptors>
<FilterDescriptor Name="LastCrawl" Type="InputOutput">
<Properties>
<Property Name="SynchronizationCookie" Type="System.String">x</Property>
</Properties>
</FilterDescriptor>
<FilterDescriptor Name="Timestamp" Type="Timestamp" />
</FilterDescriptors>
<Parameters>
<Parameter Name="LastCrawlDate" Direction="InOut">
<TypeDescriptor Name="LastCrawlDate" TypeName="System.DateTime" IsCollection="false" AssociatedFilter="LastCrawl">
<Interpretation>
<NormalizeDateTime LobDateTimeMode="Local" />
</Interpretation>
</TypeDescriptor>
</Parameter>
<Parameter Name="deletedIds" Direction="Return">
<TypeDescriptor TypeName="Microsoft.BusinessData.Runtime.DynamicType[]" Name="Nodes" IsCollection="true">
<TypeDescriptors>
<TypeDescriptor TypeName="Microsoft.BusinessData.Runtime.DynamicType" Name="Node">
<TypeDescriptors>
<TypeDescriptor Name="ID" TypeName="System.String" IdentifierName="ID" />
</TypeDescriptors>
</TypeDescriptor>
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Name="ReadDeletedIncrementalListInstance" Type="DeletedIdEnumerator" ReturnParameterName="deletedIds">
<AccessControlList>
<AccessControlEntry Principal="NT AUTHORITY\Authenticated Users">
<Right BdcRight="Execute" />
<Right BdcRight="SetPermissions" />
</AccessControlEntry>
</AccessControlList>
</MethodInstance>
</MethodInstances>
</Method>
<!-- Finder -->
<Method Name="ReadAllItems" DefaultDisplayName="ReadAllItems" IsStatic="false">
<Parameters>
<Parameter Name="returnAllItems" Direction="Return">
<TypeDescriptor TypeName="Microsoft.BusinessData.Runtime.DynamicType[]" Name="Nodes" IsCollection="true" >
<TypeDescriptors>
<TypeDescriptor TypeName="Microsoft.BusinessData.Runtime.DynamicType" Name="Node">
<TypeDescriptors>
<TypeDescriptor TypeName="System.String" IdentifierName="ID" Name="ID" />
<TypeDescriptor TypeName="System.String" Name="Name" />
<TypeDescriptor TypeName="System.String" Name="Title" />
<TypeDescriptor TypeName="System.String" Name="Path" />
</TypeDescriptors>
</TypeDescriptor>
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Type="Finder" Name="ReadAllItems" DefaultDisplayName="ReadAllItems" ReturnParameterName="returnAllItems" Default="true" ReturnTypeDescriptorName="Nodes" ReturnTypeDescriptorLevel="0">
<AccessControlList>
<AccessControlEntry Principal="NT AUTHORITY\Authenticated Users">
<Right BdcRight="Execute" />
</AccessControlEntry>
<AccessControlEntry Principal="NT AUTHORITY\System">
<Right BdcRight="SetPermissions"/>
</AccessControlEntry>
</AccessControlList>
</MethodInstance>
</MethodInstances>
</Method>
<!-- SpecificFinder -->
<Method Name="ReadItem" DefaultDisplayName="ReadItem" IsStatic="false">
<Parameters>
<Parameter Direction="In" Name="ID">
<TypeDescriptor TypeName="System.String" IdentifierName="ID" Name="ID" />
</Parameter>
<Parameter Direction="Return" Name="returnParameter">
<TypeDescriptor TypeName="Microsoft.BusinessData.Runtime.DynamicType" Name="Node">
<TypeDescriptors>
<TypeDescriptor TypeName="System.String" IdentifierName="ID" Name="ID" ReadOnly="true" />
<TypeDescriptor TypeName="System.String" Name="Title" />
<TypeDescriptor TypeName="System.String" Name="Author" />
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Type="SpecificFinder" ReturnParameterName="returnParameter" ReturnTypeDescriptorName="Node" Default="true" Name="ReadItem" DefaultDisplayName="ReadItem" ReturnTypeDescriptorLevel="0">
<AccessControlList>
<AccessControlEntry Principal="NT AUTHORITY\Authenticated Users">
<Right BdcRight="Execute" />
</AccessControlEntry>
<AccessControlEntry Principal="NT AUTHORITY\System">
<Right BdcRight="SetPermissions"/>
</AccessControlEntry>
</AccessControlList>
</MethodInstance>
</MethodInstances>
</Method>
</Methods>
</Entity>
</Entities>
</LobSystem>
What I'm doing wrong? I would really appreciate any input.
You have the same name for your SynchronizationCookie ("x"), give a different cookie name to each of your methods
I encountered similar issue recently (SpecificFinder not called) in my custom BCS connector and managed to sort it out. In my scenario I have two entities (parent and child), and SpecificFinder was called only for parent entities but was not called for the child ones.
It turned out that the issue was related to the way I constructed "access URIs". Initially the URIs were like this:
<protocol>://<entity_name>/<entity_id>
And my start URL (specified in the content source definition) was an URL of a "fake" parent entity (without any ID):
<protocol>://<parent_entity_name>
But it seems that SharePoint crawler treats access URIs in the same way as web URLs, and applies a filter by the URL path specified in the content source definition. In other words, in my case, it would only crawl URIs corresponding to the following pattern:
<protocol>://<parent_entity_name>/*
After I changed my access URI format to
<protocol>://root/<entity_name>
and set my start URL in the content source definition to
<protocol>://root
everything started working properly.

Error deploying SharePoint 2010 solution - Cannot create more than '500' IEntity objects per ILobSystem object

I am generating a sharepoint 2010 bdc model xml file along with the entities and associated service classes from a model 1st LLBLGen framework/ C# .net 3.5 project. All was going well when suddenly I started receiving this error while deploying the BDC solution;
"Error 178 Error occurred in deployment step 'Add Solution': Cannot create more than '500' IEntity objects per ILobSystem object. "
It had been deploying fine (after modifying the registry to extend the timeout settings) with the current number of entities. I can't find any reference to IEntity object limitations in MSDN nor via google and have tried changing the generated xml file in various ways to test. If I remove an entity, the error shifts to the beginning of the next entity. Visual Studio builds the solution just fine with only warnings about the datetime datatype (known problem apparently).
I only have 59 entities defined. Some of which are in inheritance hierarchies and there are numerous FK relationships expressed in the model. It doesn't make any sense to me that I have too many entities in my model. I have plenty more I would like to add. I am including EstimatedInstanceCount="10000" on each entity but that doesn't seem to effect anything. In fact I believe it is the default. The model file is quite large but I will include the following single entity snippet for reference as to what code is being generated.
<Entity Name="Load" Namespace="SharePoint.DataConnector.VoyagerModel" EstimatedInstanceCount="10000" Version="1.0.0.26">
<Properties>
<Property Name="Class" Type="System.String">SharePoint.DataConnector.VoyagerModel.LoadService, VoyagerModel</Property>
</Properties>
<Identifiers>
<Identifier Name="Id" TypeName="System.Int32" />
<!-- TODO: Change the name of the ID and if needed the TypeName of your identifier. -->
</Identifiers>
<Methods>
<!-- start finder method -->
<Method Name="ReadList">
<!-- TODO: Change the name of the method if needed. -->
<Parameters>
<Parameter Direction="Return" Name="returnParameter">
<TypeDescriptor TypeName="System.Collections.Generic.IEnumerable`1[[SharePoint.DataConnector.VoyagerModel.Load, VoyagerModel]]" IsCollection="true" Name="LoadList">
<TypeDescriptors>
<TypeDescriptor Name="Load" TypeName="SharePoint.DataConnector.VoyagerModel.Load, VoyagerModel">
<TypeDescriptors>
<TypeDescriptor Name="Id" TypeName="System.Int32" IdentifierName="Id" IsCollection="false" ReadOnly="false" />
<!-- TODO: Add TypeDescriptors when you add properties to Load. -->
<TypeDescriptor Name="OrderId" IsCollection="false" ReadOnly="false" TypeName="System.Int32" />
<TypeDescriptor Name="Status" IsCollection="false" ReadOnly="false" TypeName="System.String" />
<TypeDescriptor Name="DriverId" TypeName="System.Int32" IdentifierEntityName="Driver" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" IsCollection="false" />
</TypeDescriptors>
</TypeDescriptor>
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Type="Finder" ReturnParameterName="returnParameter" Default="true" Name="ReadList" DefaultDisplayName="Load List">
<Properties>
<Property Name="RootFinder" Type="System.String">x</Property>
</Properties>
</MethodInstance>
</MethodInstances>
</Method>
<!-- end finder method -->
<!-- start specific finder method -->
<Method Name="ReadItem">
<Parameters>
<Parameter Direction="In" Name="id">
<TypeDescriptor TypeName="System.Int32" IdentifierName="Id" Name="Id" IsCollection="false" />
</Parameter>
<Parameter Direction="Return" Name="returnParameter">
<TypeDescriptor TypeName="SharePoint.DataConnector.VoyagerModel.Load, VoyagerModel" Name="Load">
<TypeDescriptors>
<TypeDescriptor Name="Id" TypeName="System.Int32" IdentifierName="Id" IsCollection="false" ReadOnly="false" />
<!-- TODO: Add TypeDescriptors when you add properties to Load. -->
<TypeDescriptor Name="OrderId" TypeName="System.Int32" IsCollection="false" />
<TypeDescriptor Name="Status" TypeName="System.String" IsCollection="false" />
<TypeDescriptor Name="DriverId" TypeName="System.Int32" IdentifierEntityName="Driver" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" IsCollection="false" />
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Type="SpecificFinder" ReturnParameterName="returnParameter" Default="true" Name="ReadItem" DefaultDisplayName="Read Load" />
</MethodInstances>
</Method>
<Method Name="Create">
<Parameters>
<Parameter Name="returnLoad" Direction="Return">
<TypeDescriptor Name="ReturnLoad" TypeName="SharePoint.DataConnector.VoyagerModel.Load, VoyagerModel">
<TypeDescriptors>
<TypeDescriptor Name="Id" TypeName="System.Int32" IdentifierName="Id" IsCollection="false" ReadOnly="false" />
<TypeDescriptor Name="OrderId" TypeName="System.Int32" IsCollection="false" />
<TypeDescriptor Name="Status" TypeName="System.String" IsCollection="false" />
<TypeDescriptor Name="DriverId" TypeName="System.Int32" IdentifierEntityName="Driver" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" IsCollection="false" />
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
<Parameter Name="newLoad" Direction="In">
<TypeDescriptor Name="NewLoad" TypeName="SharePoint.DataConnector.VoyagerModel.Load, VoyagerModel">
<TypeDescriptors>
<TypeDescriptor Name="Id" IdentifierName="Id" IsCollection="false" ReadOnly="false" TypeName="System.Int32" CreatorField="false" />
<TypeDescriptor Name="OrderId" TypeName="System.Int32" IsCollection="false" CreatorField="true" />
<TypeDescriptor Name="Status" TypeName="System.String" IsCollection="false" CreatorField="true" />
<TypeDescriptor Name="DriverId" TypeName="System.Int32" IdentifierEntityName="Driver" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" IsCollection="false" />
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Name="Create" Type="Creator" ReturnParameterName="returnLoad" ReturnTypeDescriptorPath="ReturnLoad" />
</MethodInstances>
</Method>
<Method Name="Delete">
<Parameters>
<Parameter Name="id" Direction="In">
<TypeDescriptor Name="Id" TypeName="System.Int32" IdentifierEntityName="Load" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" />
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Name="Delete" Type="Deleter" />
</MethodInstances>
</Method>
<Method Name="Update">
<Parameters>
<Parameter Name="Load" Direction="In">
<TypeDescriptor Name="Load" TypeName="SharePoint.DataConnector.VoyagerModel.Load, VoyagerModel">
<TypeDescriptors>
<TypeDescriptor Name="Id" TypeName="System.Int32" IdentifierName="Id" IsCollection="false" ReadOnly="false" />
<TypeDescriptor Name="OrderId" TypeName="System.Int32" IsCollection="false" UpdaterField="true" />
<TypeDescriptor Name="Status" TypeName="System.String" IsCollection="false" UpdaterField="true" />
<TypeDescriptor Name="DriverId" TypeName="System.Int32" IdentifierEntityName="Driver" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" IsCollection="false" />
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<MethodInstance Name="Update" Type="Updater" />
</MethodInstances>
</Method>
<!-- start related entity methods -->
<Method Name="LoadToOrders">
<Parameters>
<Parameter Name="id" Direction="In">
<TypeDescriptor Name="Id" TypeName="System.Int32" IdentifierEntityName="Load" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" ForeignIdentifierAssociationEntityName="Load" ForeignIdentifierAssociationEntityNamespace="SharePoint.DataConnector.VoyagerModel" ForeignIdentifierAssociationName="LoadToOrdersAssociationNavigator" />
</Parameter>
<Parameter Name="orderList" Direction="Return">
<TypeDescriptor Name="OrderList" TypeName="System.Collections.Generic.IEnumerable`1[[SharePoint.DataConnector.VoyagerModel.Order, VoyagerModel]]" IsCollection="true">
<TypeDescriptors>
<TypeDescriptor Name="Order" TypeName="SharePoint.DataConnector.VoyagerModel.Order, VoyagerModel">
<TypeDescriptors>
<TypeDescriptor Name="Id" IsCollection="false" ReadOnly="true" TypeName="System.Int32" IdentifierEntityName="Order" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" />
</TypeDescriptors>
</TypeDescriptor>
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<Association Name="LoadToOrdersAssociationNavigator" Type="AssociationNavigator" ReturnParameterName="orderList" ReturnTypeDescriptorPath="OrderList">
<SourceEntity Name="Load" Namespace="SharePoint.DataConnector.VoyagerModel" />
<DestinationEntity Name="Order" Namespace="SharePoint.DataConnector.VoyagerModel" />
</Association>
</MethodInstances>
</Method>
<Method Name="LoadToDriver">
<Parameters>
<Parameter Name="id" Direction="In">
<TypeDescriptor Name="Id" TypeName="System.Int32" IdentifierEntityName="Load" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" ForeignIdentifierAssociationEntityName="Load" ForeignIdentifierAssociationEntityNamespace="SharePoint.DataConnector.VoyagerModel" ForeignIdentifierAssociationName="LoadToDriverAssociationNavigator" />
</Parameter>
<Parameter Name="driverList" Direction="Return">
<TypeDescriptor Name="DriverList" TypeName="System.Collections.Generic.IEnumerable`1[[SharePoint.DataConnector.VoyagerModel.Driver, VoyagerModel]]" IsCollection="true">
<TypeDescriptors>
<TypeDescriptor Name="Driver" TypeName="SharePoint.DataConnector.VoyagerModel.Driver, VoyagerModel">
<TypeDescriptors>
<TypeDescriptor Name="Id" IsCollection="false" ReadOnly="true" TypeName="System.Int32" IdentifierEntityName="Driver" IdentifierEntityNamespace="SharePoint.DataConnector.VoyagerModel" IdentifierName="Id" />
</TypeDescriptors>
</TypeDescriptor>
</TypeDescriptors>
</TypeDescriptor>
</Parameter>
</Parameters>
<MethodInstances>
<Association Name="LoadToDriverAssociationNavigator" Type="AssociationNavigator" ReturnParameterName="driverList" ReturnTypeDescriptorPath="DriverList">
<SourceEntity Name="Load" Namespace="SharePoint.DataConnector.VoyagerModel" />
<DestinationEntity Name="Driver" Namespace="SharePoint.DataConnector.VoyagerModel" />
</Association>
</MethodInstances>
</Method>
<!-- end related entity methods -->
</Methods>
<AssociationGroups>
<AssociationGroup Name="DriverToLoadAssociation">
<AssociationReference AssociationName="LoadToDriverAssociationNavigator" Reverse="true" />
</AssociationGroup>
</AssociationGroups>
</Entity>
Is this a misleading error message?
What changes could I try to the model?
Could there be any site settings effecting this?
Thanks for any help!
I have actually ran in to the same problem as you described and couldn't find much information about it back then either. The MSDN article you referred to however is for SharePoint 2007 and the BDC model, not for the Business Connectivity Services.
If you only have 59 entities, it is likely the LobSystem isn't completely removed after retracting your solution. The model and entities do get removed, but the LobSystem itself will still exist. You can check this from Central Administration.Thus every new deployment you do will add the entities to the system again and raising the ´entity count´, reaching the 500 limitation much faster then expected.
Try removing the LobSystem manually (through Central Administration) so a new LobSystem will get created during deployment as well.
OK, so apparently not too many people are working with large enterprise level BDC models? I'm scared...
I've found what I guess is my answer in MSDN. If you go to MSDN You'll find the LobSystem limitations detailed of which;
LobSystemInstances - Max instances per system: 300
Entities - Max entities per system: 200
Associations - Max associations per system: 1000
Individually, these don't sound like a problem. I am using a single Lob instance and I only have 59 entities. And on average 8 or so associations on each. But how the Max associations are calculated I have no idea. Does each side of the association count as an instance? Does each reference to the association add a reference?
I would love to hear some deeper insight into the LobSystem architecture.
In the mean time, I am going to split my model into separate schema groups and modify my templates to create associations in the bdc model schema file which fully qualify across different LobSystem models.
If anyone knows why this won't work, please stop me NOW!

Deploy 3 ContentTypes using 1 Feature - Only 2 gets deployed

I have a feature which has following manifest file that defines multiple content types:
<?xml version="1.0" encoding="utf-8" ?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
<ContentType ID="0x01008e5736f1388b4809a9f102da1e573ddb"
Name="$Resources:Balticovo,ContentType_AgendaName"
Group="$Resources:core,CustomContentTypesGroup"
Description="$Resources:Balticovo,ContentType_AgendaDescription"
Version="1">
<FieldRefs>
<!-- Jautājumu pacēla-->
<FieldRef ID="{31b28519-c87e-4e0d-9c1b-d02c5e034cf9}" />
<!-- Kam piešķirts -->
<FieldRef ID="{53101f38-dd2e-458c-b245-0c236cc13d1a}" />
<!-- Saistītās personas -->
<FieldRef ID="{E5C80D9B-4E09-4457-A6A9-5A6F574DEDA5}" />
<!-- Komentāri -->
<FieldRef ID="{6df9bd52-550e-4a30-bc31-a4366832a87f}" />
<!-- Izpildīt līdz -->
<FieldRef ID="{cd21b4c2-6841-4f9e-a23a-738a65f99889}" />
</FieldRefs>
<XmlDocuments>
<XmlDocument NamespaceURI="http://schemas.microsoft.com/sharepoint/events">
<spe:Receivers xmlns:spe="http://schemas.microsoft.com/sharepoint/events">
<Receiver>
<Name>AgendaToTaskOnAdd</Name>
<Type>ItemAdded</Type>
<SequenceNumber>10000</SequenceNumber>
<Assembly>Balticovo.SharePoint, Version=1.0.0.0, Culture=neutral, PublicKeyToken=9f4da00116c38ec5</Assembly>
<Class>Balticovo.SharePoint.AgendaToTask</Class>
<Data></Data>
<Filter></Filter>
</Receiver>
<Receiver>
<Name>AgendaToTaskOnUpdate</Name>
<Type>ItemUpdating</Type>
<SequenceNumber>10000</SequenceNumber>
<Assembly>Balticovo.SharePoint, Version=1.0.0.0, Culture=neutral, PublicKeyToken=9f4da00116c38ec5</Assembly>
<Class>Balticovo.SharePoint.AgendaToTask</Class>
<Data></Data>
<Filter></Filter>
</Receiver>
</spe:Receivers>
</XmlDocument>
</XmlDocuments>
</ContentType>
<ContentType ID="0x0100AD4DFC626A3F4db492A4FCF91B0E47A0"
Name="$Resources:Balticovo,ContentType_ReglarAttendeeName"
Group="$Resources:core,CustomContentTypesGroup"
Description="$Resources:Balticovo,ContentType_ReglarAttendeeDescription"
Version="1">
<FieldRefs>
<FieldRef ID="{fa564e0f-0c70-4ab9-b863-0177e6ddd247}" Required="FALSE" Hidden="TRUE" />
<FieldRef ID="{37D4FF81-9DE1-436a-B270-923E93258507}" />
</FieldRefs>
<XmlDocuments>
<XmlDocument NamespaceURI="http://schemas.microsoft.com/sharepoint/events">
<spe:Receivers xmlns:spe="http://schemas.microsoft.com/sharepoint/events">
<Receiver>
<Name>AddAttendeeToCurrentMeeting</Name>
<Type>ItemAdded</Type>
<SequenceNumber>10000</SequenceNumber>
<Assembly>Balticovo.SharePoint, Version=1.0.0.0, Culture=neutral, PublicKeyToken=9f4da00116c38ec5</Assembly>
<Class>Balticovo.SharePoint.RegularAttendeesEventReceiver</Class>
<Data></Data>
<Filter></Filter>
</Receiver>
</spe:Receivers>
</XmlDocument>
</XmlDocuments>
</ContentType>
<ContentType ID="0x01008606FC8499F9407b83AF3DBAD6865F58"
Name="$Resources:Balticovo,ContentType_WebApplicationQueryName"
Group="$Resources:core,CustomContentTypesGroup"
Description="$Resources:Balticovo,ContentType_WebApplicationQueryDescription"
Version="1">
<FieldRefs>
<FieldRef ID="{acbe30d6-ea25-40a2-b6e5-9df76e9c881e}" />
<FieldRef ID="{6c732395-7404-4ad4-9b03-50195b70c006}" />
<FieldRef ID="{cb16a530-21ca-43b1-b270-dbb33fa3f7a7}" />
<FieldRef ID="{bd94a837-82ab-4a8b-b7df-9978cd35f9ec}" />
<FieldRef ID="{c05e3059-b1fc-4116-8f7d-1cfde24b96f4}" />
<FieldRef ID="{32fb6f25-cf6e-4e9c-8244-137d017c9348}" />
<FieldRef ID="{e42ca75d-f017-4eb7-91a6-236dfd71017a}" />
<FieldRef ID="{EAA39077-D6AF-464e-8052-9001B4E99834}" />
</FieldRefs>
</ContentType>
</Elements>
So, there are 3 CT's, however first one doesn't deploy. It's not hidden, because when checking SPWeb.AvailableContentTypes - there is no such CT available.
ID of CType is Unique.
Receiver classes are publicly
available.
Referencing fields are also
available.
Trying this on a fresh web application.
Oh, what could be wrong?
Solved.
Those <!-- --> comments between tags prevented this content type to be deployed.

Resources