Sharing IT Knowledge and Life – Chia sẻ kiến thức IT và đời sống

Showing posts with label Networking. Show all posts
Showing posts with label Networking. Show all posts

Monday, September 3, 2018

Java Concurrency

1. Java Concurrency from docs.oracle.com

Computer users take it for granted that their systems can do more than one thing at a time. They assume that they can continue to work in a word processor, while other applications download files, manage the print queue, and stream audio. Even a single application is often expected to do more than one thing at a time. For example, that streaming audio application must simultaneously read the digital audio off the network, decompress it, manage playback, and update its display. Even the word processor should always be ready to respond to keyboard and mouse events, no matter how busy it is reformatting text or updating the display. Software that can do such things is known as concurrent software.
The Java platform is designed from the ground up to support concurrent programming, with basic concurrency support in the Java programming language and the Java class libraries. Since version 5.0, the Java platform has also included high-level concurrency APIs. This lesson introduces the platform's basic concurrency support and summarizes some of the high-level APIs in the java.util.concurrent packages.

Java EE 7: Building Web Applications with WebSocket, JavaScript and HTML5

Purpose

how to create an application that uses the WebSocket API for real-time communication between a client and a server:
  • Create a Java Platform, Enterprise Edition 7 (Java EE 7) application that uses the WebSocket API
  • Use the OnOpen and OnMessage WebSocket lifecycle events to perform different actions on the Java EE 7 application.
  • Define a client-side WebSocket endpoint by using JavaScript
  • Operate on Plain Old Java Objects (POJOs), in real-time, with actions invoked from a web browser client

Sunday, January 7, 2018

Unstructured Supplementary Service Data (USSD)

Unstructured Supplementary Service Data (USSD), sometimes referred to as "Quick Codes" or "Feature codes", is a communications protocol used by GSM cellular telephones to communicate with the mobile network operator's computers. USSD can be used for WAPbrowsing, prepaid callback service, mobile-money services, location-based content services, menu-based information services, and as part of configuring the phone on the network.[1]
USSD messages are up to 182 alphanumeric characters long. Unlike Short Message Service (SMS) messages, USSD messages create a real-time connection during a USSD session. The connection remains open, allowing a two-way exchange of a sequence of data. This makes USSD more responsive than services that use SMS.[1]  (extract from Unstructured Supplementary Service Data).

Tuesday, August 8, 2017

Apache MINA Spring

Apache MINA (Multipurpose Infrastructure for Network Application) is an open source java network application framework. MINA is can be used to create Scalable, high performance Network applications. MINA provides unified API's for various transports like TCP, UDP, Serial communication, In-VM pipe. It also makes it easy to make an implementation of custom transport type. MINA provides both high-level and low-level network API's.
Application Structure

MINA based Application Architecture

Friday, June 23, 2017

Java DateTimeFormatter


ThingWorx: Datetime format to be used in JavaScript with parseDate
  • The format strings used by the parseDate function are based on Java's DateTimeFormatter class. 
  • Format strings used by parseDate are case sensitive.
  • Some of the common placeholders used by parseDate
    • yyyy = Year (4 digits)
    • yy = Year (2 digits)
    • MM = Month (numeric)
    • dd = Day
    • HH = Hours (24h)
    • hh = Hours (12h)
    • mm = minutes
    • ss = seconds
    • SSS = milliseconds
    • a = AM/PM
    • zzz or ZZZ = timezone
      • zzz assumes GMT with zero offset
        • parseDate(newDate , "yyyyMMddHHmmsszzz")
      • ZZZ - GMT zero offset must be explicitly set or UTC can be used
        • e.g GMT0 or UTC
        • parseDate( newDate , "yyyyMMddHHmmssZZZ")

Friday, April 14, 2017

Friday, January 1, 2016

Mobile Concept

Contents / Nội dung: English | Tiếng Việt

Mobile Concept (English)

1. What is telecommunications?

Telecommunications, also called telecommunication, is the exchange of information over significant distances by electronic means. A complete, single telecommunications circuit consists of two stations, each equipped with a transmitter and a receiver. The transmitter and receiver at any station may be combined into a single device called a transceiver. The medium of signal transmission can be electrical wire or cable (also known as "copper"), optical fiber or electromagnetic fields. The free-space transmission and reception of data by means of electromagnetic fields is called wireless.

2. Areas of telecommunications

  • Voice services (fixed, mobile, etc.), data services (e.g. ADSL), video conferencing, Internet TV, telecom network infrastructure for broadband Internet services, satellite, and other telecom/Internet products and services
  • Value-added services on the Internet and mobile phones
  • Messaging, data and entertainment services on mobile networks
  • Online games on the Internet and mobile phones
  • Trading of telecom and Internet equipment

