apache / apache/maven-archetype
[ARCHETYPE-539] Maven archetype:generate hangs on retrieval of archetype-catalog.xml even on offline mode
- Dominant language
- Java
- Stars
- 148
- Forks
- 181
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 8
Description
**[Franz Allan Valencia See](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=franz_see)** opened **[ARCHETYPE-539](https://issues.apache.org/jira/browse/ARCHETYPE-539?redirect=false)** and commented
**Steps to reproduce**
1.a Have slow connection
1.b.Alternatively, simulate slow connection with [crapify](https://www.npmjs.com/package/crapify)
1.b.1. Install crapify - `npm install crapify -g`
1.b.2. Run crapify - `crapify --port=5000 --speed=1 start`
1.b.3. Configure `~/.m2/settings.xml` to use crapify
```xml
...
crapify-proxy
true
http
localhost
5000
...
```
2. Execute
```bash
$ mvn archetype:generate -DgroupId=com.example -DartifactId=example -Dversion=1.0-SNAPSHOT -o
```
**Expected Behaviour:**
The list of available archetypes would be shown to the user.
_Note: I believe in older versions, only the basic archetypes are shown like quickstart_
**Actual Behaviour:**
Maven command hangs in this last last line:
```bash
[DEBUG] Searching for remote catalog: https://repo.maven.apache.org/maven2/archetype-catalog.xml
```
---
**Affects:** 3.0.1
**Attachments:**
- [build.log](https://issues.apache.org/jira/secure/attachment/12908576/build.log) (_20.48 kB_)
2 votes, 4 watchers
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing `mvn archetype:generate ... -o` with the proxy setup described and trace the `archetype:generate` entry point when it searches for `https://repo.maven.apache.org/maven2/archetype-catalog.xml`. Done means offline mode no longer hangs on remote catalog retrieval and the available archetypes are shown.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- build-system, cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100