Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Nilesh 4 posts 24 karma points
    Dec 28, 2011 @ 16:32
    Nilesh
    0

    Getting exception while running Revision extraction

    Hi Guys

     

    I am using RevisionExtraction to extract a revision to a destination server with Courier version 2.5.1. But I am getting this exception on call to  Extract() method.

     

    System.Web.Services.Protocols.SoapException: Server was unable to process request. ---> System.ArgumentNullException: Value cannot be null.
    Parameter name: key
       at System.Collections.Generic.Dictionary`2.FindEntry(TKey key)
       at Umbraco.Courier.Core.ContextManager.Get(String key)
       at Umbraco.Courier.RepositoryProviders.Local.TransferResources(ResourceTransfer[] resources) in c:\Program Files (x86)\teamcity\buildAgent\work\7302128a06ae6604\Umbraco.Courier.RepositoryProviders\Local\Local.cs:line 149
       --- End of inner exception stack trace ---

     

    I wonder if anyone facing same issue can help me?

     

    Thanks

    Nilesh

  • Nikolay Arhangelov 15 posts 34 karma points
    Jul 02, 2013 @ 13:58
    Nikolay Arhangelov
    0

    Hello,

    I am having a similar issue with the Extract method:

    The given key was not present in the dictionary.
       at System.Collections.Generic.Dictionary`2.get_Item(TKey key)
       at Umbraco.Courier.Core.PersistenceManager.get_Default()
       at Umbraco.Courier.RepositoryProviders.Local.OpenSession(String key)
       at Umbraco.Courier.Core.Extraction.RevisionExtraction.Extract()
       at Infragistics.Umbraco.Tasks.ExtractRevisionTask.Execute() in ...

    My version of Courier is 2.7.5

    Here is my code:

    string pluginsRoot = Path.Combine(UmbracoRoot, @"Umbraco\Plugins");
    string configPath = Path.Combine(UmbracoRoot, @"Config\config.xml");

    TypeResolver.LoadAssembliesIntoAppDomain(pluginsRoot, "*.dll");

    Context.Current.SettingsFilePath = Context.Current.MapPath(configPath);

    Context.Current.BaseDirectory = UmbracoRoot;
    Context.Current.HasHttpContext = false;
    try
    {
    CourierWebserviceRepositoryProvider repositoryProvider = new CourierWebserviceRepositoryProvider();
    repositoryProvider.Login = Login;
    repositoryProvider.Password = Password;
    repositoryProvider.Url = UmbracoUrl;
    repositoryProvider.UserId = -1;

    using (Repository repository = new Repository(repositoryProvider))
    {
    using (RevisionExtraction extractingEngine = new RevisionExtraction(Revision))
    {
    extractingEngine.Source = repository;
    extractingEngine.ExtractedItem += (sender, e) => Log.LogMessage("Extracted item {0}.", e.Item.Name);
    extractingEngine.ExtractedItemResources += (sender, e) => Log.LogMessage("Extracted resource {0}.", e.Item.Name);
    extractingEngine.Extract();
    }
    }

    return true;
    }
    catch (Exception exc)
    {
    Log.LogErrorFromException(exc);
    return false;
    }
  • Jeremy Pyne 106 posts 246 karma points MVP c-trib
    Jul 02, 2013 @ 19:36
    Jeremy Pyne
    0

    similer: Looks like it is never trying to create the document/cant find it.

     

    /2/2013 1:27:47 PM; Umbraco.Courier.Core.Exceptions.ExtractionManagerException: There was a problem with extracting database information for the item: Name:Document Why Windstream Property Data | Id:b12a9253-9fc9-4625-9fec-e999d0c5c0ff | Provider:PropertyData. Stacktrace: System.NullReferenceException: Object reference not set to an instance of an object.

       at Umbraco.Courier.Persistence.V6.NHibernate.Helpers.ContentTypeHelper.GetPropertyTypesRecursively(CmsContentType ct, ISession session) in c:\Program Files (x86)\teamcity\buildAgent\work\650bafc4b83aa858\Core\Umbraco.Courier.Persistence.V6.NHibernate\Helpers\ContentTypeHelper.cs:line 175

       at Umbraco.Courier.Persistence.V6.NHibernate.Helpers.ContentTypeHelper.GetPropertyTypesRecursively(String ct, Guid nodeObjectType, ISession session) in c:\Program Files (x86)\teamcity\buildAgent\work\650bafc4b83aa858\Core\Umbraco.Courier.Persistence.V6.NHibernate\Helpers\ContentTypeHelper.cs:line 170

       at Umbraco.Courier.Persistence.V6.NHibernate.Persisters.ContentPropertyDataItem.PersistItem[T](T item) in c:\Program Files (x86)\teamcity\buildAgent\work\650bafc4b83aa858\Core\Umbraco.Courier.Persistence.V6.NHibernate\Persisters\ContentPropertyData.cs:line 76

       at Umbraco.Courier.ItemProviders.PropertyItemProvider.HandleExtract(Item item)

       at Umbraco.Courier.Core.ItemProvider.Extract(Item item)

       at Umbraco.Courier.RepositoryProviders.Local.ExtractItem(Item item, Boolean overwrite)

       at Umbraco.Courier.Core.Extraction.RevisionExtraction.extractItem(GraphNode node, Boolean isDependency)

       at Umbraco.Courier.Core.Extraction.RevisionExtraction.extractReadyRevisionBatch()

       at Umbraco.Courier.Core.Extraction.RevisionExtraction.extractReadyRevisionBatch()

       at Umbraco.Courier.Core.Extraction.RevisionExtraction.Extract() ---> System.NullReferenceException: Object reference not set to an instance of an object.

       at Umbraco.Courier.Persistence.V6.NHibernate.Helpers.ContentTypeHelper.GetPropertyTypesRecursively(CmsContentType ct, ISession session) in c:\Program Files (x86)\teamcity\buildAgent\work\650bafc4b83aa858\Core\Umbraco.Courier.Persistence.V6.NHibernate\Helpers\ContentTypeHelper.cs:line 175

       at Umbraco.Courier.Persistence.V6.NHibernate.Helpers.ContentTypeHelper.GetPropertyTypesRecursively(String ct, Guid nodeObjectType, ISession session) in c:\Program Files (x86)\teamcity\buildAgent\work\650bafc4b83aa858\Core\Umbraco.Courier.Persistence.V6.NHibernate\Helpers\ContentTypeHelper.cs:line 170

       at Umbraco.Courier.Persistence.V6.NHibernate.Persisters.ContentPropertyDataItem.PersistItem[T](T item) in c:\Program Files (x86)\teamcity\buildAgent\work\650bafc4b83aa858\Core\Umbraco.Courier.Persistence.V6.NHibernate\Persisters\ContentPropertyData.cs:line 76

       at Umbraco.Courier.ItemProviders.PropertyItemProvider.HandleExtract(Item item)

       at Umbraco.Courier.Core.ItemProvider.Extract(Item item)

       at Umbraco.Courier.RepositoryProviders.Local.ExtractItem(Item item, Boolean overwrite)

       at Umbraco.Courier.Core.Extraction.RevisionExtraction.extractItem(GraphNode node, Boolean isDependency)

       at Umbraco.Courier.Core.Extraction.RevisionExtraction.extractReadyRevisionBatch()

       at Umbraco.Courier.Core.Extraction.RevisionExtraction.extractReadyRevisionBatch()

       at Umbraco.Courier.Core.Extraction.RevisionExtraction.Extract()

       --- End of inner exception stack trace ---

       at Umbraco.Courier.Core.Extraction.RevisionExtraction.Extract()

       at Umbraco.Courier.Core.Tasks.ExtractionTask.Run()

       at Umbraco.Courier.Core.TaskManager.manageTask(IRevisionTask value)

Please Sign in or register to post replies

Write your reply to:

Draft