Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / Component Services / March 2008

Tip: Looking for answers? Try searching our database.

exhausted, beaten - C# COM+ component as a web services...FileNotFoundException

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
uncle - 22 Jan 2008 19:31 GMT
- I have a class lib C# project that has a few methods and the (I
think) proper magic for managing via COM+.
- I can expose it via SOAP using the property dialog (identity tab)
uses soap checkbox.
- A virtual directory magically shows up in IIS.
- I am running on Windows Server 2003 Standard

When I hit the url for the service (http://localhost/Cache/
COMPlusCache.Cache.soap?WSDL) I get some FileNotFoundException mess
(see below).

So, what have I tried? glad you asked...
- giving the C:\WINDOWS\Temp directory very open permissions (as
suggested by someone)
- giving C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\Temporary
ASP.NET Files very open permissions
- trying ASP.NET 2.0.50727 (instead of 1.1.4322) - just get nothing
from the wsdl url
- switching to release mode when I build my dll

Setup wise, I have...
- signed dll
- regsvcs Cache.dll
- gacutil /i Cache.dll

ANY HELP !!! pleeeeeaaaaase

result from http://localhost/Cache/COMPlusCache.Cache.soap?WSDL

System.IO.FileNotFoundException: File or assembly name Cache, or one
of its dependencies, was not found.
File name: "Cache"
  at System.Reflection.Assembly.nLoad(AssemblyName fileName, String
codeBase, Boolean isStringized, Evidence assemblySecurity, Boolean
throwOnFileNotFound, Assembly locationHint, StackCrawlMark& stackMark)
  at System.Reflection.Assembly.InternalLoad(AssemblyName
assemblyRef, Boolean stringized, Evidence assemblySecurity,
StackCrawlMark& stackMark)
  at System.Reflection.Assembly.InternalLoad(String assemblyString,
Evidence assemblySecurity, StackCrawlMark& stackMark)
  at System.Reflection.Assembly.Load(String assemblyString)
  at System.Runtime.Remoting.RemotingConfigInfo.LoadType(String
typeName, String assemblyName)
  at
System.Runtime.Remoting.RemotingConfigInfo.GetServerTypeForUri(String
URI)
  at
System.Runtime.Remoting.RemotingConfigHandler.GetServerTypeForUri(String
URI)
  at
System.Runtime.Remoting.RemotingServices.GetServerTypeForUri(String
URI)
  at
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.CanServiceRequest(HttpContext
context)
  at
System.Runtime.Remoting.Channels.Http.HttpRemotingHandler.InternalProcessRequest(HttpContext
context)

=== Pre-bind state information ===
LOG: DisplayName = Cache, Version=1.0.0.0, Culture=neutral,
PublicKeyToken=fcc054921a88ed92
(Fully-specified)
LOG: Appbase = file:///C:/WINDOWS/system32/com/SoapVRoots/Cache
LOG: Initial PrivatePath = bin
Calling assembly : (Unknown).
===

LOG: Publisher policy file is not found.
LOG: No redirect found in host configuration file (c:\windows
\microsoft.net\framework\v1.1.4322\aspnet.config).
LOG: Using machine configuration file from C:\WINDOWS\Microsoft.NET
\Framework\v1.1.4322\config\machine.config.
LOG: Post-policy reference: Cache, Version=1.0.0.0, Culture=neutral,
PublicKeyToken=fcc054921a88ed92
LOG: Attempting download of new URL file:///c:/windows/microsoft.net/framework/v1.1.4322/Temporary
ASP.NET Files/cache/b38bb36f/b2e75973/Cache.DLL.
LOG: Attempting download of new URL file:///c:/windows/microsoft.net/framework/v1.1.4322/Temporary
ASP.NET Files/cache/b38bb36f/b2e75973/Cache/Cache.DLL.
LOG: Attempting download of new URL file:///C:/WINDOWS/system32/com/SoapVRoots/Cache/bin/Cache.DLL.
LOG: Attempting download of new URL file:///C:/WINDOWS/system32/com/SoapVRoots/Cache/bin/Cache/Cache.DLL.
LOG: Attempting download of new URL file:///c:/windows/microsoft.net/framework/v1.1.4322/Temporary
ASP.NET Files/cache/b38bb36f/b2e75973/Cache.EXE.
LOG: Attempting download of new URL file:///c:/windows/microsoft.net/framework/v1.1.4322/Temporary
ASP.NET Files/cache/b38bb36f/b2e75973/Cache/Cache.EXE.
LOG: Attempting download of new URL file:///C:/WINDOWS/system32/com/SoapVRoots/Cache/bin/Cache.EXE.
LOG: Attempting download of new URL file:///C:/WINDOWS/system32/com/SoapVRoots/Cache/bin/Cache/Cache.EXE.
John Saunders [MVP] - 23 Jan 2008 01:12 GMT
>- I have a class lib C# project that has a few methods and the (I
> think) proper magic for managing via COM+.
[quoted text clipped - 91 lines]
> LOG: Attempting download of new URL
> file:///C:/WINDOWS/system32/com/SoapVRoots/Cache/bin/Cache/Cache.EXE.

