56 Commits
1.2.0 ... 1.3.0

Author SHA1 Message Date
Redkale
ee712c55a0 2016-11-24 15:24:14 +08:00
Redkale
79f70266e4 2016-11-24 12:05:17 +08:00
Redkale
3ffb8d510d 2016-11-24 11:59:35 +08:00
Redkale
e55fc1a421 2016-11-14 15:49:03 +08:00
Redkale
ee9fb4a9b8 2016-11-13 10:54:12 +08:00
Redkale
ef3536beed 2016-11-11 11:37:19 +08:00
Redkale
fbababaf40 2016-11-11 10:43:16 +08:00
Redkale
4548cf78d6 2016-11-10 16:29:42 +08:00
Redkale
86a219e3e1 2016-11-10 16:27:41 +08:00
Redkale
9e0876dee2 2016-11-10 16:22:04 +08:00
Redkale
e9096372d3 2016-11-09 13:15:00 +08:00
Redkale
cef367c693 2016-11-08 16:25:26 +08:00
Redkale
2634524439 2016-11-08 09:40:54 +08:00
Redkale
10d27bf78c 2016-11-07 21:07:56 +08:00
Redkale
5b7739b26b 2016-11-07 19:15:27 +08:00
Redkale
11f895a0ca 2016-11-07 14:12:44 +08:00
Redkale
63099b72be 2016-11-07 12:42:02 +08:00
Redkale
0d8f7a4fa2 2016-11-07 12:28:26 +08:00
Redkale
83f460660b 2016-11-07 09:28:23 +08:00
Redkale
786d25678b 2016-11-04 09:29:30 +08:00
Redkale
f57d8325b3 2016-10-31 16:43:47 +08:00
Redkale
22adab4f93 2016-10-31 16:28:24 +08:00
Redkale
805e3910c4 增加ColumnValue功能 2016-10-31 14:09:21 +08:00
Redkale
ecd827e3b4 增加ColumnValue功能 2016-10-31 14:04:45 +08:00
Redkale
19150e9f9c 增加ColumnValue功能 2016-10-31 13:32:08 +08:00
Redkale
de5a725acc 2016-10-31 09:35:28 +08:00
Redkale
aae2305274 2016-10-28 11:54:10 +08:00
Redkale
00ba1ecee9 2016-10-28 09:32:27 +08:00
Redkale
e59465eaf9 2016-10-27 19:36:39 +08:00
Redkale
6f0b4604fc 2016-10-27 16:43:55 +08:00
Redkale
9f97f81bae 2016-10-24 11:46:48 +08:00
Redkale
ffcd04a626 2016-10-22 10:23:53 +08:00
Redkale
ecf102aff3 2016-10-21 10:53:37 +08:00
Redkale
c16b0b520d 2016-10-21 10:35:19 +08:00
Redkale
2f25ee1c05 2016-10-21 10:11:32 +08:00
Redkale
b5011fa069 2016-10-19 17:37:37 +08:00
Redkale
55e2109764 2016-10-19 10:09:44 +08:00
Redkale
5cf4c8a95a 2016-10-19 10:08:09 +08:00
Redkale
6b319caa28 2016-10-18 14:45:11 +08:00
Redkale
b97a23930a 2016-10-18 13:34:12 +08:00
Redkale
6c918a6c95 2016-10-18 10:49:36 +08:00
Redkale
20ba119f93 2016-10-18 10:48:36 +08:00
Redkale
95ca74f9f9 2016-10-17 18:11:03 +08:00
Redkale
f28cbb4ac5 2016-10-14 14:31:56 +08:00
Redkale
e3f851ed1f 2016-10-13 17:35:05 +08:00
Redkale
d3cf414c51 2016-10-13 16:43:55 +08:00
Redkale
ea98bb814f 2016-10-11 12:30:02 +08:00
Redkale
515e8256cc Update README.md 2016-10-10 20:33:42 +08:00
Redkale
903c58b239 2016-10-10 20:28:04 +08:00
Redkale
1c59c86ba2 2016-10-10 19:20:19 +08:00
Redkale
b2c6dd2db2 2016-10-10 19:19:56 +08:00
Redkale
beffe53d4d 2016-10-10 19:02:35 +08:00
Redkale
4eb5edaef2 2016-10-10 17:53:18 +08:00
Redkale
ba07d343ae 2016-10-10 17:52:15 +08:00
Redkale
c887a9dc4c 2016-10-10 17:44:57 +08:00
Redkale
689cdca004 2016-10-10 17:15:51 +08:00
212 changed files with 1042 additions and 859 deletions

