Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Software > Commerce Server Catalog > Catalog Web Ser...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 1 Topic 754 of 763
Post > Topic >>

Catalog Web Service Im****t Failure

by adamstewart1980@[EMAIL PROTECTED] Aug 21, 2007 at 10:58 AM

Hi there,

We are running CS2k2 FP1 and SP4. We have a .NET windows service that
picks up xml files, transforms them, and then creates / appends the
catalog via the web service. This has worked fine for months and is in
production.

Recently a file failed to load, and in the process of the failure it
stopped the whole update process, and left us with an empty catalog.
This is down to our code, and that we dont have a failover mechanism
in place right now. We're looking in to that also.

However i have investigated the reason that the failure occured. It
seems that one record in the extract is causing the issues, and more
to the point two characters in particular.

It would appear that a text field we have contains the string
'%s' (remove ' ), and this causes the entire load process to fail.


// connect to catalog webservice
CatalogServiceAgent agent = new CatalogServiceAgent(webServiceUrl,
ServiceAgent.DefaultAuthMethods);
agent.SoapProxy.Timeout = 9999000; // milliseconds

CatalogContext ctx = CatalogContext.Create(agent, new
ConsoleDebugContext(DebugMode.Debug));
// begin im****t
XmlIm****tOptions im****t = new XmlIm****tOptions();
im****t.FileName = im****tSourceFile;
im****t.Mode = (im****tType == FileExtractType.Full) ?
CatalogIm****tMode.Full : CatalogIm****tMode.Incremental;
int operationId = ctx.Im****tXml(im****t);
// wait for im****t to finish
while (ctx.GetIm****tProgress(operationId).Status ==
CatalogOperationsStatus.InProgress)
{
  // The im****t is in progress so wait here before checking the status
again
  Thread.Sleep(20000); // 20 seconds
}
CatalogOperationsStatus im****tResult =
ctx.GetIm****tProgress(operationId).Status;

results in a status of 'Failed'

Ive looked at the DB trace, and when compared to this record running
without the offending string there is a noticiable difference, SQL is
executing a log more commands when a successfully load happens. So it
looks like the Web Service is truncating the entire process without
providing any usefull feedback

Surely a text field can take a string like %s -> yes this could be a
placeholder value somewhere, but we've tried others such as %d and
that works fine.

Any ideas?
 




 1 Posts in Topic:
Catalog Web Service Import Failure
adamstewart1980@[EMAIL PR  2007-08-21 10:58:39 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Thu Dec 4 11:35:49 CST 2008.