• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Problem with Amazon S3 today - Using FileWrite() CF9.0.2

New Here ,
Apr 03, 2013 Apr 03, 2013

Copy link to clipboard

Copied

We use Amazon S3 for storing the majority of our products and the code is well established and has been working hundreds of times a day for well over 8 months, so it's very stable however today I've had loads and loads of problems with errors - Is anyone else seeing issues?

The code is very simple:

<cfset fileWrite("#baseS3Url#/#amazonFileName#", "#binFileData#")>

<cfset storeSetMetadata("#baseS3Url#/#amazonFileName#", { content_type="#setContentType(XML)#" })>

OR

<cfset fileWrite("#baseS3Url#/#amazonFileName##fileExtension#", "#binFileData#")>

<cfset storeSetMetadata("#baseS3Url#/#amazonFileName##fileExtension#", { content_type="#setContentType(fileExtension)#" })>

but is throwing the following stack trace

StackTrace: coldfusion.vfs.VFileOutputStream$VFSFileSystemException: Request Error. nullCould not close the output stream for file "s3://<cname>/0/0/1/1/3/4/5/1134503_SRBDG7FY8U.pdf"..

    at coldfusion.vfs.VFileOutputStream.close(VFileOutputStream.java:81)

    at coldfusion.tagext.io.FileUtils.writeFile(FileUtils.java:867)

    at coldfusion.runtime.CFPage.FileWrite(CFPage.java:2918)

    at coldfusion.runtime.CFPage.FileWrite(CFPage.java:2909)

    at cfAmazonUtil2ecfc1396299930$funcWRITEFILETOAMAZON.runFunction(F:\CfGlobal\amazonWebServices\AmazonUtil.cfc:160)

    at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)

    at coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:405)

    at coldfusion.runtime.UDFMethod$ArgumentCollectionFilter.invoke(UDFMethod.java:368)

    at coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:55)

    at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)

    at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)

    at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:491)

    at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:337)

    at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2360)

    at cfListenerUtils2ecfc321451058$funcWRITEFILETOAMAZON.runFunction(F:\CfGlobal\util\ListenerUtils.cfc:758)

    at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)

    at coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:405)

    at coldfusion.runtime.UDFMethod$ArgumentCollectionFilter.invoke(UDFMethod.java:368)

    at coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:55)

    at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)

    at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)

    at coldfusion.runtime.CfJspPage._invokeUDF(CfJspPage.java:2582)

    at cfListenerUtils2ecfc321451058$funcWRITEFILETOLOCALPLUSAMAZON.runFunction(F:\CfGlobal\util\ListenerUtils.cfc:812)

    at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)

    at coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:405)

    at coldfusion.runtime.UDFMethod$ArgumentCollectionFilter.invoke(UDFMethod.java:368)

    at coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:55)

    at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)

    at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)

    at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:491)

    at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:337)

    at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2360).....

  

Caused by: org.apache.commons.vfs.FileSystemException: Could not close the output stream for file "s3://documents.etsosreports.co.uk/0/0/1/1/3/4/5/1134503_SRBDG7FY8U.pdf".

    at org.apache.commons.vfs.provider.DefaultFileContent$FileContentOutputStream.close(DefaultFileContent.java:599)

    at coldfusion.vfs.VFileOutputStream.close(VFileOutputStream.java:69)

    ... 52 more

Caused by: java.io.IOException: Request Error. null

    at coldfusion.vfs.s3.S3OutputStream._close(S3OutputStream.java:145)

    at coldfusion.vfs.s3.S3OutputStream.access$000(S3OutputStream.java:46)

    at coldfusion.vfs.s3.S3OutputStream$1.run(S3OutputStream.java:108)

    at java.security.AccessController.doPrivileged(Native Method)

    at coldfusion.vfs.s3.S3OutputStream.close(S3OutputStream.java:103)

    at java.io.FilterOutputStream.close(Unknown Source)

    at org.apache.commons.vfs.util.MonitorOutputStream.close(MonitorOutputStream.java:53)

    at org.apache.commons.vfs.provider.DefaultFileContent$FileContentOutputStream.close(DefaultFileContent.java:595)

    ... 53 more

TagContext: 

    [array]

    1) [struct]

        COLUMN: 0

        ID: CF_CFPAGE

        LINE: 160

        RAW_TRACE: at cfAmazonUtil2ecfc1396299930$funcWRITEFILETOAMAZON.runFunction(F:\CfGlobal\amazonWebServices\AmazonUtil.cfc:160)

        TEMPLATE: F:\CfGlobal\amazonWebServices\AmazonUtil.cfc

        TYPE: CFML

    2) [struct]

        COLUMN: 0

        ID: CF_TEMPLATEPROXY

        LINE: 758

        RAW_TRACE: at cfListenerUtils2ecfc321451058$funcWRITEFILETOAMAZON.runFunction(F:\CfGlobal\util\ListenerUtils.cfc:758)

        TEMPLATE: F:\CfGlobal\util\ListenerUtils.cfc

        TYPE: CFML

    3) [struct]

        COLUMN: 0

        ID: CF_UDFMETHOD

        LINE: 812

        RAW_TRACE: at cfListenerUtils2ecfc321451058$funcWRITEFILETOLOCALPLUSAMAZON.runFunction(F:\CfGlobal\util\ListenerUtils.cfc:812)

        TEMPLATE: F:\CfGlobal\util\ListenerUtils.cfc

        TYPE: CFML

    4) [struct]

        COLUMN: 0

        ID: CF_TEMPLATEPROXY

        LINE: 84

        RAW_TRACE: at cfDeliveryUsersBatch2ecfc1575326645$funcPROCESS.runFunction(F:\web\integration.etsos.co.uk\wwwroot\ScheduledTasks\deliveryUsers\DeliveryUsersBatch.cfc:84)

        TEMPLATE: F:\web\integration.etsos.co.uk\wwwroot\ScheduledTasks\deliveryUsers\DeliveryUsersBatch.cfc

        TYPE: CFML

    5) [struct]

        COLUMN: 0

        ID: CFINVOKE

        LINE: 28

        RAW_TRACE: at cfDeliveryUsers2ecfm1067211157$func_CFFUNCCFTHREAD_CFDELIVERYUSERS2ECFM10672111571.runFunction(F:\web\integration.etsos.co.uk\wwwroot\ScheduledTasks\deliveryUsers\DeliveryUsers.cfm:28)

        TEMPLATE: F:\web\integration.etsos.co.uk\wwwroot\ScheduledTasks\deliveryUsers\DeliveryUsers.cfm

        TYPE: CFML

Type: Application

msg: Request Error. nullCould not close the output stream for file "s3://documents.etsosreports.co.uk/0/0/1/1/3/4/5/1134503_SRBDG7FY8U.pdf".

Views

1.3K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 04, 2013 Apr 04, 2013

Copy link to clipboard

Copied

This is still continuing today - I'm starting to think it has something to do with the 9.0.2 Hotfix patch 1 that was installed this weekend

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 10, 2019 Apr 10, 2019

Copy link to clipboard

Copied

LATEST

Hello Jo, did you ever find an answer to this?  I'm experiencing the same issue.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation