These forums have been archived and are now read-only.

The new forums are live and can be found at https://forums.eveonline.com/

EVE Technology Lab

 
  • Topic is locked indefinitely.
 

Why are we not combining market data, player devs?

Author
Dragonaire
Here there be Dragons
#281 - 2012-05-10 16:15:51 UTC
If you don't care about checking the header or checksum on PHP you can use method given in http://us3.php.net/manual/en/function.gzdecode.php#106397 instead of the more complex function Desmont McCallock linked. The other function seems to be more for dealing with a group of compressed files or a more complex header then you seem to get from gzencode() or would expect to see in HTTP.

Finds camping stations from the inside much easier. Designer of Yapeal for the Eve API. Check out the Yapeal PHP API Library thread.

Ilyk Halibut
Deep Core Mining Inc.
Caldari State
#282 - 2012-05-12 03:20:12 UTC
EMDR should now support gzip a little better for the HTTP gateway. I'm not certain that the form-encoded POST decompression is working as intended, though. Probably need some eyes on that.

EVE Market Data Relay - A real-time feed of EVE Market data http://www.eve-emdr.com

Ilyk Halibut
Deep Core Mining Inc.
Caldari State
#283 - 2012-05-12 03:26:29 UTC
Unless there is any technical reason not to do so, I'm going to yank that GET upload part from the spec. It's absolutely useless, and doesn't even make sense as far as HTTP is concerned. Due to the length limits discussed earlier, this becomes a non-starter for the vast majority of servers (unless you're a bonehead and up your limits, opening yourself up to some pretty silly GET requests).

EVE Market Data Relay - A real-time feed of EVE Market data http://www.eve-emdr.com

Dragonaire
Here there be Dragons
#284 - 2012-05-12 04:19:59 UTC
I deleted the stuff on GET again I don't know who put that back in P I dropped it before this last big edit someone did but they added it back with it it seems X

Finds camping stations from the inside much easier. Designer of Yapeal for the Eve API. Check out the Yapeal PHP API Library thread.

Desmont McCallock
#285 - 2012-05-12 06:11:07 UTC  |  Edited by: Desmont McCallock
I know who did it but I'm not a snitch. For the record it wasn't me (although I added the notice).
Dragonaire
Here there be Dragons
#286 - 2012-05-12 17:01:26 UTC
np I just figured it was someone that had missed when we decided it should be dropped here a page or two back Smile

Finds camping stations from the inside much easier. Designer of Yapeal for the Eve API. Check out the Yapeal PHP API Library thread.

Ilyk Halibut
Deep Core Mining Inc.
Caldari State
#287 - 2012-05-14 04:12:31 UTC
Can we get rid of the PUT method, too? I don't see any reason to put additional burden on service developers to support this if there's no reason. As discussed earlier, it's not technically correct to use PUT unless you know the exact URI of the item you're PUTting.

EVE Market Data Relay - A real-time feed of EVE Market data http://www.eve-emdr.com

Dragonaire
Here there be Dragons
#288 - 2012-05-16 22:01:31 UTC
I have no problem with doing so just thought someone had been using it so I didn't take it out when I was doing the edit. You are correct it shouldn't be used for this.

Finds camping stations from the inside much easier. Designer of Yapeal for the Eve API. Check out the Yapeal PHP API Library thread.

Desmont McCallock
#289 - 2012-05-20 08:59:01 UTC
Can we now update the wiki and change the spec version from '0.1alpha' to '0.1'?
Dragonaire
Here there be Dragons
#290 - 2012-05-21 15:32:08 UTC
I think so

Finds camping stations from the inside much easier. Designer of Yapeal for the Eve API. Check out the Yapeal PHP API Library thread.

Tonto Auri
Vhero' Multipurpose Corp
#291 - 2012-05-29 12:20:19 UTC  |  Edited by: Tonto Auri
Just chiming in.
I've seen in a parallel topic, that there's a concern about the data acceptance. (I.e., we can upload the data, but can we know, if our data could be accepted, before we start sending a payload?)
So, for a suggestion: How about a simple discovery sequence?
Something as simple, as
{
  "resultType" : "discovery",
  "version" : "0.1",
  "generator" : { "name" : "Yapeal", "version" : "11.335.1737" },
  "currentTime" : "2011-10-22T15:46:00+00:00"
}

with the answer (if the outlet is really accepting EMUU format) like
{
  "resultType" : "status",
  "version" : "0.1",
  "status" : "unavailable",
  "message" : "Human-readable explanation of the server status, intended to be displayed to operator.",
  "generator" : { "name" : "Yapeal", "version" : "11.335.1737" },
  "currentTime" : "2011-10-22T15:46:00+00:00",
}


I would recommend to perform a discovery at least once per client session.

I would also advise to use HTTP status codes accompanying the reply, in the range of
Status / HTTP code
available - 100 Continue or 200 OK
unavailable - 503 Service Unavailable or more appropriate code from 4xx range

