This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 196238 - Importing of the remote project breaks the original project
Summary: Importing of the remote project breaks the original project
Status: RESOLVED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Remote (show other bugs)
Version: 7.0
Hardware: PC Linux
: P2 normal (vote)
Assignee: Vladimir Kvashin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-03 15:26 UTC by Alexander Pepin
Modified: 2011-03-08 05:48 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Pepin 2011-03-03 15:26:41 UTC
Prerequisite - create a makefile based project on some Solaris host using OSS express tool collection

Steps to reproduce:
- add the remote host (only GNU is found)
- import the project
- try to build the project
Result: build fails as CC was not found. In fact tools defined in the project should be used instead of setting a new tool collection. The system includes for the project are also taken from GNU.

Moreover the original project is broken as now it uses development host <host_name> instead of "localhost" and that <host_name> host is not configured.
Comment 1 Vladimir Kvashin 2011-03-03 15:39:03 UTC
I can't reproduce the situation with "localhost". I know for sure that there was such an error a while ago, but it was fixed before merging synchronizing code back to NB.
Comment 2 Vladimir Kvashin 2011-03-03 17:25:53 UTC
Changing remote project development host reason is understood. I believe that's because of exceptions described in issue 196234 (which is fixed, but other exceptions might occur; so I'm now working on a safer way of synchronizing to remote host)
Comment 3 Vladimir Kvashin 2011-03-03 18:08:22 UTC
Partial fix - more reliable way of sync
http://hg.netbeans.org/cnd-main/rev/160249f4ee8a

Tool collection issue still presents.
Comment 4 Leonid Lenyashin 2011-03-04 00:38:08 UTC
(In reply to comment #2)
>I'm now working on a safer way of synchronizing to
> remote host

Yes, please! I hope you are syncing to a copy, verify it is good and then quickly substitute the original with a copy, aren't you?
Comment 5 Quality Engineering 2011-03-04 05:43:50 UTC
Integrated into 'main-golden', will be available in build *201103040000* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/160249f4ee8a
User: Vladimir Kvashin <vkvashin@netbeans.org>
Log: more reliable full remote project meta-data sync (fixing  #196238 - Importing of the remote project breaks the original project)
Comment 6 Vladimir Kvashin 2011-03-04 08:16:16 UTC
(In reply to comment #4)
> I hope you are syncing to a copy, verify it is good and then
> quickly substitute the original with a copy, aren't you?
That's what I do now; but I copy file by file to the original place, so if connect is broken in process we have the original project broken as well. The best way is to deliver all changes to a temporary place on remote host and then to quickly substitute original files, I believe.
Comment 7 Vladimir Kvashin 2011-03-04 14:48:28 UTC
After the following fix 
http://hg.netbeans.org/cnd-main/rev/5857f074d7e5
remote project isn't spoiled any more, I believe

However changes described in Comment #6 still should be done, so I'm not closing the issue, just downgrading to P2.
Comment 8 Alexander Pepin 2011-03-04 16:05:08 UTC
see also bug #196302
Comment 9 Alexander Pepin 2011-03-04 16:09:29 UTC
In addition to comment #8

Source files logical folder in the original project disappears from Project as well (after changing tool collection in the shadow project).
Comment 10 Quality Engineering 2011-03-05 05:45:02 UTC
Integrated into 'main-golden', will be available in build *201103050000* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/5857f074d7e5
User: Vladimir Kvashin <vkvashin@netbeans.org>
Log: when synchronizing to the remote project, leave tools collection (fixing #196238 - Importing of the remote project breaks the original project)
Comment 11 Quality Engineering 2011-03-07 05:36:44 UTC
Integrated into 'main-golden', will be available in build *201103070000* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/f9be6c21ce86
User: Vladimir Kvashin <vkvashin@netbeans.org>
Log: don't allow to save the same project in parallel (fixing #196300 FileNotFoundException, #196238 Importing of the remote project breaks the original project )
Comment 12 Leonid Lenyashin 2011-03-07 11:31:51 UTC
(In reply to comment #6)
> (In reply to comment #4)
> > I hope you are syncing to a copy, verify it is good and then
> > quickly substitute the original with a copy, aren't you?
> That's what I do now; but I copy file by file to the original place, so if
> connect is broken in process we have the original project broken as well. The
> best way is to deliver all changes to a temporary place on remote host and then
> to quickly substitute original files, I believe.
That is what I meant in my question.
Comment 13 Vladimir Kvashin 2011-03-07 16:32:26 UTC
(In reply to comment #12)

This is already done.

The only thing to do here is to eliminate unnecessary synchronization at all: project system saves project metadata quite often, even if it is not changed; so I now make a local diff and send data to remote only it really differs - this is done, but not pushed yet, I'm testing and fixing this right now.
Comment 14 Vladimir Kvashin 2011-03-07 18:44:40 UTC
(In reply to comment #13)
This is done:
http://hg.netbeans.org/cnd-main/rev/67fc498889ab
Comment 15 Quality Engineering 2011-03-08 05:48:07 UTC
Integrated into 'main-golden', will be available in build *201103080000* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/67fc498889ab
User: Vladimir Kvashin <vkvashin@netbeans.org>
Log: full remote: don't upload project meta data if it has not been changed (fixing #196238 Importing of the remote project breaks the original project)