View File

@@ -21,4 +21,4 @@
&nbsp;&nbsp;&nbsp;由于RedKale使用了JDK 8 内置的ASM包所以需要在源码工程中的编译器选项中加入 <b>-XDignore.symbol.file=true</b>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<h5>详情请访问:&nbsp;&nbsp;&nbsp;&nbsp;<a href='http://redkale.org' target='_blank'>http://redkale.org</a></h5>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<h5>详情请访问:&nbsp;&nbsp;&nbsp;&nbsp;<a href='https://redkale.org' target='_blank'>https://redkale.org</a></h5>

158
pom.xml
View File

@@ -1,158 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.redkale</groupId>
<artifactId>redkale</artifactId>
<name>Redkale</name>
<packaging>jar</packaging>
<url>http://redkale.org</url>
<!-- -SNAPSHOT
mvn clean deploy -P release -Dgpg.passphrase=password
mvn release:clean release:prepare release:perform
-->
<version>1.0.0-rc1</version>
<description>Redkale is a Microservices Framework written in Java</description>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.5.1</version>
<configuration>
<encoding>UTF-8</encoding>
<compilerArguments>
<verbose />
<bootclasspath>${java.home}/lib/rt.jar</bootclasspath>
</compilerArguments>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.6</version>
<configuration>
<archive>
<manifest>
<mainClass>org.redkale.boot.Application</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>3.0.0</version>
<executions>
<execution>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.10.3</version>
<configuration>
<charset>${file_encoding}</charset>
<encoding>${file_encoding}</encoding>
</configuration>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-compiler-javac</artifactId>
<version>2.7</version>
</dependency>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-utils</artifactId>
<version>3.0.22</version>
</dependency>
</dependencies>
<profiles>
<profile>
<id>release-sign-artifacts</id>
<activation>
<property>
<name>performRelease</name>
<value>true</value>
</property>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>1.6</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<scm>
<url>https://github.com/redkale/redkale/tags/redkale-1.0.0-rc1</url>
<connection>scm:svn:https://github.com/redkale/redkale/tags/redkale-1.0.0-rc1</connection>
</scm>
<developers>
<developer>
<id>redkale</id>
<name>redkale</name>
<email>redkale@qq.com</email>
</developer>
</developers>
<licenses>
<license>
<name>Apache 2</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
<comments>A business-friendly OSS license</comments>
</license>
</licenses>
<distributionManagement>
<snapshotRepository>
<id>ossrh</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
</snapshotRepository>
<repository>
<id>ossrh</id>
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>
</project>

View File

