The requested content is transmitted as is. To save network bandwidth, a web server can be configured to compress encode a requested content.
You may notice Accept-Encoding is set to " gzip,deflate " that passed from your browser to a web server. The compression comes with a price: initial response delay and more computation power is required from a web server; that decreases the number of concurrent users the web server may serve at the same time.
The problem can be solved by adding a compressed content cache see Figure 2 or by using pre-compressed data. The second way looks more attractive — it does not require any processing power from the web server; but, it requires more work upfront such as compression of the content. That gives an additional headache for web designers and content authors when they are trying to publish their content. The ZIP is one of the widely used compression formats.
A ZIP file contains multiple files that are compressed by numerous archival methods. The file structure can be presented as two parts, the compressed data and a directory.
See Figure 4. The Content-Encoding header has to be set to " deflate " for the HTTP response to tell a web browser that the content is encoded.
In the past, IPython had the notion of a prompt string that allowed arbitrary code to be evaluated, and this was put to good use by many in creating prompts that displayed system status, path information, and even more esoteric uses like remote instrument status acquired over the network. But now that IPython has a clean separation between the kernel and the clients, the kernel has no prompt knowledge; prompts are a frontend feature, and it should be even possible for different frontends to display different prompts while interacting with the same kernel.
Upon completion of the execution request, the kernel always sends a reply, with a status code indicating what happened and additional data depending on the outcome. See below for the possible return codes and associated data.
Execution of cells in the IPython kernel. This counter is used to populate the In[n] and Out[n] prompts. Payloads are considered deprecated , though their replacement is not yet implemented. Pager payloads are generally displayed in a separate pane, that can be viewed alongside code, and are not included in notebook documents.
Allows the kernel to request exit, e. Only for console frontends. Code can be inspected to show useful information to the user. It is up to the Kernel to decide what information should be displayed, and its formatting.
In the notebook, this is used to show tooltips over function calls, etc. Lexing is up to the kernel. For clients to explicitly request history from a kernel. The kernel has all the actual execution history stored in a single location, so clients can request it from the kernel when needed. New in version 4. Most of the history messaging options are not used by Jupyter frontends, and many kernels do not implement them. The notebook interface does not use history messages at all.
We may remove some options in a future version of the message spec. When the user enters a line in a console style interface, the console must decide whether to immediately execute the current code, or whether to show a continuation prompt for further input. The frontend should also handle the kernel not replying promptly. It may default to sending the code for execution, or it may implement simple fallback heuristics for whether to execute the code e.
Frontends may have ways to override this, forcing the code to be sent for execution or forcing a continuation prompt. Deprecated since version 5. Kernels are not expected to implement handlers for this message. This allows clients to only have to know about a single port the shell channel to connect to a kernel.
The ports for any additional channels the kernel is listening on should be included in the reply. If any ports are omitted from the reply, this indicates that the channels are not running. When a client needs the currently open comms in the kernel, it can issue a request for the currently open comms.
This message can be used to fetch core information of the kernel, including language e. Refer to the lists of available Pygments lexers and codemirror modes for those fields. The client sends a shutdown request to the kernel, and once it receives the reply message which is otherwise empty , it can assume that the kernel has completed shutdown safely.
The request is sent on the control channel. When the clients detect a dead kernel thanks to inactivity on the heartbeat socket, they simply send a forceful process termination signal, since a dead process is unlikely to respond in any useful way to messages. In case a kernel can not catch operating system interrupt signals e.
An interruption will then result in the following message on the control channel:. This message type is used with debugging kernels to request specific actions to be performed by the debugger such as adding a breakpoint or stepping into a code. Debug requests and replies are sent over the control channel to prevent queuing behind execution requests.
In order to support the debugging of notebook cells and of Jupyter consoles, which are not based on source files, we need a message to submit code to the debugger to which breakpoints can be added.
In order to support page reloading, or a client connecting at a later stage, Jupyter kernels must store the state of the debugger such as breakpoints, whether the debugger is currently stopped. The inspectVariables is meant to retrieve the values of all the variables that have been defined in the kernel. It is a DAP Request with no extra argument. The richInspectVariables request allows to get the rich representation of a variable that has been defined in the kernel.
Content of the richInspectVariables request:. Content of the richInspectVariables response:. This type of message is used to bring back data that should be displayed text, html, svg, etc. This data is published to all frontends.
Each message can have multiple representations of the data; it is up to the frontend to decide which to use and how. A single message should contain all possible representations of the same information. Probably not, because the displayhook also has to handle the Out prompt display. On the other hand we could put that information into the metadata section. The metadata contains any metadata that describes the output. Global keys are assumed to apply to the output as a whole.
The metadata dict can also contain mime-type keys, which will be sub-dictionaries, which are interpreted as applying only to output of that type. Third parties should put any data they write into a single dict with a reasonably unique name to avoid conflicts. The transient dict contains runtime metadata that should not be persisted to document formats and is fully optional.
Results can have multiple simultaneous formats depending on its configuration. Frontends are free to display any or all of these according to its capabilities.
Frontends should ignore mime-types they do not understand. The data itself is any JSON object and depends on the format. It is often, but not always a string. Thus, the outputs associated with a given execution shall generally arrive between the busy and idle status messages associated with a given request. Asynchronous output e.
The handling of these out-of-order output messages is currently undefined in this specification, but the Jupyter Notebook continues to handle IOPub messages associated with a given request after the idle message has arrived, as long as the output area corresponding to that request is still active.
Changed in version 4. With the stdin socket, the kernel makes the request, and the single frontend provides the response. This pattern allows code to prompt the user for a line of input, which would normally be read from stdin in a terminal.
These steps are repeated until the eighth signal is not received or until all possible sixth values have been stored in said second storage means, the sixth value being in the list of valid network numbers provided in the sixth signal. The value contained in the second storage means is then stored into the first storage means. In a particular embodiment of the invention, a plurality of entities and routers are interconnected in a computer controlled communication system which allows for the transfer of data between the plurality of entities in one local subset of the system and also allows the transfer of data between an entity in one local subset of the communication system and an entity in another local subset of the communication system through the routers.
One set of entities is typically located on one local subset and another set of entities is typically located on another local subset of the communication system. Each local subset of the communication system is provided with a list of valid network numbers which are unique for that subset as compared to the entire communication system. According to the method and apparatus of the present invention, upon start-up, entities on a particular local subset of the communication system first randomly generate network values and node values and determine whether these values are unique on the local subset and then subsequently query the router directly connected to the particular local subset to determine whether the network values are within the valid list provided for the particular local subset of which the entity is part.
The routers for each subset network in the internet typically include a first router which is seeded with a list of valid network values for a particular local subset and then the remaining routers in the local subset are allocated that list of network numbers so that each local subset will have a unique list of valid network numbers.
According to the method and apparatus of the invention, an entity on a particular local subset of the communication system first determines whether a value has been stored which represents a previously saved address for that particular entity in the communication system. This value will typically include a network value and a node value and is typically saved in a memory means which saves information even if power is lost or turned off e.
If a previously saved address has not been stored then the first entity will typically store a randomly generated value in a storage means e. RAM , which randomly generated value is representative of a first randomly generated address which includes a network value and a node value. In either case then the entity transmits an enquiry signal to determine if the value which has been randomly generated is used for the unique identification of any other entity on the local subset of the communication system.
If that value is being used for the address--and hence the unique identification--of any other entity on the local subset, then the entity will receive an acknowledge signal from the other entity which has already used the address; this acknowledge signal will indicate to the entity that the entity's first value for an address in the communication system is not available as it is being used as an address for another entity on the local subset of the communication system.
Having received this acknowledge signal, the entity then generates another random value and stores it in a storage means; this random value is a second randomly generated address and includes a network value and a node value. This process will continue as the entity attempts to find a combination of the network value and the node value which is unique within the local subset of the communication system. If a unique address is found on the local subset, the entity then transmits a signal requesting information from a router means which is directly connected to the local subset of the communication system.
The request for information from a router means includes a request to determine if a router exists and includes a request to determine the list of valid network values which are permitted for the particular local subset on which the requesting entity resides. The request for information from a router also includes a request for information concerning the zones which are permitted for the particular local subset on which the entity resides.
If a router is directly connected to the local subset, the router will respond within a predetermined period of time with the requested information so that the entity receives a signal indicating the list of valid network values for the local subset on which the entity resides. If the entity waits a predetermined period of time for the response from a router and if no response is received, then the entity sets its tentative address as the final address of the entity in the communication system.
If the router responds within a predetermined period of time then the entity determines whether its tentative address which has been randomly generated as described above includes a network value which is within the valid list of network values.
If the network value is not within the list of valid network values indicated by the router, then the entity generates another random address which includes a network value which is randomly generated within the list of valid network values and a randomly generated node value. As will be described below these values are randomly generated. This address will be tested to determine if it specifies a unique address for the entity among the addresses used by the other entities on the local subset.
This process continues until the entity has obtained a unique address which is in the list of valid network values to use as a final address or until the entity determines that there are no other addresses available, in which case an error condition is indicated and the process stops.
The present invention is illustrated by way of example and not limitation in the figures of the accompanying and in which like references indicate similar elements and in which:. A local area network node startup method for assigning a unique address is described. In the following description for the purposes of explanation, specific numbers, bytes, registers, addresses, times, signals, and formats are set forth in order to provide a thorough understanding of the present invention.
However, it will be apparent to one skilled in the art that the present invention may by practiced without the specific details. In other instances, well known circuits and devices are shown in block diagram form in order to not unnecessarily obscure the present invention. Referring to FIG. These network resources may include, among other things, printers, modems, memory, disk devices, etc.
For the purposes of this specification, all data processing and peripheral devices which are coupled to the network are collectively referred to as "entities". As shown, the entities through are interconnected for data transfer to one another by common cable The entities are coupled to cable by connection modules on FIG.
It will be appreciated by one skilled in the art that cable may comprise any shared media, such as co-axial cable, fiber optics, radio channel, twisted pair cable, or the like. The present invention permits access to various network resources such as data stored in local memories or disk and the common use of printers without the need to predefine addresses for each device coupled to cable Note that the network , shown in FIG. As soon as a node detects that cable traffic has ceased on cable , the node will wait for a certain mandatory time period to pass to allow the network to settle, and then the node will begin to transmit its data.
In an alternative embodiment, network may be a standard token-ring networking system. In this case, networking cable further couples nodes and directly so that the network forms a complete loop. Data travels unidirectionally in the network at a data rate of approximately four to sixteen megabits per second. Each connection module is a "repeater," that is, when data is received from an adjoining node "upstream" from the receiving node, the token is placed back on the network cable This is done after the node has examined the token to see if the node must act upon the token, and transform it accordingly, if required.
In this alternative embodiment for network , the token-ring topology is driven in accordance with IEEE Computer system comprises a bus or other communication means for communicating information, a processing means coupled with bus for processing information, a random access memory RAM or other dynamic storage device commonly referred to as main memory coupled to bus for storing information and instructions for processor Computer system further comprises a display device , such as a cathode ray tube CRT , coupled to bus for displaying information to the computer user, an alpha-numeric input device , including alpha numeric and other keys, coupled to bus for communicating information and command selections to processor , and may also comprise a cursor control device , such as a mouse, a track ball, or cursor direction keys, coupled to bus for communicating direction information and command selections to processor and for controlling cursor movement.
Computer system may also be coupled to connection module via bus Processor is one of the family of microprocessors manufactured by Motorola, Inc. Andrews, and Alan B. Oppenheimer 1st Ed. Referring now to FIG. Two frames are shown in FIG. For the purposes of the remainder of this application, each byte is 8 bits in length. Depending on whether network in the preferred embodiment is an ETHERNET or Token-ring network system in the alternative embodiment, the corresponding packet will be used.
If network in an alternative embodiment is a Token-ring network, the packets transmitted are in the format of a TLAP packet, frame To understand the two packets frames shown in FIG. This informs the hardware and software that certain non-IEEE standard protocol software is being used in networking system Note that for the remainder of this application certain values will be represented in hexadecimal notation base In the present system, notice that it is also necessary to distinguish between the various protocol families used since the SAP quantity merely identifies that the packet being sent is in a non-IEEE standard format.
This SNAP quantity identifies the particular subprotocol being used in the packet. The SNAP quantity will vary according to which particular protocol stack the packet corresponds. The values contained within these SNAP fields are discussed below.
The next three fields of frame are known as the IEEE This header specifies the source and destination SAPs being used, and a control byte indicating the type of packet. These values indicated that it is a non-standard IEEE protocol being used by both the destination and source nodes for the addresses given in and The third portion of the The next five bytes in frame are known as the SNAP protocol discriminator and indicates to the data link the type of packet being transmitted.
AARP is discussed below. The next two fields of a standard ELAP packet in frame is the data field and a padding field The data field contains certain data, depending on the particular protocol being implemented and the type of packet being transmitted, which will be discussed below. This may include the source and destination protocol addresses as well as any data.
Finally, the last field in frame is a padding field, and is used if the packet does not equal the minimum 60 bytes of information required for an ETHERNET packet. Therefore, if frame is less than the minimum 60 bytes in length, bytes are inserted into the pad field until the packet equals 60 bytes in length. Frame first comprises a TLAP header comprising 8 fields. The TLAP header starts with a field being a unique 2 byte identifier for use within the Token-ring network.
The next 6 bytes are used for the Token-ring node destination address , and the following 6 bytes are used for the Token-ring node source address for the node transmitting the packet.
As in the ETHERNET system, the 6 byte node hardware addresses in fields and are statically assigned to each of the nodes comprising network The following field may be 0 to 18 bytes long and comprises source routing information. This information is used by the Token-ring networking system if the high order bit of the source hardware address is set.
If that bit is not set, then field is 0 bytes in length, and there is no routing information contained in the packet. However, if the most significant bit of is set, then the routing information may comprise 2 to 18 bytes of source routing information indicating which bridges in the network the packet must traverse in order to reach the destination node specified in field Each field comprises one byte of information.
Fields , and contain the same values as fields , and in the ELAP Again, this field contains the same value as in frame depending on the type of packet being transmitted.
The remainder of the frame comprises a data field , which will contain certain information as in ELAP field The diagram shown in FIG. This model defines the concepts of a protocol and a service interface that defines a protocol architectural framework consisting of 7 layers comprising: Physical , Data Link , Network , Transport , Session , Presentation , and Application Each layer may be thought of as a separate process or filter which either appends protocol information onto existing data packets transmitted in system , or routes appropriate data packets through network system depending on the type of packet and the particular layer in which the packet resides.
The various layers allow packets to be transmitted from one variety of hardware to another, and one process socket to another. For instance, the packets described with reference to FIG. This high level address generally resides in layer of the protocol stacks Each of these protocol "stacks" correspond with the protocol layers shown on FIG.
For instance, each protocol stack may incorporate a different set of high level protocol addresses corresponding to the specific instance of that stack for the given nodes. As shown in of FIG. In order to resolve protocol addresses residing at levels and into hardware addresses used at level , AARP expects certain packets from nodes in network As shown in FIG. The packets fields , fields , and fields each constitute the data field portion of ELAP packet for transmitting the packet to the appropriate node in network Packets , , and each comprise fields indicating a hardware address length , , and , and a protocol address length , , and The hardware address length , , and are constant for the three packets since the hardware addresses in the currently performed embodiments are each six bytes in length.
The protocol address length contained in fields , , and are the same for packets , , and because the protocol address length in the present invention is always equal to four bytes. The next field in packets , , and , is a two-byte function field indicating the type of AARP packet being transmitted. In , contains a one, indicating that it is an AARP request packet being transmitted.
In , the function field contains a two, indicating that it is an AARP response packet. In , the function field contains a three, indicating that it is an AARP probe packet. The AARP probe packet is used to determine whether the address is currently being used by another node on the network. This probing function is discussed below.
The next two fields in AARP packets , , and are the source hardware address , , and , and the source protocol address , , and The source protocol address , , or is the address maintained by the node as the current protocol address used by the layer of the network model shown in FIG. An AMT is a list of hardware addresses which are statically assigned to each node along with corresponding protocol addresses for each protocol family used in network When asked by a client process to determine a hardware address corresponding to a given protocol address, AARP scans the AMT in the node for that protocol address.
If the hardware address is not found in the AMT, then AARP tries to determine the hardware address by querying all nodes supporting the corresponding protocol family.
Whenever a new address mapping is determined, new AMT entries are entered for that specific protocol to correspond with the given hardware address. Old AMT mappings between hardware addresses and protocol addresses are purged using a least recently algorithm, and AMT entries are modified if given protocol or hardware addresses are modified. If a request packet or a probe packet is sent and an AARP response is received by the transmitting node, then the destination hardware address can be placed into the AMT for the protocol address transmitted in the packet.
From that point forward, the node may use the AMT to send a packet datagram to the node's hardware address directly without performing any address resolution between a protocol address and a hardware address.
If a response packet is not received within a specified time interval after re-transmitting for a specified number of times the AARP probe or request packet , then the transmitting node leaves that entry in its AMT blank. The failure to respond within a given time indicates that no node is using the protocol address. Every time a packet is received from another node in the system, address information may be obtained by AARP since both the hardware address and protocol address is provided in ELAP packet The method of updating AMT entries in this way is known as "gleaning".
Some processes, at their option, may not perform address "gleaning" due to the overhead associated with updating address information every time a packet is received. The source protocol address , , and in the packet is provided by the node using a mapping in the AMT if the node knows what its corresponding protocol address is.
At the time of dynamic address assignment, the source protocol address field of packet is set to the address which is being determined whether unique or not. In an AARP request packet or an AARP response packet , fields and should contain the protocol address of the requesting or responding node.
In AARP response packet , the destination hardware address is provided in field In packets , , and , each field , , and is used to transmit a requested or destination protocol address by a transmitting node. This protocol address is four bytes in length. In an AARP request , the protocol address for which a hardware address is desired is transmitted in field In packet AARP probe , a tentative protocol address comprises the last four bytes of the packet. A tentative protocol address is transmitted by a node during system power-up to determine if the protocol address is in use by any other node on the network.
When such a probe is made, any node having a protocol address equal to the value contained within field will transmit an AARP response packet containing the same protocol address in field and the corresponding hardware address in field This indicates to the probing node that the protocol address is not available for use. Notice that the address is broken into 3 distinct fields , , and Notice that the field one byte in length is not used at this time and must be set to zero.
In the prior art, the network number represented all of the nodes on network separated from the remainder of the internet by a device known as an internet router IR.
0コメント