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 247417 - NPE in ODCSRepository:131
Summary: NPE in ODCSRepository:131
Status: RESOLVED FIXED
Alias: None
Product: connecteddeveloper
Classification: Unclassified
Component: ODCS (show other bugs)
Version: 8.0.1
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: Tomas Stupka
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-09-23 17:51 UTC by Tomas Pavek
Modified: 2015-08-20 17:42 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 Tomas Pavek 2014-09-23 17:51:58 UTC
Got this exception reported several times from JDev (NB binaries from 09/15).

java.lang.NullPointerException
  org.netbeans.modules.odcs.tasks.repository.ODCSRepository.<init>(ODCSRepository.java:131)
  org.netbeans.modules.odcs.tasks.ODCSConnector.createODCSRepository(ODCSConnector.java:94)
  org.netbeans.modules.odcs.tasks.ODCSConnector.createRepository(ODCSConnector.java:70)
  org.netbeans.modules.bugtracking.team.TeamRepositories.createRepository(TeamRepositories.java:201)
  org.netbeans.modules.bugtracking.team.TeamRepositories.getRepository(TeamRepositories.java:167)
  org.netbeans.modules.bugtracking.team.TeamRepositories.getRepository(TeamRepositories.java:148)
  org.netbeans.modules.bugtracking.team.TeamRepositories.getRepository(TeamRepositories.java:138)
  org.netbeans.modules.bugtracking.api.Util.getTeamRepository(Util.java:204)
  org.netbeans.modules.odcs.tasks.bridge.QueryAccessorImpl.getRepository(QueryAccessorImpl.java:198)
  org.netbeans.modules.odcs.tasks.bridge.QueryAccessorImpl.getAllIssuesQuery(QueryAccessorImpl.java:78)
  org.netbeans.modules.odcs.ui.dashboard.OdcsProjectNode$6.run(OdcsProjectNode.java:360)
  org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1423)
  org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2033)

No reproducible steps so far. The reporter claims it is not related to a particular project.

Wondering what can be null on the line:
TeamAccessorUtils.getTeamAccessor(project.getFeatureLocation()).addPropertyChangeListener(this, project.getWebLocation().toString());
Comment 1 Tomas Stupka 2014-09-26 15:47:11 UTC
> Wondering what can be null on the line:
> TeamAccessorUtils.getTeamAccessor(project.getFeatureLocation()).addPropertyChangeListener(this, project.getWebLocation().toString());
lets see ... will add some logging and asserts

would be great if we could ping the original reporter to reproduce once it is integrated into jdev
Comment 2 Quality Engineering 2014-09-28 01:57:05 UTC
Integrated into 'main-silver', will be available in build *201409280001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/f810faf4f99f
User: Tomas Stupka <tstupka@netbeans.org>
Log: more logging

Issue #247417 - NPE in ODCSRepository:131
Comment 3 Tomas Pavek 2014-10-01 09:55:49 UTC
Got a log back, it's the TeamAccessor that is missing. The project is valid (on the server), the logged web location as well.
Comment 4 Tomas Pavek 2014-10-03 10:17:12 UTC
Still not able to reproduce reliably, but from the logs received from the reporter it appears that when it happened, the project "feature location" was a http URL while the project "web location" was https. It is possible that the registered server URL also was https and so not matching with the feature location.

Since the listener is attached to the server that should be present in the incoming TeamProject (ODCSProject), I'm wondering why not to simply use the project.getHost(). I've pushed a fix like this. Not sure if it fixes the problem, but perhaps it could be more robust.

http://hg.netbeans.org/core-main/rev/7cafb5c65436
Comment 5 Tomas Stupka 2014-10-03 10:57:36 UTC
thanks
Comment 6 Quality Engineering 2014-10-05 02:04:44 UTC
Integrated into 'main-silver', will be available in build *201410050001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/7cafb5c65436
User: Tomas Pavek <tpavek@netbeans.org>
Log: #247417: use project server host instead of "feature location" to determine server to attach listener to
Comment 7 Quality Engineering 2015-08-20 17:42:07 UTC
Integrated into 'releases/release801', will be available in build *201508201622* or newer. Wait for official and publicly available build.

Changeset: http://hg.netbeans.org/releases/rev/ecf18a79406e
User: Tomas Stupka <tstupka@netbeans.org>
Log: #247417: use project server host instead of "feature location" to determine server to attach listener to