@@ -10,8 +10,9 @@
<!--
javax.persistence.jdbc.driver在JPA的值是JDBC驱动Redkale有所不同值应该是javax.sql.DataSource的子类。
为了兼容用户习惯Redkale内置常见JDBC驱动到javax.sql.DataSource的映射关系
com.mysql.jdbc.Driver —————— com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource
org.mariadb.jdbc.Driver —————— org.mariadb.jdbc.MySQLDataSource
org.postgresql.Driver —————— org.postgresql.ds.PGConnectionPoolDataSource
com.mysql.jdbc.Driver —————— com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource
oracle.jdbc.driver.OracleDriver —————— oracle.jdbc.pool.OracleConnectionPoolDataSource
com.microsoft.sqlserver.jdbc.SQLServerDriver —————— com.microsoft.sqlserver.jdbc.SQLServerConnectionPoolDataSource
因此 com.mysql.jdbc.Driver 会被自动转换成 com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource
@@ -23,13 +24,13 @@
<!-- 最大连接数默认值CPU数*16 -->
<property name="javax.persistence.connections.limit" value="32"/>
<!-- 包含的SQL模板相当于反向LIKE不同的JDBC驱动的SQL语句不一样Redkale内置了MySQL、Oracle、Sqlserver的语句 -->
<!-- 包含的SQL模板相当于反向LIKE不同的JDBC驱动的SQL语句不一样Redkale内置了MySQL的语句 -->
<property name="javax.persistence.contain.sqltemplate" value="LOCATE(${keystr}, ${column}) > 0"/>
<property name="javax.persistence.notcontain.sqltemplate" value="LOCATE(${keystr}, ${column}) = 0"/>
<!-- 复制表结构的SQL模板Redkale内置了MySQL的语句 -->
<property name="javax.persistence.tablenotexist.sqlstates" value="42000;42S02"/>
<property name="javax.persistence.tablecopy.sqltemplate" value="CREATE TABLE ${newtable} LIKE ${oldtable}"/>
<property name="javax.persistence.tablecopy.sqltemplate" value="CREATE TABLE ${newtable} LIKE ${oldtable}"/>
</properties>
</persistence-unit>

View File

@@ -61,6 +61,13 @@ public @interface Column {
*/
String name() default "";
/**
* (Optional) The comment of the column.
*
* @return String
*/
String comment() default "";
/**
* (Optional) Whether the column is a unique key. This is a
* shortcut for the <code>UniqueConstraint</code> annotation at the table
@@ -96,17 +103,6 @@ public @interface Column {
*/
boolean updatable() default true;
/**
* (Optional) The SQL fragment that is used when
* generating the DDL for the column.
* <p>
* Defaults to the generated SQL to create a
* column of the inferred type.
*
* @return String
*/
String columnDefinition() default "";
/**
* (Optional) The name of the table that contains the column.
* If absent the column is assumed to be in the primary table.

View File

@@ -40,4 +40,11 @@ public @interface Entity {
* @return String
*/
String name() default "";
/**
* (Optional) The comment of the entity.
*
* @return String
*/
String comment() default "";
}

View File

@@ -1,4 +1,4 @@
/*******************************************************************************
/** *****************************************************************************
* Copyright (c) 2008 - 2013 Oracle Corporation. All rights reserved.
*
* This program and the accompanying materials are made available under the
@@ -12,7 +12,7 @@
* Linda DeMichiel - Java Persistence 2.1
* Linda DeMichiel - Java Persistence 2.0
*
******************************************************************************/
***************************************************************************** */
package javax.persistence;
import java.lang.annotation.Target;
@@ -23,13 +23,14 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME;
/**
* Provides for the specification of generation strategies for the
* values of primary keys.
* values of primary keys.
*
* <p> The <code>GeneratedValue</code> annotation
* <p>
* The <code>GeneratedValue</code> annotation
* may be applied to a primary key property or field of an entity or
* mapped superclass in conjunction with the {@link Id} annotation.
* The use of the <code>GeneratedValue</code> annotation is only
* required to be supported for simple primary keys. Use of the
* required to be supported for simple primary keys. Use of the
* <code>GeneratedValue</code> annotation is not supported for derived
* primary keys.
*
@@ -58,22 +59,5 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME;
@Retention(RUNTIME)
public @interface GeneratedValue {
/**
* (Optional) The primary key generation strategy
* that the persistence provider must use to
* generate the annotated entity primary key.
* @return GenerationType
*/
@Deprecated
GenerationType strategy() default GenerationType.AUTO;
/**
* (Optional) The name of the primary key generator
* to use as specified in the SequenceGenerator
* or TableGenerator annotation.
* <p> Defaults to the id generator supplied by persistence provider.
* @return String
*/
@Deprecated
String generator() default "";
}

View File

