[JBoss JIRA] (JBIDE-11170) Forge: resource is not picked-up after creation on windows
by Pavol Srna (JIRA)
Pavol Srna created JBIDE-11170:
----------------------------------
Summary: Forge: resource is not picked-up after creation on windows
Key: JBIDE-11170
URL: https://issues.jboss.org/browse/JBIDE-11170
Project: Tools (JBoss Tools)
Issue Type: Bug
Components: forge
Affects Versions: 3.3.0.Beta1
Environment: jbdevstudio-product-universal-5.0.0.v201203010100M-H88-Beta1, winXP
Reporter: Pavol Srna
Assignee: Koen Aers
Priority: Critical
Fix For: 3.3.0.Beta1
Path, or quotation marks issues?
Forge console output:
[test] test $ entity --named customer
? In which package you'd like to create this @Entity, or enter for default [com.test.model]
Created @Entity [com.test.model.customer]
***INFO*** The command [pick-up] takes [1] unnamed argument(s), but found [2].
***INFO*** Swallowed unknown token [and] for command [pick-up].
***INFO*** Swallowed unknown token [Settings/Pali/workspace/test/src/main/java/com/test/model/customer.java] for command [pick-up].
Picked up type <UnknownFileResource>: Documents
Wrote C:\/Documents and Settings/Pali/workspace/test/src/main/java/com/test/model/customer.java
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months
[JBoss JIRA] (JBIDE-10903) Deploy folder sometimes not added to JBoss deployment path list
by Daniel Atallah (JIRA)
Daniel Atallah created JBIDE-10903:
--------------------------------------
Summary: Deploy folder sometimes not added to JBoss deployment path list
Key: JBIDE-10903
URL: https://issues.jboss.org/browse/JBIDE-10903
Project: Tools (JBoss Tools)
Issue Type: Bug
Components: JBossAS/Servers
Affects Versions: 3.3.0.M5
Environment: Windows 7 / Eclipse Indigo SR1 / JBoss 4.2.3
Reporter: Daniel Atallah
Assignee: Rob Stryker
A number of people in my team have run into intermittent issues where when the Server is started, the deploy folder that is specified in the Server "Deployment" tab doesn't seem to ever get added to the list of locations that JBoss looks for stuff to deploy.
We're using a custom deploy folder (it's an ordinary directory on a local drive).
The normal course of operations is that JBoss starts up successfully and outputs the following line:
{noformat}19:41:06,117 INFO [Server] JBoss (MX MicroKernel) [4.2.3.GA (build: SVNTag=JBoss_4_2_3_GA date=200807181417)] Started in 15s:550ms{noformat}
Then, if things work successfully, a few seconds later the following output appears and my EAR is deployed (my custom deploy folder is "C:/export/spare/Devl-JBoss/development/dev/deploy"):
{noformat}19:41:14,948 INFO [EARDeployer] Init J2EE application: file:/C:/export/spare/Devl-JBoss/development/dev/deploy/Foo.ear/{noformat}
If things don't work successfully, the second line never appears and the server just sits there without any of the deployed resources being available.
Not being familiar with how the JBoss Tools integration works, it looks to me that JBoss Tools is somehow waiting for the Server to start up fully before adding the deploy folder and in the cases where it doesn't work, it never notices that the Server has started up so it never adds the deploy folder.
I've tried setting the server logging to TRACE level and when it isn't working, the custom deploy folder doesn't appear anywhere in the log output.
This issue is intermittent, I haven't been able to identify any specific scenarios under which it is triggered.
When it does happen, sometimes restarting the server will resolve it, but other times we need to do a "Clean" publish to the server, and sometimes even that will not fix the issue (more than once deleted my workspace .metadata and started clean to get it working).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months
[JBoss JIRA] (JBIDE-10232) exploded deploy does not work on windows because of use of File#renameTo
by Jim Sellers (Created) (JIRA)
exploded deploy does not work on windows because of use of File#renameTo
------------------------------------------------------------------------
Key: JBIDE-10232
URL: https://issues.jboss.org/browse/JBIDE-10232
Project: Tools (JBoss Tools)
Issue Type: Bug
Components: JBossAS/Servers
Environment: JBossAS Tools: Version: 2.3.0.v20111104-1515-H45-M4
Java version: 1.5.0_22, vendor: Sun Microsystems Inc.
Java home: C:\devtools\java\jdk1.5.0_22\jre
Default locale: en_CA, platform encoding: Cp1252
OS name: "windows xp", version: "5.1", arch: "x86", family: "windows"
Reporter: Jim Sellers
Assignee: Rob Stryker
Setup: in a project on windows with an ear / war / jar in an exploded format and having started the server in debug mode. If you make any changes to a file in the jar, the jar will be rebuilt and try to be deployed. This seems to work but it pops up an error dialog box *every time*. The error message looks like the following:
{code}
Error renaming C:\devtools\jboss\jboss-4.2.3.GA\server\default\tmp\jbosstoolsTemp\tmp2587902707203199490.jar to C:\devtools\jboss\jboss-4.2.3.GA\server\default\deploy\MyExampleEAR.ear\MyExampleWAR.war\WEB-INF\lib\MyDependantJar-2.3-SNAPSHOT.jar.
This may be caused by your server's temporary deploy directory being on a different filesystem than the final destination.
You may adjust these settings in the server editor.
{code}
For the method org.jboss.ide.eclipse.as.core.server.xpl.PublishCopyUtil#safeRename(File,File,int) it calls File#renameTo(File) for moving the file from the temp directory to WEB-INF/lib. From the javadocs for renameTo it says that this might not work if the file in the destination already exists.
Possible fixes:
# before calling the rename, try to delete on the destination file ( to.delete() )
# org.apache.commons.io.FileUtils#moveFile(File,File) tries to call the renameTo and if that fails it falls back to coping the file to the destination.
{code:JAVA|title=Sample Unit test}
/* This test needs to be run on windows. */
@Test
public void testCopyForWindows() throws IOException {
File from = File.createTempFile("source", ".txt");
File to = File.createTempFile("target", ".txt");
File[] files = {from, to};
for (File file : files) {
// set for cleanup
file.deleteOnExit();
assertTrue("file should exist" + file.getAbsolutePath(), file.exists());
assertTrue("file should be writable" + file.getAbsolutePath(), file.canWrite());
}
// if safeRename was not private!
assertTrue("should have been able to rename the file", safeRename(from, to, 10));
}
{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months
[JBoss JIRA] (JBIDE-10218) Run button in toolbar needs to run the newly generated project
by Burr Sutter (Created) (JIRA)
Run button in toolbar needs to run the newly generated project
--------------------------------------------------------------
Key: JBIDE-10218
URL: https://issues.jboss.org/browse/JBIDE-10218
Project: Tools (JBoss Tools)
Issue Type: Bug
Reporter: Burr Sutter
The Run icon in the Eclipse toolbar is where a new developer (new to JBoss Tools) expects to go directly after he has generated a new project from either File-New or JBoss Central by using one of the archetypes or project examples/quickstarts.
This means the generated project needs to be highlighted in the Project Explorer and the Run button should "just work".
There is also an issue with Run vs Debug - if the server is in "debug mode" then Run should just assume that is OK and not prompt the user.
Run on Server should be the default so the user can use a single click on OK
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 11 months