Return-Path: X-Original-To: apmail-camel-users-archive@www.apache.org Delivered-To: apmail-camel-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 51F51173B8 for ; Thu, 25 Sep 2014 19:14:54 +0000 (UTC) Received: (qmail 45719 invoked by uid 500); 25 Sep 2014 19:14:53 -0000 Delivered-To: apmail-camel-users-archive@camel.apache.org Received: (qmail 45662 invoked by uid 500); 25 Sep 2014 19:14:53 -0000 Mailing-List: contact users-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@camel.apache.org Delivered-To: mailing list users@camel.apache.org Received: (qmail 45650 invoked by uid 99); 25 Sep 2014 19:14:53 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 25 Sep 2014 19:14:53 +0000 X-ASF-Spam-Status: No, hits=2.3 required=5.0 tests=SPF_SOFTFAIL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: softfail (athena.apache.org: transitioning domain of sc.e.dawson@gmail.com does not designate 216.139.236.26 as permitted sender) Received: from [216.139.236.26] (HELO sam.nabble.com) (216.139.236.26) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 25 Sep 2014 19:14:49 +0000 Received: from [192.168.236.26] (helo=sam.nabble.com) by sam.nabble.com with esmtp (Exim 4.72) (envelope-from ) id 1XXEUm-0001nT-2r for users@camel.apache.org; Thu, 25 Sep 2014 12:14:28 -0700 Date: Thu, 25 Sep 2014 12:14:28 -0700 (PDT) From: scottdawson To: users@camel.apache.org Message-ID: <1411672468051-5757022.post@n5.nabble.com> In-Reply-To: References: Subject: Re: Corrupt pdf from classpath MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Hello, I wrote a component based on the code shown here: http://code.notsoclever.cc/writing-camel-component-camel-static-resource/ to deliver static files, mostly PNG files in my case but I see no reason why it won't work for PDFs. The first code sample in the article gives everything needed to deliver static files and it detects the type of the file to set the HTTP Content-Type header correctly. Regards, Scott -- View this message in context: http://camel.465427.n5.nabble.com/Corrupt-pdf-from-classpath-tp5756921p5757022.html Sent from the Camel - Users mailing list archive at Nabble.com.