@@ -1,56 +0,0 @@
/*******************************************************************************
* Copyright (c) 2008 - 2013 Oracle Corporation. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v1.0 and Eclipse Distribution License v. 1.0
* which accompanies this distribution.
* The Eclipse Public License is available at http://www.eclipse.org/legal/epl-v10.html
* and the Eclipse Distribution License is available at
* http://www.eclipse.org/org/documents/edl-v10.php.
*
* Contributors:
* Linda DeMichiel - Java Persistence 2.1
* Linda DeMichiel - Java Persistence 2.0
*
******************************************************************************/
package javax.persistence;
/**
* Defines the types of primary key generation strategies.
*
* @see GeneratedValue
*
* @since Java Persistence 1.0
*/
public enum GenerationType {
/**
* Indicates that the persistence provider must assign
* primary keys for the entity using an underlying
* database table to ensure uniqueness.
*/
TABLE,
/**
* Indicates that the persistence provider must assign
* primary keys for the entity using a database sequence.
*/
SEQUENCE,
/**
* Indicates that the persistence provider must assign
* primary keys for the entity using a database identity column.
*/
IDENTITY,
/**
* Indicates that the persistence provider should pick an
* appropriate strategy for the particular database. The
* <code>AUTO</code> generation strategy may expect a database
* resource to exist, or it may attempt to create one. A vendor
* may provide documentation on how to create such resources
* in the event that it does not support schema generation
* or cannot create the schema resource at runtime.
*/
AUTO
}

View File

@@ -1,4 +1,4 @@
/*******************************************************************************
/** *****************************************************************************
* Copyright (c) 2008 - 2013 Oracle Corporation. All rights reserved.
*
* This program and the accompanying materials are made available under the
@@ -12,7 +12,7 @@
* Linda DeMichiel - Java Persistence 2.1
* Linda DeMichiel - Java Persistence 2.0
*
******************************************************************************/
***************************************************************************** */
package javax.persistence;
import java.lang.annotation.Target;
@@ -22,9 +22,10 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME;
/**
* Specifies the primary table for the annotated entity. Additional
* tables may be specified using SecondaryTable or SecondaryTables annotation.
* tables may be specified using SecondaryTable or SecondaryTables annotation.
*
* <p> If no <code>Table</code> annotation is specified for an entity
* <p>
* If no <code>Table</code> annotation is specified for an entity
* class, the default values apply.
*
* <pre>
@@ -37,27 +38,25 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME;
*
* @since Java Persistence 1.0
*/
@Target(TYPE)
@Target(TYPE)
@Retention(RUNTIME)
public @interface Table {
/**
* (Optional) The name of the table.
* <p> Defaults to the entity name.
* <p>
* Defaults to the entity name.
*
* @return String
*/
String name() default "";
/** (Optional) The catalog of the table.
* <p> Defaults to the default catalog.
* <p>
* Defaults to the default catalog.
*
* @return String
*/
String catalog() default "";
/** (Optional) The schema of the table.
* <p> Defaults to the default schema for user.
* @return String
*/
String schema() default "";
}

View File

