Why are my new file contents not read?!

Hi,
I have a web application with a StartupServlet. In this Servlet my web application is initialised by reading out a file (init.xml) from disk. When the app server has been started and I modified the contents of the init.xml and reload the StartupServlet the new contents are not read. Only the old file contents are visible at the StartupServlet... The init.xml file is read using the ClassLoader.getResouceAsStream();
Could someone please explain to me why the old file contents are read and not the new file contents???
dee3lmo

Notice that by simply accessing your servlet again, your servlet won't be reloaded!
Please read the resource from your servlet using the ServletContext, as follows:
getServletContext().getResourceAsStream("init.xml");
instead of using the servlet's classloader.
This will ensure that you will always read the most recent version of the resource, without having
to reload your servlet.
Hope this helps.

Similar Messages

  • Why is my new Macbook pro not reading my iphone 3GS device but my Windows desktop does not seem to have this problem?

    Whenever I plug my iphone 3GS into my windows PC I have no problem syncing and backing up my apps etc but whenever I plug it into my new macbook pro, it simply cannot read my device at all and everything is fully updated. Help please. Thank you

    I cannot recall the DVD player ever being a place to "store" videos - it is simply an app to play videos.
    If your machine is new, then iMovie should be included as the "shrunk" version of iLife is included with Lion (iMovie, Garageband, and iPhoto). However, iMovie is not a place to store videos either - it is a video editor. You import your clips and edit them in order to then burn to a DVD or share via a social media site.
    Have you considered simply dragging the clips to your folder "Movies"? That would be a great place to just store them (please be aware that videos are usually large files, so keep your hard drive space in mind so you keep a minimum free and available for the OS to operate properly):

  • Why does the new operating system not delete the moved files from their original location - it seems like an enormous waste of space, time and effort to clean up every file once you've moved it

    Why does the new operating system not delete the moved files from their original locations - it seems like an enormous waste of space, time and effort to clean up every file once you've moved it - also, when transferring large amounts of files it becomes a very large problem remembering which files were transferred and which not.

    You're going to need to be more specific, as I'm not quite sure I understand what you're talking about.
    If you're referring to copying from an external hard drive or flash drive, and you want to actually move files rather than copy them, you can hold down the option key to force it to do a "move" rather than a "copy." This is not new behavior, though... the Mac OS has worked this way as long as I can recall (and I've been using it since 1984).
    If you're having a problem with trying to move files from one place to another on a single drive causing them to be copied instead, that is likely because of some permissions issue preventing you from actually being able to move them.

  • Why are my exported files not going to me email?  I have used 3 different ones.

    Why are my exported files not going to my email (receipts & business card)?  I have used 3 different ones...2 yahoo and 1 hotmail.  I have checked spam box also.

    For the Receipts app I chose to export the info as a PDF file..an email was requested..I entered info and clicked send.  For the Business Card app I chose Send, not Print..an email was requested..I entered info and clicked send.  I haven't received anything, not even in my spam folder.

  • Why are some of my songs not in order in my albums?

    I was wondering why are some of my songs not in order in my albums? This wasn't a problem when I first used i-tunes, but I had to download a newer version of i-tunes to get my sister's ipod to work.  For Example my album "AC DC Live" has track #3 Back in Black as the first song listed.  How can this be fixed?

    Hello igho234,
    Thank you for contacting Apple Support Communities. You don't mention how those songs got onto your playlist, but this article may address your issue, if they were imported from a third-party application or CD.
    iOS: Songs or other audio content are skipped during playback
    http://support.apple.com/kb/TS3159
    Regards,
    Jeff D.

  • Why are most of my keywords not included when I export images?

    Why are most of my keywords not included when I export images?
    Since starting with Lightroom 1, I've entered keywords into either of the two fields between "keyword tags" and "keyword suggestions" in the keywording panel.  I was unaware that some keywords are more equal than others, or that Lightroom offered (or has added?) hierarchy support.
    I recently stumbled into the news (to me) that Lightroom tags can be organized into a hierarchy, so I exported my keywords to a text file to examine.  I hadn't unwittingly created any hierarchies, but an astounding fraction of the keywords were within square brackets.  Sure enough, if I export an image, keywords within square brackets are omitted from the output (jpeg) file.  How nice.  Since I began with Lightroom 1, I've added nearly 1600 keywords.. Too bad most of them are coded wrong... so as not to accompany output that I create.
    1.     What was I supposed to do, as a photographer beginning to use Lightroom, to enter keywords simply but reliably:  what I type is what I get? I'd expected that's what the "just type here" interface would provide.
    I especially dislike obtaining erratic results:  most keywords are in square brackets, but a few are not.  Of course, when I use a simplified interface, I should expect not to have access to some of the options or features.  However, I shouldn't inadvertently trigger undocumented behavior.
    2.     Does the Adobe reference help system say how to enter keywords simply and reliably, in its documentation of the keywording panel? I don't find my answer under the Keywords topic, within Home / Using Photoshop Lightroom 3 / Organizing photos in the catalog.
    (I NOW realize that the instructions for the "Create/Edit keyword tags" dialog mention exporting. However, that's not the method I was using.)
    Dick Rawson

    I'm afraid that I distracted you with my background mention of hierarcharial keywords; I'm not asking about them.
    I've entered keywords for several years of using Lightroom.  Suddenly, this week, I find that most (yet not all) of them have the attribute of "don't include the keyword in an exported file's metadata."  I never intended to ask for that; I thought all keywords will stay with the file and its offspring, and that's what I wanted.
    So I'm asking:
    1.     What did I do "wrong" to induce Lightroom to give the keywords that attribute? I never intended to ask it to.
    2.     Where does Adobe document how to enter keywords reliably so that they stay with the file on output?  I can't find that Adobe does.
    > Can you be more clear about keywords in square brackets? I know when you export the keywords as a list you can get a normalized data file that uses punctuation and tabs as delimiters...
    I did export the keywords into such a list:  most keywords in the plain-text list have square brackets surrounding them, indicating keywords that will be omitted from metadata of any image that Lightroom exports.
    My concern is not that the brackets are there.  They encode the attribute of "don't include the keyword in an exported file's metadata," and recognizing that attribute concerns me.
    > ...but I've never seen keywords in image files or in the interface rendered so.
    I haven't, either.
    Dick Rawson

  • Why are previews in Bridge blurry (not rendering properly)?

    Why are previews in Bridge blurry (not rendering properly)?
    I found a simple answer to this question: control click on the thumbnail and select "purge cache for selection"
    After years of intermittently having this problem, this solved the issue. I had just finished a fresh install of main sys hd (new hd) and first time opening bridge encountered this issue again after not having the problem for a few years.
    Hope this helps others.  

    Why are previews in Bridge blurry (not rendering properly)?
    I found a simple answer to this question: control click on the thumbnail and select "purge cache for selection"
    After years of intermittently having this problem, this solved the issue. I had just finished a fresh install of main sys hd (new hd) and first time opening bridge encountered this issue again after not having the problem for a few years.
    Hope this helps others.  

  • After syncing my music onto my iphone5, why are songs grayed out and not playable

    after syncing my music onto my iphone5, why are songs grayed out and not playable?

    If you are syncing music to the iPhone automatically, you won't be able to drag and drop tracks on to the iPhone and the music will be grayed out.
    You'll have to Manually Manage the music.
    Configure iPhone, iPad, or iPod for manual management
    If you have iTunes 7 or later*, follow these instructions:
    Connect the device to your computer.
    Open iTunes.
    Select iPhone, iPad, or iPod in the Devices list.
    Click the Summary tab and select "Manually manage music and videos".
    Click Apply.
    Even when you have enabled manual management, you can still sync some content automatically. Select any content tab, such as Video, to enable automatic syncing for that type of content.

  • Why are my new music downloads going to icloud?

    Why are my new music downloads going to icloud? I never set it up and dont use it. I just recently purchased a few songs and when I hooked up to the computer is says I have to download them AGAIN to my computer from icloud. Why did this happen? My husband and I share a computer and both have our own id. I couldnt figure out why iTunes was telling me to do this and found out my husbands id was in my iPod.

    On your phone, how many of your contacts are in the On My Phone group, or any other group that is not iCloud, and how many are in the iCloud group (382?)
    Why are my contacts not backing up to iCloud?
    Not the same thing, don't confuse a backup of your phone with an iCloud data account. Backup is a separate function.

  • Why are some 100% Accurate Rips not matched by iTunes Match?

    Why are some 100% Accurate Rips not matched by iTunes Match?
    Is there an Apple Support employee that can address this question?
    The phenomenom occurs for over 500 of my tracks spread out among 100+ albums.
    Certain tracks simply do not match to the iTunes library, despite being 100% Accurate bit-for-bit Rips. For reference, I use dBpoweramp for ripping, which checks CRC.
    As an example, take Aerosmith's "Get a Grip" album; Tracks 2 and 5 will not Match to iTunes, despite perfect integrity in the ripping process.
    Upon looking further into those particular tracks, I notice a discrepency between the "track length" reported on the iTunes store page, and my accurate rips for those tracks [track 2 & 5 on iTunes: 4:09 & 6:19, respectively; track 2 & 5 direct accurate rip from physical CD: 4:10 & 6:07, respectively].
    So clearly, with track 5, there is a major discrepency, 12 seconds difference, which leads me to think the iTunes release of this album and retail release of the CD I physically own are quite different.
    Well there, I guess I've solved the "reason" for the undesired functionality, but it certainly doesn't solve the issue at hand.
    A major aspect of the iTunes Match product is To Match, so that, in part, bit-rate upgrades can take place, and also to provide management and format uniformity.  I do realize that there is no guarantee iTunes has every album one could own, and entirely un-matched, and thereby Uploaded, Albums are a significant upside feature of iTunes Match; however, 1+ tracks on each of a significant quantity of albums, which iTunes carries, not matching to iTunes creates heterogeneous-format albums, and significantly more library management.
    If there is a workaround for this issue it would significantly improve the user experience for iTunes Match.  A user shouldn't have many hetereogeneous-format albums when iTunes carries/sells those albums, and the user has perfect quality rips from their physical CD.

    https://discussions.apple.com/community/itunes/search.jspa?peopleEnabled=true&us erID=&containerType=14&container=2882&spotlight=false&q=why%20are%20some%20songs %20on%20an%20album%20not%20matched%3F%20*

  • Why is the new Safari (7) not letting sound be heard from Soundcloud widgets (players) on my website when the earlier Safari worked fine, and other browsers also work fine?

    Why is the new Safari (7) not letting sound be heard from Soundcloud widgets (players) on my website when the earlier Safari worked fine, and other browsers also work fine?

    Might be an incompatible extension or plugin ...
    Try troubleshooting Safari extensions and third party plugins.
    From the Safari menu bar click Safari > Preferences then select the Extensions tab. Turn that OFF, quit and relaunch Safari to test. If that helped, turn one extension on then quit and relaunch Safari to test until you find the incompatible extension then click uninstall.
    If it's not an extensions issue, try troubleshooting third party plug-ins.
    Back to Safari > Preferences. This time select the Security tab. Deselect:  Allow all other plug-ins. Quit and relaunch Safari to test.
    If that made a difference, instructions for troubleshooting plugins here.

  • Why are calls from my favorites not ringing when my phone is silenced at night?

    Why are calls from my favorites not ringing when my phone is silenced at night?

    You Might Have scheduled do not diturb... Turn Of Scheduled button in settings>do not disturb>scheduled..

  • Why are ACR PSD files 10-20 percent larger than the same file resaved in PSD?

    Why are ACR > PSD files 10-20 percent larger than the same file resaved in PSD? I posted this many years ago and never found an answer. Now that my drives fill up quicker, I thought I might chase this question a little bit further.
    Same .CR2 saved within ACR either with cmd-R or open ACR within PSD, the saved file is 34.5mb. Resave that same file (no edits) within PSD either with or without Max-compatible and the file is now 30.7mb. Another file that is 24.5 becomes 19.5MB.
    Why the difference? Is ACR and PSD actually using different compression strategies?
    thanks.
    Mac 10.8.5 / CC / ACR 8.4.1 - but this has been a consistent behavior over many years and versions, CS6 / CC.
    Same .CR2 saved within ACR either with cmd-R or open ACR within PSD, the saved file is 34.5mb. Resave that same file (no edits) within PSD either with or without Max-compatible and the file is now 30.7mb. Another file that is 24.5 becomes 19.5MB.

    Hi Jeff
    If it is RLE it's not as efficient as LZW:
    Saved ACR>PSD = 40.1MB  (sample image this AM)
    opened in PS and resaved as PSD = 30.8MB
    resaved as TIF without LZW = 40.1MB    (this adds to your thought that the ACR>PSD doesn't us any compression)
    resaved as TIF/LZW = 9.6MB
    Jeff Schewe wrote:
    I really think your priorities are a bit off. 10-20% is meaningless...you just need to get bigger....  and quit fussing over a few GB's here or there...
    ???   I hope that the Adobe engineers are fussing over 10-20% efficiencies.
    I'm within arms reach to a rack of 40TB of drives (doesn't include off-site drives), and all 2TB drives are being recycled to 4TB drives, as a result the rack is always growing. Actually the ACR>PSD files don't really make a difference in our long term storage, only for the nightly backups. But anyway, how you save, what you save etc. should all be part of the discussion.
    .... so in my case, throw in an excess MB here and there and all of a sudden you are talking TB's. Plus advantages in backup times, drive life, and energy use.
    Somebody added compression into the PS>PSD format, but it wasn't included in the ACR>PSD format, was it a decision or an oversight? If it's just a matter of making ACR compatible with PS when saving the same PSD format..... then why not?
    regards,
    j

  • Why is the new CC Library not included in Indesign ?

    Hello,
    Why is the new CC Library not included in InDesign ?
    It works great between Photoshop and Illustrator but now I really miss this feature in Indesign.

    Don't know why, but CC Library is a totally different thing compared with InDesign's own library format stored in *.indl files. So I suggest, that you'll make a feature request here:
    Adobe - Feature Request/Bug Report Form
    Hope, that it will work again today. Heard, some users had problems with the bug report form yesterday…
    (For the "why": Sometimes the developer teams of the individual CC products do not talk to each other that much, I think.)
    Uwe

  • New File() is not working on MAC

    Hi,
    I don't know exactly what is the problem,since i search in forums.
    but in my code
    File f = new File("/Users/sky/Desktop/dist/test.txt");
    is not working on Mac os.
    Please help !

    skymania wrote:
    On window it will give output : success
    On Mac it will give nothing.
    On window and mac both file is not exist (physically). Bull.
    Simply doing new File(...) does NOT create a file on disk, no matter what the OS.
    On Windows, before running the Java code:
    C:\>dir C:\CONFIG.SYS
    02/05/2008  01:06 PM                 0 CONFIG.SYS
    C:\>dir C:\zzzzz
    File Not FoundThen I run this Java:
    package scratch;
    import java.io.File;
    * Copyright (c) 2009 Tone Software Corporation
    * @author Jeff Verdegan
    public class NewFileDoesNotCreateAFileOnDisk {
      public static void main (String[] args) throws Exception{
        File f1 = new File("C:/CONFIG.SYS");
        File f2 = new File("C:/zzzzz");
        System.out.println(f1.getCanonicalPath () + ".exists() is " + f1.exists ());
        System.out.println(f2.getCanonicalPath () + ".exists() is " + f2.exists ());
    }and I get this result:
    C:\CONFIG.SYS.exists() is true
    C:\zzzzz.exists() is falseAnd then I do the dir again, and I get the same results.
    Thus proving that new File does NOT create a file on the disk.
    If you would bother to read the docs for the File class like I suggested, you'll see a way that you can create a file on disk.
    And if you read my other comments, you'll see how to create a file as you write to it.

Maybe you are looking for