So, where _is_ Cache.dll located? It appears that it should be in
C:\Windows\System32\com\SoapVRoots\Cache\bin\Cache.dll.
Signature

--------------------------------------------------------------------------------
John Saunders | MVP - Windows Server System - Connected System Developer

uncle - 23 Jan 2008 02:23 GMT
On Jan 22, 7:12 pm, "John Saunders [MVP]" <john.saunders at
trizetto.com> wrote:

> >- I have a class lib C# project that has a few methods and the (I
> > think) proper magic for managing via COM+.
[quoted text clipped - 97 lines]
> --------------------------------------------------------------------------------
> John Saunders | MVP - Windows Server System - Connected System Developer

The Cache.dll the comes from building my project is in c:\aktxyz\Cache
\Cache.dll
- I then register the dll into the GAC
- I then register the dll as a com+ component
- I then enable the com+ component for soap activation

This last step is supposed to automagically create the virtual
directory (in the C:\Windows\System32\com\SoapVRoots folder).  I have
read different things about the dll automatically being generated for
the SoapVRoots and something about the ASP.NET temp directory.  All
the instructions I have been able to find imply that there should be
no DLL copying around required.
uncle - 23 Jan 2008 02:29 GMT
> On Jan 22, 7:12 pm, "John Saunders [MVP]" <john.saunders at
>
[quoted text clipped - 117 lines]
> the instructions I have been able to find imply that there should be
> no DLL copying around required.

So, another set of questions would be
- where should the Cache.DLL go?
- who should put it there?
- is it the same Cache.DLL as spit out by my class lib C# project?
 - I don't think so, I think it is some auto generated proxy of some
sort
John Saunders [MVP] - 23 Jan 2008 18:40 GMT
>> On Jan 22, 7:12 pm, "John Saunders [MVP]" <john.saunders at
>>
[quoted text clipped - 126 lines]
>  - I don't think so, I think it is some auto generated proxy of some
> sort

Why not try copying your Cache.dll to
C:\Windows\System32\com\SoapVRoots\Cache\bin\ and see what happens?
Signature

--------------------------------------------------------------------------------
John Saunders | MVP - Windows Server System - Connected System Developer

uncle - 25 Jan 2008 03:53 GMT
Tried that, BadImageFormatException.

On Jan 23, 12:40 pm, "John Saunders [MVP]" <john.saunders at
trizetto.com> wrote:

> >> On Jan 22, 7:12 pm, "John Saunders [MVP]" <john.saunders at
>
[quoted text clipped - 132 lines]
> --------------------------------------------------------------------------------
> John Saunders | MVP - Windows Server System - Connected System Developer
John Saunders [MVP] - 25 Jan 2008 10:43 GMT
> Tried that, BadImageFormatException.

If the DLL isn't in C:\Windows\System32\com\SoapVRoots\Cache\bin\, then you
get a file not found. If it _is_ in
C:\Windows\System32\com\SoapVRoots\Cache\bin\, you get bad image format
instead of file not found. I think that means that it *found* the file and
that it has a bad image format.
Signature

--------------------------------------------------------------------------------
John Saunders | MVP - Windows Server System - Connected System Developer

caractacus - 07 Mar 2008 08:58 GMT
I am having trouble in this area, but I solved the File not Found message:

Ensure that the DLL containing your interfaces is also installed into the
GAC. It's your DLL's dependencies that are not being found.

I moved my interfaces into the ServicedComponent DLL before I understood the
problem.

With regard to the discussion up to this point -  it's in the GAC. You do
not need to copy it anywhere.

I am having ongoing problems with this in VISTA on .NET 2.0. I can't get
SOAP to work on serviced components - there's no WSDL support and the .soap
url reports tht the service cannot be found. At least I managed to figure out
that you MUST have an HTTPS binding on the defauilt web site to even enable
'Uses SOAP'.

Guys, please update your documentation! We're exhausted, beaten.

> > Tried that, BadImageFormatException.
>
[quoted text clipped - 3 lines]
> instead of file not found. I think that means that it *found* the file and
> that it has a bad image format.
John Saunders [MVP] - 07 Mar 2008 16:00 GMT
> I am having ongoing problems with this in VISTA on .NET 2.0. I can't get
> SOAP to work on serviced components - there's no WSDL support and the
[quoted text clipped - 6 lines]
>
> Guys, please update your documentation! We're exhausted, beaten.

I'd suggest you start a new thread about your ongoing problems.
Signature

--------------------------------------------------------------------------------
John Saunders | MVP - Windows Server System - Connected System Developer


Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.