Also on the note of status codes, I've noticed that specification does not clarify format of server responce to the uploads. And as I've seen in this and other topics, this already leading to some confusion.
I strongly suggest using the same tatus form as above, with status=accepted/HTTP code 202 for succesful uploads, or a proper 4xx/5xx error status for rejected uploads.

Two most common elements in the universe are hydrogen and stupidity. -- Harlan Ellison

Tonto Auri
Vhero' Multipurpose Corp
#292 - 2012-05-29 12:27:08 UTC
Desmont McCallock wrote:
What I haven't seen so far by any of you, is the usage of the specs URI for API entry points.
Quote:
Uploads
[SITEROOT]/api/upload

Syndication
[SITEROOT]/api/syndicate

I want to raise a question.
What is the reason to use two different outlets for the same data?

Two most common elements in the universe are hydrogen and stupidity. -- Harlan Ellison

Desmont McCallock
#293 - 2012-05-29 13:08:56 UTC  |  Edited by: Desmont McCallock
@Tonto
Post 1
The 'discovery' proposal will solve also my concerns on determining which server is alive before constructing the message. I now have to include an endpoint in the message without knowing if it's actually online. If the upload fails I have to suspend that endpoint and eventually disable it if uploading to it fails continuously.

As for the reply message, from my POV what to use is quite trivial, but should be documented in the specs and clarified.

Post 2
Probably separate handling scripts.
Dragonaire
Here there be Dragons
#294 - 2012-05-29 15:44:43 UTC
Really this is outside of what the format is about and I guess I don't understand why people keep thinking they need to reinvent the wheel on these things. Everyone keeps getting hung up on how the message is transported between end points but that has nothing to do with the actual format. How it sent between the end points doesn't matter truly. It could be sent through share memory between two process on the same computer, over a serial cable, or bluetooth, etc that is outside of the message. If data is being sent over a TCP/IP connection which has flow control etc that should be used. If it is being sent on port 80 it should follow HTTP rules as well which means when a receiver is down it should return one of the HTTP error codes.

You don't need to 'discover' anything you simple need to sent it and if where you are sending it to accepts it as far as the transmitter is concerned it's done. If the receiver is accepting the data but not doing what it is suppose to that is on them. It's the responsibility of the site you are sending to to make sure when they aren't able to receive the message to response accordingly with what ever flow control the connection has. At the same time you shouldn't be trying to send the message to a site that hasn't clearly said they accept data in the format either as it's just a waste of time for both of you.

Quote:
I want to raise a question.
What is the reason to use two different outlets for the same data?
The idea was tied in with there being mostly sources and sunks and having a channel for sunks to cross talk or the use of relays. Mixed in with that was the idea to allow both push and pull for the syndicated collected data. So the idea was sources would send to api/upload and then the sunk could either forward the data to subscribers automatically through api/syndicate (push) or request it (pull)

Finds camping stations from the inside much easier. Designer of Yapeal for the Eve API. Check out the Yapeal PHP API Library thread.

Tonto Auri
Vhero' Multipurpose Corp
#295 - 2012-05-29 17:31:58 UTC
Dragonaire wrote:
Really this is outside of what the format is about

That's right, but there's a problem.
Format itself isn't a solution to a problem.
The solution is a way to interchange the data in a way that is understood at all ends of the exchange.
You need not only format to describe the data, but a protocol to transfer it as well.
I've already seen something along the lines of "I do "echo 1" to mark a succesful data transfer.
If i'm to develop an uploader myself, what should I do? Should I expect that "1" as the reply to my upload?

Quote:
and I guess I don't understand why people keep thinking they need to reinvent the wheel on these things. Everyone keeps getting hung up on how the message is transported between end points but that has nothing to do with the actual format. How it sent between the end points doesn't matter truly. It could be sent through share memory between two process on the same computer, over a serial cable, or bluetooth, etc that is outside of the message. If data is being sent over a TCP/IP connection which has flow control etc that should be used. If it is being sent on port 80 it should follow HTTP rules as well which means when a receiver is down it should return one of the HTTP error codes.

First, i'm not going to discuss the transport layer.
My concern was about exact states of a transaction, not the process of it.
I.e., "a client open a connection" does not specify, what connection it is. A UNIX socket, a HTTP server port or a shared memory area? Client open a connection, that is suitable for data transfer. doesn't matter, which connection it is.
Next, client sends a payload. How? Doesn't matter, really. Format matters. The one we described earlier.
Next, server should somehow signal to client, that it accepted the payload. It is a required step in about any stateful communication protocol you could find. If you're operating on raw TCP sockets, it's quite easy, but in most other cases, you'll need server to send something more meaningful. Probably suitable for operator's eyes, too. Especially in case of errors.
I'm up for HTTP codes myself, when it's operated over HTTP, there's plently for most of use-cases, and a room to invent more, if need. But this should be clarified in specification.

