Giter VIP home page Giter VIP logo

visitsb / meteorserver Goto Github PK

View Code? Open in Web Editor NEW
29.0 29.0 9.0 315 KB

Meteor is an HTTP server which gives developers the freedom to think about web development in an entirely new way. It comprises the Meteor server and a standalone Javascript class which can be used in webpages to provide an abstraction layer for receiving data streams. Designed to be as simple and flexible as possible, Meteor offers a great solution for those wishing to add asynchronous functionality to their web projects.

Perl 70.50% JavaScript 9.73% Shell 0.57% HTML 19.19%

meteorserver's People

Contributors

visitsb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

meteorserver's Issues

Configurable escaping mechanism

Feature-request: A configurable escaping mechanism.

Currently, when receiving messages to be used in browsers I have to escape quotes because the output mechanism simply puts quotes around them, for example:
Meteor.process(id,"channel","text");

It's probably best to do a full string escape here, such as JSON does on double-quotes strings:
http://stackoverflow.com/questions/3020094/how-should-i-escape-strings-in-json
However, ADDMESSAGE will not accept \r\n anyway because that signifies the end of the message, so these should be pre-escaped anyway by external software, and then unescaped in meteord. This way, the strings are received exactly the same as they are submitted.

I believe having the escaping be done automatically is better. However it should not be done for every transport mechanism. For example, I have an extra mechanism for plain connections which do their own parsing, which has the following MessageTemplate:
text\r\n

This should do no escaping, or at most escaping \r and \n (but as these need to be pre-escaped this is not useful).

.co.uk domain issues

There are a couple of places that .co.uk domains don't seem to work. I've patched them as follows:

meteor.js:

    extract_xss_domain: function(old_domain) {
            if (old_domain.match(/^(\d{1,3}\.){3}\d{1,3}$/)) return old_domain;
            domain_pieces = old_domain.split('.');
           tld = domain_pieces[domain_pieces.length - 1];
            if (tld == "com" || tld == "net" || tld == "org") {
               return domain_pieces.slice(-2, domain_pieces.length).join(".");
            } else { // a .co.uk or .org.uk account
               return domain_pieces.slice(-3, domain_pieces.length).join(".");
            }
    },

poll.html:

var thisdomain = document.domain;
var topdomain
var tld = domainparts[domainparts.length - 1];
if (tld == "com" || tld == "net" || tld == "org") {
topdomain = domainparts[domainparts.length-2]+"."+domainparts[domainparts.length-1];
} else { // a .co.uk or .org.uk account
topdomain = domainparts[domainparts.length-3]+"."+domainparts[domainparts.length-2]+"."+domainparts[domainparts.length-1];
}
document.domain=topdomain

They seem to work OK on my hosts now.

Can't locate Meteor/Syslog.pm in @INC

I get this when I try to start meteord the usual way:

user@host:~/git/meteorserver/src$ ./meteord -d
Can't locate Meteor/Syslog.pm in @INC (you may need to install the Meteor::Syslog module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.24.1 /usr/local/share/perl/5.24.1 /usr/lib/x86_64-linux-gnu/perl5/5.24 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.24 /usr/share/perl/5.24 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at ./meteord line 49.
BEGIN failed--compilation aborted at ./meteord line 49.
user@host:~/git/meteorserver/src$ 

Namespace collision

Dear,

It's not really a troll, but I'm wondering if you heard about https://www.meteor.com/. Or if you guys are somehow related? Because, they achieved your goal in a quiet elegant manner!

Thanks for the answer!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.