3. More related concepts

  • Mobile communication: wireless communication that lets users make calls, send messages and access data while moving, using radio waves.
  • Cellular network: a network divided into areas called cells, each served by a base station. Neighboring cells use different frequencies so the same frequencies can be reused elsewhere.
  • Base station (BTS / NodeB / eNodeB / gNodeB): equipment with antennas that connects mobile devices to the core network (2G: BTS, 3G: NodeB, 4G: eNodeB, 5G: gNodeB).
  • Mobile generations (1G to 5G): 1G analog voice; 2G digital voice and SMS (GSM); 3G mobile Internet (UMTS/HSPA); 4G high-speed broadband (LTE); 5G very high speed, low latency and massive device connectivity.
  • SIM (Subscriber Identity Module): a card (or eSIM) that identifies the subscriber and stores authentication data for the network.
  • Roaming: using a mobile service on another operator's network, typically in another area or country.
  • Handover (handoff): transferring an ongoing call or data session from one cell to another without interruption as the user moves.
  • Spectrum / frequency band: the range of radio frequencies licensed to operators for providing services.
  • Bandwidth, throughput and latency: bandwidth is the maximum capacity of a link; throughput is the actual data rate achieved; latency is the delay of data from sender to receiver.
  • SMS / MMS: short text messages / multimedia messages (images, audio, video) over the mobile network.
  • VAS (Value-Added Services): extra services beyond basic voice and data, such as ringback tones, news by SMS, mobile payment and entertainment.
  • VoIP / VoLTE: voice over IP networks / voice calls over a 4G LTE network.
  • OTT (Over-The-Top): services delivered over the Internet without an operator's direct involvement, such as Zalo, WhatsApp, YouTube and Netflix.
  • MVNO (Mobile Virtual Network Operator): an operator that provides mobile services using another operator's network infrastructure.
  • Mobile application: software running on a mobile device. Main types: native (iOS/Android), web app (runs in the browser) and hybrid (web technology wrapped in a native shell).
  • IoT (Internet of Things): physical devices and sensors connected to the Internet, often through mobile networks.

4. Other posts related to mobile


Mobile Concept (Tiếng Việt)

1. Viễn thông là gì?

Viễn thông là việc trao đổi thông tin ở khoảng cách xa bằng các phương tiện điện tử. Một mạch viễn thông hoàn chỉnh gồm hai trạm, mỗi trạm có một bộ phát và một bộ thu. Bộ phát và bộ thu tại mỗi trạm có thể được tích hợp thành một thiết bị gọi là bộ thu phát (transceiver). Môi trường truyền tín hiệu có thể là dây dẫn điện hoặc cáp đồng, cáp quang hoặc trường điện từ. Việc truyền và nhận dữ liệu trong không gian tự do bằng trường điện từ được gọi là không dây (wireless).

2. Một số lĩnh vực hoạt động của viễn thông

  • Dịch vụ thoại (cố định, di động,..), Dịch vụ truyền dữ liệu (ví dụ ADSL), Video Conference, TiVi Internet, hạ tầng mạng viễn thông cho dịch vụ Internet băng thông rộng, vệ tinh, các sản phẩm/dịch vụ viễn thông, Internet khác
  • Dịch vụ giá trị gia tăng trên mạng Internet, điện thoại di động
  • Dịch vụ tin nhắn, dữ liệu, thông tin giải trí trên mạng điện thoại di động
  • Cung cấp trò chơi trực tuyến trên mạng Internet, điện thoại di động
  • Buôn bán thiết bị viễn thông và Internet.