Quote:
You don't need to 'discover' anything you simple need to sent it and if where you are sending it

The problem was outlined earlier by Desmont, and more thoroughly explained in his post regarding uploader integration in EVEMon.
If we'd take your approach, I could, theoretically, put "http://microsoft.com/" into list of outlets, and spam it with megabytes of market uploads.
While funny as it is, I would take any steps in my reach to prevent this kind of things from happening. It's just not nice to the community.

Quote:
At the same time you shouldn't be trying to send the message to a site that hasn't clearly said they accept data in the format either as it's just a waste of time for both of you.

What I should or not, poses a communication issue along with a possibility of human mistakes.
While i'm against solving social issues with technical solutions, if I can prevent basic mechanical errors at the application design stage, I would do so.

Two most common elements in the universe are hydrogen and stupidity. -- Harlan Ellison

Tonto Auri
Vhero' Multipurpose Corp
#296 - 2012-05-29 17:34:01 UTC
Quote:
Quote:
I want to raise a question.
What is the reason to use two different outlets for the same data?
The idea was tied in with there being mostly sources and sunks and having a channel for sunks to cross talk or the use of relays. Mixed in with that was the idea to allow both push and pull for the syndicated collected data. So the idea was sources would send to api/upload and then the sunk could either forward the data to subscribers automatically through api/syndicate (push) or request it (pull)

Ahha. Now, I recall. Makes a little sense. It was "a little" while since last time I've participated in this thread...

Two most common elements in the universe are hydrogen and stupidity. -- Harlan Ellison

Ilyk Halibut
Deep Core Mining Inc.
Caldari State
#297 - 2012-05-29 17:47:48 UTC
I think HTTP codes are the way to go with denoting whether a response succeeded. Get a HTTP 200, everything is peachy. See some of the 4xx and 5xx codes? You probably have problems, read the body or status text for details.

EVE Market Data Relay - A real-time feed of EVE Market data http://www.eve-emdr.com

Ilyk Halibut
Deep Core Mining Inc.
Caldari State
#298 - 2012-05-29 17:52:42 UTC
Desmont McCallock wrote:
The 'discovery' proposal will solve also my concerns on determining which server is alive before constructing the message. I now have to include an endpoint in the message without knowing if it's actually online. If the upload fails I have to suspend that endpoint and eventually disable it if uploading to it fails continuously.

I think I may be with Dragonaire on this one. I don't want to deal with all of these discovery/ping requests. Send data my way, if it succeeds, we're both happy, if not, disable uploads temporarily or indefinitely. Adding a discovery view will just increase the volume of HTTP requests, and badly designed clients will still block while hitting the discovery view.

EVE Market Data Relay - A real-time feed of EVE Market data http://www.eve-emdr.com

Tonto Auri
Vhero' Multipurpose Corp
#299 - 2012-05-29 22:32:45 UTC
Ilyk Halibut wrote:
Desmont McCallock wrote:
The 'discovery' proposal will solve also my concerns on determining which server is alive before constructing the message. I now have to include an endpoint in the message without knowing if it's actually online. If the upload fails I have to suspend that endpoint and eventually disable it if uploading to it fails continuously.

I think I may be with Dragonaire on this one. I don't want to deal with all of these discovery/ping requests. Send data my way, if it succeeds, we're both happy, if not, disable uploads temporarily or indefinitely. Adding a discovery view will just increase the volume of HTTP requests, and badly designed clients will still block while hitting the discovery view.

"All of the discovery requests" would be less than 1% of the total traffic. Even if performed before each upload, which should be strongly discouraged.
Also, you're viewing the situation from your own idealistic POV, assuming that everything should work as intended. Reality says, it doesn't...

Two most common elements in the universe are hydrogen and stupidity. -- Harlan Ellison

Ilyk Halibut
Deep Core Mining Inc.
Caldari State
#300 - 2012-05-30 02:31:34 UTC
Tonto Auri wrote:

"All of the discovery requests" would be less than 1% of the total traffic. Even if performed before each upload, which should be strongly discouraged.

This is entirely dependent upon client design, and is a completely arbitrary number.
Tonto Auri wrote:

Also, you're viewing the situation from your own idealistic POV, assuming that everything should work as intended. Reality says, it doesn't...

This addition would do nothing to make something work that wouldn't under the current means.

This sums it up perfectly
Dragonaire wrote:

You don't need to 'discover' anything you simple need to sent it and if where you are sending it to accepts it as far as the transmitter is concerned it's done.

This discovery thing is a solution in search of a problem. Follow the spec, point your uploaders at the endpoints that the service published, and that's all there is to it. There is no need to discover anything.

EVE Market Data Relay - A real-time feed of EVE Market data http://www.eve-emdr.com