开发者

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, Vo开发者_C百科yagerModel">
                        <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!

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