The link of files while streaming is misbehaving when server is restarted
See original GitHub issueHere is the explanation of the issue I ma facing:
- I am using the
{{HelperFunction.link}}method to stream files on Client side. The problem is when the server is restarted this function returns a link but the link is not pointing to the desired file. The app is not deployed and the MongoDB and Meteor app are both running on localhost. Moreover when I use different device on the same network to access the app, I face the same issue. Is there another way to show or access the file, maybe by using thedata=""property of html tags. - I am unable to retrieve
ostrio:filespackage version - Meteor v2.1
- Windows(Microsoft Edge v89.0.774.68)
- I think this is an issue with the link. I had like to know if we can retrieve the file in form of Data
Shared
const ImageSchema = Object.assign({}, FilesCollection.schema, {
timestamp: {
type: Number,
optional:true,
},
username: {
type: String,
optional:true,
},
chatRoomsID: {
type: String,
optional: true
}
});
Images = new FilesCollection({
collectionName: 'Images',
schema: ImageSchema
});
Images.collection.attachSchema(new SimpleSchema(ImageSchema));
Client Side
HTML
<img src="{{imageFile.link}}" alt="{{name}}" style="width: 100%; height: 300px;">
Client JS
Template.chatroomid.onRendered(function(){
imageFile() {
Meteor.subscribe('Images');
}
});
Template.chatroomid.helpers({
imageFile() {
return Images.findOne({_id:`${this._id}`});
}
});
Server Side
Meteor.publish('Images', function tasksPublication() {
return Images.find().cursor;
});
Issue Analytics
- State:
- Created 2 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
Media streaming turns off during reboot - Microsoft Community
1. On your search, type "services. · 2. Look for Windows Media Player Network Sharing Service > Right click and select Properties ·...
Read more >Won't Read Hard Drives and the Network Shares Stop after a Minute ...
My issue is not that it won't play a certain file type, it is that both the old device and a brand new...
Read more >RTC Connecting Discord – How to Fix the Server Error
3 of the fixes involve your computer network settings, while the remaining 2 happen right in your Discord app.
Read more >Server breaks on OVT connection loss · Issue #355 - GitHub
The setup is OBS -> rtmp -> OME origin -> OVT -> OME edge -> HLS ... Or will the stream recover when...
Read more >How to Fix It When Google Chrome Is Not Responding - Lifewire
Reset Chrome to default. It's always possible something was corrupted, or the combination of settings caused a problem. The only way to know...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Thank you very much @dr-dimitru. You were very helpful and the issue was resolved
@GSYamaji Feel free to close it in case if the issue is solved on your end.