Comments (4)
Hi @Raudius ! Thanks for sharing! Yeah, it does seem like the tracker itself is not responding. Considering that bt.tracker.MultiTracker
is involved in the stack, there should be an announce-list
property in the torrent file. Bt should try announcing to all trackers in this list. Is this the only tracker-related exception in out.log?
from bt.
OK so I just realised that HTTP trackers don't work with this library (as they havent been implemented yet(?)). I was able to get those to work through ttorrent.
But with when starting the client I also get this line of output:
1124 [bt.net.pool.incoming-acceptor] INFO bt.net.PeerConnectionPool - Opening server channel for incoming connections @ /192.168.1.40:6891
Which sugggests that it is listening only for connections locally? Shouldnt that be my public address instead?
Then after that line and after the tracker connection times out I get the error in the first post, and it repeats it after each timeout preceded by the error:
151120 [bt.peer.peer-collector] ERROR bt.peer.PeerRegistry - Error when querying peer source: bt.peer.TrackerPeerSource@2456c2b9
from bt.
HTTP trackers are supported, but for the sake of keeping the core with minimum number of 3-rd party dependencies it's shipped as a separate module.
Include this in your pom.xml:
<dependency>
<groupId>com.github.atomashpolskiy</groupId>
<artifactId>bt-core</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>com.github.atomashpolskiy</groupId>
<artifactId>bt-http-tracker-client</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
Then create your client in the following way:
BtRuntime runtime = BtRuntime.builder().module(new HttpTrackerModule()).build();
Or
BtRuntime runtime = BtRuntime.builder().module(new HttpTrackerModule()).module(new PeerExchangeModule()).build();
if you also want to make use of peer exchange.
You might also want to look through the brief explanation of basic concepts, it should help build a better picture of the main API:
http://atomashpolskiy.github.io/bt/intro/
from bt.
But with when starting the client I also get this line of output:
1124 [bt.net.pool.incoming-acceptor] INFO bt.net.PeerConnectionPool - Opening server channel for incoming connections @ /192.168.1.40:6891
Which sugggests that it is listening only for connections locally? Shouldnt that be my public address instead?
Nope, it's listening on a local port. Peers will be able to contact you via your external address, which will be communicated to them by the tracker, that you are working with.
If you'd like to listen on a different interface/port, use Config
[1]:
Config config = new Config();
config.setAcceptorAddress(/* network address */);
config.setAcceptorPort(/* network port */);
// tweak other parameters
BtRuntime runtime = BtRuntime.builder(config).build();
[1] http://atomashpolskiy.github.io/bt/javadoc/latest/bt/runtime/Config.html
from bt.
Related Issues (20)
- [BUG] Many Incoming Encryption fail with InvalidMessage HOT 1
- [BUG] Weird metainfo validation error in CLI HOT 3
- [BUG] springboot use HOT 1
- how to download the file range pieces? HOT 2
- [BUG] Something does not work as it should
- Gradle issues with cling dependency library (upnp module) HOT 3
- Running CliClient.java Locally Reports an Error HOT 1
- java.lang.NoSuchMethodError: No virtual method getAnnotatedSuperclass()Ljava/lang/reflect/AnnotatedType; in class Ljava/lang/Class; or its super classes (declaration of 'java.lang.Class' appears in /apex/com.android.art/javalib/core-oj.jar) HOT 2
- Vulnerable dependencies
- [BUG] Cling 2.2.1 not found in Maven Central HOT 3
- How to access DHT Database at runtime? HOT 1
- Stopping client and stopWhenDownloaded() throws java.lang.RuntimeException HOT 1
- How can I get the info.files[0].filehash info
- [BUG] Something does not work as it should
- Dependency org.yaml:snakeyaml, leading to CVE problem
- Does it support Android?
- [BUG] Android - only maxSimultaneouslyAssignedPieces are downloaded if PieceSelector.getNextPieces supplies subset of all pieces in torrent HOT 3
- [QUESTION] Code affecting the performance HOT 2
- [BUG] Cannot decode torrent due to validation error
- [Request] Implement a getter-interface for events that receives Peer from an event
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bt.