@@ -8,6 +8,7 @@ package org.redkale.boot;
import java.io.*;
import java.lang.reflect.*;
import java.util.*;
import javax.persistence.Column;
import org.redkale.convert.json.JsonConvert;
import org.redkale.net.http.*;
import org.redkale.util.*;
@@ -15,6 +16,8 @@ import org.redkale.util.*;
/**
* 继承 HttpBaseServlet 是为了获取 WebAction 信息
*
* 详情见: https://redkale.org
*
* @author zhangjx
*/
public class ApiDocs extends HttpBaseServlet {
@@ -95,7 +98,12 @@ public class ApiDocs extends HttpBaseServlet {
fieldmap.put("type", field.getType().isArray() ? (field.getType().getComponentType().getName() + "[]") : field.getGenericType().getTypeName());
Comment comment = field.getAnnotation(Comment.class);
if (comment != null) fieldmap.put("comment", comment.value());
if (comment != null) {
fieldmap.put("comment", comment.value());
} else {
Column col = field.getAnnotation(Column.class);
if (col != null) fieldmap.put("comment", col.comment());
}
if (servlet.getClass().getAnnotation(Rest.RestDynamic.class) != null) {
if (field.getAnnotation(RestAddress.class) != null) continue;
@@ -140,7 +148,7 @@ public class ApiDocs extends HttpBaseServlet {
}
@Override
public boolean authenticate(int module, int actionid, HttpRequest request, HttpResponse response) throws IOException {
public boolean authenticate(int moduleid, int actionid, HttpRequest request, HttpResponse response) throws IOException {
return true;
}
}

View File

@@ -6,6 +6,7 @@
package org.redkale.boot;
import java.io.*;
import java.lang.reflect.Modifier;
import java.net.*;
import java.nio.ByteBuffer;
import java.nio.channels.*;
@@ -33,7 +34,7 @@ import org.w3c.dom.*;
* <p>
* 进程启动类程序启动后读取application.xml,进行classpath扫描动态加载Service与Servlet 优先加载所有SNCP协议的服务 再加载其他协议服务, 最后进行Service、Servlet与其他资源之间的依赖注入。
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/
@@ -526,6 +527,7 @@ public final class Application {
}
public static <T extends Service> T singleton(String name, Class<T> serviceClass) throws Exception {
if (serviceClass == null) throw new IllegalArgumentException("serviceClass is null");
final Application application = Application.create(true);
application.init();
application.start();
@@ -533,7 +535,9 @@ public final class Application {
T service = server.resourceFactory.find(name, serviceClass);
if (service != null) return service;
}
return null;
if (Modifier.isAbstract(serviceClass.getModifiers())) throw new IllegalArgumentException("abstract class not allowed");
if (serviceClass.isInterface()) throw new IllegalArgumentException("interface class not allowed");
throw new IllegalArgumentException(serviceClass.getName() + " maybe have zero not-final public method");
}
public static Application create(final boolean singleton) throws IOException {

View File

@@ -20,7 +20,7 @@ import org.redkale.util.AnyValue.DefaultAnyValue;
/**
* class过滤器 符合条件的class会保留下来存入FilterEntry。
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <T> 泛型

View File

@@ -11,7 +11,7 @@ import java.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -18,7 +18,7 @@ import java.util.logging.Formatter;
/**
* 自定义的日志输出类
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -22,7 +22,7 @@ import org.redkale.util.*;
* HTTP Server节点的配置Server
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/
@@ -189,7 +189,9 @@ public class NodeHttpServer extends NodeServer {
for (int i = 0; i < mappings.length; i++) {
mappings[i] = prefix + mappings[i];
}
ss.add(new AbstractMap.SimpleEntry<>(servlet.getClass().getName(), mappings));
if (servlet.getClass().getSimpleName().charAt(0) != '_') {
ss.add(new AbstractMap.SimpleEntry<>(servlet.getClass().getName(), mappings));
}
}
});
//输出信息

View File

@@ -11,7 +11,7 @@ import org.redkale.service.Service;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -11,7 +11,7 @@ import java.lang.annotation.*;
* 根据application.xml中的server节点中的protocol值来适配Server的加载逻辑
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -31,7 +31,7 @@ import org.redkale.util.*;
* Server节点的初始化配置类
*
*
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -15,7 +15,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -10,7 +10,7 @@ import java.lang.reflect.Type;
/**
* 对不明类型的对象进行序列化; BSON序列化时将对象的类名写入WriterJSON则不写入。
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <T> 序列化的泛型类型

View File

@@ -14,7 +14,7 @@ import java.util.*;
* 支持一定程度的泛型。
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <T> 反解析的数组元素类型

View File

@@ -13,7 +13,7 @@ import java.lang.reflect.*;
* 支持一定程度的泛型。
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <T> 序列化的数组元素类型

View File

@@ -16,7 +16,7 @@ import java.util.Collection;
* 支持一定程度的泛型。
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <T> 反解析的集合元素类型

View File

@@ -13,7 +13,7 @@ import java.util.Collection;
* 集合大小不能超过 32767。 在BSON中集合大小设定的是short对于大于32767长度的集合传输会影响性能所以没有采用int存储。
* 支持一定程度的泛型。
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <T> 序列化的集合元素类型
*/

View File

@@ -9,7 +9,7 @@ package org.redkale.convert;
* 序列化操作类
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类

View File

@@ -13,7 +13,7 @@ import static java.lang.annotation.RetentionPolicy.*;
* 依附在setter、getter方法、字段进行简单的配置
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -8,7 +8,7 @@ package org.redkale.convert;
/**
* ConvertColumn 对应的实体类
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
*/
public final class ConvertColumnEntry {

View File

@@ -12,7 +12,7 @@ import static java.lang.annotation.RetentionPolicy.*;
/**
* ConvertColumn 的多用类
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
*/
@Inherited

View File

@@ -14,7 +14,7 @@ import java.lang.annotation.*;
* 该值必须是全局唯一
* 使用场景: 当BSON序列化为了不指定class可以使用@ConvertEntity来取个别名。关联方法: Reader.readClassName() 和 Writer.writeClassName(String value) 。
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
*/
@Inherited

View File

@@ -6,7 +6,7 @@ package org.redkale.convert;
/**
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
*/
public class ConvertException extends RuntimeException {

View File

@@ -19,7 +19,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类

View File

@@ -7,7 +7,7 @@ package org.redkale.convert;
/**
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
*/
public enum ConvertType {

View File

@@ -11,7 +11,7 @@ import org.redkale.util.Attribute;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类

View File

@@ -10,7 +10,7 @@ import java.lang.reflect.Type;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类

View File

@@ -11,7 +11,7 @@ import org.redkale.util.Attribute;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <W> Writer输出的子类

View File

@@ -10,7 +10,7 @@ import java.lang.reflect.Type;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <W> Writer输出的子类

View File

@@ -12,7 +12,7 @@ import java.util.Map;
/**
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <K> Map key的数据类型
* @param <V> Map value的数据类型

View File

@@ -12,7 +12,7 @@ import java.util.Map;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <K> Map key的数据类型

View File

@@ -15,7 +15,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类

View File

@@ -12,7 +12,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <W> Writer输出的子类

View File

@@ -8,7 +8,7 @@ package org.redkale.convert;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -11,7 +11,7 @@ import java.lang.reflect.Type;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类

View File

@@ -10,7 +10,7 @@ import org.redkale.util.Attribute;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -11,6 +11,8 @@ import static org.redkale.convert.Reader.SIGN_NULL;
import org.redkale.util.*;
/**
*
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -11,7 +11,7 @@ import java.util.function.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -33,7 +33,7 @@ import org.redkale.util.*;
*
* </pre></blockquote>
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -11,7 +11,7 @@ import org.redkale.convert.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -14,7 +14,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -10,7 +10,7 @@ import org.redkale.convert.SimpledCoder;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <T> 序列化/反解析的数据类型

View File

@@ -9,6 +9,8 @@ import java.io.*;
import org.redkale.convert.*;
/**
*
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -9,6 +9,8 @@ import java.io.*;
import org.redkale.convert.*;
/**
*
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -13,7 +13,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -14,7 +14,7 @@ import java.math.BigInteger;
* BigInteger 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.Writer;
* boolean[] 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.Writer;
* boolean 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.Writer;
* byte[] 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.Writer;
* byte 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* char[] 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -10,7 +10,7 @@ import org.redkale.convert.*;
/**
* CharSequence 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.Writer;
/**
* char 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.*;
* java.nio.channels.CompletionHandler 的SimpledCoder实现, 只输出null
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -14,7 +14,7 @@ import org.redkale.util.*;
* Dlong 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -14,7 +14,7 @@ import java.util.Date;
* Date 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* double[] 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* double 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.Writer;
* 枚举 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* float[] 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* float 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -14,7 +14,7 @@ import java.net.*;
* InetAddress 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* int[] 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* int 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.Writer;
* long[] 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.Writer;
/**
* long 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.Writer;
* Number 的SimpledCoder实现
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -11,7 +11,7 @@ import org.redkale.convert.*;
/**
* Pattern 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* short[] 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* short 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* String[] 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -12,7 +12,7 @@ import org.redkale.convert.Writer;
/**
* String 的SimpledCoder实现
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
* @param <R> Reader输入的子类型
* @param <W> Writer输出的子类型

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.SimpledCoder;
* Type 的SimpledCoder实现 只支持Type的子类Class
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -11,7 +11,7 @@ import org.redkale.convert.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -11,7 +11,7 @@ import org.redkale.convert.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <R> Reader输入的子类型

View File

@@ -11,7 +11,10 @@ import org.redkale.convert.*;
import static org.redkale.convert.Reader.*;
/**
*
* 只支持UTF-8格式
*
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -15,7 +15,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -16,7 +16,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -15,7 +15,7 @@ import org.redkale.util.DLong;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -12,7 +12,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -10,7 +10,7 @@ import org.redkale.convert.SimpledCoder;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <T> 序列化/反解析的数据类型

View File

@@ -10,6 +10,8 @@ import org.redkale.convert.*;
/**
*
* 详情见: https://redkale.org
*
* @author zhangjx
*/
class JsonStreamReader extends JsonByteBufferReader {

View File

@@ -13,6 +13,8 @@ import org.redkale.util.*;
/**
*
* 详情见: https://redkale.org
*
* @author zhangjx
*/
class JsonStreamWriter extends JsonByteBufferWriter {

View File

@@ -13,7 +13,7 @@ import org.redkale.util.*;
*
* writeTo系列的方法输出的字符不能含特殊字符
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -15,7 +15,7 @@ import java.util.concurrent.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

View File

@@ -18,7 +18,7 @@ import org.redkale.watch.*;
/**
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
*/
public class Context {

View File

@@ -12,7 +12,7 @@ import org.redkale.util.*;
/**
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
*/
@SuppressWarnings("unchecked")
@@ -34,7 +34,7 @@ public final class PrepareRunner implements Runnable {
public void run() {
final PrepareServlet prepare = context.prepare;
final ObjectPool<? extends Response> responsePool = context.responsePool;
if (data != null) {
if (data != null) { //BIO模式的UDP连接创建AsyncConnection时已经获取到ByteBuffer数据了
final Response response = responsePool.get();
response.init(channel);
try {

View File

@@ -16,7 +16,7 @@ import org.redkale.util.*;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <K> SessionID的类型

View File

@@ -14,7 +14,7 @@ import java.util.concurrent.*;
/**
*
* <p> 详情见: http://redkale.org
* <p> 详情见: https://redkale.org
* @author zhangjx
*/
public abstract class ProtocolServer {

View File

@@ -13,7 +13,7 @@ import org.redkale.convert.json.JsonConvert;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <C> Context子类型

View File

@@ -12,7 +12,7 @@ import java.util.function.BiConsumer;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <C> Context的子类型

View File

@@ -20,7 +20,7 @@ import org.redkale.watch.WatchFactory;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <K> 请求ID的数据类型 例如HTTP协议请求标识为url请求ID的数据类型就是String
@@ -144,11 +144,15 @@ public abstract class Server<K extends Serializable, C extends Context, R extend
public Logger getLogger() {
return this.logger;
}
public PrepareServlet<K, C, R, P, S> getPrepareServlet(){
public PrepareServlet<K, C, R, P, S> getPrepareServlet() {
return this.prepare;
}
public C getContext() {
return this.context;
}
@SuppressWarnings("unchecked")
public void addServlet(S servlet, final Object attachment, AnyValue conf, K... mappings) {
this.prepare.addServlet(servlet, attachment, conf, mappings);

View File

@@ -11,7 +11,7 @@ import java.io.IOException;
/**
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
* @param <C> Context的子类型

View File

@@ -19,7 +19,7 @@ import org.redkale.watch.WatchFactory;
* 传输客户端
*
* <p>
* 详情见: http://redkale.org
* 详情见: https://redkale.org
*
* @author zhangjx
*/

Some files were not shown because too many files have changed in this diff Show More