Significance of the Checkedout Path on the File file type

Good morning - I'm hoping someone can help me here.  I'm wondering what is the significance of the property Checkedout Path when adding a file to the vault manually.

I have the following code that takes a PDF file from a data structure that I am passing in to the method, writes the physical file out and then checks the file into the Vault.

phyFile = @"D:\\Temp\\" + fileName;
FileStream fs = new FileStream(phyFile,FileMode.OpenOrCreate);
fs.Write(matRecord[0].h_report_blob,0,matRecord[0].h_report_blob.Length);
fs.Close();
Item newReport = inn.newItem("File", "add");
newReport.setAttribute("doGetItem", "0");
newReport.setProperty("Comments", "Materials Report");
newReport.setProperty("file_type", pdfType.getProperty("id"));
newReport.setProperty("filename", fileName);
newReport.attachPhysicalFile(phyFile);
newReport = newReport.apply();

if(File.Exists(phyFile))
{
 File.Delete(phyFile);
 }

Once this code is complete, I can search the physical vault on my machine and I can see that the file has been created in the vault, and it has been deleted from the local file system from where I attached it.  When I go to view the physical file from within Aras, my machine actually gives me a Blue Screen of Death (BSOD) and completely crashes.  In attempting to try and figure out what is going on, I commented out the last section of code to delete the file from the local file system.  When I do that and I view the file from within Aras, it displays perfectly.

If I take the @"D:\\Temp\\" + section out of the code, where I would expect it to write to the Innovator\Server\Temp folder (I'm guessing on this), I get an Object: Object error.

Can I remove the file from the path that it is check in from?  Is this the problem that Aras is creating a link to the path from which it is being checked in from and when that file is deleted, it is causing all kinds of problems?  I would think that I would be able to just view it seeing that it has actually been created in the vault.  Is there somewhere that I can check to see the physical vault location property of the file when it is checked in?

TIA for the help!!!

Parents
  • Hi Mark,

    To the best of my knowledge, Aras Innovator does not create a link between the original file and File item. It merely creates a copy in the physical vault location specified in your VaultServerConfig.xml.

    I tried replicating your code in an 11.0 SP15 instance I have installed on my machine, but I was able to view the File without issue even with the code that deletes the file running properly. Could you let us know what the approximate size of this pdf that you're uploading is? Could you also let us know what version of Aras Innovator you are using? If you don't know what version you are using, you can check by selecting Help > About on the main menu when you log in.

    To answer your last question, you can view the physical File after it's been created in the vault by first navigating to your physical Vault folder. You can find this information in the VaultServerConfig.xml at the root of your Aras Innovator installation. By default the physical Vault will be at C:\Aras\Vault\. Once there you should see a folder corresponding with the name of the database you are using, e.g. InnovatorSolutions.

    From here, the rest of the path to the physical file will be determined by the ID of the File item within Aras Innovator. The first folder will correspond with the first character of the File's ID. The name of the second folder will be the first and second characters of the File's ID. The last folder will be the rest of the File's ID. For example, the path to the file "Test.pdf" with ID 0D71DA1CE0B24EE690802BAF977D3216 stored in the database InnovatorSolutions would be: C:\Aras\Vault\InnovatorSolutions\0\D7\1DA1CE0B24EE690802BAF977D3216\Test.pdf

    Chris

    Christopher Gillis

    Aras Labs Software Engineer

  • Chris

    Thanks for the answer.  I am using 11SP10.  The size of the PDF can vary between 500K to 1.50Mb - the one that I was loading in my example was 1.37Mb.

    I located the file in the physical vault and am able to view it fine through File Explorer.  The problem comes when using the application.  If the source file is there (as in D:\Temp), then there are no issues.  However when I rename the file, that is when I get the issue.  I have tried this both on IE 11 and Chrome and it gives the issue.  I'm not sure if this also might be related to my PDF software which is Foxit, but I have completely deleted and re-installed it and I still have the same issue.

    Thanks for your help

    Mark

  • Hi Mark,

    I set up a similar test in an 11.0 SP10 instance I had installed locally with a larger PDF file matching the size range you are using, and I still wasn't able to reproduce the issue. To the best of my knowledge, the checkedout_path property on the File item primarily exists now for legacy purposes, so I'm not sure that it would be causing the crashing behavior that you're seeing.

    I'd recommend checking out the system logs that happen directly before the crash in the Windows Event Viewer to see if that gives you an idea of what's causing the crash. If that doesn't yield any results, you can contact Aras Support. They might have seen this behavior before, and they can also help to check your Windows and browser settings to see if there's anything that might be causing this.

    Chris

  • Chris - thanks for testing it in your environment.  I looked in the Event Viewer (actually cleared it out totally and then recreated the problem) and there is nothing in there.  The only thing I can look at is the minidump files from the operating system and I see the following:

    PAGE_FAULT_IN_NONPAGED_AREA 0x00000050 ffffb501`2365f000 00000000`00000000 fffff806`6be628da 00000000`00000000 ntoskrnl.exe

    ntoskrnl.exe+1aa0a0

    In researching the 0x000000050 code, it is almost like a catch all error - it can be anything from software to hardware and anything else in between.  Back to the drawing board unfortunately, but I will also email Aras Support to see if they have come across anything similar.

    Mark

Reply
  • Chris - thanks for testing it in your environment.  I looked in the Event Viewer (actually cleared it out totally and then recreated the problem) and there is nothing in there.  The only thing I can look at is the minidump files from the operating system and I see the following:

    PAGE_FAULT_IN_NONPAGED_AREA 0x00000050 ffffb501`2365f000 00000000`00000000 fffff806`6be628da 00000000`00000000 ntoskrnl.exe

    ntoskrnl.exe+1aa0a0

    In researching the 0x000000050 code, it is almost like a catch all error - it can be anything from software to hardware and anything else in between.  Back to the drawing board unfortunately, but I will also email Aras Support to see if they have come across anything similar.

    Mark

Children