3. Một số khái niệm liên quan khác

  • Thông tin di động (Mobile communication): truyền thông không dây dùng sóng vô tuyến, cho phép người dùng gọi điện, nhắn tin và truy cập dữ liệu khi di chuyển.
  • Mạng di động tế bào (Cellular network): mạng được chia thành các vùng gọi là cell, mỗi cell do một trạm gốc phục vụ. Các cell lân cận dùng tần số khác nhau để có thể tái sử dụng tần số ở nơi khác.
  • Trạm gốc (BTS / NodeB / eNodeB / gNodeB): thiết bị cùng anten kết nối thiết bị di động với mạng lõi (2G: BTS, 3G: NodeB, 4G: eNodeB, 5G: gNodeB).
  • Các thế hệ mạng di động (1G đến 5G): 1G thoại analog; 2G thoại số và SMS (GSM); 3G Internet di động (UMTS/HSPA); 4G băng thông rộng tốc độ cao (LTE); 5G tốc độ rất cao, độ trễ thấp, kết nối số lượng lớn thiết bị.
  • SIM (Subscriber Identity Module): thẻ (hoặc eSIM) định danh thuê bao và lưu thông tin xác thực với nhà mạng.
  • Chuyển vùng (Roaming): sử dụng dịch vụ di động trên mạng của nhà mạng khác, thường ở vùng hoặc quốc gia khác.
  • Chuyển giao (Handover): chuyển cuộc gọi hoặc phiên dữ liệu đang diễn ra từ cell này sang cell khác mà không bị gián đoạn khi người dùng di chuyển.
  • Phổ tần / băng tần (Spectrum): dải tần số vô tuyến được cấp phép cho nhà mạng để cung cấp dịch vụ.
  • Băng thông, thông lượng và độ trễ (Bandwidth, Throughput, Latency): băng thông là dung lượng tối đa của đường truyền; thông lượng là tốc độ dữ liệu thực tế đạt được; độ trễ là thời gian trễ của dữ liệu từ nơi gửi đến nơi nhận.
  • SMS / MMS: tin nhắn văn bản ngắn / tin nhắn đa phương tiện (hình ảnh, âm thanh, video) qua mạng di động.
  • VAS (Dịch vụ giá trị gia tăng): các dịch vụ bổ sung ngoài thoại và dữ liệu cơ bản, như nhạc chờ, tin tức qua SMS, thanh toán di động, giải trí.
  • VoIP / VoLTE: thoại qua mạng IP / cuộc gọi thoại qua mạng 4G LTE.
  • OTT (Over-The-Top): dịch vụ cung cấp qua Internet mà không cần nhà mạng trực tiếp tham gia, như Zalo, WhatsApp, YouTube, Netflix.
  • MVNO (Nhà mạng di động ảo): nhà cung cấp dịch vụ di động dựa trên hạ tầng mạng của nhà mạng khác.
  • Ứng dụng di động (Mobile application): phần mềm chạy trên thiết bị di động. Các dạng chính: native (iOS/Android), web app (chạy trên trình duyệt) và hybrid (công nghệ web đóng gói trong vỏ native).
  • IoT (Internet vạn vật): các thiết bị vật lý và cảm biến kết nối Internet, thường thông qua mạng di động.

4. Các bài viết khác liên quan tới lĩnh vực di động

Tuesday, September 13, 2011

Socket Programming

Introduction

Sockets are interfaces that can "plug into" each other over a network. Once so "plugged in", the programs so connected communicate.This article discusses only simple aspects of stream inet sockets (don't worry about exactly what that is right now). For the purposes of this article, a "server" program is exposed via a socket connected to a certain /etc/services port number. A "client" program can then connect its own socket to the server's socket, at which time the client program's writes to the socket are read as stdin to the server program, and stdout from the server program are read from the client's socket reads. This is one subset of socket programming, but it's perhaps the easiest to master, so this is where you should start.
Diagram of a simple xinetd socket usage


Diagram of client-server socket connection via xinetd.
Note that the client communicates by reading and writing the socket,
but the server program communicates via stdin and stdout.

Sunday, February 20, 2011

Saturday, December 18, 2010

Bộ giao thức TCP/IP, Ipv4, Ipv6

Ngày nay, cùng với sự phát triển mạnh mẽ của Internet, bộ giao thức nền tảng của nó là TCP/IP đã trở nên phổ biến ở mọi lúc, mọi nơi. TCP/IP phổ biến đến mức nhiều người coi đây là bộ giao thức gần như bắt buộc đối với các hệ điều hành và ứng dụng mạng hiện đại. Bài viết này giới thiệu một cách hệ thống về bộ giao thức TCP/IP, địa chỉ IPv4 và IPv6.

1. Tổng quan về TCP/IP

TCP/IP (Transmission Control Protocol/Internet Protocol) là bộ giao thức chuẩn công nghiệp, ban đầu được thiết kế cho mạng diện rộng (Wide Area Network – WAN) và hiện là bộ giao thức chuẩn của mạng Internet.

Khái niệm phân lớp giao thức đã tồn tại từ rất lâu trước khi mô hình tham chiếu 7 lớp OSI được ISO chuẩn hóa (năm 1984). TCP/IP là một ví dụ thành công của việc áp dụng khái niệm này.

POPULAR | PHỔ BIẾN

TAGS

VIEWS