Solved

Using Railo trying to save to a file but I get the error that it is locked

Posted on 2014-11-16
4
254 Views
Last Modified: 2014-11-23
I have some code that updates a CSS file that my app is using . Using Coldfusion as my server I am able to write to the file. I also need by site to work with Railo but when I try to do the same thing I get the error:

C:\Railo\ver_421\webapps\ROOT\css\dynamic_styles.css (The requested operation cannot be performed on a file with a user-mapped section open)

I am writing to the file by doing the following:
<cffile action="write" file="#StylePath#dynamic_styles.css" output="#StyleText#" >
0
Comment
Question by:WestCoast_BC
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 52

Expert Comment

by:_agx_
ID: 40446479
(no points... I don't have a definitive answer)

A quick search suggests it *might* be a java bug on windows. I'd suggest asking on the Railo list. The guys that wrote it would know if it's a java issue and if there's a work around.
0
 

Accepted Solution

by:
WestCoast_BC earned 0 total points
ID: 40451682
I solved this by doing the following:

I set useFileMappedBuffer to false in my <jetty>/etc/webdefault.xml file.
0
 
LVL 52

Expert Comment

by:_agx_
ID: 40453340
Ah, so it is a MappedByteBuffer issue. Good to know.  Thanks for posting the answer!
0
 

Author Closing Comment

by:WestCoast_BC
ID: 40460456
This solved my problem
0

Featured Post

 Watch the Recording: Learning MySQL 5.7

MySQL 5.7 has a lot of new features. If you've dabbled with an older version of MySQL, it is definitely worth learning.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When setting up new project requests for our site, one of the most powerful tools our team has available to use is Axure (http://www.axure.com/). It’s a tool for creating software and web prototypes that can function and interact as if it were the a…
Meet the world's only “Transparent Cloud™” from Superb Internet Corporation. Now, you can experience firsthand a cloud platform that consistently outperforms Amazon Web Services (AWS), IBM’s Softlayer, and Microsoft’s Azure when it comes to CPU and …
The purpose of this video is to demonstrate how to integrate Mailchimp with Facebook. This will be demonstrated using a Windows 8 PC. Mailchimp and Facebook will be used. Log into your Mailchimp account. : Click on your name. Go to Account Setti…
The purpose of this video is to demonstrate how to prevent comment spam on a WordPress Website. This will be demonstrated using a Windows 8 PC. Plugin Akismet will be used. Go to your WordPress login page. This will look like the following: myw…

635 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question